<aside> 💡 Key Points

I. Introduction


1. Imprecision of Context Insensitivity, C.I.

A method may be called multiple times under different calling contexts during execution, and therefore, the variables of the method may also point to different objects.

In C.I. pointer analysis, objects under different contexts are mixed and propagated to other parts of program (through return values or side-effects), causing spurious data flows

2. Context Sensitivity

Context sensitivity models calling contexts by distinguishing different data flows of different contexts to improve precision

The oldest and best-known context sensitivity strategy is call-site sensitivity (call-string)

Cloning-Based Context Sensitivity

The most straightforward approach to implement context sensitivity

Untitled

3. Context-Sensitive Heap

The most common choice is to inherit contexts from the method where the object is allocated.

e.g.: x() { var a = new A() } a will inherit contexts from x()