[llvm] Aarch64 align zcz zcm tests to be strict (PR #200645)

Tomer Shafir via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 3 02:43:34 PDT 2026


https://github.com/tomershafir updated https://github.com/llvm/llvm-project/pull/200645

>From c2ac03167c64635853c8f851a74370b975fd1a69 Mon Sep 17 00:00:00 2001
From: tomershafir <tomer.shafir8 at gmail.com>
Date: Sun, 31 May 2026 11:39:05 +0300
Subject: [PATCH] [AArch64] Align ZCM/ZCZ test strictness(NFC)

---
 .../AArch64/arm64-zero-cycle-regmove-fpr.ll   | 10 ++---
 .../AArch64/arm64-zero-cycle-regmove-fpr8.mir | 10 ++---
 .../AArch64/arm64-zero-cycle-regmove-gpr.ll   | 10 ++---
 .../AArch64/arm64-zero-cycle-zeroing-gpr.ll   | 42 +++++++++----------
 4 files changed, 36 insertions(+), 36 deletions(-)

diff --git a/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-fpr.ll b/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-fpr.ll
index 8980457b8c9e7..ef5ad5029c1b6 100644
--- a/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-fpr.ll
+++ b/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-fpr.ll
@@ -1,8 +1,8 @@
-; RUN: llc < %s -mtriple=arm64-linux-gnu | FileCheck %s -check-prefixes=CHECK,NOZCM-FPR128-CPU --match-full-lines
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=generic | FileCheck %s -check-prefixes=CHECK,NOZCM-FPR128-CPU --match-full-lines
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 | FileCheck %s -check-prefixes=CHECK,ZCM-FPR128-CPU --match-full-lines
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 -mattr=-zcm-fpr128 | FileCheck %s -check-prefixes=CHECK,NOZCM-FPR128-ATTR --match-full-lines
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mattr=+zcm-fpr128 | FileCheck %s -check-prefixes=CHECK,ZCM-FPR128-ATTR --match-full-lines
+; RUN: llc < %s -mtriple=arm64-linux-gnu | FileCheck %s --match-full-lines -check-prefixes=CHECK,NOZCM-FPR128-CPU
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=generic | FileCheck %s --match-full-lines -check-prefixes=CHECK,NOZCM-FPR128-CPU
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 | FileCheck %s --match-full-lines -check-prefixes=CHECK,ZCM-FPR128-CPU
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 -mattr=-zcm-fpr128 | FileCheck %s --match-full-lines -check-prefixes=CHECK,NOZCM-FPR128-ATTR
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mattr=+zcm-fpr128 | FileCheck %s --match-full-lines -check-prefixes=CHECK,ZCM-FPR128-ATTR
 
 define void @zero_cycle_regmove_FPR64(double %a, double %b, double %c, double %d) {
 entry:
diff --git a/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-fpr8.mir b/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-fpr8.mir
index f8ebc26f5e0ae..22917a89d928a 100644
--- a/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-fpr8.mir
+++ b/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-fpr8.mir
@@ -1,8 +1,8 @@
-# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-linux-gnu %s | FileCheck %s -check-prefixes=ALL,NOZCM-FPR128-CPU --match-full-lines
-# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-apple-macosx -mcpu=generic %s | FileCheck %s -check-prefixes=ALL,NOZCM-FPR128-CPU --match-full-lines
-# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-apple-macosx -mcpu=apple-m1 %s | FileCheck %s -check-prefixes=ALL,ZCM-FPR128-CPU --match-full-lines
-# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-apple-macosx -mcpu=apple-m1 -mattr=-zcm-fpr128 %s | FileCheck %s -check-prefixes=ALL,NOZCM-FPR128-ATTR --match-full-lines
-# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-apple-macosx -mattr=+zcm-fpr128 %s | FileCheck %s -check-prefixes=ALL,ZCM-FPR128-ATTR --match-full-lines
+# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-linux-gnu %s | FileCheck %s --match-full-lines -check-prefixes=ALL,NOZCM-FPR128-CPU
+# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-apple-macosx -mcpu=generic %s | FileCheck %s --match-full-lines -check-prefixes=ALL,NOZCM-FPR128-CPU
+# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-apple-macosx -mcpu=apple-m1 %s | FileCheck %s --match-full-lines -check-prefixes=ALL,ZCM-FPR128-CPU
+# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-apple-macosx -mcpu=apple-m1 -mattr=-zcm-fpr128 %s | FileCheck %s --match-full-lines -check-prefixes=ALL,NOZCM-FPR128-ATTR
+# RUN: llc -o - -run-pass=postrapseudos -mtriple=arm64-apple-macosx -mattr=+zcm-fpr128 %s | FileCheck %s --match-full-lines -check-prefixes=ALL,ZCM-FPR128-ATTR
 
 ---
 name: zero_cycle_regmove_FPR8
diff --git a/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-gpr.ll b/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-gpr.ll
index f3a99cb7e83b3..354a89c16b124 100644
--- a/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-gpr.ll
+++ b/llvm/test/CodeGen/AArch64/arm64-zero-cycle-regmove-gpr.ll
@@ -1,8 +1,8 @@
-; RUN: llc < %s -mtriple=arm64-linux-gnu | FileCheck %s -check-prefixes=ALL,NOTCPU-LINUX 
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=generic | FileCheck %s -check-prefixes=ALL,NOTCPU-APPLE 
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 | FileCheck %s -check-prefixes=ALL,CPU 
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 -mattr=-zcm-gpr64 | FileCheck %s -check-prefixes=ALL,NOTATTR 
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mattr=+zcm-gpr64 | FileCheck %s -check-prefixes=ALL,ATTR 
+; RUN: llc < %s -mtriple=arm64-linux-gnu | FileCheck %s --match-full-lines -check-prefixes=ALL,NOTCPU-LINUX
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=generic | FileCheck %s --match-full-lines -check-prefixes=ALL,NOTCPU-APPLE
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 | FileCheck %s --match-full-lines -check-prefixes=ALL,CPU
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 -mattr=-zcm-gpr64 | FileCheck %s --match-full-lines -check-prefixes=ALL,NOTATTR
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mattr=+zcm-gpr64 | FileCheck %s --match-full-lines -check-prefixes=ALL,ATTR
 
 define void @zero_cycle_regmove_GPR32(i32 %a, i32 %b, i32 %c, i32 %d) {
 entry:
diff --git a/llvm/test/CodeGen/AArch64/arm64-zero-cycle-zeroing-gpr.ll b/llvm/test/CodeGen/AArch64/arm64-zero-cycle-zeroing-gpr.ll
index 0f284aa9ad282..abfd79e092395 100644
--- a/llvm/test/CodeGen/AArch64/arm64-zero-cycle-zeroing-gpr.ll
+++ b/llvm/test/CodeGen/AArch64/arm64-zero-cycle-zeroing-gpr.ll
@@ -1,44 +1,44 @@
-; RUN: llc < %s -mtriple=aarch64-linux-gnu | FileCheck %s -check-prefixes=ALL,NOZCZ-GPR32-NOZCZ-GPR64
-; RUN: llc < %s -mtriple=aarch64-linux-gnu -mattr=+zcz-gpr32 | FileCheck %s -check-prefixes=ALL,ZCZ-GPR32
-; RUN: llc < %s -mtriple=aarch64-linux-gnu -mattr=+zcz-gpr64 | FileCheck %s -check-prefixes=ALL,NOZCZ-GPR32-ZCZ-GPR64
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=generic | FileCheck %s -check-prefixes=ALL,NOZCZ-GPR32-NOZCZ-GPR64
-; RUN: llc < %s -mtriple=arm64-apple-ios -mcpu=cyclone | FileCheck %s -check-prefixes=ALL,ZCZ-GPR32,ZCZ-GPR64
-; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 | FileCheck %s -check-prefixes=ALL,ZCZ-GPR32,ZCZ-GPR64
-; RUN: llc < %s -mtriple=aarch64-linux-gnu -mcpu=exynos-m3 | FileCheck %s -check-prefixes=ALL,NOZCZ-GPR32-NOZCZ-GPR64
-; RUN: llc < %s -mtriple=aarch64-linux-gnu -mcpu=kryo | FileCheck %s -check-prefixes=ALL,ZCZ-GPR32,ZCZ-GPR64
-; RUN: llc < %s -mtriple=aarch64-linux-gnu -mcpu=falkor | FileCheck %s -check-prefixes=ALL,ZCZ-GPR32,ZCZ-GPR64
+; RUN: llc < %s -mtriple=aarch64-linux-gnu | FileCheck %s --match-full-lines -check-prefixes=ALL,NOZCZ-GPR32-NOZCZ-GPR64
+; RUN: llc < %s -mtriple=aarch64-linux-gnu -mattr=+zcz-gpr32 | FileCheck %s --match-full-lines -check-prefixes=ALL,ZCZ-GPR32
+; RUN: llc < %s -mtriple=aarch64-linux-gnu -mattr=+zcz-gpr64 | FileCheck %s --match-full-lines -check-prefixes=ALL,NOZCZ-GPR32-ZCZ-GPR64
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=generic | FileCheck %s --match-full-lines -check-prefixes=ALL,NOZCZ-GPR32-NOZCZ-GPR64
+; RUN: llc < %s -mtriple=arm64-apple-ios -mcpu=cyclone | FileCheck %s --match-full-lines -check-prefixes=ALL,ZCZ-GPR32,ZCZ-GPR64
+; RUN: llc < %s -mtriple=arm64-apple-macosx -mcpu=apple-m1 | FileCheck %s --match-full-lines -check-prefixes=ALL,ZCZ-GPR32,ZCZ-GPR64
+; RUN: llc < %s -mtriple=aarch64-linux-gnu -mcpu=exynos-m3 | FileCheck %s --match-full-lines -check-prefixes=ALL,NOZCZ-GPR32-NOZCZ-GPR64
+; RUN: llc < %s -mtriple=aarch64-linux-gnu -mcpu=kryo | FileCheck %s --match-full-lines -check-prefixes=ALL,ZCZ-GPR32,ZCZ-GPR64
+; RUN: llc < %s -mtriple=aarch64-linux-gnu -mcpu=falkor | FileCheck %s --match-full-lines -check-prefixes=ALL,ZCZ-GPR32,ZCZ-GPR64
 
 define i8 @ti8() {
 entry:
-; ALL-LABEL: ti8:
+; ALL-LABEL: {{_?}}ti8:{{ *}}{{(;|//)}}{{ *}}@ti8
 ; NOZCZ-GPR32-NOZCZ-GPR64: mov w0, wzr
-; ZCZ-GPR32: mov w0, #0
-; NOZCZ-GPR32-ZCZ-GPR64: mov x0, #0
+; ZCZ-GPR32: mov w0, #0{{ *}}{{(;|//)}}{{ *}}=0x0
+; NOZCZ-GPR32-ZCZ-GPR64: mov x0, #0{{ *}}{{(;|//)}}{{ *}}=0x0
   ret i8 0
 }
 
 define i16 @ti16() {
 entry:
-; ALL-LABEL: ti16:
+; ALL-LABEL: {{_?}}ti16:{{ *}}{{(;|//)}}{{ *}}@ti16
 ; NOZCZ-GPR32-NOZCZ-GPR64: mov w0, wzr
-; ZCZ-GPR32: mov w0, #0
-; NOZCZ-GPR32-ZCZ-GPR64: mov x0, #0
+; ZCZ-GPR32: mov w0, #0{{ *}}{{(;|//)}}{{ *}}=0x0
+; NOZCZ-GPR32-ZCZ-GPR64: mov x0, #0{{ *}}{{(;|//)}}{{ *}}=0x0
   ret i16 0
 }
 
 define i32 @ti32() {
 entry:
-; ALL-LABEL: ti32:
+; ALL-LABEL: {{_?}}ti32:{{ *}}{{(;|//)}}{{ *}}@ti32
 ; NOZCZ-GPR32-NOZCZ-GPR64: mov w0, wzr
-; ZCZ-GPR32: mov w0, #0
-; NOZCZ-GPR32-ZCZ-GPR64: mov x0, #0
+; ZCZ-GPR32: mov w0, #0{{ *}}{{(;|//)}}{{ *}}=0x0
+; NOZCZ-GPR32-ZCZ-GPR64: mov x0, #0{{ *}}{{(;|//)}}{{ *}}=0x0
   ret i32 0
 }
 
 define i64 @ti64() {
 entry:
-; ALL-LABEL: ti64:
-; NOZCZ-GPR32-NOZCZ-GPR64 mov x0, xzr
-; ZCZ-GPR64: mov x0, #0
+; ALL-LABEL: {{_?}}ti64:{{ *}}{{(;|//)}}{{ *}}@ti64
+; NOZCZ-GPR32-NOZCZ-GPR64: mov x0, xzr
+; ZCZ-GPR64: mov x0, #0{{ *}}{{(;|//)}}{{ *}}=0x0
   ret i64 0
 }



More information about the llvm-commits mailing list