This is an archive of the discontinued LLVM Phabricator instance.

[GlobalISel] Add matchers for constant splat.
ClosedPublic

Authored by abinavpp on Nov 26 2021, 3:24 AM.

Details

Summary

This change exposes isBuildVectorConstantSplat() to the llvm namespace
and uses it to implement the constant splat versions of
m_SpecificICst().

CombinerHelper::matchOrShiftToFunnelShift() can now work with vector
types and CombinerHelper::matchMulOBy2()'s match for a constant splat is
simplified.

Diff Detail

Event Timeline

abinavpp created this revision.Nov 26 2021, 3:24 AM
abinavpp requested review of this revision.Nov 26 2021, 3:24 AM
Herald added a project: Restricted Project. · View Herald TranscriptNov 26 2021, 3:24 AM
paquette accepted this revision.Nov 29 2021, 11:39 AM

This looks reasonable to me

This revision is now accepted and ready to land.Nov 29 2021, 11:39 AM
This revision was automatically updated to reflect the committed changes.