Skip to main content
Cornell University
We gratefully acknowledge support from the Simons Foundation, member institutions, and all contributors. Donate
arxiv logo > cs > arXiv:2204.10455

Help | Advanced Search

arXiv logo
Cornell University Logo

quick links

  • Login
  • Help Pages
  • About

Computer Science > Programming Languages

arXiv:2204.10455 (cs)
[Submitted on 22 Apr 2022 (v1), last revised 25 Sep 2022 (this version, v4)]

Title:Optimal Heap Limits for Reducing Browser Memory Use

Authors:Marisa Kirisame, Pranav Shenoy, Pavel Panchekha
View a PDF of the paper titled Optimal Heap Limits for Reducing Browser Memory Use, by Marisa Kirisame and 2 other authors
View PDF
Abstract:Garbage-collected language runtimes carefully tune heap limits to reduce garbage collection time and memory usage. However, there's a trade-off: a lower heap limit reduces memory use but increases garbage collection time. Classic methods for setting heap limits include manually tuned heap limits and multiple-of-live-size rules of thumb, but it is not clear when one rule is better than another or how to compare them.
We address this problem with a new framework where heap limits are set for multiple heaps at once. Our key insight is that every heap limit rule induces a particular allocation of memory across multiple processes, and this allocation can be sub-optimal. We use our framework to derive an optimal "square-root" heap limit rule, which minimizes total memory usage for any amount of total garbage collection time. Paradoxically, the square-root heap limit rule achieves this coordination without communication: it allocates memory optimally across multiple heaps without requiring any communication between those heaps.
To demonstrate that this heap limit rule is effective, we prototype it for V8, the JavaScript runtime used in Google Chrome, Microsoft Edge, and other browsers, as well as in server-side frameworks like this http URL and Deno. On real-world web pages, our prototype achieves reductions of approximately 16.0% of memory usage while keeping garbage collection time constant. On memory-intensive benchmarks, reductions of up to 30.0% of garbage collection time are possible with no change in total memory usage.
Subjects: Programming Languages (cs.PL); Systems and Control (eess.SY)
Cite as: arXiv:2204.10455 [cs.PL]
  (or arXiv:2204.10455v4 [cs.PL] for this version)
  https://doi.org/10.48550/arXiv.2204.10455
arXiv-issued DOI via DataCite

Submission history

From: Marisa Kirisame [view email]
[v1] Fri, 22 Apr 2022 01:26:48 UTC (523 KB)
[v2] Wed, 27 Apr 2022 09:27:34 UTC (523 KB)
[v3] Fri, 16 Sep 2022 16:59:32 UTC (629 KB)
[v4] Sun, 25 Sep 2022 06:22:19 UTC (629 KB)
Full-text links:

Access Paper:

    View a PDF of the paper titled Optimal Heap Limits for Reducing Browser Memory Use, by Marisa Kirisame and 2 other authors
  • View PDF
  • TeX Source
  • Other Formats
view license
Current browse context:
cs.PL
< prev   |   next >
new | recent | 2022-04
Change to browse by:
cs
cs.SY
eess
eess.SY

References & Citations

  • NASA ADS
  • Google Scholar
  • Semantic Scholar
a export BibTeX citation Loading...

BibTeX formatted citation

×
Data provided by:

Bookmark

BibSonomy logo Reddit logo

Bibliographic and Citation Tools

Bibliographic Explorer (What is the Explorer?)
Connected Papers (What is Connected Papers?)
Litmaps (What is Litmaps?)
scite Smart Citations (What are Smart Citations?)

Code, Data and Media Associated with this Article

alphaXiv (What is alphaXiv?)
CatalyzeX Code Finder for Papers (What is CatalyzeX?)
DagsHub (What is DagsHub?)
Gotit.pub (What is GotitPub?)
Hugging Face (What is Huggingface?)
Papers with Code (What is Papers with Code?)
ScienceCast (What is ScienceCast?)

Demos

Replicate (What is Replicate?)
Hugging Face Spaces (What is Spaces?)
TXYZ.AI (What is TXYZ.AI?)

Recommenders and Search Tools

Influence Flower (What are Influence Flowers?)
CORE Recommender (What is CORE?)
  • Author
  • Venue
  • Institution
  • Topic

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? | Disable MathJax (What is MathJax?)
  • About
  • Help
  • contact arXivClick here to contact arXiv Contact
  • subscribe to arXiv mailingsClick here to subscribe Subscribe
  • Copyright
  • Privacy Policy
  • Web Accessibility Assistance
  • arXiv Operational Status
    Get status notifications via email or slack