[lld] [LLD] Add CHECK-NEXT for cgprofile-obj.s tests (PR #121677)

Haohai Wen via llvm-commits llvm-commits at lists.llvm.org
Sat Jan 4 18:54:18 PST 2025


https://github.com/HaohaiWen created https://github.com/llvm/llvm-project/pull/121677

None

>From ec126b3bd808209d0c8ab313edef48de82722c72 Mon Sep 17 00:00:00 2001
From: Haohai Wen <haohai.wen at intel.com>
Date: Sun, 5 Jan 2025 10:51:30 +0800
Subject: [PATCH] [LLD] Add CHECK-NEXT for cgprofile-obj.s tests

---
 lld/test/COFF/cgprofile-obj.s | 31 +++++++++++++++++--------------
 lld/test/ELF/cgprofile-obj.s  | 31 +++++++++++++++++--------------
 2 files changed, 34 insertions(+), 28 deletions(-)

diff --git a/lld/test/COFF/cgprofile-obj.s b/lld/test/COFF/cgprofile-obj.s
index 756279a8b5759a..c16aa2e198dfbd 100644
--- a/lld/test/COFF/cgprofile-obj.s
+++ b/lld/test/COFF/cgprofile-obj.s
@@ -36,17 +36,20 @@ Aa:
     .cg_profile B, C, 30
     .cg_profile C, D, 90
 
-# CG-OBJ: 140001000 T A
-# CG-OBJ: 140001001 T B
-# CG-OBJ: 140001002 T C
-# CG-OBJ: 140001003 t D
-
-# NO-CG: 140001000 t D
-# NO-CG: 140001001 T C
-# NO-CG: 140001002 T B
-# NO-CG: 140001003 T A
-
-# CG-OBJ-OF: 140001000 t D
-# CG-OBJ-OF: 140001001 T A
-# CG-OBJ-OF: 140001004 T C
-# CG-OBJ-OF: 140001005 T B
\ No newline at end of file
+# CG-OBJ:      140001000 T A
+# CG-OBJ-NEXT: 140001000 t Aa
+# CG-OBJ-NEXT: 140001001 T B
+# CG-OBJ-NEXT: 140001002 T C
+# CG-OBJ-NEXT: 140001003 t D
+
+# NO-CG:      140001000 t D
+# NO-CG-NEXT: 140001001 T C
+# NO-CG-NEXT: 140001002 T B
+# NO-CG-NEXT: 140001003 T A
+# NO-CG-NEXT: 140001003 t Aa
+
+# CG-OBJ-OF:      140001000 t D
+# CG-OBJ-OF-NEXT: 140001001 T A
+# CG-OBJ-OF-NEXT: 140001001 t Aa
+# CG-OBJ-OF-NEXT: 140001004 T C
+# CG-OBJ-OF-NEXT: 140001005 T B
diff --git a/lld/test/ELF/cgprofile-obj.s b/lld/test/ELF/cgprofile-obj.s
index 14016658707af4..358dcd9fadaa1b 100644
--- a/lld/test/ELF/cgprofile-obj.s
+++ b/lld/test/ELF/cgprofile-obj.s
@@ -39,17 +39,20 @@ Aa:
     .cg_profile B, C, 30
     .cg_profile C, D, 90
 
-# CG-OBJ: 0000000000201123 t D
-# CG-OBJ: 0000000000201122 T C
-# CG-OBJ: 0000000000201121 T B
-# CG-OBJ: 0000000000201120 T A
-
-# NO-CG: 0000000000201120 t D
-# NO-CG: 0000000000201121 T C
-# NO-CG: 0000000000201122 T B
-# NO-CG: 0000000000201123 T A
-
-# CG-OBJ-OF: 0000000000201120 t D
-# CG-OBJ-OF: 0000000000201124 T C
-# CG-OBJ-OF: 0000000000201125 T B
-# CG-OBJ-OF: 0000000000201121 T A
+# CG-OBJ:      0000000000201123 t D
+# CG-OBJ-NEXT: 0000000000201120 t Aa
+# CG-OBJ-NEXT: 0000000000201122 T C
+# CG-OBJ-NEXT: 0000000000201121 T B
+# CG-OBJ-NEXT: 0000000000201120 T A
+
+# NO-CG:      0000000000201120 t D
+# NO-CG-NEXT: 0000000000201123 t Aa
+# NO-CG-NEXT: 0000000000201121 T C
+# NO-CG-NEXT: 0000000000201122 T B
+# NO-CG-NEXT: 0000000000201123 T A
+
+# CG-OBJ-OF:      0000000000201120 t D
+# CG-OBJ-OF-NEXT: 0000000000201121 t Aa
+# CG-OBJ-OF-NEXT: 0000000000201124 T C
+# CG-OBJ-OF-NEXT: 0000000000201125 T B
+# CG-OBJ-OF-NEXT: 0000000000201121 T A



More information about the llvm-commits mailing list