[llvm-bugs] [Bug 35692] New: Fails to compile documentation example on MacOSX

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Dec 19 06:38:46 PST 2017


https://bugs.llvm.org/show_bug.cgi?id=35692

            Bug ID: 35692
           Summary: Fails to compile documentation example on MacOSX
           Product: clang
           Version: trunk
          Hardware: PC
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: CUDA
          Assignee: unassignedclangbugs at nondot.org
          Reporter: gonzalobg88 at gmail.com
                CC: llvm-bugs at lists.llvm.org

I've installed MacOSX high sierra, updated xcode, installed latest cuda (CUDA
9.1), and when trying to compile the documentation example in:
https://llvm.org/docs/CompileCudaWithLLVM.html#invoking-clang

like this:

clang++ axpy.cu -o axpy --cuda-gpu-arch=sm_35 -L/usr/local/cuda/lib -lcudart
-ldl -lrt -pthread

it fails to compile with the following error: 

clang-6.0: error: cannot find libdevice for sm_35. Provide path to different
CUDA installation via --cuda-path, or pass -nocudalib to build without linking
with libdevice.


I've tried passing clang --cuda-path=/usr/local/cuda/ and also
--cuda-path=/Developer/NVIDIA/CUDA-9.1/ without any luck.

The paths in /usr/local/cuda all link to /Developer/NVIDIA/CUDA-9.1/.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20171219/0b8cf20a/attachment.html>


More information about the llvm-bugs mailing list