...
首页> 外文期刊>ACM Transactions on Programming Languages and Systems >A Region-Based Compilation Technique for Dynamic Compilers
【24h】

A Region-Based Compilation Technique for Dynamic Compilers

机译:动态编译器的基于区域的编译技术

获取原文
获取原文并翻译 | 示例
   

获取外文期刊封面封底 >>

       

摘要

Method inlining and data flow analysis are two major optimization components for effective program transformations, but they often suffer from the existence of rarely or never executed code contained in the target method. One major problem lies in the assumption that the compilation unit is partitioned at method boundaries. This article describes the design and implementation of a region-based compilation technique in our dynamic optimization framework, in which the compiled regions are selected as code portions without rarely executed code. The key parts of this technique are the region selection, partial inlining, and region exit handling. For region selection, we employ both static heuristics and dynamic profiles to identify and eliminate rare sections of code. The region selection process and method inlining decisions are interwoven, so that method inlining exposes other targets for region selection, while the region selection in the inline target conserves the inlining budget, allowing more method inlining to be performed. The inlining process can be performed for parts of a method, not just for the entire body of the method. When the program attempts to exit from a region boundary, we trigger recompilation and then use on-stack replacement to continue the execution from the corresponding entry point in the recompiled code. We have implemented these techniques in our Java JIT compiler, and conducted a comprehensive evaluation. The experimental results show that our region-based compilation approach achieves approximately 4% performance improvement on average, while reducing the compilation overhead by 10% to 30%, in comparison to the traditional method-based compilation techniques.
机译:方法内联和数据流分析是有效进行程序转换的两个主要优化组件,但它们经常遭受目标方法中包含的很少执行或从未执行的代码的困扰。一个主要问题在于假设编译单元在方法边界处进行了划分。本文介绍了在我们的动态优化框架中基于区域的编译技术的设计和实现,其中,将已编译区域选择为代码部分,而很少执行代码。该技术的关键部分是区域选择,部分内联和区域出口处理。对于区域选择,我们同时使用静态启发式和动态配置文件来识别和消除罕见的代码段。区域选择过程和方法内联决策是相互交织的,因此方法内联为区域选择公开了其他目标,而内联目标中的区域选择节省了内联预算,从而允许执行更多方法内联。内联过程可以针对方法的各个部分执行,而不仅针对方法的整个主体。当程序尝试从区域边界退出时,我们触发重新编译,然后使用栈上替换从重新编译的代码中的相应入口点继续执行。我们已经在Java JIT编译器中实现了这些技术,并进行了全面的评估。实验结果表明,与传统的基于方法的编译技术相比,基于区域的编译方法平均可将性能提高约4%,同时将编译开销减少10%至30%。

著录项

相似文献

  • 外文文献
  • 中文文献
  • 专利
获取原文

客服邮箱:kefu@zhangqiaokeyan.com

京公网安备:11010802029741号 ICP备案号:京ICP备15016152号-6 六维联合信息科技 (北京) 有限公司©版权所有
  • 客服微信

  • 服务号