CodeQL library for C/C++
codeql/cpp-all 6.0.1 (changelog, source)
Search

Class VariableVirtualVariable

Represents the MemoryLocation for an IRVariable that acts as its own VirtualVariable. Includes any VariableMemoryLocation that exactly overlaps its entire IRVariable, and only if that IRVariable does not escape.

Import path

import semmle.code.cpp.ir.implementation.aliased_ssa.internal.AliasedSSA

Direct supertypes

Indirect supertypes

Inherited fields

Inherited predicates

canDefineReadOnly

Holds if a definition of this location can be the definition of a read-only use location.

from MemoryLocation0
canReuseSsafrom MemoryLocation0
coversEntireVariable

Holds if this memory location covers the entire variable.

from VariableMemoryLocation
getAnAllocation

Gets an allocation associated with this MemoryLocation.

from AllocationMemoryLocation
getEndBitOffsetfrom VariableMemoryLocation
getIRFunctionfrom AllocationMemoryLocation
getIRTypefrom MemoryLocation0
getLocationfrom AllocationMemoryLocation
getStartBitOffsetfrom VariableMemoryLocation
getTypefrom VariableMemoryLocation
getUniqueIdfrom VariableMemoryLocation
getVirtualVariablefrom AllocationMemoryLocation
isAlwaysAllocatedOnStack

Holds if the location always represents memory allocated on the stack (for example, a variable with automatic storage duration).

from VariableMemoryLocation
isMayAccessfrom AllocationMemoryLocation
isReadOnly

Holds if the location cannot be overwritten except by definition of a MemoryLocation for which def.canDefineReadOnly() holds.

from AllocationMemoryLocation
toStringfrom MemoryLocation0
toStringInternalfrom VariableMemoryLocation

Charpred