Reusing Just-in-Time Compiled Code
Meetesh Kalpesh Mehta, Sebastián Krynski, Hugo Musso Gualandi, Manas Thakur, Jan Vitek
Abstract
Most code is executed more than once. If not entire programs then libraries remain unchanged from one run to the next. Just-in-time compilers expend considerable effort gathering insights about code they compiled many times, and often end up generating the same binary over and over again. We explore how to reuse compiled code across runs of different programs to reduce warm-up costs of dynamic languages. We propose to use speculative contextual dispatch to select versions of functions from an off-line curated code repository. That repository is a persistent database of previously compiled functions indexed by the context under which they were compiled. The repository is curated to remove redundant code and to optimize dispatch. We assess practicality by extending Ř, a compiler for the R language, and evaluating its performance. Our results suggest that the approach improves warmup times while preserving peak performance.
CCS Concepts: • Software and its engineering → Just-in-time compilers; Dynamic analysis.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext b2ae7cb5-5f37-4d5f-99e6-b311b46ce92eCited by top-tier papers1
Ask how each one uses itBuilds on3
- Contextual dispatch for function specializationOlivier Flückiger, Guido Chari, Ming-Ho Yee, Jan Jecmen et al.OOPSLA 2020 · 31 citations
- JITServer: Disaggregated Caching JIT Compiler for the JVM in the CloudAlexey Khrabrov, Marius Pirvu, Vijay Sundaresan, Eyal de LaraUSENIX ATC 2022 · 16 citations
- Deoptless: speculation with dispatched on-stack replacement and specialized continuationsOlivier Flückiger, Jan Jecmen, Sebastián Krynski, Jan VitekPLDI 2022 · 5 citations
Related papers
- Adaptive Code Generation for Data-Intensive AnalyticsWangda Zhang, Junyoung Kim, Kenneth A. Ross, Eric Sedlar et al.VLDB 2021 · 12 citations
- Formally verified speculation and deoptimization in a JIT compilerAurèle Barrière, Sandrine Blazy, Olivier Flückiger, David Pichardie et al.POPL 2021 · 38 citations
- What we eval in the shadows: a large-scale study of eval in R programsAviral Goel, Pierre Donat-Bouillud, Filip Krikava, Christoph M. Kirsch et al.OOPSLA 2021 · 3 citations
- Wax: Optimizing Data Center Applications With Stale ProfileTawhid Bhuiyan, Sumya Hoque, Angelica Aparecida Moreira, Tanvir Ahmed KhanASPLOS 2026 · 1 citation
- Permutable Compiled Queries: Dynamically Adapting Compiled Queries without RecompilingPrashanth Menon, Amadou Ngom, Todd C. Mowry, Andrew Pavlo et al.VLDB 2021 · 26 citations
