File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -539,10 +539,13 @@ void LazyValueInfoImpl::solve() {
539
539
}
540
540
std::pair<BasicBlock *, Value *> e = BlockValueStack.back ();
541
541
assert (BlockValueSet.count (e) && " Stack value should be in BlockValueSet!" );
542
+ unsigned StackSize = BlockValueStack.size ();
543
+ (void ) StackSize;
542
544
543
545
if (solveBlockValue (e.second , e.first )) {
544
546
// The work item was completely processed.
545
- assert (BlockValueStack.back () == e && " Nothing should have been pushed!" );
547
+ assert (BlockValueStack.size () == StackSize &&
548
+ BlockValueStack.back () == e && " Nothing should have been pushed!" );
546
549
#ifndef NDEBUG
547
550
std::optional<ValueLatticeElement> BBLV =
548
551
TheCache.getCachedValueInfo (e.second , e.first );
@@ -556,7 +559,8 @@ void LazyValueInfoImpl::solve() {
556
559
BlockValueSet.erase (e);
557
560
} else {
558
561
// More work needs to be done before revisiting.
559
- assert (BlockValueStack.back () != e && " Stack should have been pushed!" );
562
+ assert (BlockValueStack.size () == StackSize + 1 &&
563
+ " Exactly one element should have been pushed!" );
560
564
}
561
565
}
562
566
}
You can’t perform that action at this time.
0 commit comments