reimplement isl_map_partial_lexopt
authorSven Verdoolaege <skimo@kotnet.org>
Thu, 30 Dec 2010 14:02:30 +0000 (15:02 +0100)
committerSven Verdoolaege <skimo@kotnet.org>
Thu, 30 Dec 2010 14:15:41 +0000 (15:15 +0100)
commit843d3aa51424772422f78b3454a0fd3f855d437d
treeed86b78e10eef49facb0b443c44ca65a319d8ee2
parent4ccaa30b8d0c267077a6fd90b229785e643de937
reimplement isl_map_partial_lexopt

In case of a map that is a union of more than one basic map,
the old implementation would look for solutions of later basic
maps in those pieces of the domain where earlier basic maps
have no solutions.  This could lead to the domain being broken
up into many small pieces, sometimes dramatically so.
The new implementation tries to avoid some of this splintering
by computing solutions for each basic map separately and then
combining the results.

In the reported case, the map was actually single-valued, so
instead we could have also detected this special case and just
returned the input or we could have tried to make the parametric
integer programming integer return a more compact result,
but the new implementation is more general that the first option
and easier than the second option.

Reported-by: Tobias Grosser <grosser@fim.uni-passau.de>
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
isl_map.c