Lines Matching +full:docs +full:- +full:openmp +full:- +full:html
1 OpenMP Command-Line Argument Reference
3 Welcome to the OpenMP in LLVM command line argument reference. The content is
4 not a complete list of arguments but includes the essential command-line
5 arguments you may need when compiling and linking OpenMP.
6 Section :ref:`general_command_line_arguments` lists OpenMP command line options
8 options relevant to OpenMP target offloading.
12 OpenMP Command-Line Arguments
13 -----------------------------
15 ``-fopenmp``
17 Enable the OpenMP compilation toolchain. The compiler will parse OpenMP
20 ``-fopenmp-extensions``
22 Enable all ``Clang`` extensions for OpenMP directives and clauses. A list of
24 `support <https://clang.llvm.org/docs/OpenMPSupport.html#openmp-extensions>`_
27 ``-fopenmp-simd``
29 This option enables OpenMP only for single instruction, multiple data
32 ``-static-openmp``
34 Use the static OpenMP host runtime while linking.
36 ``-fopenmp-version=<arg>``
38 Set the OpenMP version to a specific version ``<arg>`` of the OpenMP standard.
39 For example, you may use ``-fopenmp-version=45`` to select version 4.5 of
40 the OpenMP standard. The default value is ``-fopenmp-version=51`` for ``Clang``.
44 Offloading Specific Command-Line Arguments
45 ------------------------------------------
47 .. _fopenmp-targets:
49 ``-fopenmp-targets``
51 | Specify which OpenMP offloading targets should be supported. For example, you
52 may specify ``-fopenmp-targets=amdgcn-amd-amdhsa,nvptx64``. This option is
55 ``-fopenmp-targets=x86_64-pc-linux-gnu``.
59 ``--offload-arch``
61 | Specify the device architecture for OpenMP offloading. For instance
62 ``--offload-arch=sm_80`` to target an Nvidia Tesla A100,
63 ``--offload-arch=gfx90a`` to target an AMD Instinct MI250X, or
64 ``--offload-arch=sm_80,gfx90a`` to target both.
65 | It is also possible to specify :ref:`fopenmp-targets` without specifying
66 ``--offload-arch``. In that case, the executables ``amdgpu-arch`` or
67 ``nvptx-arch`` will be executed as part of the compiler driver to
70 ``--offload-arch=native``.
72 ``--offload-device-only``
77 if device-only runtimes are created.
79 ``--offload-host-only``
85 ``--offload-host-device``
90 ``-Xopenmp-target <arg>``
93 ``-Xopenmp-target -march=sm_80``.
95 ``-Xopenmp-target=<triple> <arg>``
99 triple. For instance ``-Xopenmp-target=nvptx64 --offload-arch=sm_80
100 -Xopenmp-target=amdgcn --offload-arch=gfx90a`` to specify the device
104 ``-Xoffload-linker<triple> <arg>``
111 ``-Xarch_device <arg>``
117 ``-Xarch_host <arg>``
121 ``-foffload-lto[=<arg>]``
124 Select either ``-foffload-lto=thin`` or ``-foffload-lto=full``. Thin LTO takes
126 this option defaults to ``-foffload-lto=full``.
128 ``-fopenmp-offload-mandatory``
140 ``-fopenmp-target-debug[=<arg>]``
143 necessary to configure the debugging in the device runtime at compile-time with
144 ``-fopenmp-target-debug=<arg>`` and enable debugging at runtime with the
149 `debugging instructions <https://openmp.llvm.org/design/Runtimes.html#debugging>`_.
152 ``-fopenmp-target-jit``
154 | Emit code that is Just-in-Time (JIT) compiled for OpenMP offloading. Embed
155 LLVM-IR for the device code in the object files rather than binary code for the
156 respective target. At runtime, the LLVM-IR is optimized again and compiled for
159 ``LIBOMPTARGET_JIT_OPT_LEVEL=3`` corresponding to optimizations level ``-O3``.
161 …`OpenMP JIT details <https://openmp.llvm.org/design/Runtimes.html#libomptarget-jit-pre-opt-ir-modu…
164 | We want to emphasize that JIT for OpenMP offloading is good for debugging as
167 ``--offload-new-driver``
169 In upstream LLVM, OpenMP only uses the new driver. However, enabling this
172 ``--offload-link``
174 Use the new offloading linker `clang-linker-wrapper` to perform the link job.
175 `clang-linker-wrapper` is the default offloading linker for OpenMP. This option
179 ``-nogpulib``
183 ``-nogpuinc``