Skip to content

Commit 55fb750

Browse files
rmacnak-googleCommit Queue
authored andcommitted
[vm] Fix race in vm/cc/SafepointOperation_SafepointOpBlockedWhileDeoptSafepointOp.
LongDeoptTask: MarkAndNotify(kFinishedDeoptOperation) main: MarkAndNotify(kPleaseExit) If main wins, LongDeoptTask will override the state and wait for a kPleaseExit that will never come. TEST=ci Change-Id: I2f29da2fca980ca8f2b3c42477c4e793d7379af4 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/416381 Commit-Queue: Ryan Macnak <[email protected]> Reviewed-by: Alexander Aprelev <[email protected]>
1 parent 9b116d0 commit 55fb750

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

runtime/vm/heap/safepoint_test.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,7 @@ ISOLATE_UNIT_TEST_CASE(
279279
// progress.
280280
deopt->MarkAndNotify(LongDeoptTask::kFinishDeoptOperation);
281281
gc->WaitUntil(WaiterTask::kExitedSafepoint);
282+
deopt->WaitUntil(LongDeoptTask::kFinishedDeoptOperation);
282283

283284
// Make both threads exit the isolate group.
284285
deopt->MarkAndNotify(LongDeoptTask::kPleaseExit);

0 commit comments

Comments
 (0)