================
@@ -0,0 +1,51 @@
+; Tests the clang-sycl-linker tool: device code splitting.
+;
+; REQUIRES: spirv-registered-target
+;
+; RUN: llvm-as %s -o %t.bc
+;
+; Test that an invalid split mode is rejected.
+; RUN: not clang-sycl-linker --dry-run -triple=spirv64
--module-split-mode=bogus %t.bc -o a.out 2>&1 \
+; RUN: | FileCheck %s --check-prefix=SPLIT-INVALID
+; SPLIT-INVALID: module-split-mode value isn't recognized: bogus
+;
+; Test the split mode ("none"): no extra splits are produced.
+; RUN: clang-sycl-linker --dry-run -v -triple=spirv64 --module-split-mode=none
%t.bc -o %t-none.out 2>&1 \
+; RUN: | FileCheck %s --check-prefix=SPLIT-NONE
+; SPLIT-NONE: sycl-device-link: inputs: {{.*}}.bc libfiles: output:
[[LLVMLINKOUT:.*]].bc
+; SPLIT-NONE-NEXT: sycl-module-split: input: [[LLVMLINKOUT]].bc, output:
[[LLVMLINKOUT]].bc, mode: none
+; SPLIT-NONE-NEXT: LLVM backend: input: [[LLVMLINKOUT]].bc, output:
{{.*}}_0.spv
+; SPLIT-NONE-NOT: LLVM backend: input: {{.*}}.bc, output: {{.*}}_1.spv
----------------
YuriPlyakhin wrote:
This PR purpose is just move the tests, keeping the functionality.
The test updates will happen in this PR:
https://github.com/llvm/llvm-project/pull/197571
https://github.com/llvm/llvm-project/pull/197566
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits