首页> 外文期刊>Software >Efficient compilation strategy for object-oriented languages under the closed-world assumption
【24h】

Efficient compilation strategy for object-oriented languages under the closed-world assumption

机译:封闭世界假设下面向对象语言的高效编译策略

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

摘要

Reaching the best level of runtime performance from a high-level, object-oriented language is often considered challenging if not unattainable. The closed-world assumption involves considering all of the source code of an application together at compile time. That assumption makes it possible to produce an efficient code. For instance, multiple inheritance can be implemented as efficiently as single inheritance. Our compilation strategy is the result of a prolonged project, tying together several compilation techniques: call graph analysis, dead code elimination, type flow analysis, code customization, implementation of dynamic dispatch, inlining, pointer optimization, switch optimization, objects layout, and so on. Merging all of these techniques into a global strategy appears to be quite problematic. Throughout the paper, two real-world compilers are used as benchmarks to provide measurements for compiler writers to evaluate the applicability of our approach. Type flow analysis is a fundamental aspect of our strategy to resolve method calls. We have extended type flow analysis to deal with the content of arrays, enabling us to process additional expressions and thus making it possible to obtain a true global analysis. Typically, more than 90% of method call sites are statically resolved. Our experience indicates that the closed-world assumption is suitable for numerous applications. Surprisingly, even library-defined control statements from dynamic languages are perfectly processed with our strategy. The Smalltalk if True : if False :, whileTrue:, to: do:, and so on are, for the very first time, perfectly translated.
机译:从高级,面向对象的语言获得最佳运行时性能通常被认为具有挑战性,即使不是无法实现的。封闭世界假设涉及在编译时一起考虑应用程序的所有源代码。该假设使得可以产生有效的代码。例如,多重继承可以和单一继承一样有效地实现。我们的编译策略是一个长期项目的结果,将几种编译技术结合在一起:调用图分析,死代码消除,类型流分析,代码定制,动态调度的实现,内联,指针优化,开关优化,对象布局等上。将所有这些技术合并到全球战略中似乎是有问题的。在整个论文中,使用了两个实际的编译器作为基准,以为编译器作者提供评估工具,以评估我们方法的适用性。类型流分析是我们解决方法调用的策略的基本方面。我们扩展了类型流分析以处理数组的内容,从而使我们能够处理其他表达式,从而有可能获得真正的全局分析。通常,静态解析超过90%的方法调用站点。我们的经验表明,封闭世界的假设适用于多种应用。令人惊讶的是,即使是来自动态语言的库定义控制语句也可以通过我们的策略得到完美处理。 Smalltalk if True:if False:,whileTrue :, to:do:等,是第一次被完美翻译。

著录项

相似文献

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

客服邮箱:kefu@zhangqiaokeyan.com

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

  • 服务号