Author: Orlando Cazalet-Hyams
Date: 2025-05-27T10:54:44+01:00
New Revision: 94929b725f415a8ab8de35194f3c2eec5192990f

URL: 
https://github.com/llvm/llvm-project/commit/94929b725f415a8ab8de35194f3c2eec5192990f
DIFF: 
https://github.com/llvm/llvm-project/commit/94929b725f415a8ab8de35194f3c2eec5192990f.diff

LOG: [KeyInstr] Add triple to Clang tests

Fixes various downstream bot failures ocurring with different default targets
e.g., windows due to mangling assumptions baked into the tests.

Added: 
    

Modified: 
    clang/test/DebugInfo/KeyInstructions/agg.c
    clang/test/DebugInfo/KeyInstructions/assign-scalar.c
    clang/test/DebugInfo/KeyInstructions/do.c
    clang/test/DebugInfo/KeyInstructions/if.c
    clang/test/DebugInfo/KeyInstructions/init-agg.c
    clang/test/DebugInfo/KeyInstructions/init-member.cpp
    clang/test/DebugInfo/KeyInstructions/init-scalar.c
    clang/test/DebugInfo/KeyInstructions/init-static.cpp
    clang/test/DebugInfo/KeyInstructions/while.c

Removed: 
    


################################################################################
diff  --git a/clang/test/DebugInfo/KeyInstructions/agg.c 
b/clang/test/DebugInfo/KeyInstructions/agg.c
index 06c9ebbb63369..e9d9da7f687c6 100644
--- a/clang/test/DebugInfo/KeyInstructions/agg.c
+++ b/clang/test/DebugInfo/KeyInstructions/agg.c
@@ -1,7 +1,7 @@
-// RUN: %clang_cc1 -gkey-instructions -x c++ %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c++ %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
-// RUN: %clang_cc1 -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
 typedef struct { int a, b, c; } Struct;

diff  --git a/clang/test/DebugInfo/KeyInstructions/assign-scalar.c 
b/clang/test/DebugInfo/KeyInstructions/assign-scalar.c
index 98d005b2e925c..afb0ed8ebdfd7 100644
--- a/clang/test/DebugInfo/KeyInstructions/assign-scalar.c
+++ b/clang/test/DebugInfo/KeyInstructions/assign-scalar.c
@@ -1,7 +1,7 @@
-// RUN: %clang_cc1 -gkey-instructions -x c++ %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c++ %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
-// RUN: %clang_cc1 -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
 unsigned long long g, h, i;

diff  --git a/clang/test/DebugInfo/KeyInstructions/do.c 
b/clang/test/DebugInfo/KeyInstructions/do.c
index f3b2bb465cae8..4f0d388f94047 100644
--- a/clang/test/DebugInfo/KeyInstructions/do.c
+++ b/clang/test/DebugInfo/KeyInstructions/do.c
@@ -1,7 +1,7 @@
-// RUN: %clang_cc1 -gkey-instructions -x c++ -std=c++17 %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c++ 
-std=c++17 %s -debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
-// RUN: %clang_cc1 -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o -  \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o -  \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
 // Perennial question: should the `dec` be in its own source atom or not

diff  --git a/clang/test/DebugInfo/KeyInstructions/if.c 
b/clang/test/DebugInfo/KeyInstructions/if.c
index df7d10d6ee7b8..b16dec7b91c4f 100644
--- a/clang/test/DebugInfo/KeyInstructions/if.c
+++ b/clang/test/DebugInfo/KeyInstructions/if.c
@@ -1,7 +1,7 @@
-// RUN: %clang_cc1 -gkey-instructions -x c++ -std=c++17 %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c++ 
-std=c++17 %s -debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank --check-prefixes=CHECK,CHECK-CXX
 
-// RUN: %clang_cc1 -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
 int g;

diff  --git a/clang/test/DebugInfo/KeyInstructions/init-agg.c 
b/clang/test/DebugInfo/KeyInstructions/init-agg.c
index b4e36efbf37bb..1021490bd75b4 100644
--- a/clang/test/DebugInfo/KeyInstructions/init-agg.c
+++ b/clang/test/DebugInfo/KeyInstructions/init-agg.c
@@ -1,8 +1,7 @@
-
-// RUN: %clang_cc1 -x c++ -gkey-instructions %s 
-debug-info-kind=line-tables-only -gno-column-info -emit-llvm -o - 
-ftrivial-auto-var-init=pattern \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -x c++ -gkey-instructions %s 
-debug-info-kind=line-tables-only -gno-column-info -emit-llvm -o - 
-ftrivial-auto-var-init=pattern \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
-// RUN: %clang_cc1 -x c -gkey-instructions %s 
-debug-info-kind=line-tables-only -gno-column-info -emit-llvm -o - 
-ftrivial-auto-var-init=pattern \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -x c -gkey-instructions %s 
-debug-info-kind=line-tables-only -gno-column-info -emit-llvm -o - 
-ftrivial-auto-var-init=pattern \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
 // The implicit-check-not is important; we don't want the GEPs created for the
