chord.analyses.alias
Class CSAliasAnalysis

java.lang.Object
  extended by chord.project.analyses.JavaAnalysis
      extended by chord.analyses.alias.CSAliasAnalysis
All Implemented Interfaces:
ITask

public class CSAliasAnalysis
extends JavaAnalysis

Context-sensitive may alias analysis.

Author:
Mayur Naik (mhn@cs.stanford.edu)

Field Summary
 
Fields inherited from class chord.project.analyses.JavaAnalysis
consumes, controls, name, produces
 
Constructor Summary
CSAliasAnalysis()
           
 
Method Summary
 void free()
          Frees relations used by this program analysis if they are in memory.
 CSObj pointsTo(CSObj obj, joeq.Class.jq_Field field)
          Provides the abstract object to which a given instance field of a given abstract object may point.
 CSObj pointsTo(Ctxt ctxt, joeq.Compiler.Quad.RegisterFactory.Register var)
          Provides the abstract object to which a given local variable may point in a given abstract context of its declaring method.
 CSObj pointsTo(joeq.Class.jq_Field field)
          Provides the abstract object to which a given static field may point.
 void run()
          Executes this analysis in a "classic" project.
 
Methods inherited from class chord.project.analyses.JavaAnalysis
getName, run, setName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CSAliasAnalysis

public CSAliasAnalysis()
Method Detail

run

public void run()
Description copied from interface: ITask
Executes this analysis in a "classic" project. This method must usually not be called directly. The correct way to call it is to call ClassicProject.runTask(String) or ClassicProject.runTask(ITask), providing this analysis either by its name or its object.

Specified by:
run in interface ITask
Overrides:
run in class JavaAnalysis

pointsTo

public CSObj pointsTo(Ctxt ctxt,
                      joeq.Compiler.Quad.RegisterFactory.Register var)
Provides the abstract object to which a given local variable may point in a given abstract context of its declaring method.

Parameters:
ctxt - An abstract context of a method.
var - A local variable declared in the method.
Returns:
The abstract object to which the given local variable may point in the given abstract context.

pointsTo

public CSObj pointsTo(joeq.Class.jq_Field field)
Provides the abstract object to which a given static field may point.

Parameters:
field - A static field.
Returns:
The abstract object to which the given static field may point.

pointsTo

public CSObj pointsTo(CSObj obj,
                      joeq.Class.jq_Field field)
Provides the abstract object to which a given instance field of a given abstract object may point.

Parameters:
obj - An abstract object.
field - An instance field.
Returns:
The abstract object to which the given instance field of the given abstract object may point.

free

public void free()
Frees relations used by this program analysis if they are in memory.

This method must be called after clients are done exercising the interface of this analysis.