Page MenuHomePhabricator

[X86] Teach DAG unfoldMemoryOperand to reconvert CMPs to tests
ClosedPublic

Authored by niravd on Feb 1 2018, 11:33 AM.

Details

Summary

Copy MI-level cmp->test conversion to SelectionDAG-level memory unfold.
This fixes a regression from D41293.

Diff Detail

Repository
rL LLVM

Event Timeline

niravd created this revision.Feb 1 2018, 11:33 AM
craig.topper added inline comments.Feb 2 2018, 9:25 AM
llvm/lib/Target/X86/X86InstrInfo.cpp
9237 ↗(On Diff #132438)

Any reason this can't be C->isNullValue()?

Or even just use isNullConstant to merge the first and second if.

niravd updated this revision to Diff 132848.Feb 5 2018, 9:19 AM

Address cleanup comments.

This revision is now accepted and ready to land.Feb 5 2018, 9:33 AM
This revision was automatically updated to reflect the committed changes.