DJXPerf: Identifying Memory Inefficiencies via Object-Centric Profiling for Java

DJXPerf: Identifying Memory Inefficiencies via Object-Centric Profiling for Java
复制标题

DOI:
10.1145/3579990.3580010
复制
发表时间:
2021-04
期刊:
Proceedings of the 21st ACM/IEEE International Symposium on Code Generation and Optimization
影响因子:
--
通讯作者:
Bolun Li;Pengfei Su;Milind Chabbi;Shuyin Jiao;Xu Liu
Bolun Li;Pengfei Su;Milind Chabbi;Shuyin Jiao;Xu Liu
中科院分区:
其他
文献类型:
--
作者:
Bolun Li;Pengfei Su;Milind Chabbi;Shuyin Jiao;Xu Liu

文献摘要

被引文献

相似文献

Java是开发可扩展企业云应用程序的首选编程语言。在此类系统中,即使节省百分之几的CPU时间也可以提供显着的竞争优势和成本节约。虽然Java的性能工具很多,但那些专注于内存层次结构中的数据局部性的工具却很少。在本文中,我们首先对Java程序中的数据局部性问题进行分类。然后,我们提出了DJXPerf,一个轻量级的,以对象为中心的Java内存分析器,它将内存层次结构的性能指标(例如,缓存/TLB未命中)。DJXPerf使用硬件性能监视计数器的统计抽样来将度量不仅归因于源代码位置,而且归因于Java对象。DJXPerf将Java对象分配上下文与它们的使用上下文结合起来,并按差局部性行为排序。DJXPerf的性能测量、对象属性和表示技术指导优化对象分配、布局和访问模式。DJXPerf平均仅产生约8.5%的运行时开销和约6%的内存开销,不需要修改硬件、操作系统、Java虚拟机或应用程序源代码,这使得它在生产中使用具有吸引力。在DJXPerf的指导下,我们研究和优化了许多Java和Scala程序,包括著名的基准测试和实际应用程序,并展示了显着的加速。
Java is the “go-to” programming language choice for developing scalable enterprise cloud applications. In such systems, even a few percent CPU time savings can offer a significant competitive advantage and cost savings. Although performance tools abound for Java, those that focus on the data locality in the memory hierarchy are rare. In this paper, we first categorize data locality issues in Java programs. We then present DJXPerf, a lightweight, object-centric memory profiler for Java, which associates memory-hierarchy performance metrics (e.g., cache/TLB misses) with Java objects. DJXPerf uses statistical sampling of hardware performance monitoring counters to attribute metrics to not only source code locations but also Java objects. DJXPerf presents Java object allocation contexts combined with their usage contexts and presents them ordered by the poor locality behaviors. DJXPerf’s performance measurement, object attribution, and presentation techniques guide optimizing object allocation, layout, and access patterns. DJXPerf incurs only ~8.5% runtime overhead and ∼6% memory overhead on average, requiring no modifications to hardware, OS, Java virtual machine, or application source code, which makes it attractive to use in production. Guided by DJXPerf, we study and optimize a number of Java and Scala programs, including well-known benchmarks and real-world applications, and demonstrate significant speedups.