[llvm] 8e451cd - [RISCV] Convert test to opaque pointers (NFC)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 22 06:56:46 PST 2022
Author: Nikita Popov
Date: 2022-12-22T15:55:53+01:00
New Revision: 8e451cda388c3fb4c6417e815da29212eadcbe69
URL: https://github.com/llvm/llvm-project/commit/8e451cda388c3fb4c6417e815da29212eadcbe69
DIFF: https://github.com/llvm/llvm-project/commit/8e451cda388c3fb4c6417e815da29212eadcbe69.diff
LOG: [RISCV] Convert test to opaque pointers (NFC)
There is a minor change in operand order (of a commutative
instruction).
Added:
Modified:
llvm/test/CodeGen/RISCV/loop-strength-reduce-loop-invar.ll
Removed:
################################################################################
diff --git a/llvm/test/CodeGen/RISCV/loop-strength-reduce-loop-invar.ll b/llvm/test/CodeGen/RISCV/loop-strength-reduce-loop-invar.ll
index bc7b32d68856..6313845ba889 100644
--- a/llvm/test/CodeGen/RISCV/loop-strength-reduce-loop-invar.ll
+++ b/llvm/test/CodeGen/RISCV/loop-strength-reduce-loop-invar.ll
@@ -25,7 +25,7 @@
; }
; }
- at A = internal global [16 x [16 x i32]] zeroinitializer, align 32 ; <[16 x [16 x i32]]*> [#uses=2]
+ at A = internal global [16 x [16 x i32]] zeroinitializer, align 32 ; <ptr> [#uses=2]
define void @test(i32 signext %row, i32 signext %N.in) nounwind {
; RV32-LABEL: test:
@@ -35,7 +35,7 @@ define void @test(i32 signext %row, i32 signext %N.in) nounwind {
; RV32-NEXT: slli a0, a0, 6
; RV32-NEXT: lui a2, %hi(A)
; RV32-NEXT: addi a2, a2, %lo(A)
-; RV32-NEXT: add a0, a2, a0
+; RV32-NEXT: add a0, a0, a2
; RV32-NEXT: addi a0, a0, 8
; RV32-NEXT: li a2, 4
; RV32-NEXT: li a3, 5
@@ -57,7 +57,7 @@ define void @test(i32 signext %row, i32 signext %N.in) nounwind {
; RV64-NEXT: slli a0, a0, 6
; RV64-NEXT: lui a3, %hi(A)
; RV64-NEXT: addi a3, a3, %lo(A)
-; RV64-NEXT: add a0, a3, a0
+; RV64-NEXT: add a0, a0, a3
; RV64-NEXT: addi a3, a0, 4
; RV64-NEXT: li a4, 4
; RV64-NEXT: li a5, 5
@@ -81,11 +81,11 @@ entry:
cond_true:
%indvar = phi i32 [ 0, %entry ], [ %indvar.next, %cond_true ]
%tmp2 = add i32 %indvar, 1
- %tmp = getelementptr [16 x [16 x i32]], [16 x [16 x i32]]* @A, i32 0, i32 %row, i32 %tmp2
- store i32 4, i32* %tmp
+ %tmp = getelementptr [16 x [16 x i32]], ptr @A, i32 0, i32 %row, i32 %tmp2
+ store i32 4, ptr %tmp
%tmp5.upgrd.1 = add i32 %indvar, 2
- %tmp7 = getelementptr [16 x [16 x i32]], [16 x [16 x i32]]* @A, i32 0, i32 %row, i32 %tmp5.upgrd.1
- store i32 5, i32* %tmp7
+ %tmp7 = getelementptr [16 x [16 x i32]], ptr @A, i32 0, i32 %row, i32 %tmp5.upgrd.1
+ store i32 5, ptr %tmp7
%indvar.next = add i32 %indvar, 1
%exitcond = icmp eq i32 %indvar.next, %N
br i1 %exitcond, label %return, label %cond_true
More information about the llvm-commits
mailing list