[llvm] 29c7d1a - [PPC] [NFC] add testcase for more store forwarding
Chen Zheng via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 3 01:46:50 PDT 2024
Author: Chen Zheng
Date: 2024-04-03T04:46:29-04:00
New Revision: 29c7d1a60c9d45e82f08cd7487178846ed5f9c6d
URL: https://github.com/llvm/llvm-project/commit/29c7d1a60c9d45e82f08cd7487178846ed5f9c6d
DIFF: https://github.com/llvm/llvm-project/commit/29c7d1a60c9d45e82f08cd7487178846ed5f9c6d.diff
LOG: [PPC] [NFC] add testcase for more store forwarding
Added:
Modified:
llvm/test/CodeGen/PowerPC/legalize-vaarg.ll
Removed:
################################################################################
diff --git a/llvm/test/CodeGen/PowerPC/legalize-vaarg.ll b/llvm/test/CodeGen/PowerPC/legalize-vaarg.ll
index b7f8b8af2472aa..8980049969da43 100644
--- a/llvm/test/CodeGen/PowerPC/legalize-vaarg.ll
+++ b/llvm/test/CodeGen/PowerPC/legalize-vaarg.ll
@@ -1,6 +1,7 @@
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
;RUN: llc < %s --mtriple=powerpc64-unknown-linux-gnu -mattr=+altivec | FileCheck %s -check-prefix=BE
;RUN: llc < %s --mtriple=powerpc64le-unknown-linux-gnu -mattr=+altivec | FileCheck %s -check-prefix=LE
+;RUN: llc < %s --mtriple=powerpc64-unknown-linux-gnu -mattr=+altivec -ppc-gather-alias-max-depth=0 | FileCheck %s -check-prefix=FORWARD
define <8 x i32> @test_large_vec_vaarg(i32 %n, ...) {
; BE-LABEL: test_large_vec_vaarg:
@@ -35,6 +36,22 @@ define <8 x i32> @test_large_vec_vaarg(i32 %n, ...) {
; LE-NEXT: lxvd2x 0, 0, 3
; LE-NEXT: xxswapd 35, 0
; LE-NEXT: blr
+;
+; FORWARD-LABEL: test_large_vec_vaarg:
+; FORWARD: # %bb.0:
+; FORWARD-NEXT: ld 3, -8(1)
+; FORWARD-NEXT: addi 3, 3, 15
+; FORWARD-NEXT: rldicr 3, 3, 0, 59
+; FORWARD-NEXT: addi 4, 3, 16
+; FORWARD-NEXT: std 4, -8(1)
+; FORWARD-NEXT: ld 4, -8(1)
+; FORWARD-NEXT: lvx 2, 0, 3
+; FORWARD-NEXT: addi 4, 4, 15
+; FORWARD-NEXT: rldicr 3, 4, 0, 59
+; FORWARD-NEXT: addi 4, 3, 16
+; FORWARD-NEXT: std 4, -8(1)
+; FORWARD-NEXT: lvx 3, 0, 3
+; FORWARD-NEXT: blr
%args = alloca ptr, align 4
%x = va_arg ptr %args, <8 x i32>
ret <8 x i32> %x
More information about the llvm-commits
mailing list