This is an archive of the discontinued LLVM Phabricator instance.

[AArch64][GlobalISel] Select arith extended add/sub in manual selection code
ClosedPublic

Authored by paquette on Nov 10 2020, 2:19 PM.

Details

Summary

The manual selection code for add/sub was not checking if it was possible to fold in shifts + extends (the *rx opcode variants).

As a result, we could never select things like

cmp x1, w0, uxtw #2

Because we don't import any patterns for compares.

This adds support for the arithmetic shifted register forms and updates tests for instructions selected using emitADD, emitADDS, and emitSUBS.

This is a 0.1% geomean code size improvement on SPECINT2000 at -Os.

Diff Detail

Event Timeline

paquette created this revision.Nov 10 2020, 2:19 PM
aemerson accepted this revision.Nov 10 2020, 10:26 PM
This revision is now accepted and ready to land.Nov 10 2020, 10:26 PM