{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

points_to_linear_slides

# points_to_linear_slides - Points-to Analysis in Almost...

This preview shows pages 1–9. Sign up to view the full content.

Points-to Analysis in Almost Linear Time Bjarne Steensgard

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Constraint-based Analysis Idea: generate constraints and solve them later x = &a; y = &b; p = &x; p = &y; x a p y b
Inclusion-based Analysis x = y pointsTo (x) ≥ pointsTo(y) What is the major drawback of this approach? O(n 3 )

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
How can we do this faster? Use equality-based analysis. Why?
Equality-based Analysis x = y pointsTo(x) = pointsTo(y) Why is this faster? What are the tradeoffs?

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
What should x point to? x = a x = b a x b a x b
Imprecise, but fast really? How to do equality-based, flow-insensitive analysis in one pass? Use type inference with points-to sets as types For every variable X , let X’s type α x = pointsTo(X) The set { α x } the goal of the analysis is found using unification-based type inference How is this analysis equality-based?

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Type system for points-to inference 3 kinds of types: Value types (pointer, function) tuples α ::= τ × λ pointer/address types: τ ::= ref (α) | (null, or actual value / not pointer) function signatures: λ ::= (α 1 ,…α n ) n+1 ,…α n+m ) |
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### Page1 / 21

points_to_linear_slides - Points-to Analysis in Almost...

This preview shows document pages 1 - 9. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online