-
Notifications
You must be signed in to change notification settings - Fork 128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CIR][CIRGen] Support for builtin __atomic_thread_fence
#1287
[CIR][CIRGen] Support for builtin __atomic_thread_fence
#1287
Conversation
I have just created the ODS definition at the moment to be sure if this is the way to go. |
969faf7
to
c2cc1a9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Initial step looks good, some inline comments. Note that this PR should come with CIRGen and LLVM lowering support, I suggest you first handle a very simple case of the fence and mark all paths not currently support with llvm_unrecheable("NYI")
, so that you can go about working in incremental PRs to complete this.
__atomic_thread_fence
__atomic_thread_fence
c2cc1a9
to
e8758ac
Compare
We just went over a rebase against upstream, apologies for the churn but please update your branch for this PR and force-push! |
e8758ac
to
ca75a57
Compare
6425312
to
97fb189
Compare
Do we need a new definition for |
That is kinda of territory of LLVM dialect. Currently llvm.fenceop uses stringattr to represent syncscope, and I assume it works meaning it lowers to LLVM IR without problem if we set it with right string value from clangir lowering to LLVM (dialect) |
97fb189
to
39bfe2b
Compare
From my sight I can see the following nits:
|
1a626c7
to
83b33a7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mostly good, few nits and ready to go
83b33a7
to
8f81369
Compare
8f81369
to
35d7898
Compare
LGMT, too |
35d7898
to
9699710
Compare
Resolves llvm#1274 Implements atomic thread fence synchronization primitive corresponding to `atomic.thread_fence` CIR.
a191e33
to
0a24062
Compare
0a24062
to
0ed0cb6
Compare
Fix #1274
Implements atomic thread fence synchronization primitive corresponding to
atomic.thread_fence
CIR.