@@ -12940,12 +12940,13 @@ void Compiler::fgAssertionGen(GenTree* tree)
12940
12940
// apLocal will be stored on bbAssertionOutIfFalse and be used for false successors.
12941
12941
// apLocalIfTrue will be stored on bbAssertionOutIfTrue and be used for true successors.
12942
12942
//
12943
- const bool doCondUpdates = tree->OperIs(GT_JTRUE) && compCurBB->KindIs(BBJ_COND) && (compCurBB->NumSucc() == 2);
12943
+ const bool makeCondAssertions =
12944
+ tree->OperIs(GT_JTRUE) && compCurBB->KindIs(BBJ_COND) && (compCurBB->NumSucc() == 2);
12944
12945
12945
12946
// Intialize apLocalIfTrue if we might look for it later,
12946
12947
// even if it ends up identical to apLocal.
12947
12948
//
12948
- if (doCondUpdates )
12949
+ if (makeCondAssertions )
12949
12950
{
12950
12951
apLocalIfTrue = BitVecOps::MakeCopy(apTraits, apLocal);
12951
12952
}
@@ -12957,7 +12958,7 @@ void Compiler::fgAssertionGen(GenTree* tree)
12957
12958
12958
12959
AssertionInfo info = tree->GetAssertionInfo();
12959
12960
12960
- if (doCondUpdates )
12961
+ if (makeCondAssertions )
12961
12962
{
12962
12963
// Update apLocal and apIfTrue with suitable assertions
12963
12964
// from the JTRUE
@@ -13897,9 +13898,10 @@ void Compiler::fgMorphBlock(BasicBlock* block, unsigned highestReachablePostorde
13897
13898
// Yes, pred assertions are available.
13898
13899
// If the pred is (a non-degenerate) BBJ_COND, fetch the appropriate out set.
13899
13900
//
13900
- ASSERT_TP assertionsOut = pred->bbAssertionOut;
13901
+ ASSERT_TP assertionsOut = pred->bbAssertionOut;
13902
+ const bool useCondAssertions = pred->KindIs(BBJ_COND) && (pred->NumSucc() == 2);
13901
13903
13902
- if (pred->KindIs(BBJ_COND) && (pred->NumSucc() == 2) )
13904
+ if (useCondAssertions )
13903
13905
{
13904
13906
if (block == pred->GetJumpDest())
13905
13907
{
@@ -13919,7 +13921,7 @@ void Compiler::fgMorphBlock(BasicBlock* block, unsigned highestReachablePostorde
13919
13921
//
13920
13922
if (!hasPredAssertions)
13921
13923
{
13922
- if (block ->NumSucc() == 1)
13924
+ if (pred ->NumSucc() == 1)
13923
13925
{
13924
13926
apLocal = assertionsOut;
13925
13927
}
0 commit comments