Class FILiveObjectAnalysis

java.lang.Object
com.ibm.wala.escape.FILiveObjectAnalysis
All Implemented Interfaces:
ILiveObjectAnalysis

public class FILiveObjectAnalysis extends Object implements ILiveObjectAnalysis
A simple liveness analysis based on flow-insensitive pointer analysis.
  • Constructor Details

    • FILiveObjectAnalysis

      public FILiveObjectAnalysis(CallGraph callGraph, HeapGraph<?> heapGraph, boolean expensiveIntraproceduralAnalysis)
  • Method Details

    • mayBeLive

      public boolean mayBeLive(CGNode allocMethod, int allocPC, CGNode m, int instructionIndex) throws IllegalArgumentException, WalaException
      Specified by:
      mayBeLive in interface ILiveObjectAnalysis
      Parameters:
      allocMethod - a method which holds an allocation site
      allocPC - bytecode index of allocation site
      m - method in question
      instructionIndex - index of an instruction in SSA IR. in m. if -1, it is interpreted as a wildcard meaning "any statement"
      Returns:
      true if an object allocated at the allocation site <allocMethod,allocPC> may be live immediately after the statement <m,instructionIndex>
      Throws:
      IllegalArgumentException
      WalaException
    • mayBeLive

      public boolean mayBeLive(InstanceKey ik, CGNode m, int instructionIndex)
      Specified by:
      mayBeLive in interface ILiveObjectAnalysis
      Parameters:
      instructionIndex - index of an SSA instruction
      ik - an instance key
      m - method in question
      Returns:
      true if an object allocated at the allocation site <allocMethod,allocPC> may be live immediately after the statement <m,instructionIndex>
    • mayBeLive

      public boolean mayBeLive(InstanceKey ik, CGNode m, IntSet instructionIndices)
      Specified by:
      mayBeLive in interface ILiveObjectAnalysis
      Parameters:
      ik - an instance key
      m - method in question
      instructionIndices - indices of instructions in SSA IR.
      Returns:
      true if an object allocated at the allocation site <allocMethod,allocPC> may be live immediately after the statement <m,instructionIndex> for any instructionIndex in the set