@@ -36,15 +35,15 @@ void a() {
 // CHECK: call void @llvm.memset{{.*}}%arr{{.*}}, !dbg [[G4R1:!.*]]
     char arr[] = { 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 
42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, };
 
-// CHECK: store i8 -86, ptr %uninit{{.*}}, !dbg [[G5R1:!.*]], !annotation
+// CHECK: store i8 {{.*}}, ptr %uninit{{.*}}, !dbg [[G5R1:!.*]], !annotation
     char uninit; // -ftrivial-auto-var-init=pattern
 }
 
 // CHECK: [[G1R1]] = !DILocation({{.*}}, atomGroup: 1, atomRank: 1)
 // CHECK: [[G2R1]] = !DILocation({{.*}}, atomGroup: 2, atomRank: 1)
-// CHECK: [[B_LINE]] = !DILocation(line: 23, scope: ![[#]])
+// CHECK: [[B_LINE]] = !DILocation(line: 22, scope: ![[#]])
 // CHECK: [[G2R2]] = !DILocation({{.*}}, atomGroup: 2, atomRank: 2)
 // CHECK: [[G3R1]] = !DILocation({{.*}}, atomGroup: 3, atomRank: 1)
-// CHECK: [[big_LINE]] = !DILocation(line: 34, scope: ![[#]])
+// CHECK: [[big_LINE]] = !DILocation(line: 33, scope: ![[#]])
 // CHECK: [[G4R1]] = !DILocation({{.*}}, atomGroup: 4, atomRank: 1)
 // CHECK: [[G5R1]] = !DILocation({{.*}}, atomGroup: 5, atomRank: 1)

diff  --git a/clang/test/DebugInfo/KeyInstructions/init-member.cpp 
b/clang/test/DebugInfo/KeyInstructions/init-member.cpp
index 5ccefd4064421..4d8e1b9dace3f 100644
--- a/clang/test/DebugInfo/KeyInstructions/init-member.cpp
+++ b/clang/test/DebugInfo/KeyInstructions/init-member.cpp
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -gkey-instructions %s -debug-info-kind=line-tables-only 
-emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s
 
 struct B {

diff  --git a/clang/test/DebugInfo/KeyInstructions/init-scalar.c 
b/clang/test/DebugInfo/KeyInstructions/init-scalar.c
index a86c029e47e8c..d4802a709b89a 100644
--- a/clang/test/DebugInfo/KeyInstructions/init-scalar.c
+++ b/clang/test/DebugInfo/KeyInstructions/init-scalar.c
@@ -1,7 +1,7 @@
-// RUN: %clang_cc1 -gkey-instructions -x c++ %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c++ %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
-// RUN: %clang_cc1 -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
 void a() {

diff  --git a/clang/test/DebugInfo/KeyInstructions/init-static.cpp 
b/clang/test/DebugInfo/KeyInstructions/init-static.cpp
index 7f12c6cbab274..2cac57e1d9fff 100644
--- a/clang/test/DebugInfo/KeyInstructions/init-static.cpp
+++ b/clang/test/DebugInfo/KeyInstructions/init-static.cpp
@@ -1,4 +1,4 @@
-// RUN: %clang_cc1 -gkey-instructions %s -debug-info-kind=line-tables-only 
-emit-llvm -o -\
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions %s 
-debug-info-kind=line-tables-only -emit-llvm -o -\
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
 // CHECK: [[b_addr:@.*]] = {{.*}}global ptr

diff  --git a/clang/test/DebugInfo/KeyInstructions/while.c 
b/clang/test/DebugInfo/KeyInstructions/while.c
index fc65abf5155d5..38cdb8433dd27 100644
--- a/clang/test/DebugInfo/KeyInstructions/while.c
+++ b/clang/test/DebugInfo/KeyInstructions/while.c
@@ -1,7 +1,7 @@
-// RUN: %clang_cc1 -gkey-instructions -x c++ -std=c++17 %s 
-debug-info-kind=line-tables-only -emit-llvm -o - \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c++ 
-std=c++17 %s -debug-info-kind=line-tables-only -emit-llvm -o - \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
-// RUN: %clang_cc1 -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o -  \
+// RUN: %clang_cc1 -triple x86_64-linux-gnu -gkey-instructions -x c %s 
-debug-info-kind=line-tables-only -emit-llvm -o -  \
 // RUN: | FileCheck %s --implicit-check-not atomGroup --implicit-check-not 
atomRank
 
 // Perennial question: should the `dec` be in its own source atom or not


        
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to