[clang] 86175d5 - Minor fix for test hip-code-object-version.hip

Yaxun Liu via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 6 17:33:16 PDT 2021


Author: Yaxun (Sam) Liu
Date: 2021-04-06T20:32:16-04:00
New Revision: 86175d5fedba7c09ad09ee5afd359e7f9246367a

URL: https://github.com/llvm/llvm-project/commit/86175d5fedba7c09ad09ee5afd359e7f9246367a
DIFF: https://github.com/llvm/llvm-project/commit/86175d5fedba7c09ad09ee5afd359e7f9246367a.diff

LOG: Minor fix for test hip-code-object-version.hip

Changed the order of checking of v2 and v3.

Change-Id: Ifea8197b398afdfb0aa1bd40140cda30f00f0c17

Added: 
    

Modified: 
    clang/test/Driver/hip-code-object-version.hip

Removed: 
    


################################################################################
diff  --git a/clang/test/Driver/hip-code-object-version.hip b/clang/test/Driver/hip-code-object-version.hip
index ba73ace411b5..0e85d9008602 100644
--- a/clang/test/Driver/hip-code-object-version.hip
+++ b/clang/test/Driver/hip-code-object-version.hip
@@ -1,5 +1,21 @@
 // REQUIRES: clang-driver, amdgpu-registered-target
 
+// Check bundle ID for code object v2.
+
+// RUN: %clang -### -target x86_64-linux-gnu \
+// RUN:   -mno-code-object-v3 \
+// RUN:   --offload-arch=gfx906 -nogpulib \
+// RUN:   %s 2>&1 | FileCheck -check-prefixes=V2,V2-WARN %s
+
+// RUN: %clang -### -target x86_64-linux-gnu \
+// RUN:   -mcode-object-version=2 \
+// RUN:   --offload-arch=gfx906 -nogpulib \
+// RUN:   %s 2>&1 | FileCheck -check-prefix=V2 %s
+
+// V2-WARN: warning: argument '-mno-code-object-v3' is deprecated, use '-mcode-object-version=2' instead [-Wdeprecated]
+// V2: "-mllvm" "--amdhsa-code-object-version=2"
+// V2: "-targets=host-x86_64-unknown-linux,hip-amdgcn-amd-amdhsa--gfx906"
+
 // Check bundle ID for code object v3.
 
 // RUN: %clang -### -target x86_64-linux-gnu \
@@ -21,22 +37,6 @@
 // V3: "-mllvm" "--amdhsa-code-object-version=3"
 // V3: "-targets=host-x86_64-unknown-linux,hip-amdgcn-amd-amdhsa--gfx906"
 
-// Check bundle ID for code object v2.
-
-// RUN: %clang -### -target x86_64-linux-gnu \
-// RUN:   -mno-code-object-v3 \
-// RUN:   --offload-arch=gfx906 -nogpulib \
-// RUN:   %s 2>&1 | FileCheck -check-prefixes=V2,V2-WARN %s
-
-// RUN: %clang -### -target x86_64-linux-gnu \
-// RUN:   -mcode-object-version=2 \
-// RUN:   --offload-arch=gfx906 -nogpulib \
-// RUN:   %s 2>&1 | FileCheck -check-prefix=V2 %s
-
-// V2-WARN: warning: argument '-mno-code-object-v3' is deprecated, use '-mcode-object-version=2' instead [-Wdeprecated]
-// V2: "-mllvm" "--amdhsa-code-object-version=2"
-// V2: "-targets=host-x86_64-unknown-linux,hip-amdgcn-amd-amdhsa--gfx906"
-
 // Check bundle ID for code object version 4.
 
 // RUN: %clang -### -target x86_64-linux-gnu \


        


More information about the cfe-commits mailing list