Add an option -munsafe-fp-atomics for AMDGPU target.
When enabled, clang adds function attribute "amdgpu-unsafe-fp-atomics"
to any functions for amdgpu target. This allows amdgpu backend to use
unsafe fp atomic instructions in these functions.
Paths
| Differential D91546
[AMDGPU] Add option -munsafe-fp-atomics ClosedPublic Authored by yaxunl on Nov 16 2020, 8:15 AM.
Details Summary Add an option -munsafe-fp-atomics for AMDGPU target. When enabled, clang adds function attribute "amdgpu-unsafe-fp-atomics"
Diff Detail Event TimelineHerald added subscribers: dang, kerbowa, jfb and 6 others. · View Herald TranscriptNov 16 2020, 8:15 AM Comment Actions LGTM. Patch description could use a pointer to more details about the unsafe atomics.
This revision is now accepted and ready to land.Nov 16 2020, 9:35 AM yaxunl added inline comments.
Closed by commit rG3f4b5893efed: [AMDGPU] Add option -munsafe-fp-atomics (authored by yaxunl). · Explain WhyNov 16 2020, 6:53 PM This revision was automatically updated to reflect the committed changes. yaxunl marked an inline comment as done.
Revision Contents
Diff 305522 clang/include/clang/Basic/TargetInfo.h
clang/include/clang/Basic/TargetOptions.h
clang/include/clang/Driver/Options.td
clang/lib/Basic/TargetInfo.cpp
clang/lib/Basic/Targets/AMDGPU.cpp
clang/lib/CodeGen/TargetInfo.cpp
clang/lib/Driver/ToolChains/Clang.cpp
clang/lib/Frontend/CompilerInvocation.cpp
clang/test/CodeGenCUDA/amdgpu-func-attrs.cu
clang/test/Driver/hip-options.hip
|
I'm curious -- what does unsafe mean here?