Skip to content

Commit

Permalink
Removing SEH load exceptions for var args and lambda translations
Browse files Browse the repository at this point in the history
  • Loading branch information
bdrodes committed Oct 23, 2024
1 parent fdf5ac6 commit a053519
Showing 1 changed file with 4 additions and 28 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3472,13 +3472,7 @@ class TranslatedVarArg extends TranslatedNonConstantExpr {
result = this.getInstruction(VarArgsVAListStoreTag())
or
tag = VarArgsVAListStoreTag() and
(
result = this.getParent().getChildSuccessor(this, kind)
or
// All store instructions could throw an SEH exception
result = this.getParent().getExceptionSuccessorInstruction(any(GotoEdge e), true) and
kind.(ExceptionEdge).isSEH()
)
result = this.getParent().getChildSuccessor(this, kind)
}

final override Instruction getChildSuccessorInternal(TranslatedElement child, EdgeKind kind) {
Expand Down Expand Up @@ -3600,22 +3594,10 @@ class TranslatedVarArgCopy extends TranslatedNonConstantExpr {

final override Instruction getInstructionSuccessorInternal(InstructionTag tag, EdgeKind kind) {
tag = VarArgsVAListLoadTag() and
(
result = this.getDestinationVAList().getFirstInstruction(kind)
or
// All load instructions could throw an SEH exception
result = this.getParent().getExceptionSuccessorInstruction(any(GotoEdge e), true) and
kind.(ExceptionEdge).isSEH()
)
result = this.getDestinationVAList().getFirstInstruction(kind)
or
tag = VarArgsVAListStoreTag() and
(
result = this.getParent().getChildSuccessor(this, kind)
or
// All store instructions could throw an SEH exception
result = this.getParent().getExceptionSuccessorInstruction(any(GotoEdge e), true) and
kind.(ExceptionEdge).isSEH()
)
result = this.getParent().getChildSuccessor(this, kind)
}

final override Instruction getChildSuccessorInternal(TranslatedElement child, EdgeKind kind) {
Expand Down Expand Up @@ -3819,13 +3801,7 @@ class TranslatedLambdaExpr extends TranslatedNonConstantExpr, InitializationCont
)
or
tag = LoadTag() and
(
result = this.getParent().getChildSuccessor(this, kind)
or
// All load instruction could throw an SEH exception
result = this.getParent().getExceptionSuccessorInstruction(any(GotoEdge e), true) and
kind.(ExceptionEdge).isSEH()
)
result = this.getParent().getChildSuccessor(this, kind)
}

override Instruction getChildSuccessorInternal(TranslatedElement child, EdgeKind kind) {
Expand Down

0 comments on commit a053519

Please sign in to comment.