针对大型代码库的高效可调选择点分析

Behnaz Hassanshahi, R. Ramesh, P. Krishnan, Bernhard Scholz, Yi Lu
{"title":"针对大型代码库的高效可调选择点分析","authors":"Behnaz Hassanshahi, R. Ramesh, P. Krishnan, Bernhard Scholz, Yi Lu","doi":"10.1145/3088515.3088519","DOIUrl":null,"url":null,"abstract":"Points-to analysis is a fundamental static program analysis technique for tools including compilers and bug-checkers. Although object-based context sensitivity is known to improve precision of points-to analysis, scaling it for large Java codebases remains a challenge. In this work, we develop a tunable, client-independent, object-sensitive points-to analysis framework where heap cloning is applied selectively. This approach is aimed at large codebases where standard analysis is typically expensive. Our design includes a pre-analysis that determines program points that contribute to the cost of an object-sensitive points-to analysis. A subsequent analysis then determines the context depth for each allocation site. While our framework can run standalone, it is also possible to tune it – the user of the framework can use the knowledge of the codebase being analysed to influence the selection of expensive program points as well as the process to differentiate the required context-depth. Overall, the approach determines where the cloning is beneficial and where the cloning is unlikely to be beneficial. We have implemented our approach using Soufflé (a Datalog compiler) and an extension of the DOOP framework. Our experiments on large programs, including OpenJDK, show that our technique is efficient and precise. For the OpenJDK, our analysis reduces 27% of runtime and 18% of memory usage in comparison with 2O1H points-to analysis for a negligible loss of precision, while for Jython from the DaCapo benchmark suite, the same analysis reduces 91% of runtime for no loss of precision.","PeriodicalId":368102,"journal":{"name":"Proceedings of the 6th ACM SIGPLAN International Workshop on State Of the Art in Program Analysis","volume":"123 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2017-06-18","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"26","resultStr":"{\"title\":\"An efficient tunable selective points-to analysis for large codebases\",\"authors\":\"Behnaz Hassanshahi, R. Ramesh, P. Krishnan, Bernhard Scholz, Yi Lu\",\"doi\":\"10.1145/3088515.3088519\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"Points-to analysis is a fundamental static program analysis technique for tools including compilers and bug-checkers. Although object-based context sensitivity is known to improve precision of points-to analysis, scaling it for large Java codebases remains a challenge. In this work, we develop a tunable, client-independent, object-sensitive points-to analysis framework where heap cloning is applied selectively. This approach is aimed at large codebases where standard analysis is typically expensive. Our design includes a pre-analysis that determines program points that contribute to the cost of an object-sensitive points-to analysis. A subsequent analysis then determines the context depth for each allocation site. While our framework can run standalone, it is also possible to tune it – the user of the framework can use the knowledge of the codebase being analysed to influence the selection of expensive program points as well as the process to differentiate the required context-depth. Overall, the approach determines where the cloning is beneficial and where the cloning is unlikely to be beneficial. We have implemented our approach using Soufflé (a Datalog compiler) and an extension of the DOOP framework. Our experiments on large programs, including OpenJDK, show that our technique is efficient and precise. For the OpenJDK, our analysis reduces 27% of runtime and 18% of memory usage in comparison with 2O1H points-to analysis for a negligible loss of precision, while for Jython from the DaCapo benchmark suite, the same analysis reduces 91% of runtime for no loss of precision.\",\"PeriodicalId\":368102,\"journal\":{\"name\":\"Proceedings of the 6th ACM SIGPLAN International Workshop on State Of the Art in Program Analysis\",\"volume\":\"123 1\",\"pages\":\"0\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"2017-06-18\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"26\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Proceedings of the 6th ACM SIGPLAN International Workshop on State Of the Art in Program Analysis\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.1145/3088515.3088519\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 6th ACM SIGPLAN International Workshop on State Of the Art in Program Analysis","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/3088515.3088519","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 26

摘要

指向分析是一种基本的静态程序分析技术,适用于包括编译器和错误检查器在内的工具。尽管基于对象的上下文敏感性可以提高点到分析的精度,但是将其扩展到大型Java代码库仍然是一个挑战。在这项工作中,我们开发了一个可调的、与客户端无关的、对象敏感的点到分析框架,在这个框架中有选择地应用堆克隆。这种方法针对的是大型代码库,其中标准分析通常是昂贵的。我们的设计包括一个预分析,用于确定对对象敏感的点对分析的成本有贡献的程序点。随后的分析确定了每个分配站点的上下文深度。虽然我们的框架可以独立运行,但也可以对其进行调整——框架的用户可以使用正在分析的代码库知识来影响昂贵的程序点的选择,以及区分所需上下文深度的过程。总的来说,该方法确定克隆在哪些地方是有益的,在哪些地方克隆不太可能有益。我们已经使用souffl(一个数据汇编器)和框架的扩展实现了我们的方法。我们在大型程序(包括OpenJDK)上的实验表明,我们的技术是高效和精确的。对于OpenJDK,我们的分析减少了27%的运行时和18%的内存使用,而与o1h点对点分析相比,精度损失可以忽略不计,而对于来自DaCapo基准套件的Jython,相同的分析减少了91%的运行时,但没有精度损失。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
An efficient tunable selective points-to analysis for large codebases
Points-to analysis is a fundamental static program analysis technique for tools including compilers and bug-checkers. Although object-based context sensitivity is known to improve precision of points-to analysis, scaling it for large Java codebases remains a challenge. In this work, we develop a tunable, client-independent, object-sensitive points-to analysis framework where heap cloning is applied selectively. This approach is aimed at large codebases where standard analysis is typically expensive. Our design includes a pre-analysis that determines program points that contribute to the cost of an object-sensitive points-to analysis. A subsequent analysis then determines the context depth for each allocation site. While our framework can run standalone, it is also possible to tune it – the user of the framework can use the knowledge of the codebase being analysed to influence the selection of expensive program points as well as the process to differentiate the required context-depth. Overall, the approach determines where the cloning is beneficial and where the cloning is unlikely to be beneficial. We have implemented our approach using Soufflé (a Datalog compiler) and an extension of the DOOP framework. Our experiments on large programs, including OpenJDK, show that our technique is efficient and precise. For the OpenJDK, our analysis reduces 27% of runtime and 18% of memory usage in comparison with 2O1H points-to analysis for a negligible loss of precision, while for Jython from the DaCapo benchmark suite, the same analysis reduces 91% of runtime for no loss of precision.
求助全文
通过发布文献求助,成功后即可免费获取论文全文。 去求助
来源期刊
自引率
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学术文献互助群
群 号:604180095
Book学术官方微信