[PATCH] D129885: [CUDA] Make the new driver properly ignore non-CUDA inputs

Fangrui Song via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 15 11:34:25 PDT 2022


MaskRay added inline comments.


================
Comment at: clang/test/Driver/cuda-phases.cu:270
+
+// RUN: %clang -### -target powerpc64le-ibm-linux-gnu -ccc-print-phases --offload-new-driver \
+// RUN: --offload-arch=sm_52 --offload-arch=sm_70 %s %S/Inputs/empty.cpp 2>&1 | FileCheck --check-prefix=NON-CUDA-INPUT %s
----------------
Use `--target=`. `-target ` is legacy.


================
Comment at: clang/test/Driver/cuda-phases.cu:271
+// RUN: %clang -### -target powerpc64le-ibm-linux-gnu -ccc-print-phases --offload-new-driver \
+// RUN: --offload-arch=sm_52 --offload-arch=sm_70 %s %S/Inputs/empty.cpp 2>&1 | FileCheck --check-prefix=NON-CUDA-INPUT %s
+// NON-CUDA-INPUT: 0: input, "[[CUDA:.+]]", cuda, (host-cuda)
----------------
The continuation line is typically indented by 2 spaces


================
Comment at: clang/test/Driver/cuda-phases.cu:273
+// NON-CUDA-INPUT: 0: input, "[[CUDA:.+]]", cuda, (host-cuda)
+// NON-CUDA-INPUT: 1: preprocessor, {0}, cuda-cpp-output, (host-cuda)
+// NON-CUDA-INPUT: 2: compiler, {1}, ir, (host-cuda)
----------------
If `-NEXT` is applicable, add it


================
Comment at: clang/test/Driver/cuda-phases.cu:297
+// NON-CUDA-INPUT: 24: clang-linker-wrapper, {18, 23}, image, (host-cuda)
+
----------------
delete blank line


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D129885/new/

https://reviews.llvm.org/D129885



More information about the cfe-commits mailing list