Class SsaDefinition
NOTE: If possible, prefer the SSA classes exposed by the new dataflow library:
import semmle.code.cpp.dataflow.new.DataFlow
// use `DataFlow::Ssa::Definition`
A definition of one or more SSA variables, including phi node definitions.
An SSA variable, as defined in the literature, is effectively the pair of
an SsaDefinition d and a StackVariable v, written (d, v) in this
documentation. Note that definitions and uses can be coincident due to the
presence of parameter definitions and phi nodes.
Not all StackVariables of a function have SSA definitions. If the variable
has its address taken, either explicitly or implicitly, then it is excluded
from analysis. SsaDefinitions are not generated in locations that are
statically seen to be unreachable.
Import path
import cppDirect supertypes
Indirect supertypes
Known direct subtypes
Predicates
| definedByParameter | Holds if the SSA variable |
| getAPhiInput | Holds if the SSA variable |
| getAUse | Gets a use of the SSA variable represented by the pair |
| getAVariable | Gets a variable corresponding to an SSA StackVariable defined by this definition. |
| getAnUltimateDefiningValue | Gets a possible defining expression for |
| getAnUltimateSsaDefinition | Gets a definition that ultimately defines this variable and is not itself a phi node. |
| getBasicBlock | Gets the |
| getDefiningValue | Gets the expression assigned to the SSA variable |
| getDefinition | Gets the control-flow node for this definition. This will usually be the control-flow node that assigns to this variable as a side effect, but there are some exceptions. If |
| getLocation | Gets the location of this definition. |
| isPhiNode | Holds if this definition is a phi node for variable |
| reachesEndOfBB | Holds if |
| toString | Gets a string representation of the SSA variable represented by the pair |
Inherited predicates
| getAPrimaryQlClass | Gets the name of a primary CodeQL class to which this element belongs. | from ElementBase |
| getPrimaryQlClasses | Gets a comma-separated list of the names of the primary CodeQL classes to which this element belongs. | from ElementBase |
| toString | Gets a textual representation of this element. | from ElementBase |