[clang] [OpenMP] Test amdgcn_openmp_device_math_c.c test on 32-bit platforms
authorMichał Górny <mgorny@gentoo.org>
Mon, 26 Dec 2022 09:21:44 +0000 (10:21 +0100)
committerMichał Górny <mgorny@gentoo.org>
Mon, 26 Dec 2022 09:38:40 +0000 (10:38 +0100)
Explicitly pass triple to the test compiler to prevent failure when
the host triple is 32-bit.  This is the same solution
as f74e3d2f81d2aae47d6032fc1d23114460d48a37, thanks to Joseph Huber
for it.

clang/test/Headers/amdgcn_openmp_device_math_c.c

index 2a54e92..e8c3f3c 100644 (file)
@@ -1,5 +1,5 @@
 // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --function-signature --include-generated-funcs --replace-value-regex "__omp_offloading_[0-9a-z]+_[0-9a-z]+" "reduction_size[.].+[.]" "pl_cond[.].+[.|,]"
-// RUN: %clang_cc1 -internal-isystem %S/Inputs/include -x c -fopenmp -fopenmp-targets=amdgcn-amd-amdhsa -D__OFFLOAD_ARCH_gfx90a__ -emit-llvm-bc %s -o %t-host.bc
+// RUN: %clang_cc1 -internal-isystem %S/Inputs/include -x c -fopenmp -fopenmp-targets=amdgcn-amd-amdhsa -triple powerpc64le-unknown-unknown -D__OFFLOAD_ARCH_gfx90a__ -emit-llvm-bc %s -o %t-host.bc
 // RUN: %clang_cc1 -include __clang_hip_runtime_wrapper.h -internal-isystem %S/../../lib/Headers/openmp_wrappers -include __clang_openmp_device_functions.h -internal-isystem %S/../../lib/Headers/openmp_wrappers -internal-isystem %S/Inputs/include -x c -fopenmp -triple amdgcn-amd-amdhsa -aux-triple x86_64-unknown-unknown -fopenmp-targets=amdgcn-amd-amdhsa -emit-llvm %s -fopenmp-is-device -fopenmp-host-ir-file-path %t-host.bc -o - | FileCheck %s --check-prefixes=CHECK
 // REQUIRES: amdgpu-registered-target