This is an archive of the discontinued LLVM Phabricator instance.

[SystemZ] Fix addcarry of addcarry of const carry (PR42606)
ClosedPublic

Authored by nikic on Jul 12 2019, 12:16 PM.

Details

Summary

This fixes https://bugs.llvm.org/show_bug.cgi?id=42606 by extending D64213. Instead of only checking if the carry comes from a matching operation, we now check the full chain of carries. Otherwise we might custom lower the outermost addcarry, but then generically legalize an inner addcarry.

This feels a bit hacky...

Diff Detail

Repository
rL LLVM

Event Timeline

nikic created this revision.Jul 12 2019, 12:16 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 12 2019, 12:16 PM
uweigand accepted this revision.Jul 12 2019, 12:27 PM

I agree it's a bit hacky, but I don't see any better solution either. In any case, the change is not wrong -- everything rejected should be rejected. Given that this fixes a real problem, I'm fine with the patch. LGTM.

This revision is now accepted and ready to land.Jul 12 2019, 12:27 PM
This revision was automatically updated to reflect the committed changes.