Novel Approaches to Systematically Evaluating and Constructing Call Graphs for Java Software

调用图 计算机科学 程序设计语言 软件 Java 理论计算机科学 图形 可扩展性 数据库
作者
Michael Reif
标识
DOI:10.26083/tuprints-00019286
摘要

Whether applications or libraries, today’s software heavily reuses existing code to build more gigantic software faster. To ensure a smooth user experience for an application’s end-user and a reliable software library for the developer, the shipped piece of software should be as bug-free as possible. Besides manual or automatic software testing, static program analysis is one possible way to find unintended behavior. While static analysis tools can detect simple problems using pattern matching, advanced problems often require complex interprocedural control- and data-flow analyses, which, in turn, presume call graphs. For example, call graphs enable static analyses to track inputs over method boundaries to find SQL-injections or null pointer dereferences. The research community proposed many different call-graph algorithms with different precision and scalability properties. However, the following three aspects are often neglected. First, a comprehensive understanding of unsoundness sources, their relevance, and the capabilities of existing call-graph algorithms in this respect is missing. These sources of unsoundness can originate from programming language features and core APIs that impact call-graph construction, e.g., reflection, but are not (entirely) modeled by the call-graph algorithm. Without understanding the sources of unsoundness’ relevance and the frequency in which they occur, it is impossible to estimate their immediate effect on either the call graph or the analysis relying on it. Second, most call-graph research examines how to build call graphs for applications, neglecting to investigate the peculiarities of building call graphs for libraries. However, the use of libraries is ubiquitous in software development. Consequently, disregarding call-graph construction for libraries is unfortunate for both library users and developers, as it is crucial to ensure that their library behaves as intended regardless of its usage. Third call-graph algorithms, are traditionally organized in an imperative monolithic style, i.e., one super-analysis computes the whole graph. Such a design can hardly hold up to the task, as different programs and analysis problems require the support for different subsets of language features and APIs. Moreover, configuring the algorithm to one’s needs is not easy. For instance, adding, removing, and exchanging support for individual features to trade-off the call graph’s precision, scalability, and soundiness. To address the first aspect, we propose a method and a corresponding toolchain for both a) understanding sources of unsoundness and b) improving the soundness of call graphs. We use our approach to assess multiple call-graph algorithms from state-of- the-art static analysis frameworks. Furthermore, we study how these features occur in real-world applications and the effort to improve a call graph’s soundness. Regarding aspect two, we show that the current practice of using call-graph algorithms designed for applications to analyze libraries leads to call graphs that both a) lack relevant call edges and b) contain unnecessary edges. Ergo, motivating the need for call-graph construction algorithms dedicated to libraries. Unlike algorithms for applications, call-graph construction algorithms for libraries must consider the goals of subsequent analyses. Concretely, we show that it is essential to distinguish between the analysis’s usage scenario. Whereas an analysis searching for potentially exploitable vulnerabilities must be conservative, an analysis for general software quality attributes, e.g., dead methods or unused fields, can safely apply optimizations. Since building one call graph that fits all needs is nonsensical, we propose two concrete algorithms, each addressing one use case. Concerning the third aspect, we devise a generic approach for collaborative static analysis featuring modular analysis that are independently compilable, exchangeable, and extensible. In particular, we decouple mutually dependent analyses, enabling their isolated development. This approach facilitates highly configurable call-graph algorithms, allowing pluggable precision, scalability, and soundiness by either switching analysis modules for features and APIs on/off, or exchanging their implementations. By addressing these three aspects, we advance the state-of-the-art in call-graph construction in multiple dimensions. First, our systematic assessment of unsoundness sources and call-graph algorithms reveals import limitations with state-of-the-art. All frameworks lack support for many features frequently found in-the-wild and produce vastly different CGs, rendering comparisons of call-graph-based static analyses infeasible. Furthermore, we leave both developers and users of call graphs with suggestions that improve the entire situation. Second, our discussion concerning library call graphs raises the awareness of considering the analysis scenario and opens up a new facet in call-graph research. Third, by featuring modular call-graph algorithms we ease to design, implement, and test them. Additionally, it allows project-based configurations, enabling puggable precision, scalability, and sound(i)ness.
最长约 10秒,即可获得该文献文件

