[PATCH] D14370: [doc] Compile CUDA with LLVM
Sean Silva via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 6 19:18:12 PST 2015
silvas added a subscriber: silvas.
silvas added a comment.
My biggest concern is to avoid giving users the false impression that what is described here is an officially supported long-term interface from clang. Would it be accurate to say that this document is meant for "LLVM developers" (or otherwise people working inside LLVM)?
Other than clarifying that, the content LGTM.
================
Comment at: docs/CompileCudaWithLLVM.rst:11-16
@@ +10,8 @@
+
+This document contains the user guides and the internals of compiling CUDA C/C++
+with LLVM. It is written for not only users who want to compile CUDA with LLVM
+but also developers who want to improve LLVM for GPUs. This
+document assumes a basic familiarity with CUDA. Information about CUDA
+programming can be found in the `CUDA programming guide
+<http://docs.nvidia.com/cuda/cuda-c-programming-guide/index.html>`_.
+
----------------
>From reading this document, I think it would be worth it to somehow qualify the audience description to say "early adopters who are willing to use unstable internal interfaces" or something like that.
================
Comment at: docs/CompileCudaWithLLVM.rst:26-29
@@ +25,6 @@
+
+#. Checkout LLVM
+
+ * ``cd where-you-want-llvm-to-live``
+ * ``svn co http://llvm.org/svn/llvm-project/llvm/trunk llvm``
+
----------------
Do you feel strongly about replicating this here from the GettingStarted page? I would prefer to avoid the duplication. But if you feel strongly that your audience will benefit from this, then we can leave it in.
================
Comment at: docs/CompileCudaWithLLVM.rst:145
@@ +144,3 @@
+
+ $ clang -cc1 -triple <target triple> -target-cpu <GPU compute capability> -include <path to cuda_builtin_vars.h> -emit-llvm -fcuda-is-device -O3 axpy.cu -o axpy.ll
+ $ llc -mcpu=<GPU compute capability> axpy.ll -o axpy.ptx
----------------
cc1 is officially an internal interface. Please put a big fat warning here that the cc1 interface is unstable and can be broken at any time.
http://reviews.llvm.org/D14370
More information about the llvm-commits
mailing list