|
16 | 16 |
|
17 | 17 | /// -fintelfpga -fsycl-link tests
|
18 | 18 | // RUN: touch %t.o
|
19 |
| -// RUN: %clangxx -### -target x86_64-unknown-linux-gnu -fsycl -fintelfpga -fsycl-link %t.o 2>&1 \ |
| 19 | +// RUN: %clangxx -### -target x86_64-unknown-linux-gnu -fsycl -fintelfpga -fsycl-link %t.o -o libfoo.a 2>&1 \ |
20 | 20 | // RUN: | FileCheck -check-prefixes=CHK-FPGA-LINK,CHK-FPGA-EARLY %s
|
21 |
| -// RUN: %clangxx -### -target x86_64-unknown-linux-gnu -fsycl -fintelfpga -fsycl-link=early %t.o 2>&1 \ |
| 21 | +// RUN: %clangxx -### -target x86_64-unknown-linux-gnu -fsycl -fintelfpga -fsycl-link=early %t.o -o libfoo.a 2>&1 \ |
22 | 22 | // RUN: | FileCheck -check-prefixes=CHK-FPGA-LINK,CHK-FPGA-EARLY %s
|
23 |
| -// RUN: %clangxx -### -target x86_64-unknown-linux-gnu -fsycl -fintelfpga -fsycl-link=image %t.o 2>&1 \ |
| 23 | +// RUN: %clangxx -### -target x86_64-unknown-linux-gnu -fsycl -fintelfpga -fsycl-link=image %t.o -o libfoo.a 2>&1 \ |
24 | 24 | // RUN: | FileCheck -check-prefixes=CHK-FPGA-LINK,CHK-FPGA-IMAGE %s
|
25 | 25 | // CHK-FPGA-LINK-NOT: clang-offload-bundler{{.*}} "-check-section"
|
26 | 26 | // CHK-FPGA-LINK: clang-offload-bundler{{.*}} "-type=o" "-targets=sycl-spir64_fpga-unknown-unknown-sycldevice" "-inputs=[[INPUT:.+\.o]]" "-outputs=[[OUTPUT1:.+\.o]]" "-unbundle"
|
| 27 | +// CHK-FPGA-LINK-NOT: clang-offload-bundler{{.*}} |
27 | 28 | // CHK-FPGA-LINK: llvm-link{{.*}} "[[OUTPUT1]]" "-o" "[[OUTPUT2:.+\.bc]]"
|
28 | 29 | // CHK-FPGA-LINK: llvm-spirv{{.*}} "-o" "[[OUTPUT3:.+\.spv]]" "-spirv-max-version=1.1" "-spirv-ext=+all" "[[OUTPUT2]]"
|
29 | 30 | // CHK-FPGA-EARLY: aoc{{.*}} "-o" "[[OUTPUT4:.+\.aocr]]" "[[OUTPUT3]]" "-sycl" "-rtl"
|
30 | 31 | // CHK-FPGA-IMAGE: aoc{{.*}} "-o" "[[OUTPUT5:.+\.aocx]]" "[[OUTPUT3]]" "-sycl"
|
31 |
| -// CHK-FPGA-LINK: {{lib|llvm-ar}}{{.*}} "[[INPUT]]" |
| 32 | +// CHK-FPGA-LINK: llvm-ar{{.*}} "cr" "libfoo.a" "[[INPUT]]" |
| 33 | + |
| 34 | +// Output designation should not be used for unbundling step |
| 35 | +// RUN: touch %t.o |
| 36 | +// RUN: touch %t.obj |
| 37 | +// RUN: %clangxx -### -target x86_64-unknown-linux-gnu -fsycl -fintelfpga -fsycl-link %t.o -o libfoo.a 2>&1 \ |
| 38 | +// RUN: | FileCheck -check-prefix=CHK-FPGA-LINK-OUT %s |
| 39 | +// RUN: %clang_cl -### -fsycl -fintelfpga -fsycl-link %t.obj -Folibfoo.a 2>&1 \ |
| 40 | +// RUN: | FileCheck -check-prefixes=CHK-FPGA-LINK-OUT %s |
| 41 | +// RUN: %clang_cl -### -fsycl -fintelfpga -fsycl-link %t.obj -o libfoo.a 2>&1 \ |
| 42 | +// RUN: | FileCheck -check-prefixes=CHK-FPGA-LINK-OUT %s |
| 43 | +// CHK-FPGA-LINK-OUT-NOT: clang-offload-bundler{{.*}} "-outputs=libfoo.a" "-unbundle" |
32 | 44 |
|
33 | 45 | /// -fintelfpga -fsycl-link clang-cl specific
|
34 | 46 | // RUN: touch %t.obj
|
35 |
| -// RUN: %clang_cl -### -fsycl -fintelfpga -fsycl-link %t.obj 2>&1 \ |
| 47 | +// RUN: %clang_cl -### -fsycl -fintelfpga -fsycl-link %t.obj -Folibfoo.lib 2>&1 \ |
| 48 | +// RUN: | FileCheck -check-prefixes=CHK-FPGA-LINK-WIN %s |
| 49 | +// RUN: %clang_cl -### -fsycl -fintelfpga -fsycl-link %t.obj -o libfoo.lib 2>&1 \ |
36 | 50 | // RUN: | FileCheck -check-prefixes=CHK-FPGA-LINK-WIN %s
|
37 | 51 | // CHK-FPGA-LINK-WIN: clang-offload-bundler{{.*}} "-type=o" "-targets=sycl-spir64_fpga-unknown-unknown-sycldevice{{.*}}" "-inputs=[[INPUT:.+\.obj]]" "-outputs=[[OUTPUT1:.+\.obj]]" "-unbundle"
|
| 52 | +// CHK-FPGA-LINK-WIN-NOT: clang-offload-bundler{{.*}} |
38 | 53 | // CHK-FPGA-LINK-WIN: llvm-link{{.*}} "[[OUTPUT1]]" "-o" "[[OUTPUT2:.+\.bc]]"
|
39 | 54 | // CHK-FPGA-LINK-WIN: llvm-spirv{{.*}} "-o" "[[OUTPUT3:.+\.spv]]" "-spirv-max-version=1.1" "-spirv-ext=+all" "[[OUTPUT2]]"
|
40 | 55 | // CHK-FPGA-LINK-WIN: aoc{{.*}} "-o" "[[OUTPUT5:.+\.aocr]]" "[[OUTPUT3]]" "-sycl" "-rtl"
|
41 |
| -// CHK-FPGA-LINK-WIN: lib.exe{{.*}} "[[INPUT]]" |
42 |
| - |
| 56 | +// CHK-FPGA-LINK-WIN: lib.exe{{.*}} "[[INPUT]]" {{.*}} "-OUT:libfoo.lib" |
43 | 57 |
|
44 | 58 | /// Check -fintelfpga -fsycl-link with an FPGA archive
|
45 | 59 | // Create the dummy archive
|
|
0 commit comments