A C++ data model supporting reachability analysis and dead code detection

Y. Chen, E. Gansner, E. Koutsofios
{"title":"A C++ data model supporting reachability analysis and dead code detection","authors":"Y. Chen, E. Gansner, E. Koutsofios","doi":"10.1145/267895.267924","DOIUrl":null,"url":null,"abstract":"A software repository provides a central information source for understanding and reengineering code in a software project. Complex reverse engineering tools can be built by analyzing information stored in the repository without reparsing the original source code. The most critical design aspect of a repository is its data model, which directly affects how effectively the repository supports various analysis tasks. This paper focuses on the design rationales behind a data model for a C++ software repository that supports reachability analysis and dead code detection at the declaration level. These two tasks are frequently needed in large software projects to help remove excess software baggage, select regression tests, and support software reuse studies. The language complexity introduced by class inheritance, friendships, and template instantiations in C++ requires a carefully designed model to catch all necessary dependencies for correct reachability analysis. We examine the major design decisions and their consequences in our model and illustrate how future software repositories can be evaluated for completeness at a selected abstraction level. Examples are given to illustrate how our model also supports variants of reachability analysis: impact analysis, class visibility analysis, and dead code detection. Finally, we discuss the implementation and experience of our analysis tools on a C++ software project.","PeriodicalId":297962,"journal":{"name":"ESEC '97/FSE-5","volume":"1 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"1997-11-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"96","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"ESEC '97/FSE-5","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/267895.267924","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 96

Abstract

A software repository provides a central information source for understanding and reengineering code in a software project. Complex reverse engineering tools can be built by analyzing information stored in the repository without reparsing the original source code. The most critical design aspect of a repository is its data model, which directly affects how effectively the repository supports various analysis tasks. This paper focuses on the design rationales behind a data model for a C++ software repository that supports reachability analysis and dead code detection at the declaration level. These two tasks are frequently needed in large software projects to help remove excess software baggage, select regression tests, and support software reuse studies. The language complexity introduced by class inheritance, friendships, and template instantiations in C++ requires a carefully designed model to catch all necessary dependencies for correct reachability analysis. We examine the major design decisions and their consequences in our model and illustrate how future software repositories can be evaluated for completeness at a selected abstraction level. Examples are given to illustrate how our model also supports variants of reachability analysis: impact analysis, class visibility analysis, and dead code detection. Finally, we discuss the implementation and experience of our analysis tools on a C++ software project.
查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
支持可达性分析和死代码检测的c++数据模型
软件存储库为理解和重新设计软件项目中的代码提供了一个中心信息源。可以通过分析存储在存储库中的信息来构建复杂的逆向工程工具,而无需重新解析原始源代码。存储库最关键的设计方面是它的数据模型,它直接影响存储库支持各种分析任务的效率。本文关注c++软件存储库的数据模型背后的设计原理,该模型支持可达性分析和声明级别的死代码检测。这两个任务在大型软件项目中经常需要,以帮助移除多余的软件包袱,选择回归测试,并支持软件重用研究。c++中由类继承、友谊和模板实例化引入的语言复杂性需要一个精心设计的模型来捕获所有必要的依赖关系,以进行正确的可达性分析。我们检查了模型中的主要设计决策及其结果,并说明了如何在选定的抽象级别上评估未来的软件存储库的完整性。示例说明了我们的模型如何支持可达性分析的变体:影响分析、类可见性分析和死代码检测。最后,我们讨论了我们的分析工具在一个c++软件项目上的实现和经验。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 去求助
来源期刊
自引率
0.00%
发文量
0
期刊最新文献
Change management needs integrated process and configuration management The use of program profiling for software maintenance with applications to the year 2000 problem Towards an adaptation of the COCOMO cost model to the software measurement theory Experiences with criticality predictions in software development A design framework for Internet-scale event observation and notification
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
已复制链接
已复制链接
快去分享给好友吧!
我知道了
×
扫码分享
扫码分享
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1