Skip to content

Commit 612ddc3

Browse files
committed
[OpenMP][Docs] Updated the faq about building an OpenMP offloading capable compiler
After some issues about building runtimes along with LLVM were fixed, building an OpenMP offloading capable compiler is pretty simple. This patch updates the FAQ part in the doc. Reviewed By: jdoerfert Differential Revision: https://reviews.llvm.org/D93671
1 parent 1432ae5 commit 612ddc3

File tree

1 file changed

+5
-16
lines changed

1 file changed

+5
-16
lines changed

openmp/docs/SupportAndFAQ.rst

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -52,22 +52,11 @@ All patches go through the regular `LLVM review process
5252
Q: How to build an OpenMP offload capable compiler?
5353
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
5454

55-
To build an *effective* OpenMP offload capable compiler we recommend a two
56-
stage build. The first stage Clang does not require to be offload capable but
57-
all backends that are targeted by OpenMP need to be enabled. By default, Clang
58-
will be build with all backends enabled. This initial (stage 1) Clang is used
59-
to create a second Clang compiler that is offload capable as well as the
60-
:ref:`device runtime libraries <device_runtime>` that will be linked into the
61-
offloaded code to provide OpenMP runtime support on the device.
62-
63-
Generic information about building LLVM is available `here
64-
<https://llvm.org/docs/GettingStarted.html>`__. The CMake options for the
65-
second stage Clang should include:
66-
67-
- `LIBOMPTARGET_NVPTX_CUDA_COMPILER=$STAGE1/bin/clang` to use the stage one
68-
compiler for the device runtime compilation.
69-
- `LIBOMPTARGET_NVPTX_ENABLE_BCLIB=ON` to enable efficient device runtimes in
70-
bitcode format.
55+
To build an *effective* OpenMP offload capable compiler, only one extra CMake
56+
option, `LLVM_ENABLE_RUNTIMES="OPENMP"`, is needed when building LLVM (Generic
57+
information about building LLVM is available `here <https://llvm.org/docs/GettingStarted.html>`__.).
58+
Make sure all backends that are targeted by OpenMP to be enabled. By default,
59+
Clang will be build with all backends enabled.
7160

7261
If your build machine is not the target machine or automatic detection of the
7362
available GPUs failed, you should also set:

0 commit comments

Comments
 (0)