#include "isl_map_private.h"
#include "isl_seq.h"
#include "isl_tab.h"
+#include <isl_dim_private.h>
+#include <isl_mat_private.h>
static void swap_equality(struct isl_basic_map *bmap, int a, int b)
{
isl_assert(bset->ctx, first + n <= bset->dim->n_out, goto error);
- if (n == 0)
+ if (n == 0 && !isl_dim_get_tuple_name(bset->dim, isl_dim_set))
return bset;
bset = isl_basic_set_cow(bset);
isl_assert(set->ctx, first + n <= set->dim->n_out, goto error);
- if (n == 0)
+ if (n == 0 && !isl_dim_get_tuple_name(set->dim, isl_dim_set))
return set;
set = isl_set_cow(set);
if (!set)
dim = isl_basic_map_dim(bmap, type);
isl_assert(bmap->ctx, first + n <= dim, goto error);
- if (n == 0)
+ if (n == 0 && !isl_dim_get_tuple_name(bmap->dim, type))
return bmap;
bmap = isl_basic_map_cow(bmap);
isl_assert(map->ctx, first + n <= isl_map_dim(map, type), goto error);
- if (n == 0)
+ if (n == 0 && !isl_dim_get_tuple_name(map->dim, type))
return map;
map = isl_map_cow(map);
if (!map)
if (progress)
*progress = 1;
isl_seq_elim(bmap->eq[k], eq, 1+pos, 1+total, NULL);
+ isl_seq_normalize(bmap->ctx, bmap->eq[k], 1 + total);
}
for (k = 0; k < bmap->n_ineq; ++k) {
if (progress)
*progress = 1;
isl_seq_elim(bmap->ineq[k], eq, 1+pos, 1+total, NULL);
+ isl_seq_normalize(bmap->ctx, bmap->ineq[k], 1 + total);
ISL_F_CLR(bmap, ISL_BASIC_MAP_NORMALIZED);
}
if (!bmap || !context)
goto error;
- if (isl_basic_map_is_universe(context)) {
- isl_basic_map_free(context);
- return bmap;
- }
if (isl_basic_map_is_universe(bmap)) {
isl_basic_map_free(context);
return bmap;
if (!map || !context)
goto error;;
- if (isl_basic_map_is_universe(context)) {
- isl_basic_map_free(context);
- return map;
- }
if (isl_basic_map_fast_is_empty(context)) {
struct isl_dim *dim = isl_dim_copy(map->dim);
isl_basic_map_free(context);