Skip to content

Commit 52f568d

Browse files
authored
[DWARFLinkerParallel] Change more cases of compare_exchange_weak to compare_exchange_strong (#138692)
This is a follow-up to 07bc54b; this fixes more occasional crashes in dsymutil on Windows on aarch64.
1 parent 2d81994 commit 52f568d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llvm/lib/DWARFLinker/Parallel/ArrayList.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ template <typename T, size_t ItemsGroupSize = 512> class ArrayList {
137137
NewGroup->Next = nullptr;
138138

139139
// Try to replace current group with allocated one.
140-
if (AtomicGroup.compare_exchange_weak(CurGroup, NewGroup))
140+
if (AtomicGroup.compare_exchange_strong(CurGroup, NewGroup))
141141
return true;
142142

143143
// Put allocated group as last group.

0 commit comments

Comments
 (0)