Debian Codegraph @

clang/test/Driver/hip-dependent-options.hip

raw
1 // RUN: not %clang -### --target=x86_64-linux-gnu --no-offload-new-driver \
2 // RUN: -x hip --cuda-gpu-arch=gfx803 --cuda-gpu-arch=gfx900 \
3 // RUN: -c -fhip-emit-relocatable -nogpuinc -nogpulib --cuda-device-only -fgpu-rdc \
4 // RUN: %S/Inputs/hip_multiple_inputs/a.cu \
5 // RUN: %S/Inputs/hip_multiple_inputs/b.hip --gpu-bundle-output \
6 // RUN: 2>&1 | FileCheck -check-prefixes=RELOCRDC %s
7 // RUN: not %clang -### --target=x86_64-linux-gnu --offload-new-driver \
8 // RUN: -x hip --cuda-gpu-arch=gfx803 --cuda-gpu-arch=gfx900 \
9 // RUN: -c -fhip-emit-relocatable -nogpuinc -nogpulib --cuda-device-only -fgpu-rdc \
10 // RUN: %S/Inputs/hip_multiple_inputs/a.cu \
11 // RUN: %S/Inputs/hip_multiple_inputs/b.hip --gpu-bundle-output \
12 // RUN: 2>&1 | FileCheck -check-prefixes=RELOCRDC %s
13
14 // RELOCRDC: error: option '-fhip-emit-relocatable' cannot be specified with '-fgpu-rdc'
15
16 // RUN: not %clang -### --target=x86_64-linux-gnu --no-offload-new-driver \
17 // RUN: -x hip --cuda-gpu-arch=gfx803 --cuda-gpu-arch=gfx900 \
18 // RUN: -c -fhip-emit-relocatable -nogpuinc -nogpulib \
19 // RUN: %S/Inputs/hip_multiple_inputs/a.cu \
20 // RUN: %S/Inputs/hip_multiple_inputs/b.hip --gpu-bundle-output \
21 // RUN: 2>&1 | FileCheck -check-prefixes=RELOCHOST %s
22 // RUN: not %clang -### --target=x86_64-linux-gnu --offload-new-driver \
23 // RUN: -x hip --cuda-gpu-arch=gfx803 --cuda-gpu-arch=gfx900 \
24 // RUN: -c -fhip-emit-relocatable -nogpuinc -nogpulib \
25 // RUN: %S/Inputs/hip_multiple_inputs/a.cu \
26 // RUN: %S/Inputs/hip_multiple_inputs/b.hip --gpu-bundle-output \
27 // RUN: 2>&1 | FileCheck -check-prefixes=RELOCHOST %s
28
29 // RELOCHOST: error: option '-fhip-emit-relocatable' cannot be specified without '--offload-device-only'