From 063e5d300ec95bd19287964e7d23ccffbb6353f1 Mon Sep 17 00:00:00 2001 From: Jeroen Ketema Date: Tue, 6 Jan 2026 17:40:52 +0100 Subject: [PATCH] C++: Remove redundant SSA branch after IR fix --- .../code/cpp/ir/dataflow/internal/SsaImplCommon.qll | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/SsaImplCommon.qll b/cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/SsaImplCommon.qll index 552f504b84b..05fa0e86d4a 100644 --- a/cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/SsaImplCommon.qll +++ b/cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal/SsaImplCommon.qll @@ -688,14 +688,9 @@ private module Cached { conversionFlow(mid, instr, false, _) ) or - exists(int ind0 | - exists(Operand address | - isDereference(operand.getDef(), address, _) and - isUseImpl(address, base, ind0) - ) - or - isUseImpl(operand.getDef().(InitializeParameterInstruction).getAnOperand(), base, ind0) - | + exists(int ind0, Operand address | + isDereference(operand.getDef(), address, _) and + isUseImpl(address, base, ind0) and ind0 = ind - 1 ) }