C++: Remove CP in getOperandMemoryAccess

The overrides of `Instruction.getOperandMemoryAccess` did not relate
`this` to any of its other parameters, which made it attempt to compute
the Cartesian product of `Instruction` and `TPhiOperand`. This happened
only during computation of aliased SSA. Perhaps the optimizer was able
to eliminate the CP for the non-aliased SSA computation.

With this change, I'm able to compute aliased SSA for medium-sized
snapshots.
This commit is contained in:
Jonas Jensen
2018-09-01 21:01:13 +02:00
committed by Jonas Jensen
parent 1bcae97447
commit e0c073360b
3 changed files with 15 additions and 15 deletions

View File

@@ -602,7 +602,7 @@ class ReturnValueInstruction extends ReturnInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof ReturnValueOperand and
exists(this.getOperand(tag.(ReturnValueOperand))) and
result instanceof IndirectMemoryAccess
}
}
@@ -629,7 +629,7 @@ class LoadInstruction extends CopyInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof CopySourceOperand and
exists(this.getOperand(tag.(CopySourceOperand))) and
result instanceof IndirectMemoryAccess
}
@@ -1015,7 +1015,7 @@ class ThrowValueInstruction extends ThrowInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof ExceptionOperand and
exists(this.getOperand(tag.(ExceptionOperand))) and
result instanceof IndirectMemoryAccess
}
@@ -1114,7 +1114,7 @@ class UnmodeledUseInstruction extends Instruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof UnmodeledUseOperand and
exists(this.getOperand(tag.(UnmodeledUseOperand))) and
result instanceof UnmodeledMemoryAccess
}
}
@@ -1125,7 +1125,7 @@ class PhiInstruction extends Instruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof PhiOperand and
exists(this.getOperand(tag.(PhiOperand))) and
result instanceof PhiMemoryAccess
}

View File

@@ -602,7 +602,7 @@ class ReturnValueInstruction extends ReturnInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof ReturnValueOperand and
exists(this.getOperand(tag.(ReturnValueOperand))) and
result instanceof IndirectMemoryAccess
}
}
@@ -629,7 +629,7 @@ class LoadInstruction extends CopyInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof CopySourceOperand and
exists(this.getOperand(tag.(CopySourceOperand))) and
result instanceof IndirectMemoryAccess
}
@@ -1015,7 +1015,7 @@ class ThrowValueInstruction extends ThrowInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof ExceptionOperand and
exists(this.getOperand(tag.(ExceptionOperand))) and
result instanceof IndirectMemoryAccess
}
@@ -1114,7 +1114,7 @@ class UnmodeledUseInstruction extends Instruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof UnmodeledUseOperand and
exists(this.getOperand(tag.(UnmodeledUseOperand))) and
result instanceof UnmodeledMemoryAccess
}
}
@@ -1125,7 +1125,7 @@ class PhiInstruction extends Instruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof PhiOperand and
exists(this.getOperand(tag.(PhiOperand))) and
result instanceof PhiMemoryAccess
}

View File

@@ -602,7 +602,7 @@ class ReturnValueInstruction extends ReturnInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof ReturnValueOperand and
exists(this.getOperand(tag.(ReturnValueOperand))) and
result instanceof IndirectMemoryAccess
}
}
@@ -629,7 +629,7 @@ class LoadInstruction extends CopyInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof CopySourceOperand and
exists(this.getOperand(tag.(CopySourceOperand))) and
result instanceof IndirectMemoryAccess
}
@@ -1015,7 +1015,7 @@ class ThrowValueInstruction extends ThrowInstruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof ExceptionOperand and
exists(this.getOperand(tag.(ExceptionOperand))) and
result instanceof IndirectMemoryAccess
}
@@ -1114,7 +1114,7 @@ class UnmodeledUseInstruction extends Instruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof UnmodeledUseOperand and
exists(this.getOperand(tag.(UnmodeledUseOperand))) and
result instanceof UnmodeledMemoryAccess
}
}
@@ -1125,7 +1125,7 @@ class PhiInstruction extends Instruction {
}
override final MemoryAccessKind getOperandMemoryAccess(OperandTag tag) {
tag instanceof PhiOperand and
exists(this.getOperand(tag.(PhiOperand))) and
result instanceof PhiMemoryAccess
}