-
Notifications
You must be signed in to change notification settings - Fork 14
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
[AIE2P] Fix combine G_SHUFFLE_VEC to G_AIE_VSEL for <64xs8> #338
Conversation
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<64 x s8>) = COPY $x2 | ||
; CHECK-NEXT: [[DEF:%[0-9]+]]:_(<64 x s8>) = G_IMPLICIT_DEF | ||
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 5 | ||
; CHECK-NEXT: [[BITCAST:%[0-9]+]]:_(<2 x s32>) = G_BITCAST [[C]](s64) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we avoid this bitcast by changing the selection pattern to use i64
for the mask instead of v2i32
now that i64
has been made legal for eL
register class?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we make v64i1 legal for eL as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@khallouh good point! Done
; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<64 x s8>) = COPY $x2 | ||
; CHECK-NEXT: [[DEF:%[0-9]+]]:_(<64 x s8>) = G_IMPLICIT_DEF | ||
; CHECK-NEXT: [[C:%[0-9]+]]:_(s64) = G_CONSTANT i64 5 | ||
; CHECK-NEXT: [[BITCAST:%[0-9]+]]:_(<2 x s32>) = G_BITCAST [[C]](s64) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can't build it as a 2 x s32 literal? (I would hope 64 x s1, but let's do small steps. )
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good enough to me. Just a philosophical question.
f16f335
to
ca266a2
Compare
ca266a2
to
c4c135e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
The PR fixes the combine of
G_SHUFFLE_VEC
toG_AIE_VSEL
for<64xs8>
type because in this case during instruction selectionG_AIE_VSEL
is selected intoVSEL_8
with a2xs32
mask.