This is an archive of the discontinued LLVM Phabricator instance.

GlobalISel: Implement fewerElementsVector for phi
ClosedPublic

Authored by arsenm on Feb 24 2019, 2:04 PM.

Diff Detail

Event Timeline

arsenm created this revision.Feb 24 2019, 2:04 PM
paquette added inline comments.Feb 25 2019, 9:01 AM
lib/CodeGen/GlobalISel/LegalizerHelper.cpp
37

Comment needs updating

2047

Can we have a comment explaining what this loop is doing for consistency with the other loop?

2048

Can we just reuse the definitions outside the loop and just use clear() to avoid calling the SmallVector constructor?

arsenm updated this revision to Diff 188242.Feb 25 2019, 12:34 PM
arsenm marked 3 inline comments as done.

Address comments

paquette accepted this revision.Feb 27 2019, 2:59 PM

LGTM aside from nits

lib/CodeGen/GlobalISel/LegalizerHelper.cpp
2032

Factor out NumParts + NumLeftover above the loop to avoid recompilation?

2050

Factor out MI.getNumOperands() above the loop to avoid recomputation?

2066

ditto above two comments

This revision is now accepted and ready to land.Feb 27 2019, 2:59 PM
arsenm closed this revision.Feb 27 2019, 4:15 PM
arsenm marked 3 inline comments as done.

r355048