科研通智能强力驱动
Strongly Powered by AbleSci AI
更新
PDF的下载单位、IP信息已删除 (2025-6-4)

科研通是完全免费的文献互助平台,具备全网最快的应助速度,最高的求助完成率。 对每一个文献求助,科研通都将尽心尽力,给求助人一个满意的交代。
实时播报
本本完成签到 ,获得积分10
刚刚
学好久完成签到 ,获得积分10
刚刚
丁丁完成签到,获得积分10
11秒前
dudu10000完成签到,获得积分10
20秒前
皮卡猪完成签到 ,获得积分10
25秒前
在水一方应助dudu10000采纳,获得10
30秒前
熊雅完成签到,获得积分10
31秒前
Akim应助al采纳,获得10
31秒前
欢喜板凳完成签到 ,获得积分10
33秒前
发个15分的完成签到 ,获得积分10
37秒前
趙途嘵生完成签到,获得积分10
39秒前
39秒前
Hello应助科研通管家采纳,获得10
39秒前
Bryan应助科研通管家采纳,获得10
40秒前
Bryan应助科研通管家采纳,获得10
40秒前
slycmd完成签到,获得积分10
40秒前
Bryan应助科研通管家采纳,获得10
40秒前
Bryan应助科研通管家采纳,获得10
40秒前
MLS8620应助hantuo采纳,获得10
40秒前
isedu完成签到,获得积分10
41秒前
斑驳发布了新的文献求助10
46秒前
wenhuanwenxian完成签到 ,获得积分10
53秒前
MLS8620应助heihei采纳,获得10
1分钟前
Kayla完成签到 ,获得积分10
1分钟前
吃小孩的妖怪完成签到 ,获得积分10
1分钟前
忧虑的静柏完成签到 ,获得积分10
1分钟前
loren313完成签到,获得积分0
1分钟前
君看一叶舟完成签到 ,获得积分10
1分钟前
probiotics完成签到 ,获得积分10
1分钟前
孙刚完成签到 ,获得积分10
1分钟前
1分钟前
zhuosht完成签到 ,获得积分10
1分钟前
鸭鸭完成签到 ,获得积分10
1分钟前
蝌蚪发布了新的文献求助10
1分钟前
蛋挞完成签到 ,获得积分10
1分钟前
蝌蚪完成签到,获得积分10
1分钟前
糖糖完成签到 ,获得积分10
1分钟前
郭德久完成签到 ,获得积分0
1分钟前
愉快无心完成签到 ,获得积分10
1分钟前
神内打工人完成签到 ,获得积分10
1分钟前
高分求助中
The Mother of All Tableaux: Order, Equivalence, and Geometry in the Large-scale Structure of Optimality Theory 3000
Social Research Methods (4th Edition) by Maggie Walter (2019) 2390
A new approach to the extrapolation of accelerated life test data 1000
Problems of point-blast theory 400
北师大毕业论文 基于可调谐半导体激光吸收光谱技术泄漏气体检测系统的研究 390
Phylogenetic study of the order Polydesmida (Myriapoda: Diplopoda) 370
Robot-supported joining of reinforcement textiles with one-sided sewing heads 320
热门求助领域 (近24小时)
化学 材料科学 医学 生物 工程类 有机化学 生物化学 物理 内科学 纳米技术 计算机科学 化学工程 复合材料 遗传学 基因 物理化学 催化作用 冶金 细胞生物学 免疫学
热门帖子
关注 科研通微信公众号,转发送积分 4001381
求助须知:如何正确求助?哪些是违规求助? 3540765
关于积分的说明 11278689
捐赠科研通 3278680
什么是DOI,文献DOI怎么找? 1808154
邀请新用户注册赠送积分活动 884376
科研通“疑难数据库(出版商)”最低求助积分说明 810291