CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
58 lines
2.8 KiB
Plaintext
58 lines
2.8 KiB
Plaintext
// Test HIPSPV static device library linking
|
|
// REQUIRES: system-linux
|
|
// REQUIRES: x86-registered-target
|
|
// REQUIRES: spirv-registered-target
|
|
// UNSUPPORTED: system-windows
|
|
|
|
// Create a dummy archive to test SDL linking
|
|
// RUN: rm -rf %t && mkdir %t
|
|
// RUN: touch %t/dummy.bc
|
|
// RUN: llvm-ar cr %t/libSDL.a %t/dummy.bc
|
|
|
|
// Test that -l options are passed to llvm-link for --offload=spirv64
|
|
// RUN: %clang -### --target=x86_64-linux-gnu --offload=spirv64 \
|
|
// RUN: --hip-path=%S/Inputs/hipspv -nohipwrapperinc %s \
|
|
// RUN: --no-offload-new-driver -L%t -lSDL \
|
|
// RUN: 2>&1 | FileCheck -check-prefixes=SDL %s
|
|
|
|
// Test that .a files are properly unbundled and passed to llvm-link
|
|
// RUN: %clang -### --target=x86_64-linux-gnu --offload=spirv64 \
|
|
// RUN: --hip-path=%S/Inputs/hipspv -nohipwrapperinc %s \
|
|
// RUN: --no-offload-new-driver %t/libSDL.a \
|
|
// RUN: 2>&1 | FileCheck -check-prefixes=SDL %s
|
|
|
|
// RUN: %clang -cc1 %s -triple spirv64-unknown-chipstar -emit-llvm-bc -o %t/dev.bc
|
|
// RUN: llvm-offload-binary -o %t/dev.out \
|
|
// RUN: --image=file=%t/dev.bc,kind=hip,triple=spirv64-unknown-chipstar,arch=generic
|
|
// RUN: %clang -cc1 %s -triple x86_64-unknown-linux-gnu -emit-obj -o %t/tu0.o \
|
|
// RUN: -fembed-offload-object=%t/dev.out
|
|
// RUN: cp %t/tu0.o %t/tu1.o
|
|
// RUN: llvm-ar cr %t/libSDL2.a %t/tu1.o
|
|
|
|
// RUN: %clang -### --target=x86_64-linux-gnu --offload-new-driver -fgpu-rdc \
|
|
// RUN: -Xoffload-compiler-spirv64-unknown-chipstar \
|
|
// RUN: --hip-path=%S/Inputs/hipspv -no-hip-rt %t/tu0.o %t/libSDL2.a \
|
|
// RUN: 2>&1 | FileCheck -check-prefixes=SDL-NEW %s -DHIP_PATH=%S/Inputs/hipspv
|
|
|
|
// RUN: clang-linker-wrapper --dry-run --host-triple=x86_64-unknown-linux-gnu \
|
|
// RUN: --device-compiler=spirv64-unknown-chipstar=--hip-path=%S/Inputs/hipspv \
|
|
// RUN: --linker-path=/usr/bin/ld -o a.out %t/tu0.o %t/libSDL2.a \
|
|
// RUN: 2>&1 | FileCheck -check-prefixes=SDL-NEW-WRAPPER %s -DHIP_PATH=%S/Inputs/hipspv
|
|
|
|
// Verify that the input files are added before the SDL files in llvm-link command
|
|
// This tests the ordering fix to match HIPAMD behavior
|
|
// SDL: "{{.*}}clang-offload-bundler" "-unbundle" "-type=a" "-input={{.*}}libSDL.a" "-targets=hip-spirv64-unknown-unknown-unknown-generic" "-output=[[SDL_A:.*\.a]]" "-allow-missing-bundles"
|
|
// SDL: "{{.*}}llvm-link" "-o" "{{.*}}.bc" "{{.*}}.bc" "[[SDL_A]]"
|
|
// SDL-NEW: "{{.*}}clang-linker-wrapper"
|
|
// SDL-NEW-SAME: "--device-compiler=spirv64-unknown-chipstar=--hip-path=[[HIP_PATH]]"
|
|
// SDL-NEW-SAME: "{{.*}}/tu0.o" "{{.*}}/libSDL2.a"
|
|
// DELETE-SDL-NEW: "{{.*}}llvm-link" "-o" "{{.*}}.bc" "{{.*}}.o" "{{.*}}.o"
|
|
|
|
// SDL-NEW-WRAPPER: clang{{.*}}" --no-default-config -o {{[^ ]*.img}}
|
|
// SDL-NEW-WRAPPER-SAME: {{[^ ]*.o}} {{[^ ]*.o}}
|
|
// SDL-NEW-WRAPPER-SAME: --hip-path=[[HIP_PATH]]
|
|
|
|
// SDL: "{{.*}}opt"
|
|
// SDL-SAME: "-load-pass-plugin" {{".*/hipspv/lib/libLLVMHipSpvPasses.so"}}
|
|
// SDL-SAME: "-passes=hip-post-link-passes"
|