This is an archive of the discontinued LLVM Phabricator instance.

GlobalISel: Add combines for extend operations
ClosedPublic

Authored by volkan on Aug 25 2020, 3:22 AM.

Details

Summary

Add various combines for G_ANYEXT, G_SEXT and G_ZEXT.

Diff Detail

Event Timeline

volkan created this revision.Aug 25 2020, 3:22 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 25 2020, 3:22 AM
volkan requested review of this revision.Aug 25 2020, 3:22 AM

Can you add some tests with vectors?

volkan updated this revision to Diff 288991.Aug 31 2020, 11:05 AM
  • Added vector tests.
arsenm added inline comments.Aug 31 2020, 12:44 PM
llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp
1759–1760

setInstrAndDebugLoc?

Why build a copy instead of CombinerHelper::replaceRegWith?

1811

setInstrAndDebugLoc?

volkan updated this revision to Diff 289015.Aug 31 2020, 1:18 PM
  • Use setInstrAndDebugLoc .
  • Use replaceRegWith to replace registers.
volkan marked 2 inline comments as done.Aug 31 2020, 1:19 PM
arsenm accepted this revision.Sep 1 2020, 6:07 AM
This revision is now accepted and ready to land.Sep 1 2020, 6:07 AM