[2608.14471] Memory Allocation for Constant-Bounded Programs
Skip to main content
Search arXiv
Press Enter to search · Advanced search
-->
Computer Science > Programming Languages
arXiv:2608.14471 (cs)
[Submitted on 14 Aug 2026]
Title:Memory Allocation for Constant-Bounded Programs
Authors:Vinícius Silva, Kael Soares, Márcio Costa e Fernando Magno Quintão Pereira<br>View a PDF of the paper titled Memory Allocation for Constant-Bounded Programs, by Vin\'icius Silva and 2 other authors
View PDF<br>HTML (experimental)
Abstract:This work studies memory allocation for constant-bounded programs, whose execution length is syntactically limited for all inputs. Examples of such programs include verified kernel extensions, cryptographic routines, and fixed-shape machine-learning models. We show that constant boundedness enables a tight, polynomial-time approximation of optimal stack usage by viewing control flow as a tree and applying a tree-scan allocation strategy augmented with memory defragmentation. Our approach guarantees memory usage bounded by the maximum live memory plus, at most, the size of the largest buffer, and is optimal when in-place swapping is permitted. We deploy the proposed allocator in two scenarios. First, in an Elixir-to-eBPF compiler, as a spiller that optimizes stack space. Second, as a static heap allocator for bounded MLIR programs using the Structured Control-Flow dialect. Results demonstrate stack reductions exceeding 90% on real eBPF workloads and show that, even under aggressive code expansion, defragmentation is rarely required and memory usage remains a small fraction of that required by naive allocation strategies.
Comments:<br>13 pages, 13 figures
Subjects:
Programming Languages (cs.PL)
MSC classes:<br>68N15
ACM classes:<br>D.3.4
Cite as:<br>arXiv:2608.14471 [cs.PL]
(or<br>arXiv:2608.14471v1 [cs.PL] for this version)
https://doi.org/10.48550/arXiv.2608.14471
Focus to learn more
arXiv-issued DOI via DataCite (pending registration)
Submission history<br>From: Fernando Quintao Pereira [view email]<br>[v1]<br>Fri, 14 Aug 2026 16:52:25 UTC (546 KB)
Full-text links:<br>Access Paper:
View a PDF of the paper titled Memory Allocation for Constant-Bounded Programs, by Vin\'icius Silva and 2 other authors<br>View PDF<br>HTML (experimental)<br>TeX Source
view license
Current browse context:
cs.PL
next >
new<br>recent<br>| 2026-08
Change to browse by:
cs
References & Citations
NASA ADS<br>Google Scholar
Semantic Scholar
export BibTeX citation<br>Loading...
BibTeX formatted citation
×
loading...
Data provided by:
Bookmark
Bibliographic Tools
Bibliographic and Citation Tools
Bibliographic Explorer Toggle
Bibliographic Explorer (What is the Explorer?)
Connected Papers Toggle
Connected Papers (What is Connected Papers?)
Litmaps Toggle
Litmaps (What is Litmaps?)
scite.ai Toggle
scite Smart Citations (What are Smart Citations?)
Code, Data, Media
Code, Data and Media Associated with this Article
alphaXiv Toggle
alphaXiv (What is alphaXiv?)
Links to Code Toggle
CatalyzeX Code Finder for Papers (What is CatalyzeX?)
DagsHub Toggle
DagsHub (What is DagsHub?)
GotitPub Toggle
Gotit.pub (What is GotitPub?)
Huggingface Toggle
Hugging Face (What is Huggingface?)
ScienceCast Toggle
ScienceCast (What is ScienceCast?)
Demos
Demos
Replicate Toggle
Replicate (What is Replicate?)
Spaces Toggle
Hugging Face Spaces (What is Spaces?)
Spaces Toggle
TXYZ.AI (What is TXYZ.AI?)
Related Papers
Recommenders and Search Tools
Link to Influence Flower
Influence Flower (What are Influence Flowers?)
Core recommender toggle
CORE Recommender (What is CORE?)
Author
Venue
Institution
Topic
About arXivLabs
arXivLabs: experimental projects with community collaborators
arXivLabs is a framework that allows collaborators to develop and share new arXiv features directly on our website.
Both individuals and organizations that work with arXivLabs have embraced and accepted our values of openness, community, excellence, and user data privacy. arXiv is committed to these values and only works with partners that adhere to them.
Have an idea for a project that will add value for arXiv's community? Learn more about arXivLabs .
Which authors of this paper are endorsers? |<br>Disable MathJax (What is MathJax?)
Major funding support from