Skip to content
This repository has been archived by the owner on Oct 12, 2022. It is now read-only.

Fix Issue 20844 - Insufficient alignment check for 16-bytes CAS on x86_64 #3109

Merged
merged 1 commit into from
May 26, 2020

Conversation

kinke
Copy link
Contributor

@kinke kinke commented May 19, 2020

No description provided.

@dlang-bot
Copy link
Contributor

Thanks for your pull request and interest in making D better, @kinke! We are looking forward to reviewing it, and you should be hearing from a maintainer soon.
Please verify that your PR follows this checklist:

  • My PR is fully covered with tests (you can see the coverage diff by visiting the details link of the codecov check)
  • My PR is as minimal as possible (smaller, focused PRs are easier to review than big ones)
  • I have provided a detailed rationale explaining my changes
  • New or modified functions have Ddoc comments (with Params: and Returns:)

Please see CONTRIBUTING.md for more information.


If you have addressed all reviews or aren't sure how to proceed, don't hesitate to ping us with a simple comment.

Bugzilla references

Auto-close Bugzilla Severity Description
20844 enhancement DMD compiler should take care of data alignment, after seeing the 'cas' call

Testing this PR locally

If you don't have a local development environment setup, you can use Digger to test this PR:

dub run digger -- build "master + druntime#3109"

@dlang-bot dlang-bot added the Enhancement New functionality label May 19, 2020
else
{
// e.g., x86_64 cmpxchg16b requires 16-bytes alignment
return cast(size_t)ptr % T.sizeof == 0;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ibuclaw: Is that a 'good' default logic for non-x86 targets? I think it's at least better than the current return true for non-DMD...

@kinke kinke force-pushed the atomic branch 2 times, most recently from 326b254 to c9c216f Compare May 19, 2020 22:41
@n8sh n8sh added the 72h no objection -> merge The PR will be merged if there are no objections raised. label May 23, 2020
@thewilsonator thewilsonator added auto-merge and removed 72h no objection -> merge The PR will be merged if there are no objections raised. labels May 26, 2020
@dlang-bot dlang-bot merged commit d11dd8c into dlang:master May 26, 2020
@kinke kinke deleted the atomic branch May 26, 2020 08:40
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Enhancement New functionality
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants