Static Program Analysis - Interprocedural Analysis

https://cs.nju.edu.cn/tiantan/software-analysis/Inter.pdf

Method Calls in Java

jvm-ir-invoke

Method Dispatch of Virtual Calls

在运行时,a virtual call 的解析基于 (以 o.foo(...) 为例):

  1. receiver object(pointed by o)的类型
  2. 调用时方法的具体签名

在这个课中,我们把签名作为函数的一个 identifier:

Class Hierarchy Analysis (CHA)

Class Resolution of CHA

class-resolution-of-CHA

Features of CHA

Call Graph Construction

BFS.

Interprocedural Control-flow Graph

ICFG 在 CFG 的基础上,多了两种类型的边:

Interprocedural Data-flow Analysis

  Intraprocedural Interprocedural
Program representation CFG ICFG
Transfer functions Node transfer Node transfer + edge transfer

Interprocedural Constant Propagation