Classification-based Static Collection Selection for Java: Effectiveness and Adaptability

N. Couderc, Christoph Reichenbach, Emma Söderberg
{"title":"Classification-based Static Collection Selection for Java: Effectiveness and Adaptability","authors":"N. Couderc, Christoph Reichenbach, Emma Söderberg","doi":"10.1145/3593434.3593469","DOIUrl":null,"url":null,"abstract":"Carefully selecting the right collection datastructure can significantly improve the performance of a Java program. Unfortunately, the performance impact of a certain collection selection can be hard to estimate. To assist developers, there exist tools that recommend collections to use based on static and/or dynamic information about a program. The majority of existing collection selection tools for Java pick their selections dynamically, which means that they must trade off sophistication in their selection algorithm against its run time overhead. For static collection selection, the Brainy tool has demonstrated that complex, machine-dependent models can produce substantial performance improvements, albeit only for C++ so far. In this paper, we port Brainy from C++ to Java, and evaluate its effectiveness for 5 benchmarks from the DaCapo benchmark suite. We compare it against the original program, but also to a ground truth, which we estimate using a variant of a brute-force approach to collection selection. Our results show that in four benchmarks out of five, our ground truth and the original program are similar. In one case, the ground truth shows an optimization yielding 20% speedup was available, but our port did not find this substantial optimization. We find that the port is more efficient but less effective than the ground truth, can easily adapt to new hardware architectures, and incorporate new datastructures with at most a few hours of human effort. We detail challenges that we encountered porting the Brainy approach to Java, and list a number of insights and directions for future research.","PeriodicalId":178596,"journal":{"name":"Proceedings of the 27th International Conference on Evaluation and Assessment in Software Engineering","volume":"17 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2023-06-14","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 27th International Conference on Evaluation and Assessment in Software Engineering","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/3593434.3593469","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

Abstract

Carefully selecting the right collection datastructure can significantly improve the performance of a Java program. Unfortunately, the performance impact of a certain collection selection can be hard to estimate. To assist developers, there exist tools that recommend collections to use based on static and/or dynamic information about a program. The majority of existing collection selection tools for Java pick their selections dynamically, which means that they must trade off sophistication in their selection algorithm against its run time overhead. For static collection selection, the Brainy tool has demonstrated that complex, machine-dependent models can produce substantial performance improvements, albeit only for C++ so far. In this paper, we port Brainy from C++ to Java, and evaluate its effectiveness for 5 benchmarks from the DaCapo benchmark suite. We compare it against the original program, but also to a ground truth, which we estimate using a variant of a brute-force approach to collection selection. Our results show that in four benchmarks out of five, our ground truth and the original program are similar. In one case, the ground truth shows an optimization yielding 20% speedup was available, but our port did not find this substantial optimization. We find that the port is more efficient but less effective than the ground truth, can easily adapt to new hardware architectures, and incorporate new datastructures with at most a few hours of human effort. We detail challenges that we encountered porting the Brainy approach to Java, and list a number of insights and directions for future research.
基于分类的Java静态集合选择:有效性和适应性
仔细选择正确的集合数据结构可以显著提高Java程序的性能。不幸的是,某个集合选择对性能的影响很难估计。为了帮助开发人员,有一些工具可以根据关于程序的静态和/或动态信息推荐使用集合。大多数现有的Java集合选择工具都是动态地选择它们的选择,这意味着它们必须权衡选择算法的复杂性和运行时开销。对于静态集合选择,Brainy工具已经证明了复杂的、依赖于机器的模型可以产生实质性的性能改进,尽管到目前为止仅适用于c++。在本文中,我们将Brainy从c++移植到Java,并在DaCapo基准测试套件中的5个基准测试中评估其有效性。我们将其与原始程序进行比较,但也与基本事实进行比较,我们使用暴力方法的变体来估计集合选择。我们的结果表明,在五个基准中的四个基准中,我们的基础真理与原始程序相似。在一个案例中,实际情况是有20%加速的优化,但是我们的移植并没有发现这种实质性的优化。我们发现,该端口比地面事实更有效,但效果较差,可以很容易地适应新的硬件架构,并结合新的数据结构,最多只需要几个小时的人工工作。我们详细介绍了将Brainy方法移植到Java中所遇到的挑战,并列出了一些未来研究的见解和方向。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信