isl_tab_min_at_most_neg_one: be consistent about returning to nonnegative sample
commit19814cbb905ab1203cb3c13f57f249f6c0736aeb
authorSven Verdoolaege <skimo@kotnet.org>
Sat, 4 Oct 2014 09:42:31 +0000 (4 11:42 +0200)
committerSven Verdoolaege <skimo@kotnet.org>
Thu, 25 Dec 2014 09:52:45 +0000 (25 10:52 +0100)
tree18e4282e1d05aaf9fd622cd2925ec1e69edab072
parentf23cbc7e682fd7965f47e3dcafe69e1e2a6eafa2
isl_tab_min_at_most_neg_one: be consistent about returning to nonnegative sample

We should only assume that the initial sample value is non-negative and
try to restore a non-negative sample value if the variable is marked
as being non-negative.
This appears to have been the intention when this function was introduced
in 3fe110a (add internal representation of LP tableaus, Wed Mar 4 18:12:30
2009 +0100) since it would only return to a non-negative sample value
if var->is_nonneg.  We missed one case where 1 is returned, however, and
when we fixed this case in 61f2899 (isl_tab_min_at_most_neg_one: restore
sample value of non-redundant constraints, Fri Apr 2 22:59:43 2010 +0200),
we appear to have forgotten to check for var->is_nonneg.

Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
isl_tab.c