|
ABSTRACT
Several program analysis problems can be cast elegantly as a logic program. In this paper we show how recently-developed techniques for incremental evaluation of logic programs can be refined and used for deriving practical implementations of incremental program analyzers. Incremental program analyzers compute the changes to the analysis information due to small changes in the input program rather than re-analyzing the program. Demand-driven analyzers compute only the information requested by the client analysis/optimization. We describe a framework based on logic programming for implementing program analyses that combines incremental and demand driven techniques. We show the effectiveness of this approach by building a practical incremental and demand-driven context insensitive points-to analysis and evaluating this implementation for analyzing C programs with 10-70K lines of code. Experiments show that our technique can compute the changes to analysis information due to small changes in the input program in, on the average, 6% of the time it takes to reanalyze the program from scratch, and with little space overhead.
REFERENCES
Note: OCR errors may be found in this Reference List extracted from the full text article. ACM has opted to expose the complete List rather than only correct and linked references.
| |
1
|
|
| |
2
|
Alfred V. Aho , Ravi Sethi , Jeffrey D. Ullman, Compilers: principles, techniques, and tools, Addison-Wesley Longman Publishing Co., Inc., Boston, MA, 1986
|
| |
3
|
L. O. Anderson. Program Analysis and Specialization for the C Programming Language. PhD thesis, DIKU, Unversity of Copenhagen, 1994.
|
 |
4
|
|
 |
5
|
|
 |
6
|
|
| |
7
|
|
 |
8
|
|
 |
9
|
|
 |
10
|
|
 |
11
|
Steven Dawson , C. R. Ramakrishnan , David S. Warren, Practical program analysis using general purpose logic programming systems—a case study, Proceedings of the ACM SIGPLAN 1996 conference on Programming language design and implementation, p.117-126, May 21-24, 1996, Philadelphia, Pennsylvania, United States
|
| |
12
|
|
 |
13
|
|
 |
14
|
Manuel Fähndrich , Jeffrey S. Foster , Zhendong Su , Alexander Aiken, Partial online cycle elimination in inclusion constraint graphs, Proceedings of the ACM SIGPLAN 1998 conference on Programming language design and implementation, p.85-96, June 17-19, 1998, Montreal, Quebec, Canada
|
 |
15
|
Manuel Fähndrich , Jakob Rehof , Manuvir Das, Scalable context-sensitive flow analysis using instantiation constraints, Proceedings of the ACM SIGPLAN 2000 conference on Programming language design and implementation, p.253-263, June 18-21, 2000, Vancouver, British Columbia, Canada
|
| |
16
|
|
 |
17
|
Ashish Gupta , Inderpal Singh Mumick , V. S. Subrahmanian, Maintaining views incrementally, Proceedings of the 1993 ACM SIGMOD international conference on Management of data, p.157-166, May 25-28, 1993, Washington, D.C., United States
|
| |
18
|
S. Guyer and C. Lin. Client-driven pointer analysis. In Static Analysis Symposium, pages 214--236, 2003.
|
 |
19
|
|
 |
20
|
|
 |
21
|
|
 |
22
|
Susan Horwitz , Thomas Reps , Mooly Sagiv, Demand interprocedural dataflow analysis, Proceedings of the 3rd ACM SIGSOFT symposium on Foundations of software engineering, p.104-115, October 12-15, 1995, Washington, D.C., United States
|
 |
23
|
|
| |
24
|
|
 |
25
|
|
| |
26
|
|
| |
27
|
|
 |
28
|
|
| |
29
|
R. Ramakrishnan. Magic Templates: A spellbinding approach to logic programming. In JICSLP, 1988.
|
| |
30
|
P. Rao, C. R. Ramakrishnan, and I. V. Ramakrishnan. A thread in time saves tabling time. In Joint International Conference/Symposium on Logic Programming. MIT Press, 1996.
|
| |
31
|
T. W. Reps. Demand interprocedural program analysis using logic databases. In Workshop on Programming with Logic Databases, ILPS, pages 163--196, 1993.
|
 |
32
|
|
| |
33
|
D. Saha and C. R. Ramakrishnan. Incremental and demand-driven points-to analysis using logic programming. Downloads are available at www.lmc.cs.sunysb.edu/~dsaha/incr_pta.
|
| |
34
|
D. Saha and C. R. Ramakrishnan. Incremental evaluation of tabled logic programs. In International Conference on Logic Programming, volume 2916 of LNCS, pages 389--406, 2003.
|
| |
35
|
|
 |
36
|
|
 |
37
|
Zhendong Su , Manuel Fähndrich , Alexander Aiken, Projection merging: reducing redundancies in inclusion constraint graphs, Proceedings of the 27th ACM SIGPLAN-SIGACT symposium on Principles of programming languages, p.81-95, January 19-21, 2000, Boston, MA, USA
[doi> 10.1145/325694.325706]
|
| |
38
|
|
| |
39
|
|
 |
40
|
|
 |
41
|
|
 |
42
|
|
| |
43
|
XSB. The XSB logic programming system. Available from http://xsb.sourceforge.net.
|
 |
44
|
Jyh-shiarn Yur , Barbara G. Ryder , William A. Landi, An incremental flow- and context-sensitive pointer aliasing analysis, Proceedings of the 21st international conference on Software engineering, p.442-451, May 16-22, 1999, Los Angeles, California, United States
[doi> 10.1145/302405.302676]
|
 |
45
|
Jyh-Shiarn Yur , Barbara G. Ryder , William A. Landi , Phil Stocks, Incremental analysis of side effects for C software system, Proceedings of the 19th international conference on Software engineering, p.422-432, May 17-23, 1997, Boston, Massachusetts, United States
[doi> 10.1145/253228.253369]
|
|