isl_map_simplify.c: uset_gist_full: check for redundant constraints in order
In particular, the constraints of the input are sorted in the caller
to favor constraints that do not involve existentially quantified
variables over those that do. However, when checking which constraint
is redundant with respect to the other constraints in the sense that
the negation results in a contradiction, the first constraint would
be checked first. This means that if two constraints are mutually
redundant, the first would end up getting removed.
Moreover, the shifted constraints are removed first and this
may result in some constraints changing position to fill up
the position of the removed constraints.
To avoid the reordering, do not remove the constraints immediately,
but mark them for removal first.
Additionally, consider the constraints from least favorable
to most favorable instead of the other way around.
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>