-
Notifications
You must be signed in to change notification settings - Fork 14.3k
[NVPTX] Optimize v2x16 BUILD_VECTORs to PRMT #116675
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1046,8 +1046,8 @@ define <2 x bfloat> @fma_bf16x2_expanded_no_nans_multiple_uses_of_fma(<2 x bfloa | |
; CHECK-SM70-LABEL: fma_bf16x2_expanded_no_nans_multiple_uses_of_fma( | ||
; CHECK-SM70: { | ||
; CHECK-SM70-NEXT: .reg .pred %p<9>; | ||
; CHECK-SM70-NEXT: .reg .b16 %rs<25>; | ||
; CHECK-SM70-NEXT: .reg .b32 %r<61>; | ||
; CHECK-SM70-NEXT: .reg .b16 %rs<21>; | ||
; CHECK-SM70-NEXT: .reg .b32 %r<62>; | ||
; CHECK-SM70-NEXT: .reg .f32 %f<19>; | ||
; CHECK-SM70-EMPTY: | ||
; CHECK-SM70-NEXT: // %bb.0: | ||
|
@@ -1130,7 +1130,6 @@ define <2 x bfloat> @fma_bf16x2_expanded_no_nans_multiple_uses_of_fma(<2 x bfloa | |
; CHECK-SM70-NEXT: setp.nan.f32 %p7, %f15, %f15; | ||
; CHECK-SM70-NEXT: or.b32 %r49, %r45, 4194304; | ||
; CHECK-SM70-NEXT: selp.b32 %r50, %r49, %r48, %p7; | ||
; CHECK-SM70-NEXT: { .reg .b16 tmp; mov.b32 {tmp, %rs20}, %r50; } | ||
; CHECK-SM70-NEXT: cvt.u32.u16 %r51, %rs17; | ||
; CHECK-SM70-NEXT: shl.b32 %r52, %r51, 16; | ||
; CHECK-SM70-NEXT: mov.b32 %f16, %r52; | ||
|
@@ -1144,8 +1143,7 @@ define <2 x bfloat> @fma_bf16x2_expanded_no_nans_multiple_uses_of_fma(<2 x bfloa | |
; CHECK-SM70-NEXT: setp.nan.f32 %p8, %f18, %f18; | ||
; CHECK-SM70-NEXT: or.b32 %r58, %r54, 4194304; | ||
; CHECK-SM70-NEXT: selp.b32 %r59, %r58, %r57, %p8; | ||
; CHECK-SM70-NEXT: { .reg .b16 tmp; mov.b32 {tmp, %rs23}, %r59; } | ||
; CHECK-SM70-NEXT: mov.b32 %r60, {%rs23, %rs20}; | ||
Comment on lines
-1147
to
-1148
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Are we now able to delete the code that generates this? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think so because it's still used for There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Those should be partially converted to |
||
; CHECK-SM70-NEXT: prmt.b32 %r60, %r59, %r50, 0x7632U; | ||
; CHECK-SM70-NEXT: st.param.b32 [func_retval0], %r60; | ||
; CHECK-SM70-NEXT: ret; | ||
%1 = fmul <2 x bfloat> %a, %b | ||
|
@@ -1185,8 +1183,8 @@ define <2 x bfloat> @fma_bf16x2_expanded_maxnum_no_nans(<2 x bfloat> %a, <2 x bf | |
; CHECK-SM70-LABEL: fma_bf16x2_expanded_maxnum_no_nans( | ||
; CHECK-SM70: { | ||
; CHECK-SM70-NEXT: .reg .pred %p<5>; | ||
; CHECK-SM70-NEXT: .reg .b16 %rs<17>; | ||
; CHECK-SM70-NEXT: .reg .b32 %r<43>; | ||
; CHECK-SM70-NEXT: .reg .b16 %rs<13>; | ||
; CHECK-SM70-NEXT: .reg .b32 %r<44>; | ||
; CHECK-SM70-NEXT: .reg .f32 %f<13>; | ||
; CHECK-SM70-EMPTY: | ||
; CHECK-SM70-NEXT: // %bb.0: | ||
|
@@ -1240,7 +1238,6 @@ define <2 x bfloat> @fma_bf16x2_expanded_maxnum_no_nans(<2 x bfloat> %a, <2 x bf | |
; CHECK-SM70-NEXT: setp.nan.f32 %p3, %f10, %f10; | ||
; CHECK-SM70-NEXT: or.b32 %r33, %r29, 4194304; | ||
; CHECK-SM70-NEXT: selp.b32 %r34, %r33, %r32, %p3; | ||
; CHECK-SM70-NEXT: { .reg .b16 tmp; mov.b32 {tmp, %rs13}, %r34; } | ||
; CHECK-SM70-NEXT: and.b32 %r35, %r15, -65536; | ||
; CHECK-SM70-NEXT: mov.b32 %f11, %r35; | ||
; CHECK-SM70-NEXT: max.f32 %f12, %f11, 0f00000000; | ||
|
@@ -1251,8 +1248,7 @@ define <2 x bfloat> @fma_bf16x2_expanded_maxnum_no_nans(<2 x bfloat> %a, <2 x bf | |
; CHECK-SM70-NEXT: setp.nan.f32 %p4, %f12, %f12; | ||
; CHECK-SM70-NEXT: or.b32 %r40, %r36, 4194304; | ||
; CHECK-SM70-NEXT: selp.b32 %r41, %r40, %r39, %p4; | ||
; CHECK-SM70-NEXT: { .reg .b16 tmp; mov.b32 {tmp, %rs15}, %r41; } | ||
; CHECK-SM70-NEXT: mov.b32 %r42, {%rs15, %rs13}; | ||
; CHECK-SM70-NEXT: prmt.b32 %r42, %r41, %r34, 0x7632U; | ||
; CHECK-SM70-NEXT: st.param.b32 [func_retval0], %r42; | ||
; CHECK-SM70-NEXT: ret; | ||
%1 = fmul <2 x bfloat> %a, %b | ||
|
Uh oh!
There was an error while loading. Please reload this page.