Skip to content

Commit

Permalink
Fix test hip-offload-compress-zlib.hip
Browse files Browse the repository at this point in the history
and hip-offload-compress-zstd.hip.

For failure https://lab.llvm.org/buildbot/#/builders/231/builds/16710

We cannot do real linking for x86_64 on certain systems, so we
do -### instead.
  • Loading branch information
yxsamliu committed Oct 4, 2023
1 parent 8d6d4f8 commit ba01ce6
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 14 deletions.
12 changes: 5 additions & 7 deletions clang/test/Driver/hip-offload-compress-zlib.hip
Original file line number Diff line number Diff line change
Expand Up @@ -20,28 +20,26 @@

// Test uncompress of bundled bitcode.

// RUN: %clang --hip-link -v --target=x86_64-linux-gnu \
// RUN: %clang --hip-link -### -v --target=x86_64-linux-gnu \
// RUN: --offload-arch=gfx1100 --offload-arch=gfx1101 \
// RUN: -fgpu-rdc -nogpulib \
// RUN: %T/a.bc --offload-device-only \
// RUN: 2>&1 | FileCheck -check-prefix=UNBUNDLE %s

// UNBUNDLE: clang-offload-bundler{{.*}} -type=bc
// UNBUNDLE: clang-offload-bundler{{.*}} "-type=bc"
// UNBUNDLE-SAME: -targets={{.*}}hip-amdgcn-amd-amdhsa-gfx1100,hip-amdgcn-amd-amdhsa-gfx1101
// UNBUNDLE-SAME: -unbundle
// UNBUNDLE-SAME: -verbose
// UNBUNDLE: Compressed bundle format

// Test compress bundled code objects.

// RUN: %clang -c -v --target=x86_64-linux-gnu \
// RUN: %clang -c -### -v --target=x86_64-linux-gnu \
// RUN: -x hip --offload-arch=gfx1100 --offload-arch=gfx1101 \
// RUN: -nogpuinc -nogpulib \
// RUN: %S/Inputs/hip_multiple_inputs/a.cu \
// RUN: --offload-compress \
// RUN: 2>&1 | FileCheck -check-prefix=CO %s

// CO: clang-offload-bundler{{.*}} -type=o
// CO: clang-offload-bundler{{.*}} "-type=o"
// CO-SAME: -targets={{.*}}hipv4-amdgcn-amd-amdhsa--gfx1100,hipv4-amdgcn-amd-amdhsa--gfx1101
// CO-SAME: -compress -verbose
// CO: Compressed bundle format
// CO-SAME: "-compress" "-verbose"
12 changes: 5 additions & 7 deletions clang/test/Driver/hip-offload-compress-zstd.hip
Original file line number Diff line number Diff line change
Expand Up @@ -20,28 +20,26 @@

// Test uncompress of bundled bitcode.

// RUN: %clang --hip-link -v --target=x86_64-linux-gnu \
// RUN: %clang --hip-link -### -v --target=x86_64-linux-gnu \
// RUN: --offload-arch=gfx1100 --offload-arch=gfx1101 \
// RUN: -fgpu-rdc -nogpulib \
// RUN: %T/a.bc --offload-device-only \
// RUN: 2>&1 | FileCheck -check-prefix=UNBUNDLE %s

// UNBUNDLE: clang-offload-bundler{{.*}} -type=bc
// UNBUNDLE: clang-offload-bundler{{.*}} "-type=bc"
// UNBUNDLE-SAME: -targets={{.*}}hip-amdgcn-amd-amdhsa-gfx1100,hip-amdgcn-amd-amdhsa-gfx1101
// UNBUNDLE-SAME: -unbundle
// UNBUNDLE-SAME: -verbose
// UNBUNDLE: Compressed bundle format

// Test compress bundled code objects.

// RUN: %clang -c -v --target=x86_64-linux-gnu \
// RUN: %clang -c -### -v --target=x86_64-linux-gnu \
// RUN: -x hip --offload-arch=gfx1100 --offload-arch=gfx1101 \
// RUN: -nogpuinc -nogpulib \
// RUN: %S/Inputs/hip_multiple_inputs/a.cu \
// RUN: --offload-compress \
// RUN: 2>&1 | FileCheck -check-prefix=CO %s

// CO: clang-offload-bundler{{.*}} -type=o
// CO: clang-offload-bundler{{.*}} "-type=o"
// CO-SAME: -targets={{.*}}hipv4-amdgcn-amd-amdhsa--gfx1100,hipv4-amdgcn-amd-amdhsa--gfx1101
// CO-SAME: -compress -verbose
// CO: Compressed bundle format
// CO-SAME: "-compress" "-verbose"

0 comments on commit ba01ce6

Please sign in to comment.