[SCEV] Always sort AddRecExprs from different loops by dominance
authorMax Kazantsev <max.kazantsev@azul.com>
Wed, 17 May 2017 04:09:14 +0000 (04:09 +0000)
committerMax Kazantsev <max.kazantsev@azul.com>
Wed, 17 May 2017 04:09:14 +0000 (04:09 +0000)
commit4c7f293d24c7126ef4dfa1c3fe52d76c44105ff7
tree15be1234fda879f4766350287ff38ec5dbc4fb24
parentb67d344850908bb2a98181c4cd4dc0a8fccf5be5
[SCEV] Always sort AddRecExprs from different loops by dominance

Sorting of AddRecExprs by loop nesting does not make sense since we only invoke
the CompareSCEVComplexity for AddRecExprs that are used by one SCEV. This
guarantees that there is always a dominance relationship between them. This
patch removes the sorting by nesting which is a dead code in current usage of
this function.

Reviewed By: sanjoy

Differential Revision: https://reviews.llvm.org/D33228

llvm-svn: 303235
llvm/lib/Analysis/ScalarEvolution.cpp