From 76c47fde2e2628084d0401bfebb7e453b0191482 Mon Sep 17 00:00:00 2001 From: Brian Fiete Date: Wed, 16 Oct 2024 13:51:30 -0400 Subject: [PATCH] CondBr fix --- IDEHelper/Backend/BeMCContext.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/IDEHelper/Backend/BeMCContext.cpp b/IDEHelper/Backend/BeMCContext.cpp index 2f5b0b1c..3d565a1a 100644 --- a/IDEHelper/Backend/BeMCContext.cpp +++ b/IDEHelper/Backend/BeMCContext.cpp @@ -3519,8 +3519,7 @@ void BeMCContext::CreateCondBr(BeMCBlock* mcBlock, BeMCOperand& testVal, const B else if (testVal.mKind == BeMCOperandKind_CmpResult) { // Beef-specific: assuming CMP results aren't stomped - auto& cmpResult = mCmpResults[testVal.mCmpResultIdx]; - AllocInst(BeMCInstKind_CondBr, trueBlock, BeMCOperand::FromCmpKind(cmpResult.mCmpKind)); + auto& cmpResult = mCmpResults[testVal.mCmpResultIdx]; if (cmpResult.mInverted) { AllocInst(BeMCInstKind_CondBr, falseBlock, BeMCOperand::FromCmpKind(cmpResult.mCmpKind));