[PATCH] D124721: [OpenMP] Allow compiling multiple target architectures with OpenMP
Joseph Huber via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon May 2 14:29:06 PDT 2022
jhuber6 updated this revision to Diff 426521.
jhuber6 added a comment.
Changing slightly, I'm using the `getArgsForToolchain` to only get the `--offload-arch` options for that toolchain. This lets us quality it with options like `-Xopenmp-target=` so we can now specify architectures per-toolchain without it causing an error. For example, the following should work:
clang input.c -fopenmp -fopenmp-targets=nvptx64,amdgcn -Xopenmp-targets=amdgcn --offload-arch=gfx803 -Xopenmp-targets=nvptx64 --offload-arch=sm_70 -c
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D124721/new/
https://reviews.llvm.org/D124721
Files:
clang/lib/Driver/Driver.cpp
clang/lib/Driver/ToolChains/AMDGPUOpenMP.cpp
clang/lib/Driver/ToolChains/Cuda.cpp
clang/test/Driver/amdgpu-openmp-toolchain-new.c
clang/test/Driver/openmp-offload-gpu-new.c
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D124721.426521.patch
Type: text/x-patch
Size: 11892 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220502/a960ac15/attachment.bin>
More information about the cfe-commits
mailing list