[llvm] f09e3ad - [AMDGPU] Update checks in mad_u64_u32.ll. NFC.
Jay Foad via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 21 02:45:19 PDT 2022
Author: Jay Foad
Date: 2022-09-21T10:42:55+01:00
New Revision: f09e3ad88a194fb2e8e47e056262b4bc1403df6b
URL: https://github.com/llvm/llvm-project/commit/f09e3ad88a194fb2e8e47e056262b4bc1403df6b
DIFF: https://github.com/llvm/llvm-project/commit/f09e3ad88a194fb2e8e47e056262b4bc1403df6b.diff
LOG: [AMDGPU] Update checks in mad_u64_u32.ll. NFC.
Added:
Modified:
llvm/test/CodeGen/AMDGPU/mad_u64_u32.ll
Removed:
################################################################################
diff --git a/llvm/test/CodeGen/AMDGPU/mad_u64_u32.ll b/llvm/test/CodeGen/AMDGPU/mad_u64_u32.ll
index 998f01db0983..d7ef6a1fb634 100644
--- a/llvm/test/CodeGen/AMDGPU/mad_u64_u32.ll
+++ b/llvm/test/CodeGen/AMDGPU/mad_u64_u32.ll
@@ -15,6 +15,13 @@ define amdgpu_ps float @mad_i32_vvv(i32 %a, i32 %b, i32 %c) {
; GFX10: ; %bb.0:
; GFX10-NEXT: v_mad_u64_u32 v[0:1], null, v0, v1, v[2:3]
; GFX10-NEXT: ; return to shader part epilog
+;
+; GFX11-LABEL: mad_i32_vvv:
+; GFX11: ; %bb.0:
+; GFX11-NEXT: v_mov_b32_e32 v3, v1
+; GFX11-NEXT: v_mov_b32_e32 v4, v0
+; GFX11-NEXT: v_mad_u64_u32 v[0:1], null, v4, v3, v[2:3]
+; GFX11-NEXT: ; return to shader part epilog
%mul = mul i32 %a, %b
%add = add i32 %mul, %c
%cast = bitcast i32 %add to float
@@ -44,6 +51,13 @@ define amdgpu_ps float @mad_i32_vvc(i32 %a, i32 %b) {
; GFX10: ; %bb.0:
; GFX10-NEXT: v_mad_u64_u32 v[0:1], null, v0, v1, 42
; GFX10-NEXT: ; return to shader part epilog
+;
+; GFX11-LABEL: mad_i32_vvc:
+; GFX11: ; %bb.0:
+; GFX11-NEXT: v_mov_b32_e32 v2, v1
+; GFX11-NEXT: v_mov_b32_e32 v3, v0
+; GFX11-NEXT: v_mad_u64_u32 v[0:1], null, v3, v2, 42
+; GFX11-NEXT: ; return to shader part epilog
%mul = mul i32 %a, %b
%add = add i32 %mul, 42
%cast = bitcast i32 %add to float
@@ -62,6 +76,13 @@ define amdgpu_ps float @mad_i32_vvi(i32 %a, i32 %b) {
; GFX10: ; %bb.0:
; GFX10-NEXT: v_mad_u64_u32 v[0:1], null, v0, v1, 0x12d687
; GFX10-NEXT: ; return to shader part epilog
+;
+; GFX11-LABEL: mad_i32_vvi:
+; GFX11: ; %bb.0:
+; GFX11-NEXT: v_mov_b32_e32 v2, v1
+; GFX11-NEXT: v_mov_b32_e32 v3, v0
+; GFX11-NEXT: v_mad_u64_u32 v[0:1], null, v3, v2, 0x12d687
+; GFX11-NEXT: ; return to shader part epilog
%mul = mul i32 %a, %b
%add = add i32 %mul, 1234567
%cast = bitcast i32 %add to float
@@ -147,6 +168,13 @@ define amdgpu_ps float @mad_i32_vvs(i32 %a, i32 %b, i32 inreg %c) {
; GFX10: ; %bb.0:
; GFX10-NEXT: v_mad_u64_u32 v[0:1], null, v0, v1, s[0:1]
; GFX10-NEXT: ; return to shader part epilog
+;
+; GFX11-LABEL: mad_i32_vvs:
+; GFX11: ; %bb.0:
+; GFX11-NEXT: v_mov_b32_e32 v2, v1
+; GFX11-NEXT: v_mov_b32_e32 v3, v0
+; GFX11-NEXT: v_mad_u64_u32 v[0:1], null, v3, v2, s[0:1]
+; GFX11-NEXT: ; return to shader part epilog
%mul = mul i32 %a, %b
%add = add i32 %mul, %c
%cast = bitcast i32 %add to float
More information about the llvm-commits
mailing list