Analysis of Object-oriented Programming Languages
|
|
- Eugene Park
- 6 years ago
- Views:
Transcription
1 Analysis of Object-oriented Programming Languages Dr. Barbara G. Ryder Rutgers University OOAnalysis, Dagstuhl 2/03, BG Ryder 1
2 Outline Why do analysis of OOPLs? Dimensions of analysis : cost and precision Examples of analyses Hierarchy-based: CHA, RTA Incorporating flow: XTA, VTA, FieldSens Context-sensitive: Object-sensitive OOAnalysis, Dagstuhl 2/03, BG Ryder 2
3 Object-oriented PL s Construct possible calling structure of program Dynamic dispatch of methods based on runtime type of receiver Understand possible dataflow in program Indirect side effects through reference variables and fields OOAnalysis, Dagstuhl 2/03, BG Ryder 3
4 Uses of Analysis Information in Compilers Object read-write information (flow) Side-effect analysis, dependence analysis Call graph construction (hierarchy) Devirtualization & inlining Synchronization removal (flow) Stack-based object allocation (flow) OOAnalysis, Dagstuhl 2/03, BG Ryder 4
5 Uses of Analysis Information in Software Engineering Tools Object read-write information (flow) Semantic browers Program slicers Debuggers Change impact analysis tools (hierarchy, flow) Testing (flow) Object relationships (Object relation diagrams) Program-based coverage metrics OOAnalysis, Dagstuhl 2/03, BG Ryder 5
6 Dimensions of Reference Analysis Many reference analyses developed over past 10+ years Different algorithm and program representation choices affect precision and cost Need to pose this as a compile-time program analysis with representations for reference variables/fields, objects, classes and program Object representation Can use an abstract object (with or without fields) to represent all objects of a class Can use object instantiations, grouped by some mechanism (e.g., creation sites) OOAnalysis, Dagstuhl 2/03, BG Ryder 6
7 Dimensions of Reference Analysis Reference representation Can use an abstract reference for all references of a particular type Can use reference names with program-wide solutions Can use references representations with per method solutions The analysis can incorporate information about flow of control in the program or ignore it Flow sensitivity (accounts for statement order) Context sensitivity (separates calling contexts) OOAnalysis, Dagstuhl 2/03, BG Ryder 7
8 Dimensions of Reference Analysis Program representation used for analysis can incorporate reachability of methods as part of the analysis or assume all methods are reachable Techniques can be differentiated by their solution formulation and directionality used e.g., for assignments p = q, interpreted as Pts-to(q) Õ Pts-to(p) vs. Pts-to(q) = Pts-to(p) OOAnalysis, Dagstuhl 2/03, BG Ryder 8
9 Hierarchy-based CHA, RTA Incorporating flow Example Analyses XTA, VTA, FieldSens Incorporating calling context Object-sensitive OOAnalysis, Dagstuhl 2/03, BG Ryder 9
10 Class Hierarchy Analysis (CHA) Idea: look at class hierarchy to determine what classes of object can be pointed to by a reference declared to be of class A, in Java this is the subtree in inheritance hierarchy rooted at A, cone (A) to find out what methods may be called at a virtual call site Makes assumption that whole program is available Ignores flow of control Uses 1 abstract object per class J. Dean, D. Grove, C. Chambers, Optimization of OO Programs Using Static Class Hierarchy, ECOOP 95 OOAnalysis, Dagstuhl 2/03, BG Ryder 10
11 Example public class A { public void main(){ A a; D d = new D(); E e = new E(); if ( ) a = d; else a = e; a.f(); public class B extends A { public void foo(){ G g = new G(); //no other object creation sites //or calls A B f() G f() f() D C f() E OOAnalysis, Dagstuhl 2/03, BG Ryder 11
12 B f() G f() A f() D C cone( C ) f() E Example public class A { public void main(){ A a; D d = new D(); E e = new E(); if ( ) a = d; else a = e; a.f(); public class B extends A { public void foo(){ G g = new G(); //no other object creation sites //or calls In CHA solution, a refers to A,B,C,G,D,E objects, d refers to D objects, e refers to E objects, g refers to G objects OOAnalysis, Dagstuhl 2/03, BG Ryder 12
13 CHA call graph Example main A.f() B.f() C.f() G.f() A f() f() B f() G C D f() E public class A { public void main(){ A a; D d = new D(); E e = new E(); if ( ) a = d; else a = e; a.f(); public class B extends A { public void foo(){ G g = new G(); //no other object creation sites //or calls OOAnalysis, Dagstuhl 2/03, BG Ryder 13
14 Call Optimizations Can devirtualize call if receiver s types all resolve to the same method Also can use runtime checks of actual receiver type (through reflection) to cascade through a small number of choices for direct calls, given predictions due to static or dynamic analysis if (s.class == Rectangle) {a= s.rectangle.area() else if (s.class == Circle){a = s.circle.area() else a = s.area();//plain dynamic dispatch OOAnalysis, Dagstuhl 2/03, BG Ryder 14
15 Rapid Type Analysis (RTA) Improves upon CHA Constructs call graph on-the-fly, interleaved with the analysis Only expands a call if has seen an instantiated object of the appropriate type Ignores classes which have not been instantiated as possible receiver types Makes assumption that whole program is available Uses 1 abstract object per class D. Bacon and P. Sweeney, Fast Static Analysis of C++ Virtual Function Calls, OOPSLA 96 OOAnalysis, Dagstuhl 2/03, BG Ryder 15
16 Example public class A { public void main(){ A a; D d = new D(); E e = new E(); if ( ) a = d; else a = e; a.f(); public class B extends A { public void foo(){ G g = new G(); //no other object creation //sites or calls RTA call graph main A.f() B.f() C.f() G.f() B f() G f() A f() C f() D How is this accomplished? RTA starts in main; Keeps track of instantiated classes (D,E). Knows potential targets of a.f(): {A.f(),B.f(),C.f(),G.f(). Expands a.f() into C.f() only. Waits to see object creations of classes A,B,G before expanding others. because execution never reaches B.foo(), algm never sees G instantiated. OOAnalysis, Dagstuhl 2/03, BG Ryder 16 E
17 RTA Findings RTA is better than CHA on virtual function resolution Inference is that call graphs constructed have same node set but not same edge set! Comparison CHA used reachability Claim both algorithms cost about the same because the dominant cost is traversing the methods and identifying call sites Claim that RTA is good enough for call graph construction so that more precise analyses are not necessary for this task OOAnalysis, Dagstuhl 2/03, BG Ryder 17
18 How to improve precision? How to achieve more precision in analysis for slightly increased cost? Incorporate flow in and out of methods Refine abstract object representing a class to include its fields Incorporate locality of reference usage in program into analysis rather than 1 solution per abstract reference variable over the entire program Always use reachability criteria in constructing call graph OOAnalysis, Dagstuhl 2/03, BG Ryder 18
19 Improved on RTA XTA Analysis Track classes propagated into and out of method calls through parameter passing Objects have one representative object per class, with distinct fields Reference variables and fields are solved for grouped by method (not one programwide solution per abstract reference) Tip and Palsberg, Scalable Propagation-based Call Graph Construction Algorithms, OOPSLA 00 OOAnalysis, Dagstuhl 2/03, BG Ryder 19
20 XTA Analysis Do a reachability propagation of classes through an on-the-fly constructed call graph At any point in the algorithm there is a set of reachable methods R, starting from main() Associate a set of classes that reach method M, S M (all references of a class have one abstract representative per method) Use abstract objects with fields to represent all instances of a class Algorithm is iterative and must continue until hits a fixed point. OOAnalysis, Dagstuhl 2/03, BG Ryder 20
21 XTA Analysis Q: How to expand virtual e.m() in reachable method M? Expand virtual call only by appropriate C Œ S M where C Œ cone(declaredtype(e)) to call M Make M reachable Add cone(paramtype(m ))«S M to S M (adds possible actual param types for M from M, to set of classes that reach M ) Add cone(returntype(m )) «S M to S M Add C to S M For each object created in M (new A()), if M is reachable, then A Œ S M For each field read =*.f in M, if M is reachable, then S f Õ S M For each field write *.f = in M, if M is reachable, then cone(declaredtype(f)) «S M Õ S f OOAnalysis, Dagstuhl 2/03, BG Ryder 21
22 {A,B static void main(){ B b1 = new B(); A a1 = new A(); f(b1); g(b1); {A,B static void f(a a2){ a2.foo(); {B,C static void g(b b2){ B b3 = b2; b3 = new C(); b3.foo(); Example of XTA class A { foo(){.. class B extends A{ foo() { class C extends B{ foo() { class D extends B{ cf Frank Tip, OOPSLA 00 foo(){ OOAnalysis, Dagstuhl 2/03, BG Ryder 22
23 Comparison with CHA static void main(){ B b1 = new B(); A a1 = new A(); f(b1); g(b1); static void f(a a2){ a2.foo(); static void g(b b2){ B b3 = b2; b3 = new C(); b3.foo(); class A { cf Frank Tip, OOPSLA 00 foo(){.. class B extends A{ foo() { class C extends B{ foo() { class D extends B{ foo(){ OOAnalysis, Dagstuhl 2/03, BG Ryder 23
24 Comparison with RTA cf Frank Tip, OOPSLA 00 static void main(){ B b1 = new B(); A a1 = new A(); f(b1); g(b1); static void f(a a2){ a2.foo(); static void g(b b2){ B b3 = b2; b3 = new C(); b3.foo(); class A { foo(){.. class B extends A{ foo() { class C extends B{ foo() { class D extends B{ foo(){ OOAnalysis, Dagstuhl 2/03, BG Ryder 24
25 Actual Solution static void main(){ B b1 = new B(); A a1 = new A(); f(b1); g(b1); static void f(a a2){ a2.foo(); static void g(b b2){ B b3 = b2; b3 = new C(); b3.foo(); class A { cf Frank Tip, OOPSLA 00 foo(){.. class B extends A{ foo() { class C extends B{ foo() { class D extends B{ foo(){ OOAnalysis, Dagstuhl 2/03, BG Ryder 25
26 XTA Findings The reachable methods set (i.e., call graph nodes) is somewhat reduced over that of RTA The number of edges in the call graph is significantly reduced by XTA over RTA (.3%-29% fewer, 7% on average) Data in paper gives comparison restricted to those calls that RTA found to be polymorphic and found could often devirtualize them OOAnalysis, Dagstuhl 2/03, BG Ryder 26
27 VTA - Variable Type Analysis How works? follows type propagation from an object creation site through plausible chains of assignments to reference variables Builds a type propagation graph, using a CHA call graph Nodes are reference variables/fields/parameters Edges represent reference to reference assignments Initializes types for some reference nodes from an associated object creation site Propagates types along directed edges cf. V.Sundaresan, et. al, Practical Virtual Method Call Resolution for Java, OOPSLA 00 OOAnalysis, Dagstuhl 2/03, BG Ryder 27
28 VTA Example static void main(){ B b1 = new B(); A a1 = new A(); f(b1); g(b1); static void f(a a2){ a2.foo(); static void g(b b2){ B b3 = b2; b3 = new C(); b3.foo(); class A { foo(){.. class B extends A{ foo() { class C extends B{ foo() { class D extends B{ foo(){ {B {B {C a1 b1 a2 b2 b3 {A {B {B {B,C OOAnalysis, Dagstuhl 2/03, BG Ryder 28
29 Points-to Analyses for C Popular flow- and context-insensitive formulations of points-to analysis Scalable Good enough for ensuring safety of some optimizations Good for program understanding applications Not great for applications needing precise def-use information (e.g., program slicing, testing) General approach is unification or inclusion constraints Newer versions kept track of individual struct fields as pointer targets Extended to points-to analyses for OOPL reference variables OOAnalysis, Dagstuhl 2/03, BG Ryder 29
30 Points-to Analyses for C Steensgaard s algorithm (POPL 96) Uses unification constraints so that for pointer assignments, p = q, algorithm makes Pts-to(p)=Pts-to(q) This union operation is done recursively for multiple-level pointers Reduces the size of the points-to graph (in terms of both nodes and edges) Almost linear solution time in terms of program size, O(n) using fast union-find algorithm Imprecision stems from merging points-to sets One points-to set per pointer variable over entire program OOAnalysis, Dagstuhl 2/03, BG Ryder 30
31 cf M Shapiro and S. Horwitz, Fast and Accurate Flow-insensitive Points-to Analysis POPL 97 Steensgaard - Example a b c a b c d e 4 d 3 e 1.a = &b 2.b = &c 3.d = &e 4.a = &d Points-to sets found 1 a b 2 c 4 d e a b,d c,e 4 OOAnalysis, Dagstuhl 2/03, BG Ryder 31
32 Steensgaard Solution Procedure - At a glance Find all pointer assignments in program Form set of points-to graph nodes from pointer variables/fields and variables (in the heap or whose address has been taken) Examine each statement, in arbitrary order, and construct points-to edges Merge nodes (and edges) where indicated by unification constraints After linear pass over these assignments, points-to graph is complete OOAnalysis, Dagstuhl 2/03, BG Ryder 32
33 Points-to Analysis for C Andersen s analysis (Thesis 1994) Uses inclusion constraints so that for pointer assignments, p = q, algorithm makes Pts-to(q) Õ Pts-to(p) Points-to graph is larger than Steensgaard s and more precise Cubic worst case complexity in program size, O(n 3 ) One points-to set per pointer variable over entire program OOAnalysis, Dagstuhl 2/03, BG Ryder 33
34 Andersen - Example 1.a = &b 2.b = &c 3.d = &e 4.a = &d 5.d = &f 6.g = d 7.g = *a a 1 2 b c 4 g 3 d e 5 f 6 Steensgaard solution 7 a 1 2 b c 4 d e 6 4 OOAnalysis, Dagstuhl 2/03, BG Ryder 34
35 Andersen s Solution Procedure - At a glance Find all pointer assignments in program Form set of points-to graph nodes from pointer variables/fields and variables on the heap or whose address is taken Examine each statement, in arbitrary order, and construct points-to edges Need to create more edges when see p = q type assignments so that all outgoing points-to edges from q are copied to be outgoing from p (i.e. processing inclusion constraints) If new outgoing edges are added to q during the algorithm, they must be also copied to p Work results in O(n 3 ) worst case cost OOAnalysis, Dagstuhl 2/03, BG Ryder 35
36 FieldSens Points-to Analysis Based on Andersen s points-to analysis Define and solve a system of annotated setinclusion constraints Handles virtual calls by simulation of run-time method lookup Models the fields of objects Extended BANE (UC Berkeley) constraint solver Analyzes only possibly executed code Ignores unreachable code from libraries Rountev, A. Milnova, B. Ryder, Points-to Analysis for Java Using Annotated Constraints OOPSLA 01 OOAnalysis, Dagstuhl 2/03, BG Ryder 36
37 Example of Points-to Analysis class A { void m(x p) {.. class B extends A { X f; void m(x q) { this.f=q; B b = new B(); X x = new X(); A a = b; a.m(x); A.m() not analyzed because it s unreachable. a b o 1 this B.m f x o 2 q OOAnalysis, Dagstuhl 2/03, BG Ryder 37
38 Annotated Constraints Form: L Õ a R L and R denote set expressions Annotation a: additional information (e.g., object fields) Kinds of set expressions L and R Set variables: represent points-to sets ref terms: represent objects Other kinds of expressions OOAnalysis, Dagstuhl 2/03, BG Ryder 38
39 Set variables and ref terms Set variables represent points-to sets For each reference variable p: V P For each object o: V o Object o is denoted by term ref(o,v o ) p o ref(o,v o ) Õ V P o f 1 o 2 ref(o 2,V o2 ) Õ f V o 1 OOAnalysis, Dagstuhl 2/03, BG Ryder 39
40 Example: Accessing Fields p = new A(); q = new B(); p.f = q; p o 1 ref(o 1,V O1 ) Õ V p ref(o 2,V O2 ) Õ V q V p Õ proj(ref,w) V q Õ f W q o 2 f Constraint generation OOAnalysis, Dagstuhl 2/03, BG Ryder 40
41 Example: Solving Constraints ref(o 1,V O1 ) Õ V p ref(o 2,V O2 ) Õ V q V p Õ proj(ref,w) Constraint resolution V q Õ f W W Õ V O1 o 1.f points to o 2 V q Õ f V O 1 ref(o 2,V O2 ) Õ f V O 1 OOAnalysis, Dagstuhl 2/03, BG Ryder 41
42 Example: Virtual Calls p.m(x); V P Õ m lam(v x ) receiver object o ref(o,v O ) Õ V P Actual method called, A.m V x Õ V z ref(o,v O ) Õ V this(a.m) OOAnalysis, Dagstuhl 2/03, BG Ryder 42
43 FieldSens Findings Empirical testing found Significant precision gains over RTA at call sites found to be polymorphic by CHA Could use points-to info in client analysis Object read-write information Synchronization removal (thread-local) Stack allocation (method-local) OOAnalysis, Dagstuhl 2/03, BG Ryder 43
44 Imprecision of Context Insensitivity class Y extends X { class A { X f; void m(x q) { this.f=q ; A a = new A() ; a.m(new X()) ; A aa = new A() ; aa.m(new Y()) ; a this A.m o 1 o 2 aa o 3 f o 4 f f f q OOAnalysis, Dagstuhl 2/03, BG Ryder 44
45 Object-sensitive Analysis Form of functional context sensitivity for flow-insensitive analysis of OO languages Formulate an object-sensitive Andersen s (points-to) analysis Analysis of instance methods and constructors distinguished for different contexts Receiver objects used to distinguish calling contexts Empirical evaluation vs. context-insensitive FieldSens analysis this, formals and return variables (effectively) replicated OOAnalysis, Dagstuhl 2/03, BG Ryder 45
46 Example: Object-sensitive Analysis o1 class A { X f; void m(x q) { this o1 o3 o1 A.m this.f=q o3; A a = new A() ; a.m(new X()) ; A aa = new A() ; aa.m(new Y()) ; OOAnalysis, Dagstuhl 2/03, BG Ryder 46 a o this 1 A.m o 1 f o 2 aa o 3 o 4 o q 1 A.m o 3 this A.m o 3 q A.m f
47 ObjSens Findings Precision gains for problems such as def-uses for object fields and side effect analysis (per statement) for practically no additional cost Clients Program test coverage metrics Program slicing Program understanding tools A. Milanova, A. Rountev, and B. Ryder. Parameterized object-sensitivity for points-to and side-effect analyses for Java. In International Symposium on Software Testing and Analysis, pages 1 11, OOAnalysis, Dagstuhl 2/03, BG Ryder 47
48 Context Sensitivity Distinguishes calling contexts Classically, has two forms (Sharir&Pneuli, 1983) Call string - keep (possibly truncated) call stack at call site associated with df solution Functional - keep (some) program state at call site associated with df solution OOAnalysis, Dagstuhl 2/03, BG Ryder 48
49 Incomparable Approaches to //in class R, w.subclasses Y,Z public R m(x x) { return x; R r = new R();//O 0 Y y = new Y();//O 1 Z z = new Z();//O 2 C1: y = r.m(y); C2: z = r.m(z); //ObjSens will report both y,z can point-to {O 1 O 2 because both calls C1,C2 have same receiver object; Call stack will separate effects of the two calls Context Sensitivity //in class R, w subclasses Y,Z public R m(x x) {return x; If (..) {r = new R();//O 1 y = new Y();//O 2 else {r = new R();//O 3 y = new Z();//O 4 C1: z = r.m(y); //call stack will combine effects of the two calls; ObjSens will differentiate the two dynamic calls by receiver objects O 1 O 3 OOAnalysis, Dagstuhl 2/03, BG Ryder 49
50 Recent Context-insensitive Points-to Analyses Liang et. al, Paste 01 Empirical comparison of flow- and context-insensitive analyses Steensgaard- and Andersen-based analyses for Java Static call graph (CHA, RTA) with on-the-fly Experiments with instance fields and abstract class fields Found Andersen (inclusion) analyses significantly more precise than Steensgaard (unification) Whaley and Lam, SAS 02 OOAnalysis, Dagstuhl 2/03, BG Ryder 50
51 More Reference Analyses Context-sensitive reference analyses Palsberg and Schwartzbach OOPSLA 91 Oxhoj, Palsberg, Schwartzbach ECOOP 92 Plevyak and Chien OOPSLA 94 Agesen ECOOP 95 Chatterjee, Ryder, Landi POPL 99 Ruf PLDI 00 Grove and Chambers TOPLAS 01 Most judged too expensive to scale in practice OOAnalysis, Dagstuhl 2/03, BG Ryder 51
52 Summary Have given overview of many reference analyses for OOPLs Many dimensions of design differences possible Key question: For a particular problem, how to select the analysis with appropriate precision and cost? OOAnalysis, Dagstuhl 2/03, BG Ryder 52
53 References O. Agesen. The cartesian product algorithm: Simple and precise type inference of parametric polymorphism. In European Conference on Object Oriented Programming, pages 2 26, 1995 L. O. Andersen. Program analysis and specialization for the C programming language. PhD thesis, DIKU, University of Copenhagen, Also available as DIKU report 94/19. D. Bacon and P. Sweeney, Fast Static Analysis of C++ Virtual Function Calls, OOPSLA 96 R. Chatterjee. Modular Data-flow Analysis of Statically Typed Objectoriented Programming Languages. PhD thesis, Department of Computer Science, Rutgers University, October R. Chatterjee, B. G. Ryder, and W. Landi. Relevant context inference. In Symposium onprinciples of Programming Languages, pages , J. Dean, D. Grove, C. Chambers, Optimization of OO Programs Using Static Class Hierarchy, ECOOP 95 OOAnalysis, Dagstuhl 2/03, BG Ryder 53
54 References David Grove and Craig Chambers. A framework for call graph construction algorithms. ACM Transactions on Programming Languages and Systems (TOPLAS), 23(6), Donglin Liang, Maikel Pennings, and Mary Jean Harrold. Evaluating the precision of static reference analysis using profiling. In Proceedings of the international symposium on Software testing and analysis, pages ACM Press, 2002 A. Milanova, A. Rountev, and B. Ryder. Parameterized object-sensitivity for points-to and side-effect analyses for Java. In International Symposium on Software Testing and Analysis, pages 1 11, N. Oxhoj, J. Palsberg, and M. Schwartzbach. Making type inference practical. In European Conference on Object-Oriented Programming, pages , J. Palsberg and M. Schwartzbach. Object-oriented type inference. In Conference on Object-Oriented Programming Systems, Languages, and Applications, pages , OOAnalysis, Dagstuhl 2/03, BG Ryder 54
55 References J. Plevyak and A. Chien. Precise concrete type inference for object oriented languages. In Proceeding of Conference on Object-Oriented Programming Systems, Languages and Applications.(OOPSLA 94), pages , October Rountev, A. Milnova, B. Ryder, Points-to Analysis for Java Using Annotated Constraints, OOPSLA 01 E. Ruf. Context-insensitive alias analysis reconsidered. In Proceedings of the SIGPLAN 95 Conference on Programming Language Design and Implementation, pages 13 22, June1995. Bjarne Steensgaard. Points-to analysis in almost linear time. In Conference Record of the Twenty-third Annual ACM SIGACT/SIGPLAN Symposium on Principles of Programming Languages, pages 32 41, V.Sundaresan, et. al, Practical Virtual Method Call Resolution for Java, OOPSLA 00 Tip and Palsberg, Scalable Propagation-based Call Graph Construction Algorithms, OOPSLA 00 J. Whaley and M. Lam. An efficient inclusion-based points-to analysis for strictly-typed languages. In Static Analysis Symposium, OOAnalysis, Dagstuhl 2/03, BG Ryder 55
OOPLs - call graph construction. Example executed calls
OOPLs - call graph construction Compile-time analysis of reference variables and fields Problem: how to resolve virtual function calls? Need to determine to which objects (or types of objects) a reference
More informationReference Analyses. VTA - Variable Type Analysis
Reference Analyses Variable Type Analysis for Java Related points-to analyses for C Steengaard Andersen Field-sensitive points-to for Java Object-sensitive points-to for Java Other analysis approaches
More informationDimensions of Precision in Reference Analysis of Object-oriented Programming Languages. Outline
Dimensions of Precision in Reference Analysis of Object-oriented Programming Languages Dr. Barbara G. Ryder Rutgers University http://www.cs.rutgers.edu/~ryder http://prolangs.rutgers.edu/ Research supported,
More informationOOPLs - call graph construction Compile-time analysis of reference variables and fields. Example
OOPLs - call graph construction Compile-time analysis of reference variables and fields Determines to which objects (or types of objects) a reference variable may refer during execution Primarily hierarchy-based
More informationPoints-to Analysis for Java Using Annotated Constraints*
Points-to Analysis for Java Using Annotated Constraints* Dr. Barbara G. Ryder Rutgers University http://www.cs.rutgers.edu/~ryder http://prolangs.rutgers.edu/ *Joint research with Atanas Rountev and Ana
More informationExtra notes on Field- sensitive points- to analysis with inclusion constraints Sept 9, 2015
Extra notes on Field- sensitive points- to analysis with inclusion constraints Sept 9, 2015 Week 3 CS6304 The Rountev et al. paper at OOPSLA 2000 extended Andersen s points- to analysis for C programs
More informationDimensions of Precision in Reference Analysis of Object-Oriented Programming Languages
Dimensions of Precision in Reference Analysis of Object-Oriented Programming Languages Barbara G. Ryder Division of Computer and Information Sciences Rutgers University New Brunswick, New Jersey 08903
More informationAdvanced Program Analyses for Object-oriented Systems
Advanced Program Analyses for Object-oriented Systems Dr. Barbara G. Ryder Rutgers University http://www.cs.rutgers.edu/~ryder http://prolangs.rutgers.edu/ July 2007 ACACES-3 July 2007 BG Ryder 1 Lecture
More informationInterprocedural Analysis with Data-Dependent Calls. Circularity dilemma. A solution: optimistic iterative analysis. Example
Interprocedural Analysis with Data-Dependent Calls Circularity dilemma In languages with function pointers, first-class functions, or dynamically dispatched messages, callee(s) at call site depend on data
More informationInterprocedural Analysis with Data-Dependent Calls. Circularity dilemma. A solution: optimistic iterative analysis. Example
Interprocedural Analysis with Data-Dependent Calls Circularity dilemma In languages with function pointers, first-class functions, or dynamically dispatched messages, callee(s) at call site depend on data
More informationAdvanced Program Analyses for Object-oriented Systems
Advanced Program Analyses for Object-oriented Systems Dr Barbara G Ryder Rutgers University http://wwwcsrutgersedu/~ryder http://prolangsrutgersedu/ July 2007 PROLANGS Languages/Compilers and Software
More informationClass Analysis for Testing of Polymorphism in Java Software
Class Analysis for Testing of Polymorphism in Java Software Atanas Rountev Ana Milanova Barbara G. Ryder Rutgers University, New Brunswick, NJ 08903, USA {rountev,milanova,ryder@cs.rutgers.edu Abstract
More informationScaling Java Points-to Analysis Using Spark
Scaling Java Points-to Analysis Using Spark Ondřej Lhoták and Laurie Hendren Sable Research Group, McGill University, Montreal, Canada {olhotak,hendren}@sable.mcgill.ca Abstract. Most points-to analysis
More informationLecture Notes: Pointer Analysis
Lecture Notes: Pointer Analysis 15-819O: Program Analysis Jonathan Aldrich jonathan.aldrich@cs.cmu.edu Lecture 9 1 Motivation for Pointer Analysis In programs with pointers, program analysis can become
More informationCO444H. Ben Livshits. Datalog Pointer analysis
CO444H Ben Livshits Datalog Pointer analysis 1 Call Graphs Class analysis: Given a reference variable x, what are the classes of the objects that x refers to at runtime? We saw CHA and RTA Deal with polymorphic/virtual
More informationAdvanced Compiler Construction
CS 526 Advanced Compiler Construction http://misailo.cs.illinois.edu/courses/cs526 INTERPROCEDURAL ANALYSIS The slides adapted from Vikram Adve So Far Control Flow Analysis Data Flow Analysis Dependence
More informationThread-Sensitive Points-to Analysis for Multithreaded Java Programs
Thread-Sensitive Points-to Analysis for Multithreaded Java Programs Byeong-Mo Chang 1 and Jong-Deok Choi 2 1 Dept. of Computer Science, Sookmyung Women s University, Seoul 140-742, Korea chang@sookmyung.ac.kr
More informationLecture Notes: Pointer Analysis
Lecture Notes: Pointer Analysis 17-355/17-665/17-819: Program Analysis (Spring 2019) Jonathan Aldrich aldrich@cs.cmu.edu 1 Motivation for Pointer Analysis In the spirit of extending our understanding of
More informationStatic Program Analysis Part 8 control flow analysis
Static Program Analysis Part 8 control flow analysis http://cs.au.dk/~amoeller/spa/ Anders Møller & Michael I. Schwartzbach Computer Science, Aarhus University Agenda Control flow analysis for the -calculus
More informationContext-sensitive points-to analysis: is it worth it?
McGill University School of Computer Science Sable Research Group Context-sensitive points-to analysis: is it worth it? Sable Technical Report No. 2005-2 Ondřej Lhoták Laurie Hendren October 21, 2005 w
More informationIdentifying Parallelism in Construction Operations of Cyclic Pointer-Linked Data Structures 1
Identifying Parallelism in Construction Operations of Cyclic Pointer-Linked Data Structures 1 Yuan-Shin Hwang Department of Computer Science National Taiwan Ocean University Keelung 20224 Taiwan shin@cs.ntou.edu.tw
More informationAlias Analysis. Last time Interprocedural analysis. Today Intro to alias analysis (pointer analysis) CS553 Lecture Alias Analysis I 1
Alias Analysis Last time Interprocedural analysis Today Intro to alias analysis (pointer analysis) CS553 Lecture Alias Analysis I 1 Aliasing What is aliasing? When two expressions denote the same mutable
More informationCS711 Advanced Programming Languages Pointer Analysis Overview and Flow-Sensitive Analysis
CS711 Advanced Programming Languages Pointer Analysis Overview and Flow-Sensitive Analysis Radu Rugina 8 Sep 2005 Pointer Analysis Informally: determine where pointers (or references) in the program may
More informationContext-sensitive points-to analysis: is it worth it?
Context-sensitive points-to analysis: is it worth it? Ondřej Lhoták 1,2 and Laurie Hendren 2 olhotak@uwaterloo.ca hendren@sable.mcgill.ca 1 School of Computer Science, University of Waterloo, Waterloo,
More informationParameterized Object Sensitivity for Points-to Analysis for Java. Authors: Ana Milanova, Atanas Rountev, Barbara G. Ryder Presenter: Zheng Song
Parameterized Object Sensitivity for Points-to Analysis for Java Authors: Ana Milanova, Atanas Rountev, Barbara G. Ryder Presenter: Zheng Song Outlines Introduction Existing Method and its limitation Object
More informationLecture 2: Control Flow Analysis
COM S/CPRE 513 x: Foundations and Applications of Program Analysis Spring 2018 Instructor: Wei Le Lecture 2: Control Flow Analysis 2.1 What is Control Flow Analysis Given program source code, control flow
More informationInterprocedural Dataflow Analysis. Galeotti/Gorla/Rau Saarland University
Interprocedural Dataflow Analysis Galeotti/Gorla/Rau Saarland University int divbyx(int x) { [result := 10/x] 1 ; void caller1() { [x := 5] 1 ; [y := divbyx(x)] 2 ; [y := divbyx(5)] 3 ; [y := divbyx(1)]
More informationAbstract Interpretation and Object-oriented Programming: Quo Vadis?
Electronic Notes in Theoretical Computer Science 131 (2005) 75 84 www.elsevier.com/locate/entcs Abstract Interpretation and Object-oriented Programming: Quo Vadis? Francesco Logozzo 1 École Polytechnique
More informationEfficient Separate Compilation of Object-Oriented Languages
Efficient Separate Compilation of Object-Oriented Languages Jean Privat, Floréal Morandat, and Roland Ducournau LIRMM Université Montpellier II CNRS 161 rue Ada 34392 Montpellier cedex 5, France {privat,morandat,ducour}@lirmm.fr
More informationAlias Analysis & Points-to Analysis. Hwansoo Han
Alias Analysis & Points-to Analysis Hwansoo Han May vs. Must Information May information The information is true on some path through a CFG Must information The information is true on all paths through
More informationHelping Programmers Debug Code Using Semantic Change Impact Analysis PROLANGS
Helping Programmers Debug Code Using Semantic Change Impact Analysis Dr. Barbara G. Ryder Rutgers University http://www.cs.rutgers.edu/~ryder This research is supported by NSF grants CCR-0204410 & CCR-0331797
More informationRefinement-Based Context-Sensitive Points-To Analysis for Java
Refinement-Based Context-Sensitive Points-To Analysis for Java Manu Sridharan, Rastislav Bodík UC Berkeley PLDI 2006 1 What Does Refinement Buy You? Increased scalability: enable new clients Memory: orders
More informationContext-Sensitive Pointer Analysis. Recall Context Sensitivity. Partial Transfer Functions [Wilson et. al. 95] Emami 1994
Context-Sensitive Pointer Analysis Last time Flow-insensitive pointer analysis Today Context-sensitive pointer analysis Emami invocation graphs Partial Transfer Functions The big picture Recall Context
More informationStatic Program Analysis Part 9 pointer analysis. Anders Møller & Michael I. Schwartzbach Computer Science, Aarhus University
Static Program Analysis Part 9 pointer analysis Anders Møller & Michael I. Schwartzbach Computer Science, Aarhus University Agenda Introduction to points-to analysis Andersen s analysis Steensgaards s
More informationParameterized Object Sensitivity for Points-to Analysis for Java
Parameterized Object Sensitivity for Points-to Analysis for Java Ana Milanova Dept. Computer Science Rensselaer Polytechnic Institute milanova@cs.rpi.edu Atanas Rountev Dept. Computer Science and Engineering
More informationEvaluating a Demand Driven Technique for Call Graph Construction
Evaluating a Demand Driven Technique for Call Graph Construction Gagan Agrawal 1,JinqianLi 2, and Qi Su 2 1 Department of Computer and Information Sciences, Ohio State University Columbus, OH 43210 agrawal@cis.ohio-state.edu
More informationScaling Java Points-To Analysis using Spark
McGill University School of Computer Science Sable Research Group Scaling Java Points-To Analysis using Spark Sable Technical Report No. 2002-9 Ondřej Lhoták and Laurie Hendren October 24, 2002 w w w.
More informationLecture 14 Pointer Analysis
Lecture 14 Pointer Analysis Basics Design Options Pointer Analysis Algorithms Pointer Analysis Using BDDs Probabilistic Pointer Analysis [ALSU 12.4, 12.6-12.7] Phillip B. Gibbons 15-745: Pointer Analysis
More informationHierarchical Pointer Analysis for Distributed Programs
Hierarchical Pointer Analysis for Distributed Programs Amir Kamil Computer Science Division, University of California, Berkeley kamil@cs.berkeley.edu April 14, 2006 1 Introduction Many distributed, parallel
More informationAlias Analysis. Advanced Topics. What is pointer analysis? Last Time
Advanced Topics Last Time Experimental Methodology Today What s a managed language? Alias Analysis - dealing with pointers Focus on statically typed managed languages Method invocation resolution Alias
More informationAnnotated Inclusion Constraints for Precise Flow Analysis
Annotated Inclusion Constraints for Precise Flow Analysis Ana Milanova Department of Computer Science Rensselaer Polytechnic Institute milanova@cs.rpi.edu Barbara G. Ryder Department of Computer Science
More informationEfficient Separate Compilation of Object-Oriented Languages
Efficient Separate Compilation of Object-Oriented Languages Jean Privat, Floréal Morandat, and Roland Ducournau LIRMM Université Montpellier II CNRS 161 rue Ada 34392 Montpellier cedex 5, France {privat,morandat,ducour}@lirmm.fr
More informationTowards Dynamic Interprocedural Analysis in JVMs
Towards Dynamic Interprocedural Analysis in JVMs Feng Qian Laurie Hendren School of Computer Science, McGill University 3480 University Street, Montreal, Quebec Canada H3A 2A7 {fqian,hendren}@cs.mcgill.ca
More informationLecture 20 Pointer Analysis
Lecture 20 Pointer Analysis Basics Design Options Pointer Analysis Algorithms Pointer Analysis Using BDDs Probabilistic Pointer Analysis (Slide content courtesy of Greg Steffan, U. of Toronto) 15-745:
More informationA Context-Sensitive Memory Model for Verification of C/C++ Programs
A Context-Sensitive Memory Model for Verification of C/C++ Programs Arie Gurfinkel and Jorge A. Navas University of Waterloo and SRI International SAS 17, August 30th, 2017 Gurfinkel and Navas (UWaterloo/SRI)
More informationDemand-Driven Points-To Analysis For Java
Demand-Driven Points-To Analysis For Java Manu Sridharan, Ras Bodik Lexin Shan Denis Gopan UC Berkeley Microsoft UW Madison OOPSLA 2005 1 Who needs better pointer analysis? IDEs: for refactoring, program
More informationShort Notes of CS201
#includes: Short Notes of CS201 The #include directive instructs the preprocessor to read and include a file into a source code file. The file name is typically enclosed with < and > if the file is a system
More informationLecture 27. Pros and Cons of Pointers. Basics Design Options Pointer Analysis Algorithms Pointer Analysis Using BDDs Probabilistic Pointer Analysis
Pros and Cons of Pointers Lecture 27 Pointer Analysis Basics Design Options Pointer Analysis Algorithms Pointer Analysis Using BDDs Probabilistic Pointer Analysis Many procedural languages have pointers
More informationStatic Analysis for Dynamic Coupling Measures
Static Analysis for Dynamic Coupling Measures Yin Liu Ana Milanova Department of Computer Science Rensselaer Polytechnic Institute Troy, NY 12180, USA {liuy,milanova}@cs.rpi.edu Abstract Coupling measures
More informationCS201 - Introduction to Programming Glossary By
CS201 - Introduction to Programming Glossary By #include : The #include directive instructs the preprocessor to read and include a file into a source code file. The file name is typically enclosed with
More informationMethod Resolution Approaches. Dynamic Dispatch
Method Resolution Approaches Static - procedural languages (w/o fcn ptrs) Dynamically determined by data values C with function pointers Compile-time analysis can estimate possible callees Dynamically
More informationLecture 16 Pointer Analysis
Pros and Cons of Pointers Lecture 16 Pointer Analysis Basics Design Options Pointer Analysis Algorithms Pointer Analysis Using BDDs Probabilistic Pointer Analysis Many procedural languages have pointers
More informationPractical Virtual Method Call Resolution for Java
Practical Virtual Method Call Resolution for Java Sable TR 1999-2 10/4/99 1 Introduction Objective To determine at compile time a call graph with as few nodes and edges as possible Background.Soot Framework
More informationCombining Analyses, Combining Optimizations - Summary
Combining Analyses, Combining Optimizations - Summary 1. INTRODUCTION Cliff Click s thesis Combining Analysis, Combining Optimizations [Click and Cooper 1995] uses a structurally different intermediate
More informationCloning-Based Context-Sensitive Pointer Alias Analysis using BDDs
More Pointer Analysis Last time Flow-Insensitive Pointer Analysis Inclusion-based analysis (Andersen) Today Class projects Context-Sensitive analysis March 3, 2014 Flow-Insensitive Pointer Analysis 1 John
More informationMaking Context-sensitive Points-to Analysis with Heap Cloning Practical For The Real World
Making Context-sensitive Points-to Analysis with Heap Cloning Practical For The Real World Chris Lattner Apple Andrew Lenharth UIUC Vikram Adve UIUC What is Heap Cloning? Distinguish objects by acyclic
More informationConstructing Control Flow Graph for Java by Decoupling Exception Flow from Normal Flow
Constructing Control Flow Graph for Java by Decoupling Exception Flow from Normal Flow Jang-Wu Jo 1 and Byeong-Mo Chang 2 1 Department of Computer Engineering Pusan University of Foreign Studies Pusan
More informationEstimating the Impact of Scalable Pointer Analysis on Optimization
Estimating the Impact of Scalable Pointer Analysis on Optimization Manuvir Das 1, Ben Liblit 2,ManuelFähndrich 1,andJakobRehof 1 1 Microsoft Research {manuvir,maf,rehof}@microsoft.com 2 EECS Department,
More informationProgram Static Analysis. Overview
Program Static Analysis Overview Program static analysis Abstract interpretation Data flow analysis Intra-procedural Inter-procedural 2 1 What is static analysis? The analysis to understand computer software
More informationBottom-up Context-Sensitive Pointer Analysis for Java
Bottom-up Context-Sensitive Pointer Analysis for Java Yu Feng, Xinyu Wang, Isil Dillig and Thomas Dillig UT Austin 1 What is this talk about? Pointer analysis Given a program variable v, what are the heap
More informationInterprocedural Analysis. CS252r Fall 2015
Interprocedural Analysis CS252r Fall 2015 Procedures So far looked at intraprocedural analysis: analyzing a single procedure Interprocedural analysis uses calling relationships among procedures Enables
More informationThe popularity of the Java programming
BY FRANK TIP, PETER F. SWEENEY, AND CHRIS LAFFRA EXTRACTING LIBRARY-BASED JAVA APPLICATIONS Reducing the size of Java applications by creating an application extractor. The popularity of the Java programming
More informationCalvin Lin The University of Texas at Austin
Interprocedural Analysis Last time Introduction to alias analysis Today Interprocedural analysis March 4, 2015 Interprocedural Analysis 1 Motivation Procedural abstraction Cornerstone of programming Introduces
More informationPointer Analysis in the Presence of Dynamic Class Loading
Pointer Analysis in the Presence of Dynamic Class Loading Martin Hirzel 1, Amer Diwan 1, and Michael Hind 2 1 University of Colorado, Boulder, CO 80309, USA {hirzel,diwan}@cs.colorado.edu 2 IBM Watson
More informationLecture 16: Object Programming Languages
Lecture 16: Object Programming Languages Introduction Corresponds to EOPL 5.1 and 5.2 Goal: to introduce Object Oriented Programming Language (OOPL) concepts using the EOPL extensible language framework
More informationPointer Analysis. Lecture 40 (adapted from notes by R. Bodik) 5/2/2008 Prof. P. N. Hilfinger CS164 Lecture 40 1
Pointer Analysis Lecture 40 (adapted from notes by R. Bodik) 5/2/2008 Prof. P. N. Hilfinger CS164 Lecture 40 1 2 Today Points-to analysis an instance of static analysis for understanding pointers Andersen
More informationPoints-to Analysis of RMI-based Java Programs
Computing For Nation Development, February 25 26, 2010 Bharati Vidyapeeth s Institute of Computer Applications and Management, New Delhi Points-to Analysis of RMI-based Java Programs Yogesh Pingle M.E.(Comp.),
More informationCOMP 181. Agenda. Midterm topics. Today: type checking. Purpose of types. Type errors. Type checking
Agenda COMP 181 Type checking October 21, 2009 Next week OOPSLA: Object-oriented Programming Systems Languages and Applications One of the top PL conferences Monday (Oct 26 th ) In-class midterm Review
More informationA Type System for Functional Traversal-Based Aspects
A Type System for Functional Traversal-Based Aspects Bryan Chadwick and Karl Lieberherr March 2 nd 2009 1 / 30 Outline Introduction Example (Pure) Semantics Example (Full Dispatch) Type System Soundness
More informationCSE 501 Midterm Exam: Sketch of Some Plausible Solutions Winter 1997
1) [10 pts] On homework 1, I asked about dead assignment elimination and gave the following sample solution: 8. Give an algorithm for dead assignment elimination that exploits def/use chains to work faster
More informationInterprocedural Analysis. Motivation. Interprocedural Analysis. Function Calls and Pointers
Interprocedural Analysis Motivation Last time Introduction to alias analysis Today Interprocedural analysis Procedural abstraction Cornerstone of programming Introduces barriers to analysis Example x =
More informationPredicting Runtime Data Dependences for Slice Inspection Prioritization
Predicting Runtime Data Dependences for Slice Inspection Prioritization Yiji Zhang and Raul Santelices University of Notre Dame Notre Dame, Indiana, USA E-mail: {yzhang20 rsanteli}@nd.edu Abstract Data
More informationIntermediate Code, Object Representation, Type-Based Optimization
CS 301 Spring 2016 Meetings March 14 Intermediate Code, Object Representation, Type-Based Optimization Plan Source Program Lexical Syntax Semantic Intermediate Code Generation Machine- Independent Optimization
More informationField Analysis. Last time Exploit encapsulation to improve memory system performance
Field Analysis Last time Exploit encapsulation to improve memory system performance This time Exploit encapsulation to simplify analysis Two uses of field analysis Escape analysis Object inlining April
More informationFaculty of Electrical Engineering, Mathematics, and Computer Science Delft University of Technology
Faculty of Electrical Engineering, Mathematics, and Computer Science Delft University of Technology exam Compiler Construction in4020 July 5, 2007 14.00-15.30 This exam (8 pages) consists of 60 True/False
More informationReusing Run-Time Type Identification (RTTI) Generated By Compiler For Construction Of The Class Hierarchy Graph (CHG).
IOSR Journal of Computer Engineering (IOSRJCE) ISSN: 2278-0661 Volume 2, Issue 6 (July-Aug. 2012), PP 05-12 Reusing Run-Time Type Identification (RTTI) Generated By Compiler For Construction Of The Class
More informationDynamic Points-To Sets: A Comparison with Static Analyses and Potential Applications in Program Understanding and Optimization
Dynamic Points-To Sets: A Comparison with Static Analyses and Potential Applications in Program Understanding and Optimization Markus Mock *, Manuvir Das +, Craig Chambers *, and Susan J. Eggers * * Department
More informationCpt S 122 Data Structures. Course Review Midterm Exam # 2
Cpt S 122 Data Structures Course Review Midterm Exam # 2 Nirmalya Roy School of Electrical Engineering and Computer Science Washington State University Midterm Exam 2 When: Monday (11/05) 12:10 pm -1pm
More informationExpressing high level optimizations within LLVM. Artur Pilipenko
Expressing high level optimizations within LLVM Artur Pilipenko artur.pilipenko@azul.com This presentation describes advanced development work at Azul Systems and is for informational purposes only. Any
More informationA Study of Type Analysis for Speculative Method Inlining in a JIT Environment
A Study of Type Analysis for Speculative Method Inlining in a JIT Environment Feng Qian and Laurie Hendren {fqian, hendren}@sable.mcgill.ca School of Computer Science, McGill University Abstract. Method
More informationProgram Slicing in the Presence of Pointers
Program Slicing in the Presence of Pointers James R. Lyle David Binkley jimmy@sst.ncsl.nist.gov binkley@sst.ncsl.nist.gov U.S. Depar tment of Commerce Technology Administration National Institute of Standards
More informationPointer Analysis: Haven t We Solved This Problem Yet?
Pointer Analysis: Haven t We Solved This Problem Yet? Michael Hind IBM Watson Research Center 30 Saw Mill River Road Hawthorne, New York 10532 hind@watson.ibm.com ABSTRACT During the past twenty-one years,
More informationPointer Analysis in the Presence of Dynamic Class Loading. Hind Presented by Brian Russell
Pointer Analysis in the Presence of Dynamic Class Loading Martin Hirzel, Amer Diwan and Michael Hind Presented by Brian Russell Claim: First nontrivial pointer analysis dealing with all Java language features
More informationEfficient Field-Sensitive Pointer Analysis for C
Efficient Field-Sensitive Pointer Analysis for C David J. Pearce Department of Computing, Imperial College, London, SW7 2BZ, UK djp1@doc.ic.ac.uk Paul H. J. Kelly Department of Computing, Imperial College,
More informationPrecise Identification of Side-effect-free Methods in Java
Precise Identification of Side-effect-free Methods in Java Atanas Rountev Department of Computer Science and Engineering Ohio State University rountev@cis.ohio-state.edu Abstract Knowing which methods
More informationBuilding a Whole-Program Type Analysis in Eclipse
Building a Whole-Program Type Analysis in Eclipse Mariana Sharp Jason Sawin Atanas Rountev ABSTRACT Eclipse has the potential to become a widely-used platform for implementation and dissemination of various
More informationTesting Object-Oriented Software. 22 November 2017
Testing Object-Oriented Software 22 November 2017 Testing Object-Oriented Software 2 Problems in object-oriented testing [Binder] Each level in the class hierarchy creates a new context for inherited features:
More informationPoints-to Analysis. Xiaokang Qiu Purdue University. November 16, ECE 468 Adapted from Kulkarni 2012
Points-to Analysis Xiaokang Qiu Purdue University ECE 468 Adapted from Kulkarni 2012 November 16, 2016 Simple example x := 5 ptr := @x *ptr := 9 y := x program S1 S2 S3 S4 dependences What are the dependences
More informationConcept as a Generalization of Class and Principles of the Concept-Oriented Programming
Computer Science Journal of Moldova, vol.13, no.3(39), 2005 Concept as a Generalization of Class and Principles of the Concept-Oriented Programming Alexandr Savinov Abstract In the paper we describe a
More informationInterprocedural Analysis. Dealing with Procedures. Course so far: Terminology
Interprocedural Analysis Course so far: Control Flow Representation Dataflow Representation SSA form Classic DefUse and UseDef Chains Optimizations Scheduling Register Allocation Just-In-Time Compilation
More informationDesign issues for objectoriented. languages. Objects-only "pure" language vs mixed. Are subclasses subtypes of the superclass?
Encapsulation Encapsulation grouping of subprograms and the data they manipulate Information hiding abstract data types type definition is hidden from the user variables of the type can be declared variables
More informationR O O T S Interprocedural Analysis
R O O T S Interprocedural Analysis Aleksandra Biresev s6albire@cs.uni-bonn.de Interprocedural Analysis An interprocedural analysis operates across an entire program, flowing information from call sites
More informationLecture 26: Pointer Analysis
[Based on slides from R. Bodik] Lecture 26: Pointer Analysis Administrivia HKN survey next Thursday. Worth 5 points (but you must show up!). Today Points-to analysis: an instance of static analysis for
More informationLecture 26: Pointer Analysis. General Goals of Static Analysis. Client 1: Example. Client 1: Optimizing virtual calls in Java
[Based on slides from R. Bodik] Administrivia Lecture 26: Pointer Analysis HKN survey next Thursday. Worth 5 points (but you must show up!). Today Points-to analysis: an instance of static analysis for
More informationGrade Weights. Language Design and Overview of COOL. CS143 Lecture 2. Programming Language Economics 101. Lecture Outline
Grade Weights Language Design and Overview of COOL CS143 Lecture 2 Project 0% I, II 10% each III, IV 1% each Midterm 1% Final 2% Written Assignments 10% 2.% each Prof. Aiken CS 143 Lecture 2 1 Prof. Aiken
More informationLecture Notes on Common Subexpression Elimination
Lecture Notes on Common Subexpression Elimination 15-411: Compiler Design Frank Pfenning Lecture 18 October 29, 2015 1 Introduction Copy propagation allows us to have optimizations with this form: l :
More informationProcedure and Object- Oriented Abstraction
Procedure and Object- Oriented Abstraction Scope and storage management cs5363 1 Procedure abstractions Procedures are fundamental programming abstractions They are used to support dynamically nested blocks
More informationC++ Yanyan SHEN. slide 1
C++ Yanyan SHEN slide 1 History C++ is an object-oriented extension of C Designed by Bjarne Stroustrup at Bell Labs His original interest at Bell Labs was research on simulation Early extensions to C are
More informationCompiler construction 2009
Compiler construction 2009 Lecture 6 Some project extensions. Pointers and heap allocation. Object-oriented languages. Module systems. Memory structure Javalette restrictions Only local variables and parameters
More informationAn Introduction to Type Inference
Sebastian Zimmeck An Introduction to Type Inference Professor Alfred V. Aho - COMS E6998-2 Advanced Topics in Programming Languages and Compilers November 29, 2011 Presentation Overview 1. Introduction
More information