Skip to content

Commit be516fa

Browse files
committed
first may be cancelled.
Currently `first` is not None by default.
1 parent 05df8df commit be516fa

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

clang/lib/CodeGen/CodeGenPGO.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1215,7 +1215,8 @@ void CodeGenPGO::emitCounterSetOrIncrement(CGBuilderTy &Builder, const Stmt *S,
12151215
auto &TheMap = (*RegionCounterMap)[S];
12161216
auto IsCounter = TheMap.getIsCounterPair();
12171217
if (!UseSkipPath) {
1218-
assert(IsCounter.first);
1218+
if (!IsCounter.first)
1219+
return;
12191220
Counter = (TheMap.first & CounterPair::Mask);
12201221
} else {
12211222
if (!IsCounter.second)

0 commit comments

Comments
 (0)