File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
stdlib/public/Concurrency Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -525,10 +525,12 @@ class alignas(2 * sizeof(void*)) ActiveTaskStatus {
525525#endif
526526static_assert (sizeof (ActiveTaskStatus) == ACTIVE_TASK_STATUS_SIZE,
527527 " ActiveTaskStatus is of incorrect size" );
528- static_assert (sizeof (std::atomic<ActiveTaskStatus>) == sizeof (ActiveTaskStatus),
529- " ActiveTaskStatus is misaligned" );
528+ #if !defined(_WIN64)
530529static_assert (sizeof (swift::atomic<ActiveTaskStatus>) == sizeof (std::atomic<ActiveTaskStatus>),
531- " swift::atomic and std::atomic are unaligned" );
530+ " swift::atomic pads std::atomic, memory aliasing invariants violated" );
531+ #endif
532+ static_assert (sizeof (swift::atomic<ActiveTaskStatus>) == sizeof (ActiveTaskStatus),
533+ " swift::atomic pads ActiveTaskStatus, memory aliasing invariants violated" );
532534
533535// / The size of an allocator slab. We want the full allocation to fit into a
534536// / 1024-byte malloc quantum. We subtract off the slab header size, plus a
You can’t perform that action at this time.
0 commit comments