Package soot.dexpler
Class DexDefUseAnalysis
- java.lang.Object
-
- soot.dexpler.DexDefUseAnalysis
-
-
Field Summary
Fields Modifier and Type Field Description protected BitSet[]localToDefsBitsprotected Map<Local,Integer>localToNumberprotected BitSet[]localToUsesBitsprotected List<Unit>unitList
-
Constructor Summary
Constructors Constructor Description DexDefUseAnalysis(Body body)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Set<Unit>collectDefinitionsWithAliases(Local l)Collect definitions of l in body including the definitions of aliases of l.List<Unit>getDefsOf(Local l)Returns the definition sites for a Local merged over all points in a method.List<Unit>getDefsOfAt(Local l, Unit s)Returns the definition sites for a Local at a certain point (Unit) in a method.Set<Unit>getUsesOf(Local l)protected voidinitialize()
-
-
-
Constructor Detail
-
DexDefUseAnalysis
public DexDefUseAnalysis(Body body)
-
-
Method Detail
-
initialize
protected void initialize()
-
collectDefinitionsWithAliases
protected Set<Unit> collectDefinitionsWithAliases(Local l)
Collect definitions of l in body including the definitions of aliases of l. This analysis exploits that the problem is flow-insensitive anyway. In this context an alias is a local that propagates its value to l.- Parameters:
l- the local whose definitions are to collect
-
getDefsOfAt
public List<Unit> getDefsOfAt(Local l, Unit s)
Description copied from interface:LocalDefsReturns the definition sites for a Local at a certain point (Unit) in a method. You can assume this method never returnsnull.- Specified by:
getDefsOfAtin interfaceLocalDefs- Parameters:
l- the Local in question.s- a unit that specifies the method context (location) to query for the definitions of the Local.- Returns:
- a list of Units where the local is defined in the current method context. If there are no uses an empty list will returned.
-
-