[DRAFT] Expression templates and generic RMW events#988
Open
ThomasHaas wants to merge 5 commits intodevelopmentfrom
Open
[DRAFT] Expression templates and generic RMW events#988ThomasHaas wants to merge 5 commits intodevelopmentfrom
ThomasHaas wants to merge 5 commits intodevelopmentfrom
Conversation
…y for C11/IMM implemented (many tests will fail)
… and implement (almost) all LLVM_RMW atomics by GenericRMWReturn
Collaborator
Author
|
I have replaced all LLVM RMW atomics by a single generic event and it seems to work. The compilation scheme for that event is also almost identical for all architectures (I just copy&pasted the code and changed the memory orders). However, while everything seems to work now, the generic event is not suitable to capture spurious failure (weak CAS) right now. And I think it might be too much to also try to capture that in the generic event (at some point it tries to do too much). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR is just a proof-of-concept implementation for generic RMW events that can model (hopefully) all standard RMWs by utilizing expression templates (expressions with holes).
Right now, many unit tests will fail because I didn't add compilation schemes for the new events to all architectures but the LLVM parser will generate a new event already for CAS operations. However, one of the (two) new events can be compiled to IMM/LLVM and so tests on the language level should work.