{"status":"ok","message-type":"work","message-version":"1.0.0","message":{"indexed":{"date-parts":[[2026,8,7]],"date-time":"2026-08-07T15:58:22Z","timestamp":1786118302697,"version":"build-2736575974"},"reference-count":70,"publisher":"Association for Computing Machinery (ACM)","issue":"3","license":[{"start":{"date-parts":[[2026,8,6]],"date-time":"2026-08-06T00:00:00Z","timestamp":1785974400000},"content-version":"vor","delay-in-days":0,"URL":"https:\/\/creativecommons.org\/licenses\/by-nc-nd\/4.0\/legalcode"}],"content-domain":{"domain":["dl.acm.org"],"crossmark-restriction":true},"short-container-title":["ACM Trans. Archit. Code Optim."],"published-print":{"date-parts":[[2026,9,30]]},"abstract":"<jats:p>To improve a program\u2019s performance and avoid excessive binary-size growth, compiler optimizations can be applied on only the most frequently executed parts of the program, i.e., hot code. Ahead-of-time (AOT) compilation can benefit from profiles to determine the hot code, and to improve optimization decisions with respect to code hotness. In this article, we present a novel technique for reducing the size of AOT compiled programs by using fully-context-sensitive profiles to concentrate the optimizations on the hot code. These profiles enable capturing different behaviors of the same subroutine when invoked from different calling contexts. We use this information to identify those subroutines that contribute significantly to the program\u2019s performance and compile them differently according to their calling contexts. We implemented this technique inside GraalVM Native Image, a state-of-the-art AOT compiler for Java, and performed an evaluation on 29 benchmarks from DaCapo, Scalabench, and Renaissance benchmarking suites. With this selective subroutine specialization, we achieved significant binary-size reductions, ranging from 11% to 38% compared to the Enterprise version of GraalVM Native Image with PGO, while retaining similar performance as the O3 optimization level with PGO.<\/jats:p>","DOI":"10.1145\/3830016","type":"journal-article","created":{"date-parts":[[2026,7,20]],"date-time":"2026-07-20T10:53:44Z","timestamp":1784544824000},"page":"1-27","update-policy":"https:\/\/doi.org\/10.1145\/crossmark-policy","source":"Crossref","is-referenced-by-count":0,"title":["Context-Aware Inlining: Using Call-Stack Profiles for Fast and Smaller Binaries"],"prefix":"10.1145","volume":"23","author":[{"ORCID":"https:\/\/orcid.org\/0000-0003-0647-1922","authenticated-orcid":false,"given":"Maja","family":"Vukasovi\u0107","sequence":"first","affiliation":[{"name":"The Department of Computer Science and Information Technology, University of Belgrade School of Electrical Engineering","place":["Belgrade, Serbia"]}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0009-0004-7169-4422","authenticated-orcid":false,"given":"Petar","family":"\u0110ekanovi\u0107","sequence":"additional","affiliation":[{"name":"The Department of Computer Science and Information Technology, University of Belgrade School of Electrical Engineering","place":["Belgrade, Serbia"]},{"name":"Oracle Srbija & Crna Gora doo","place":["Belgrade, Serbia"]}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0009-0008-0105-6280","authenticated-orcid":false,"given":"Boris","family":"Spasojevi\u0107","sequence":"additional","affiliation":[{"name":"Oracle Software Technology GmbH","place":["Geneva, Switzerland"]}],"role":[{"vocabulary":"crossref","role":"author"}]},{"ORCID":"https:\/\/orcid.org\/0000-0003-0260-2729","authenticated-orcid":false,"given":"Aleksandar","family":"Prokopec","sequence":"additional","affiliation":[{"name":"Oracle Software Technology GmbH","place":["Geneva, Switzerland"]}],"role":[{"vocabulary":"crossref","role":"author"}]}],"member":"320","published-online":{"date-parts":[[2026,8,6]]},"reference":[{"key":"e_1_3_1_2_2","doi-asserted-by":"publisher","DOI":"10.1007\/BFb0053060"},{"key":"e_1_3_1_3_2","doi-asserted-by":"publisher","DOI":"10.1145\/960116.54014"},{"key":"e_1_3_1_4_2","doi-asserted-by":"publisher","DOI":"10.1147\/sj.391.0211"},{"key":"e_1_3_1_5_2","doi-asserted-by":"publisher","DOI":"10.1007\/978-3-540-24851-4_8"},{"key":"e_1_3_1_6_2","doi-asserted-by":"publisher","DOI":"10.1145\/277650.277665"},{"key":"e_1_3_1_7_2","doi-asserted-by":"publisher","DOI":"10.1145\/351397.351416"},{"key":"e_1_3_1_8_2","doi-asserted-by":"publisher","DOI":"10.1109\/JPROC.2004.840305"},{"key":"e_1_3_1_9_2","doi-asserted-by":"publisher","DOI":"10.1145\/583854.582432"},{"key":"e_1_3_1_10_2","doi-asserted-by":"publisher","DOI":"10.1145\/2384616.2384679"},{"key":"e_1_3_1_11_2","doi-asserted-by":"publisher","DOI":"10.1145\/258916.258928"},{"key":"e_1_3_1_12_2","doi-asserted-by":"publisher","DOI":"10.1145\/197405.197406"},{"key":"e_1_3_1_13_2","doi-asserted-by":"publisher","DOI":"10.1145\/349299.349303"},{"key":"e_1_3_1_14_2","doi-asserted-by":"publisher","DOI":"10.1145\/3763103"},{"key":"e_1_3_1_15_2","doi-asserted-by":"publisher","DOI":"10.1145\/1167515.1167488"},{"key":"e_1_3_1_16_2","doi-asserted-by":"publisher","DOI":"10.1145\/73141.74831"},{"key":"e_1_3_1_17_2","doi-asserted-by":"publisher","DOI":"10.1002\/spe.4380211204"},{"key":"e_1_3_1_18_2","doi-asserted-by":"publisher","DOI":"10.1016\/0096-0551(93)90005-L"},{"key":"e_1_3_1_19_2","unstructured":"Oracle Corporation. 2025. Project Crema: Open World for Native Image. Retrieved February 24 2026 from https:\/\/github.com\/oracle\/graal\/issues\/11327"},{"key":"e_1_3_1_20_2","volume-title":"An Aggressive Approach to Loop Unrolling","author":"Davidson Jack W.","year":"1995","unstructured":"Jack W. Davidson and Sanjay Jinturkar. 1995. An Aggressive Approach to Loop Unrolling. Technical Report. Citeseer."},{"key":"e_1_3_1_21_2","doi-asserted-by":"publisher","DOI":"10.5555\/925015"},{"key":"e_1_3_1_22_2","doi-asserted-by":"publisher","DOI":"10.1007\/3-540-48743-3_12"},{"key":"e_1_3_1_23_2","doi-asserted-by":"publisher","DOI":"10.1145\/3238147.3241533"},{"key":"e_1_3_1_24_2","doi-asserted-by":"publisher","DOI":"10.1145\/356989.357008"},{"key":"e_1_3_1_25_2","doi-asserted-by":"publisher","DOI":"10.1145\/3428288"},{"key":"e_1_3_1_26_2","doi-asserted-by":"publisher","DOI":"10.1145\/1134760.1134780"},{"key":"e_1_3_1_27_2","doi-asserted-by":"publisher","DOI":"10.1145\/1297105.1297033"},{"key":"e_1_3_1_28_2","doi-asserted-by":"publisher","DOI":"10.1145\/217838.217848"},{"key":"e_1_3_1_29_2","volume-title":"Managing Interprocedural Optimization","author":"Hall Mary Wolcott","year":"1991","unstructured":"Mary Wolcott Hall. 1991. Managing Interprocedural Optimization. Ph. D. Dissertation. Rice University."},{"key":"e_1_3_1_30_2","doi-asserted-by":"publisher","DOI":"10.1109\/CGO.2003.1191550"},{"key":"e_1_3_1_31_2","doi-asserted-by":"publisher","DOI":"10.1109\/CGO57630.2024.10444807"},{"key":"e_1_3_1_32_2","doi-asserted-by":"publisher","DOI":"10.1145\/2647508.2647509"},{"key":"e_1_3_1_33_2","doi-asserted-by":"publisher","DOI":"10.5555\/646149.679193"},{"key":"e_1_3_1_34_2","doi-asserted-by":"publisher","DOI":"10.1145\/178243.178478"},{"key":"e_1_3_1_35_2","doi-asserted-by":"publisher","DOI":"10.1109\/ASSET.1999.756775"},{"key":"e_1_3_1_36_2","doi-asserted-by":"publisher","DOI":"10.1145\/1133956.1133980"},{"key":"e_1_3_1_37_2","doi-asserted-by":"publisher","DOI":"10.1145\/353171.353191"},{"key":"e_1_3_1_38_2","article-title":"Loop optimizations in modern C compilers","volume":"15","author":"Jubb Chae","year":"2014","unstructured":"Chae Jubb. 2014. Loop optimizations in modern C compilers. Columbia University, New York, str 15 (2014).","journal-title":"Columbia University, New York, str"},{"key":"e_1_3_1_39_2","doi-asserted-by":"publisher","DOI":"10.1145\/778559.778562"},{"key":"e_1_3_1_40_2","doi-asserted-by":"publisher","DOI":"10.1002\/spe.4380010203"},{"key":"e_1_3_1_41_2","doi-asserted-by":"publisher","DOI":"10.1109\/CGO.2003.1191534"},{"key":"e_1_3_1_42_2","doi-asserted-by":"publisher","DOI":"10.1145\/3168811"},{"key":"e_1_3_1_43_2","unstructured":"Bingxin Liu Yinghui Huang Jianhua Gao Jianjun Shi Yongpeng Liu Yipin Sun and Weixing Ji. 2025. From profiling to optimization: Unveiling the profile guided optimization. arXiv:2507.16649. Retrieved from https:\/\/arxiv.org\/abs\/2507.16649"},{"key":"e_1_3_1_44_2","doi-asserted-by":"publisher","DOI":"10.1145\/300979.300991"},{"key":"e_1_3_1_45_2","doi-asserted-by":"publisher","DOI":"10.1145\/1806799.1806808"},{"key":"e_1_3_1_46_2","first-page":"427","volume-title":"Proceedings of the IARCS Annual Conference on Foundations of Software Technology and Theoretical Computer Science (2009)","author":"Odersky Martin","year":"2009","unstructured":"Martin Odersky and Adriaan Moors. 2009. Fighting bit rot with types (experience report: Scala collections). In Proceedings of the IARCS Annual Conference on Foundations of Software Technology and Theoretical Computer Science (2009). Schloss Dagstuhl\u2013Leibniz-Zentrum f\u00fcr Informatik, 427\u2013451."},{"key":"e_1_3_1_47_2","doi-asserted-by":"publisher","DOI":"10.1145\/3135932.3135947"},{"key":"e_1_3_1_48_2","first-page":"1","volume-title":"Proceedings of the 2001 Symposium on JavaTM Virtual Machine Research and Technology Symposium - Volume 1 (JVM\u201901)","author":"Paleczny Michael","year":"2001","unstructured":"Michael Paleczny, Christopher Vick, and Cliff Click. 2001. The Java hotspotTM server compiler. In Proceedings of the 2001 Symposium on JavaTM Virtual Machine Research and Technology Symposium - Volume 1 (JVM\u201901). USENIX Association, USA, 1."},{"key":"e_1_3_1_49_2","doi-asserted-by":"publisher","DOI":"10.1145\/93542.93550"},{"key":"e_1_3_1_50_2","doi-asserted-by":"publisher","DOI":"10.1145\/3428235"},{"key":"e_1_3_1_51_2","doi-asserted-by":"publisher","DOI":"10.1109\/CGO.2019.8661171"},{"key":"e_1_3_1_52_2","doi-asserted-by":"publisher","DOI":"10.1145\/3136000.3136002"},{"key":"e_1_3_1_53_2","doi-asserted-by":"publisher","DOI":"10.1145\/3314221.3314637"},{"key":"e_1_3_1_54_2","doi-asserted-by":"publisher","DOI":"10.1145\/1273440.1250709"},{"key":"e_1_3_1_55_2","doi-asserted-by":"publisher","DOI":"10.1109\/MICRO.2006.49"},{"key":"e_1_3_1_56_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICSE.2001.919096"},{"key":"e_1_3_1_57_2","doi-asserted-by":"publisher","DOI":"10.1145\/359810.359830"},{"key":"e_1_3_1_58_2","doi-asserted-by":"publisher","DOI":"10.1145\/772970.772975"},{"key":"e_1_3_1_59_2","doi-asserted-by":"publisher","DOI":"10.1109\/CGO.2009.12"},{"key":"e_1_3_1_60_2","doi-asserted-by":"publisher","DOI":"10.1145\/2048066.2048118"},{"key":"e_1_3_1_61_2","doi-asserted-by":"publisher","DOI":"10.1145\/3241653.3241660"},{"key":"e_1_3_1_62_2","doi-asserted-by":"publisher","DOI":"10.1109\/ICAPP.2002.1173607"},{"key":"e_1_3_1_63_2","doi-asserted-by":"publisher","DOI":"10.1109\/TELFOR.2011.6143851"},{"key":"e_1_3_1_64_2","doi-asserted-by":"publisher","DOI":"10.1145\/2892208.2892225"},{"key":"e_1_3_1_65_2","doi-asserted-by":"publisher","DOI":"10.1145\/2581122.2544157"},{"key":"e_1_3_1_66_2","doi-asserted-by":"publisher","DOI":"10.5555\/648042.744889"},{"key":"e_1_3_1_67_2","doi-asserted-by":"publisher","DOI":"10.1145\/3612937"},{"key":"e_1_3_1_68_2","doi-asserted-by":"publisher","DOI":"10.1109\/TELFOR63250.2024.10819162"},{"key":"e_1_3_1_69_2","doi-asserted-by":"publisher","DOI":"10.1145\/3563838.3567677"},{"key":"e_1_3_1_70_2","unstructured":"Baptiste Wicht Roberto A. Vitillo Dehao Chen and David Levinthal. 2014. Hardware counted profile-guided optimization. arXiv:1411.6361. Retrieved from https:\/\/arxiv.org\/abs\/1411.6361"},{"key":"e_1_3_1_71_2","doi-asserted-by":"publisher","DOI":"10.1007\/11532378_3"}],"container-title":["ACM Transactions on Architecture and Code Optimization"],"original-title":[],"language":"en","link":[{"URL":"https:\/\/dl.acm.org\/doi\/pdf\/10.1145\/3830016","content-type":"unspecified","content-version":"vor","intended-application":"similarity-checking"}],"deposited":{"date-parts":[[2026,8,6]],"date-time":"2026-08-06T15:43:58Z","timestamp":1786031038000},"score":1,"resource":{"primary":{"URL":"https:\/\/dl.acm.org\/doi\/10.1145\/3830016"}},"subtitle":[],"short-title":[],"issued":{"date-parts":[[2026,8,6]]},"references-count":70,"journal-issue":{"issue":"3","published-print":{"date-parts":[[2026,9,30]]}},"alternative-id":["10.1145\/3830016"],"URL":"https:\/\/doi.org\/10.1145\/3830016","relation":{},"ISSN":["1544-3566","1544-3973"],"issn-type":[{"value":"1544-3566","type":"print"},{"value":"1544-3973","type":"electronic"}],"subject":[],"published":{"date-parts":[[2026,8,6]]},"assertion":[{"value":"2025-11-25","order":0,"name":"received","label":"Received","group":{"name":"publication_history","label":"Publication History"}},{"value":"2026-06-24","order":2,"name":"accepted","label":"Accepted","group":{"name":"publication_history","label":"Publication History"}},{"value":"2026-08-06","order":3,"name":"published","label":"Published","group":{"name":"publication_history","label":"Publication History"}}]}}