package cg
- Source
- package.scala
- Alphabetic
- By Inheritance
- cg
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Type Members
- class AllocationSitesPointsToTypeIterator extends TypeIterator with PointsToTypeIterator[AllocationSite, AllocationSitePointsToSet] with SimpleContextProvider
Type iterator with 1-call sensitivity for objects, for the 0-1-CFA algorithm.
- trait AnalysisState extends AnyRef
- trait BaseAnalysisState extends AnalysisState
- class CFA_k_l_TypeIterator extends TypeIterator with PointsToTypeIterator[AllocationSite, AllocationSitePointsToSet] with CallStringContextProvider
Context-sensitive points-to type iterator for the k-l-CFA algorithm.
- class CGState[ContextType <: Context] extends BaseAnalysisState with TypeIteratorState with TACAIBasedAnalysisState[ContextType]
- class CHATypeIterator extends TypeIterator with SimpleContextProvider
Provides types based only on local, static type information.
Provides types based only on local, static type information. Never registers any dependencies, the continuation function throws an error if called anyway.
- class CallGraphAnalysis extends ReachableMethodAnalysis with TypeConsumerAnalysis
Generates call graphs based on the used TypeIterator.
Generates call graphs based on the used TypeIterator. It uses the AI information of the three-address code to get the most precise information for virtual calls.
handleImpreciseCall
will be invoked for each virtual call, that could not be resolved precisely. - class CallGraphDeserializerScheduler extends BasicFPCFEagerAnalysisScheduler
- case class CallSite(pc: Int, methodName: String, methodDescriptor: MethodDescriptor, receiver: ReferenceType) extends Product with Serializable
- case class CallSiteDescription(declaredTarget: MethodDesc, line: Int, pc: Option[Int], targets: List[MethodDesc]) extends Product with Serializable
A call site has a
declaredTarget
method, is associated with a line number (-1 if unknown) and contains the set of computed target methods (targets
). - trait CallStringContextProvider extends TypeIterator
- sealed trait CalleesAndCallers extends AnyRef
A convenience class for call graph constructions.
A convenience class for call graph constructions. Manages direct/indirect calls and incomplete call sites and allows the analyses to retrieve the required org.opalj.fpcf.PartialResults for Callers and Callees.
- trait Calls extends CalleesAndCallers
- class ConfiguredNativeMethodsCallGraphAnalysis extends FPCFAnalysis
Add calls from configured native methods to the call graph.
Add calls from configured native methods to the call graph. Calls can be specialized under the config key configKey.
specify that
registerNatives
will callinitializeSystemClass
. { cf = "java/lang/System", name = "registerNatives", desc = "()V", methodInvocations = [ { cf = "java/lang/System", name = "initializeSystemClass", desc = "()V" } ] }
Example: - trait ContextualAnalysis extends AnyRef
- class DirectCalls extends DirectCallsBase with IncompleteCallSites
- trait DirectCallsBase extends Calls
- class DoPrivilegedCGAnalysis extends FPCFAnalysis
- class DoPrivilegedMethodAnalysis extends TACAIBasedAPIBasedAnalysis with TypeConsumerAnalysis
Models the behavior for
java.security.AccessController.doPrivileged*
.Models the behavior for
java.security.AccessController.doPrivileged*
.On each call of the concrete doPrivilegedMethod method it will call the declaredRunMethod upon its first parameter and returns the result of this call.
For each such call, the analysis will add an indirect call to the call graph.
TODO: The current implementation won't work if the JDK is not included. In order to perform the analysis even if the method is a org.opalj.br.VirtualDeclaredMethod, the org.opalj.br.analyses.VirtualFormalParameters must also be present for those methods.
- class FinalizerAnalysis extends FPCFAnalysis
Computes the set of finalize methods that are being called by the VM during the execution of the
project
.Computes the set of finalize methods that are being called by the VM during the execution of the
project
. Extends the call graph analysis (org.opalj.tac.fpcf.analyses.cg.CallGraphAnalysis) to include the calls to these methods. - trait IncompleteCallSites extends CalleesAndCallers
- class IndirectCalls extends IndirectCallsBase with IncompleteCallSites
- trait IndirectCallsBase extends Calls
- class LoadedClassesAnalysis extends FPCFAnalysis
For a reachable methods (see Callers) this class computes the classes that are being loaded (e.g.
For a reachable methods (see Callers) this class computes the classes that are being loaded (e.g. due to static field accesses).
- case class MethodDesc(name: String, declaringClass: String, returnType: String, parameterTypes: List[String]) extends Product with Serializable
A method is represented using the
name
, thedeclaringClass
, itsreturnType
and itsparameterTypes
. - class OISReadObjectAnalysis extends TACAIBasedAPIBasedAnalysis with TypeConsumerAnalysis
Analysis handling the specifics of java.io.ObjectInputStream.readObject.
Analysis handling the specifics of java.io.ObjectInputStream.readObject. This method may instantiate new objects and invoke readObject, readResolve, readExternal or validateObject on them.
- class OOSWriteObjectAnalysis extends TACAIBasedAPIBasedAnalysis with TypeConsumerAnalysis
Analysis handling the specifics of java.io.ObjectOutputStream.writeObject.
Analysis handling the specifics of java.io.ObjectOutputStream.writeObject. This method may invoke writeObject, writeReplace or writeExternal on its parameter.
- trait PointsToTypeIterator[ElementType, PointsToSet >: Null <: PointsToSetLike[ElementType, _, PointsToSet]] extends TypeIterator
Functionality for providing types based on individual points-to information, e.g., CFA.
Functionality for providing types based on individual points-to information, e.g., CFA. Points-to information is stored per variable.
- class PropagationBasedTypeIterator extends TypeIterator with SimpleContextProvider
Configurable type iterator for the XTA family of call graphs.
Configurable type iterator for the XTA family of call graphs. Based on the given TypeSetEntitySelector, XTA, MTA, FTA or CTA behavior can be produced. Types are stored per entity plus a global set of types.
- class RTATypeIterator extends TypeIterator with SimpleContextProvider
Fast type iterator based on a global set of instantiated types.
- trait ReachableMethodAnalysis extends FPCFAnalysis with TypeConsumerAnalysis
Base trait for analyses that are executed for every method that is reachable.
Base trait for analyses that are executed for every method that is reachable. The analysis is performed by
processMethod
. - case class ReachableMethodDescription(method: MethodDesc, callSites: List[CallSiteDescription]) extends Product with Serializable
A reachable method contains of the
method
itself and the call sites within that method. - case class ReachableMethodsDescription(reachableMethods: List[ReachableMethodDescription]) extends Product with Serializable
Representation of all Methods that are reachable in the represented call graph.
Representation of all Methods that are reachable in the represented call graph. TODO: This classes are copy&paste code from the JCG project and should be included as Dependency.
- class SerializationRelatedCallsAnalysis extends FPCFAnalysis
Handles the effect of serialization to the call graph.
Handles the effect of serialization to the call graph. As an example models the invocation of constructors when
readObject
is called, if there is a cast afterwards. - trait SimpleContextProvider extends TypeIterator
- class StaticInitializerAnalysis extends FPCFAnalysis
Extends the call graph analysis to include calls to static initializers from within the JVM for each loaded class (LoadedClasses).
Extends the call graph analysis to include calls to static initializers from within the JVM for each loaded class (LoadedClasses). This requires the LoadedClasses to be computed, e.g. by the LoadedClassesAnalysis.
- class ThreadRelatedCallsAnalysis extends FPCFAnalysis
This analysis handles implicit method invocations related to the
java.lang.Thread
API.This analysis handles implicit method invocations related to the
java.lang.Thread
API. As an example, a call toThread#start
eventual lead to an invocation of therun
method of the correspondingjava.lang.Runnable
object. - class ThreadStartAnalysis extends TACAIBasedAPIBasedAnalysis with TypeConsumerAnalysis
On calls to Thread.start(), it adds calls to the corresponding run method.
On calls to Thread.start(), it adds calls to the corresponding run method. The run method is determined using points-to information.
- trait TypeConsumerAnalysis extends ProjectBasedAnalysis
- abstract class TypeIterator extends AnyRef
Core class of the call-graph framework: Provides type and (if available) points-to information to client classes.
Core class of the call-graph framework: Provides type and (if available) points-to information to client classes. Each type iterator represents one traditional call-graph algorithm.
Type iterators are responsible for managing the dependencies for their internal information themselves. They provide suitable continuation functions to be invoked from an analysis' continuation in order to process these opaque dependencies.
- trait TypeIteratorState extends AnalysisState
A trait to implement state classes that have to manage the state of a TypeIterator, i.e., the dependencies introduced by querying type information.
- trait TypesBasedPointsToTypeIterator extends TypeIterator with PointsToTypeIterator[ReferenceType, TypeBasedPointsToSet]
Context-insensitive points-to type iterator for the 0-CFA algorithm.
- class UncaughtExceptionHandlerAnalysis extends TACAIBasedAPIBasedAnalysis with TypeConsumerAnalysis
- type V = DUVar[ValueInformation]
- class VMReachableMethods extends VMReachableMethodsBase with IncompleteCallSites
- trait VMReachableMethodsBase extends CalleesAndCallers
Value Members
- final def pcOfDefSite(valueOrigin: ValueOrigin)(implicit stmts: Array[Stmt[V]]): Int
- final def persistentUVar(value: V)(implicit stmts: Array[Stmt[V]]): Some[(ValueInformation, IntTrieSet)]
A persistent representation (using pcs instead of TAC value origins) for a UVar.
- final def uVarForDefSites(defSites: (ValueInformation, IntTrieSet), pcToIndex: Array[Int]): V
- final def valueOriginsOfPCs(pcs: PCs, pcToIndex: Array[Int]): IntTrieSet
- object AllocationsUtil
- object CallGraphAnalysisScheduler extends BasicFPCFTriggeredAnalysisScheduler
- object CallSiteDescription extends Serializable
- object ConfiguredNativeMethodsCallGraphAnalysisScheduler extends BasicFPCFTriggeredAnalysisScheduler
- object DoPrivilegedAnalysisScheduler extends BasicFPCFEagerAnalysisScheduler
- object FinalizerAnalysisScheduler extends BasicFPCFTriggeredAnalysisScheduler
- object LoadedClassesAnalysisScheduler extends BasicFPCFTriggeredAnalysisScheduler
- object MethodDesc extends Serializable
- object ReachableMethodDescription extends Serializable
- object ReachableMethodsDescription extends Serializable
- object SerializationRelatedCallsAnalysisScheduler extends BasicFPCFEagerAnalysisScheduler
- object StaticInitializerAnalysisScheduler extends BasicFPCFEagerAnalysisScheduler
- object ThreadRelatedCallsAnalysisScheduler extends BasicFPCFEagerAnalysisScheduler