================ @@ -0,0 +1,39 @@ +// Check that -fcf-protection does not get passed to the device-side +// compilation. + +// RUN: %clang -### -x cuda --target=x86_64-unknown-linux-gnu -nogpulib \ +// RUN: -nogpuinc --offload-arch=sm_52 -fcf-protection=full -c %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=CUDA + +// CUDA: "-cc1" "-triple" "nvptx64-nvidia-cuda" +// CUDA-NOT: "-fcf-protection=full" +// CUDA: "-cc1" "-triple" "x86_64-unknown-linux-gnu" +// CUDA: "-fcf-protection=full" + +// RUN: %clang -### -x hip --target=x86_64-unknown-linux-gnu -nogpulib \ +// RUN: -nogpuinc --offload-arch=gfx90a -fcf-protection=full -c %s 2>&1 \ +// RUN: | FileCheck %s --check-prefix=HIP + +// HIP: "-cc1" "-triple" "amdgcn-amd-amdhsa" +// HIP-NOT: "-fcf-protection=full" +// HIP: "-cc1" "-triple" "x86_64-unknown-linux-gnu" +// HIP: "-fcf-protection=full" + ---------------- arsenm wrote:
Can you check explicitly passing this through to the device? https://github.com/llvm/llvm-project/pull/88402 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits