This is an archive of the discontinued LLVM Phabricator instance.

[X86] Merge ADDSUB/SUBADD detection into single methods that can detect either and indicate what they found.
ClosedPublic

Authored by craig.topper on Mar 15 2018, 2:10 PM.

Details

Summary

Previously, we called the same functions twice with a bool flag determining whether we should look for ADDSUB or SUBADD. It would be more efficient to run the code once and detect either pattern with a flag to tell which type it found.

Diff Detail

Repository
rL LLVM

Event Timeline

craig.topper created this revision.Mar 15 2018, 2:10 PM
RKSimon accepted this revision.Mar 16 2018, 7:51 AM

LGTM with a couple of minors.

I haven't checked recently - is PR30633 finished now?

lib/Target/X86/X86ISelLowering.cpp
7600 ↗(On Diff #138620)

ADDSUB/SUBADD

7695 ↗(On Diff #138620)

What is better - splitting into 2 x 256-bit entries or BLEND(ADD.SUB) ?

This revision is now accepted and ready to land.Mar 16 2018, 7:51 AM
This revision was automatically updated to reflect the committed changes.