[PATCH] D105191: [Clang][OpenMP] Add support for Static Device Libraries
Ye Luo via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Sep 14 21:39:36 PDT 2021
ye-luo added a comment.
1. modf works now.
2. if I modify the complile.sh
clang++ -fopenmp -fopenmp-targets=nvptx64 -c classA.cpp
rm -f libmylib.a
ar qc libmylib.a classA.o
ranlib libmylib.a
clang++ -fopenmp -fopenmp-targets=nvptx64 main.cpp -L. -lmylib
./a.out
doesn't work. I think the solution is adding sm_XX to the module name regardless of user command line.
3, directly linking static archive doesn't work.
clang++ -fopenmp -fopenmp-targets=nvptx64 main.cpp libmylib.a
CMake generates this style of link line. So this really needs to work.
only the following case works right now.
clang++ -fopenmp -fopenmp-targets=nvptx64 main.cpp -L. -lmylib
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D105191/new/
https://reviews.llvm.org/D105191
More information about the cfe-commits
mailing list