Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@AlexGuteniev
Copy link
Contributor

Fixes #4472

  • Invent always-lock-free compile-time check independently from atomic<T>
    • Sharing the checks implementation is a bomb for vNext. In vNext I expect atomic<3 bytes> to be always-lock-free, but not atomic_ref<3 bytes>
    • Having the template constant in global scope is unnecessary, atomic_ref<T> doesn't have volatile things
  • Expand test matrix for that
    • Requires DCAS machine, but it is Win8+ requirement
    • clang-cl wants cx16 feature enabled for that

@AlexGuteniev AlexGuteniev requested a review from a team as a code owner March 14, 2024 10:53
@AlexGuteniev AlexGuteniev changed the title Sulfur Fix atomic_ref<16 bytes>::is_always_lock_free Mar 14, 2024
@StephanTLavavej StephanTLavavej added the bug Something isn't working label Mar 15, 2024
@StephanTLavavej StephanTLavavej self-assigned this Mar 16, 2024
@StephanTLavavej
Copy link
Member

I'm mirroring this to the MSVC-internal repo - please notify me if any further changes are pushed.

@StephanTLavavej StephanTLavavej merged commit 7ac8388 into microsoft:main Mar 19, 2024
@StephanTLavavej
Copy link
Member

☢️ 🛠️ 😻

@AlexGuteniev AlexGuteniev deleted the sulfur branch March 19, 2024 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

<atomic>: With _STD_ATOMIC_ALWAYS_USE_CMPXCHG16B defined to 1, atomic_ref<16 bytes> does not report is_lock_free and is_always_lock_free correctly

2 participants