Skip to content
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

implement syncscopes everywhere #20

Merged
merged 7 commits into from
Dec 10, 2024
Merged

implement syncscopes everywhere #20

merged 7 commits into from
Dec 10, 2024

Conversation

vchuravy
Copy link
Member

@vchuravy vchuravy commented Dec 2, 2024

TODO

  • Tests
  • Support in UnsafeAtomicsLLVM ext
  • Tests in UnsafeAtomicsLLVM
  • GPU syncscopes

Base automatically changed from vc/fence2 to master December 3, 2024 12:42
@vchuravy vchuravy marked this pull request as ready for review December 6, 2024 14:24
@vchuravy vchuravy requested a review from maleadt December 6, 2024 14:25
@@ -45,4 +47,8 @@ const seq_cst = Internal.seq_cst
const acquire_release = acq_rel
const sequentially_consistent = seq_cst

# SyncScope
const none = Internal.none
Copy link
Member Author

Choose a reason for hiding this comment

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

Should we have an alias for this called system?

@vchuravy
Copy link
Member Author

vchuravy commented Dec 6, 2024

@maleadt so the last remaining question is what do we do about the GPU backend specific syncscopes.

  1. Enumerate all of them like Clang
  2. Only enumerate the OpenCL ones so that WIP: Support LLVM atomic intrinsics. JuliaGPU/GPUCompiler.jl#652 has something to target

@maleadt
Copy link
Member

maleadt commented Dec 6, 2024

What about leaving it up to the caller and simply using symbols? I'm not sure how we'll be able to generalize this without some input from the back-end anyway (i.e. Metal.jl specifying which syncscope to use for a certain kind of array).

@vchuravy
Copy link
Member Author

vchuravy commented Dec 6, 2024

Yeah, right now, I allow for anything to be wrapped in LLVMSyncScope

@vchuravy vchuravy merged commit 98bb4ab into master Dec 10, 2024
4 checks passed
@vchuravy vchuravy deleted the vc/syncscope branch December 10, 2024 06:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants