Skip to content

Commit e9b1d81

Browse files
author
Robert Marsh
committed
C++: QLDoc for VirtualVariable in IR construction
1 parent 1931693 commit e9b1d81

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

cpp/ql/src/semmle/code/cpp/ir/implementation/aliased_ssa/internal/AliasedSSA.qll

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,12 @@ abstract class MemoryLocation extends TMemoryLocation {
133133
predicate isAlwaysAllocatedOnStack() { none() }
134134
}
135135

136+
/**
137+
* Represents a set of `MemoryLocation`s that cannot overlap with
138+
* `MemoryLocation`s outside of the set. The `VirtualVariable` will be
139+
* represented by a `MemoryLocation` that totally overlaps all other
140+
* `MemoryLocations` in the set.
141+
*/
136142
abstract class VirtualVariable extends MemoryLocation { }
137143

138144
abstract class AllocationMemoryLocation extends MemoryLocation {

cpp/ql/src/semmle/code/cpp/ir/implementation/unaliased_ssa/internal/SimpleSSA.qll

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,12 @@ class MemoryLocation extends TMemoryLocation {
5959
final string getUniqueId() { result = var.getUniqueId() }
6060
}
6161

62+
/**
63+
* Represents a set of `MemoryLocation`s that cannot overlap with
64+
* `MemoryLocation`s outside of the set. The `VirtualVariable` will be
65+
* represented by a `MemoryLocation` that totally overlaps all other
66+
* `MemoryLocations` in the set.
67+
*/
6268
class VirtualVariable extends MemoryLocation { }
6369

6470
/** A virtual variable that groups all escaped memory within a function. */

0 commit comments

Comments
 (0)