This is an archive of the discontinued LLVM Phabricator instance.

[X86] Enable 8-bit OR with disjoint bits to convert to LEA
ClosedPublic

Authored by craig.topper on Mar 1 2019, 6:33 PM.

Details

Summary

We already support 8-bits adds in convertToThreeAddress. But we can also support 8-bit OR if the bits are disjoint. We already do this for 16/32/64.

Diff Detail

Repository
rL LLVM

Event Timeline

craig.topper created this revision.Mar 1 2019, 6:33 PM
RKSimon added inline comments.Mar 3 2019, 4:11 AM
lib/Target/X86/X86InstrInfo.h
596 ↗(On Diff #189020)

Is16BitOp?

craig.topper retitled this revision from [X86] Enable 8-bit OR with disjoint bits to conver to LEA to [X86] Enable 8-bit OR with disjoint bits to convert to LEA.Mar 3 2019, 12:12 PM

Fix bad argument name in header. I flipped the polarity part way through making the patch and failed to change this.

Herald added a project: Restricted Project. · View Herald TranscriptMar 3 2019, 12:23 PM
RKSimon accepted this revision.Mar 5 2019, 5:34 AM

LGTM

This revision is now accepted and ready to land.Mar 5 2019, 5:34 AM
This revision was automatically updated to reflect the committed changes.