This is an archive of the discontinued LLVM Phabricator instance.

[DAGCombiner] Don't reduce BUILD_VECTOR to BITCAST before LegalizeTypes if VT is legal.
ClosedPublic

Authored by Jim on Jul 30 2023, 11:08 PM.

Details

Summary

Targets may lose some optimization opportunities for certain vector operation
if we reduce BUILD_VECTOR to BITCAST early.

And if VT is not legal, reduce BUILD_VECTOR to BITCAST before LegailizeTypes
can get benefit. Because type-legalizer often scalarizes illegal type of vectors.

Diff Detail

Event Timeline

Jim created this revision.Jul 30 2023, 11:08 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 30 2023, 11:08 PM
Jim requested review of this revision.Jul 30 2023, 11:08 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 30 2023, 11:08 PM
Jim edited the summary of this revision. (Show Details)
Jim updated this revision to Diff 548885.Aug 9 2023, 11:46 PM

Rebase

Jim edited the summary of this revision. (Show Details)Aug 13 2023, 8:03 PM

kindly ping.

Jim updated this revision to Diff 551425.Aug 18 2023, 1:28 AM

Rebase

sebastian-ne accepted this revision.Aug 18 2023, 2:20 AM

Thanks, LGTM.
Sorry for the late reply, I was on vacation.

This revision is now accepted and ready to land.Aug 18 2023, 2:20 AM
Jim added a comment.Aug 18 2023, 9:46 PM

Thanks, LGTM.
Sorry for the late reply, I was on vacation.

Thanks for reply.

This revision was landed with ongoing or failed builds.Aug 18 2023, 9:54 PM
This revision was automatically updated to reflect the committed changes.