com.ibm.wala.ssa
Class SSACache

java.lang.Object
  extended by com.ibm.wala.ssa.SSACache

public class SSACache
extends java.lang.Object

A mapping from IMethod -> SSAOptions -> SoftReference -> IR This doesn't work very well ... GCs don't do such a great job with SoftReferences ... revamp it.


Constructor Summary
SSACache(IRFactory<IMethod> factory)
           
 
Method Summary
 DefUse findOrCreateDU(IMethod m, Context C, SSAOptions options)
           
 DefUse findOrCreateDU(IR ir, Context C)
           
 IR findOrCreateIR(IMethod m, Context C, SSAOptions options)
           
 void invalidate(IMethod method, Context C)
           
 void invalidateDU(IMethod method, Context C)
           
 void invalidateIR(IMethod method, Context C)
           
 void wipe()
          The existence of this is unfortunate.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SSACache

public SSACache(IRFactory<IMethod> factory)
Parameters:
factory -
Method Detail

findOrCreateIR

public IR findOrCreateIR(IMethod m,
                         Context C,
                         SSAOptions options)
Parameters:
m - a "normal" (bytecode-based) method
options - options governing ssa construction
Returns:
an IR for m, built according to the specified options. null if m is abstract or native.
Throws:
java.lang.IllegalArgumentException - if m is null

findOrCreateDU

public DefUse findOrCreateDU(IMethod m,
                             Context C,
                             SSAOptions options)
Parameters:
m - a method
options - options governing ssa construction
Returns:
DefUse information for m, built according to the specified options. null if unavailable
Throws:
java.lang.IllegalArgumentException - if m is null

findOrCreateDU

public DefUse findOrCreateDU(IR ir,
                             Context C)
Returns:
DefUse information for m, built according to the specified options. null if unavailable
Throws:
java.lang.IllegalArgumentException - if ir is null

wipe

public void wipe()
The existence of this is unfortunate.


invalidateIR

public void invalidateIR(IMethod method,
                         Context C)

invalidateDU

public void invalidateDU(IMethod method,
                         Context C)

invalidate

public void invalidate(IMethod method,
                       Context C)