This is an archive of the discontinued LLVM Phabricator instance.

[DAG][AArch64] Limit preferIncOfAddToSubOfNot until after legalization if the node has wrap flags
ClosedPublic

Authored by dmgreen on Apr 20 2023, 8:41 AM.

Details

Summary

If the add node has wrap flags then they will be destroyed by converting to sub/not. The flags can be useful in converting to rhadd, for example, but that can happen late if the node types need to be legalized. This limits the preferIncOfAddToSubOfNot fold until after legalize DAG if the node have flags to allow more folding.

Diff Detail

Event Timeline

dmgreen created this revision.Apr 20 2023, 8:41 AM
dmgreen requested review of this revision.Apr 20 2023, 8:41 AM
Herald added a project: Restricted Project. · View Herald TranscriptApr 20 2023, 8:41 AM
This revision is now accepted and ready to land.Apr 20 2023, 8:56 AM
This revision was landed with ongoing or failed builds.Apr 21 2023, 10:36 AM
This revision was automatically updated to reflect the committed changes.