isl_schedule.c: simplify computation of number of constraints
[platform/upstream/isl.git] / isl_band.c
index 1613621..53582f0 100644 (file)
@@ -10,6 +10,7 @@
 
 #include <isl_band_private.h>
 #include <isl_schedule_private.h>
+#include <isl_list_private.h>
 
 isl_ctx *isl_band_get_ctx(__isl_keep isl_band *band)
 {
@@ -69,7 +70,7 @@ __isl_give isl_band_list *isl_band_get_children(
        if (!band->children)
                isl_die(isl_band_get_ctx(band), isl_error_invalid,
                        "band has no children", return NULL);
-       return isl_band_list_copy(band->children);
+       return isl_band_list_dup(band->children);
 }
 
 int isl_band_n_member(__isl_keep isl_band *band)
@@ -139,7 +140,7 @@ __isl_give isl_union_map *isl_band_get_suffix_schedule(
                int i, n;
                isl_band_list *children;
 
-               suffix = isl_union_map_empty(isl_union_map_get_dim(band->map));
+               suffix = isl_union_map_empty(isl_union_map_get_space(band->map));
                children = isl_band_get_children(band);
                n = isl_band_list_n_band(children);
                for (i = 0; i < n; ++i) {
@@ -185,17 +186,3 @@ __isl_give isl_printer *isl_printer_print_band(__isl_take isl_printer *p,
 
        return p;
 }
-
-void isl_band_dump(__isl_keep isl_band *band)
-{
-       isl_printer *printer;
-
-       if (!band)
-               return;
-
-       printer = isl_printer_to_file(isl_band_get_ctx(band), stderr);
-       printer = isl_printer_print_band(printer, band);
-       printer = isl_printer_end_line(printer);
-
-       isl_printer_free(printer);
-}