[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"detail-sidebar-cat-0-en-105":3,"doc-seo-327178-105":59,"doc-detail-327178-en":131,"doc-similar-327178":164},{"code":4,"msg":5,"data":6},0,"success",[7,13,18,23,28,33,38,43,48,51,55],{"id":8,"doc_module":4,"doc_module_name":9,"category_name":10,"show_sort_weight":11,"slug":12},1,"Document","Story & Novel",90,"story-novel",{"id":14,"doc_module":4,"doc_module_name":9,"category_name":15,"show_sort_weight":16,"slug":17},2,"Literature",80,"literature",{"id":19,"doc_module":4,"doc_module_name":9,"category_name":20,"show_sort_weight":21,"slug":22},4,"Exam",70,"exam",{"id":24,"doc_module":4,"doc_module_name":9,"category_name":25,"show_sort_weight":26,"slug":27},5,"Comic",60,"comic",{"id":29,"doc_module":4,"doc_module_name":9,"category_name":30,"show_sort_weight":31,"slug":32},6,"Technology",50,"technology",{"id":34,"doc_module":4,"doc_module_name":9,"category_name":35,"show_sort_weight":36,"slug":37},7,"Healthcare",40,"healthcare",{"id":39,"doc_module":4,"doc_module_name":9,"category_name":40,"show_sort_weight":41,"slug":42},8,"Research & Report",30,"research-report",{"id":44,"doc_module":4,"doc_module_name":9,"category_name":45,"show_sort_weight":46,"slug":47},9,"Religion & Spirituality",20,"religion-spirituality",{"id":46,"doc_module":4,"doc_module_name":9,"category_name":49,"show_sort_weight":46,"slug":50},"World Cup","world-cup",{"id":52,"doc_module":4,"doc_module_name":9,"category_name":53,"show_sort_weight":52,"slug":54},10,"Lifestyle","lifestyle",{"id":56,"doc_module":4,"doc_module_name":9,"category_name":57,"show_sort_weight":24,"slug":58},19,"General","general",{"code":4,"msg":60,"data":61},"ok",{"site_id":62,"language":63,"slug":64,"title":65,"keywords":66,"description":67,"schema_data":68,"social_meta":124,"head_meta":126,"extra_data":128,"updated_unix":130},105,"en","understanding-agent-based-patching-of-compiler-missed-optimizations","Understanding Agent-Based Patching of Compiler Missed Optimizations","","Compiler missed optimizations occur when compilers fail to optimize certain code patterns, requiring substantial developer effort to implement or patch them. This paper presents a systematic study of how agent-based approaches patch missed optimizations, focusing on the key challenge of generalizing beyond the reported case. A benchmark of real-world LLVM issues compares agent-generated patches to developer patches by optimization scope. Results show partial overlap is common, and some agents over-generalize; retrieval and distillation using historical knowledge improve alignment and practical value.",{"@graph":69,"@context":123},[70,84,106],{"@type":71,"itemListElement":72},"BreadcrumbList",[73,77,79,82],{"item":74,"name":75,"@type":76,"position":8},"https://docshare.wps.com","Home","ListItem",{"item":78,"name":9,"@type":76,"position":14},"https://docshare.wps.com/document/",{"item":80,"name":40,"@type":76,"position":81},"https://docshare.wps.com/document/research-report/",3,{"item":83,"name":65,"@type":76,"position":19},"https://docshare.wps.com/document/understanding-agent-based-patching-of-compiler-missed-optimizations/327178/",{"url":83,"name":65,"@type":85,"image":86,"author":91,"headline":65,"publisher":94,"fileFormat":97,"inLanguage":63,"description":67,"dateModified":98,"datePublished":99,"encodingFormat":97,"isAccessibleForFree":100,"interactionStatistic":101},"DigitalDocument",{"url":87,"@type":88,"width":89,"height":90},"https://docshare.wps.com/thumbnails/understanding-agent-based-patching-of-compiler-missed-optimizations/327178.png","ImageObject",300,407,{"name":92,"@type":93},"Maeve","Person",{"url":74,"name":95,"@type":96},"DocShare","Organization","application/pdf","2026-11-29","2026-09-21",true,{"@type":102,"interactionType":103,"userInteractionCount":105},"InteractionCounter",{"@type":104},"ViewAction",23,{"@type":107,"mainEntity":108},"FAQPage",[109,115,119],{"name":110,"@type":111,"acceptedAnswer":112},"What does “compiler missed optimization” mean in this paper?","Question",{"text":113,"@type":114},"It refers to situations where compilers fail to apply intended optimizations to certain code, resulting in suboptimal generated output.","Answer",{"name":116,"@type":111,"acceptedAnswer":117},"Why is patching missed optimizations harder than conventional bug fixing?",{"text":118,"@type":114},"A missed-optimization patch must generalize the optimization correctly beyond the motivating test cases, not just satisfy the existing test suite.",{"name":120,"@type":111,"acceptedAnswer":121},"How do the authors evaluate agent-generated patches?",{"text":122,"@type":114},"They build a benchmark of real-world LLVM missed-optimization issues and compare agent patches with developer patches based on optimization scope and alignment with the intended generalization.","https://schema.org",{"og:url":83,"og:type":125,"og:title":65,"og:site_name":95,"og:description":67},"article",{"robots":127,"canonical":83},"index,follow",{"doc_id":129,"site_id":62},327178,1790031949,{"code":4,"msg":5,"data":132},{"doc_id":129,"user_id":133,"nickname":92,"user_avatar":134,"doc_module":4,"category_id":39,"category_name":40,"doc_title":65,"doc_description":67,"doc_content":135,"file_id":136,"file_url":137,"file_type":138,"file_size":139,"view_count":105,"is_deleted":4,"is_public":8,"is_downloadable":8,"audit_status":8,"page_count":140,"language":141,"language_code":63,"site_id":62,"html_lang":63,"table_of_contents":142,"faqs":143,"seo_title":144,"seo_description":67,"update_tm":145,"read_time":146,"preview_page_count":19,"preview_urls":147},5909877438554,"https://ap-avatar.wpscdn.com/avatar/5600025385ad2bf12a7?_k=1778553567797529272","Understanding Agent-Based Patching of Compiler Missed Optimizations  \nBatu Guan  \nThe Chinese University of Hong Kong Hong Kong SAR [btguan@cse.cuhk.edu.hk](btguan@cse.cuhk.edu.hk)  \nZirui Wang  \nThe Chinese University of Hong Kong Hong Kong SAR [zrwang@cse.cuhk.edu.hk](zrwang@cse.cuhk.edu.hk)  \nShaohua Li  \nThe Chinese University of Hong Kong Hong Kong SAR [shaohuali@cse.cuhk.edu.hk](shaohuali@cse.cuhk.edu.hk)  \narXiv :2607 .02370v2 [ cs . SE] 3 Jul 2026  \nAbstract—Compiler missed optimizations refer to cases in which compilers failed to optimize certain code. It takes many compiler developers’ efforts to implement or patch such missed optimizations. In this paper, we present a systematic study of how well agents patch compiler missed optimizations. We identify a significant challenge that patching a missed optimization requires more than just fixing the reported case, and instead requires generalizing to similar cases. We construct a benchmark of realworld LLVM missed optimization issues and compare agentgenerated patches with patches from developers in terms of optimization scope. Our results show that coding agents often optimize the given examples, but many generated patches either cover only part of the developer-intended scope or partially overlap with it; in some cases, they further generalize beyond the reference patch. We further introduce historical-knowledge augmentation techniques that leverage prior LLVM optimization pull requests through retrieval and distillation, showing that they improve developer-aligned generalization and yield practical benefits when applied to real-world IR.  \nIndex Terms—compiler missed optimization, llvm, coding agents, generalization  \nI. INTRODUCTION  \nCompiler optimization is a fundamental component of modern compiler design and software performance engineering. It aims to improve the efficiency of generated code without altering the intended behavior of the program [1] . Modern compilers, such as LLVM [2], often perform optimizations by identifying specific code patterns and replacing them with more efficient equivalents. This process often requires compiler optimization passes to enumerate and match a large number of code patterns in order to identify potential optimization opportunities in the target code.  \nHowever, during the design and implementation of compiler optimization rules, many optimization opportunities may remain unrecognized or unexploited by compiler developers, leading to the problem of missed optimizations. Such missed optimizations can result in suboptimal generated code and have long been a persistent challenge in compiler development [3] . To uncover these missed opportunities, researchers and compiler developers have explored a broad spectrum of techniques, including superoptimizers represented by Souper [4], synthesis-based systems exemplified by Hydra [5], and more recent AI-driven approaches, such as the method proposed by Italiano and Cummins [6] and LPO [3] . As these techniques continue to expose large numbers of missed optimization  \ncases, the main bottleneck is increasingly shifting from identifying optimization opportunities to integrating them as highquality patches within the compiler maintenance process.  \nThis shift makes automated patching attractive. In particular, recent advances in agents powered by large language models (LLMs) suggest a promising path toward automatically resolving compiler issues through patch generation, thereby reducing substantial manual engineering effort [7] . These efforts primarily demonstrate the potential of LLM agents in conventional compiler issue resolution, particularly in bug fixing. However, missed optimization patching is fundamentally different from conventional bug fixing. For a bug fix, correctness is often approximated by whether the patch satisfies the existing test suite [8]–[10] . By comparison, a missed optimization raisesa different challenge that the goal is not merely to make the motivating test ","cbCaihdmg7XqOXCa","https://ap.wps.com/l/cbCaihdmg7XqOXCa","pdf",998627,11,"English","# Introduction\n## Compiler optimization and missed optimizations\n## Automated agent-based patching\n## Generalization challenge","[{\"question\":\"What does “compiler missed optimization” mean in this paper?\",\"answer\":\"It refers to situations where compilers fail to apply intended optimizations to certain code, resulting in suboptimal generated output.\"},{\"question\":\"Why is patching missed optimizations harder than conventional bug fixing?\",\"answer\":\"A missed-optimization patch must generalize the optimization correctly beyond the motivating test cases, not just satisfy the existing test suite.\"},{\"question\":\"How do the authors evaluate agent-generated patches?\",\"answer\":\"They build a benchmark of real-world LLVM missed-optimization issues and compare agent patches with developer patches based on optimization scope and alignment with the intended generalization.\"}]","Understanding Agent-Based Patching of Compiler Missed Optimizations | PDF",1789976597,28,[148,152,156,160],{"page_no":8,"url":149,"width":150,"height":151},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-16/875224de065b864a95888aa4b9909028.webp",983,1272,{"page_no":14,"url":153,"width":154,"height":155},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-16/11a5e9c1c069c9b1c57054a4d6c6b5d7.webp",982,1270,{"page_no":81,"url":157,"width":158,"height":159},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-16/691baaa158317fa21600c879ce1d90e4.webp",981,1269,{"page_no":19,"url":161,"width":162,"height":163},"https://res-academy.cache.wpscdn.com/upload/kdocshare/2026-11-16/1fed3efb7cc43721eb89b684b492d1a2.webp",980,1268,{"list":165,"token":66},[166,173,180,187,193,199,205,211,217,223],{"doc_id":167,"doc_title":168,"file_type":138,"home_preview_img_url":169,"slug":170,"view_count":171,"category_name":40,"create_tm":172},497900,"CompilerDream - Learning a Compiler World Model for General Code Optimization","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229930678176/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=pRqS3fdmBWrJGPperqLLsMrFXjQ%3D","compilerdream-learning-a-compiler-world-model-for-general-code-optimization",14,1790970982,{"doc_id":174,"doc_title":175,"file_type":138,"home_preview_img_url":176,"slug":177,"view_count":178,"category_name":40,"create_tm":179},497945,"Testing Static Analyses for Precision and Soundness","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229930681029/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=%2FXD2brjr%2FJkVrHuh%2BgrrNWi%2Bgvc%3D","testing-static-analyses-for-precision-and-soundness",12,1790972104,{"doc_id":181,"doc_title":182,"file_type":138,"home_preview_img_url":183,"slug":184,"view_count":185,"category_name":40,"create_tm":186},84590,"LLVM-Bench Benchmarking and Advancing Large Language Models for LLVM Compiler Issue Resolution","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229809062494/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=JERPPvlD0wiiJB1%2BTY3d7v9Lveo%3D","llvm-bench-benchmarking-and-advancing-large-language-models-for-llvm-compiler-issue-resolution",29,1784196962,{"doc_id":188,"doc_title":189,"file_type":138,"home_preview_img_url":190,"slug":191,"view_count":52,"category_name":40,"create_tm":192},502941,"A Cascading Cooperative Multi-agent Framework for On-ramp Merging Control Integrating Large Language Models - Abstract","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229931816147/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=D3WxisezDaUWmt9Zpm0v5IFqlGM%3D","a-cascading-cooperative-multi-agent-framework-for-on-ramp-merging-control-integrating-large-language-models-abstract",1791046537,{"doc_id":194,"doc_title":195,"file_type":138,"home_preview_img_url":196,"slug":197,"view_count":185,"category_name":40,"create_tm":198},82562,"Knowledge-Enhanced Agentic Vulnerability Repair","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229808763388/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=opNe2CVxUJ%2F7z3mbyNnZR21PUok%3D","knowledge-enhanced-agentic-vulnerability-repair",1784181544,{"doc_id":200,"doc_title":201,"file_type":138,"home_preview_img_url":202,"slug":203,"view_count":29,"category_name":40,"create_tm":204},701214,"Finding Time - How Programmers Manipulate Code to Decrease Runtime","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110230012054147/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=r%2FFkdO1tZr0wBTazo4%2FNyqcjhfY%3D","finding-time-how-programmers-manipulate-code-to-decrease-runtime",1794524189,{"doc_id":206,"doc_title":207,"file_type":138,"home_preview_img_url":208,"slug":209,"view_count":171,"category_name":40,"create_tm":210},122600,"ImageNet-Patch - A Dataset for Benchmarking Machine Learning Robustness against Adversarial Patches","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229836913885/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=IqobYCcfgE5OlWWPH8WnX5aAs7Y%3D","imagenet-patch-a-dataset-for-benchmarking-machine-learning-robustness-against-adversarial-patches",1785811665,{"doc_id":212,"doc_title":213,"file_type":138,"home_preview_img_url":214,"slug":215,"view_count":46,"category_name":40,"create_tm":216},154792,"THE POLITICS OF A GAME PATCH - PATCH NOTE DOCUMENTS AND THE PATCHING PROCESSES IN LEAGUE OF LEGENDS","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229869943559/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=sdQio%2BUFifTWo7o0%2BHkUxr3N1V8%3D","the-politics-of-a-game-patch-patch-note-documents-and-the-patching-processes-in-league-of-legends",1787899084,{"doc_id":218,"doc_title":219,"file_type":138,"home_preview_img_url":220,"slug":221,"view_count":31,"category_name":40,"create_tm":222},31577,"Enhancing LLM-based Quantum Code Generation with Multi-Agent Optimization and Quantum Error Correction","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229744575160/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=bwAbM0h2240u%2BL8X0qtrncVJD%2B0%3D","enhancing-llm-based-quantum-code-generation-with-multi-agent-optimization-and-quantum-error-correction",1779742918,{"doc_id":224,"doc_title":225,"file_type":138,"home_preview_img_url":226,"slug":227,"view_count":228,"category_name":40,"create_tm":229},85017,"Perfopt-Bench: Evaluating Coding Agents on Software Performance Optimization","https://weboffice-temporary-prod-sg.obs.ap-southeast-3.myhuaweicloud.com:443/export/thumbnail/export/thumbnail/110229809285109/last/300/407?AWSAccessKeyId=HPUAE6OPDRI9QZXR6WJG&Expires=1796108039&Signature=QBqN8qvATO6s81OqZI1E7T6wCFY%3D","perfopt-bench-evaluating-coding-agents-on-software-performance-optimization",35,1784200312]