HomePhabricator

[SCEV][NFC] Check NoWrap flags before lexicographical comparison of SCEVs

Authored by mkazantsev on Dec 6 2017, 4:44 AM.

Description

[SCEV][NFC] Check NoWrap flags before lexicographical comparison of SCEVs

Lexicographical comparison of SCEV trees is potentially expensive for big
expression trees. We can define ordering between them for AddRecs and
N-ary operations by SCEV NoWrap flags to make non-equality check
cheaper.

This change does not prevent grouping eqivalent SCEVs together and is
not supposed to have any meaningful impact on behavior of any transforms.

Reviewed By: sanjoy
Differential Revision: https://reviews.llvm.org/D40645

llvm-svn: 319889

Details