Skip to content

Commit

Permalink
JIT: Allow RBO for known relops even without a dominator (#86774)
Browse files Browse the repository at this point in the history
Delay the check for whether there is a dominator to the case where we're
actually going to try to infer from it.
  • Loading branch information
jakobbotsch authored May 26, 2023
1 parent 182b013 commit 33f78c0
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/coreclr/jit/redundantbranchopts.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -459,11 +459,6 @@ bool Compiler::optRedundantBranch(BasicBlock* const block)
unsigned matchCount = 0;
const unsigned matchLimit = 4;

if (domBlock == nullptr)
{
return false;
}

// Unpack the tree's VN
//
ValueNum treeNormVN;
Expand All @@ -482,6 +477,11 @@ bool Compiler::optRedundantBranch(BasicBlock* const block)
}
else
{
if (domBlock == nullptr)
{
return false;
}

JITDUMP("Relop [%06u] " FMT_BB " value unknown, trying inference\n", dspTreeID(tree), block->bbNum);
}

Expand Down

0 comments on commit 33f78c0

Please sign in to comment.