Skip to content

Commit 1439df0

Browse files
committed
[HIP] Fix test rcom-detect.hip
This patches fixes https://bugs.llvm.org/show_bug.cgi?id=51404 Some builds use custom resource directory for clang, therefore the test cannot assume default resource directory for clang. Use -resource-dir to force it. Differential Revision: https://reviews.llvm.org/D111726
1 parent d2e6f47 commit 1439df0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

clang/test/Driver/rocm-detect.hip

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
// RUN: cp -r %S/Inputs/rocm-spack %T
4343
// RUN: ln -fs %clang %T/rocm-spack/llvm-amdgpu-4.0.0-ieagcs7inf7runpyfvepqkurasoglq4z/bin/clang
4444
// RUN: %T/rocm-spack/llvm-amdgpu-4.0.0-ieagcs7inf7runpyfvepqkurasoglq4z/bin/clang -### -v \
45+
// RUN: -resource-dir=%T/rocm-spack/llvm-amdgpu-4.0.0-ieagcs7inf7runpyfvepqkurasoglq4z/lib/clang \
4546
// RUN: -target x86_64-linux-gnu --cuda-gpu-arch=gfx900 --print-rocm-search-dirs %s 2>&1 \
4647
// RUN: | FileCheck -check-prefixes=SPACK %s
4748

@@ -83,7 +84,7 @@
8384
// SPACK: ROCm installation search path (Spack 4.0.0): [[DIR:.*]]
8485
// SPACK: ROCm installation search path: [[CLANG:.*]]
8586
// SPACK: ROCm installation search path: [[DIR]]/llvm-amdgpu-4.0.0-ieagcs7inf7runpyfvepqkurasoglq4z
86-
// SPACK: ROCm installation search path: [[CLANG]]/{{(llvm/)?}}lib{{[0-9]*}}/clang/{{[0-9.]+}}
87+
// SPACK: ROCm installation search path: [[DIR]]/llvm-amdgpu-4.0.0-ieagcs7inf7runpyfvepqkurasoglq4z/lib/clang
8788
// SPACK: ROCm installation search path: /opt/rocm
8889
// SPACK: InstalledDir: [[DIR]]/llvm-amdgpu-4.0.0-ieagcs7inf7runpyfvepqkurasoglq4z/bin
8990
// SPACK: Found HIP installation: [[DIR]]/hip-4.0.0-5f63slrursbrvfe2txrrjkynbsywsob5, version 4.0.20214-a2917cd

0 commit comments

Comments
 (0)