X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=basis_reduction_templ.c;h=46fd91128bd9af4f430f8bacdac81ca29f55f285;hb=5d157c90e755f6acc8b214acb5344e052136568f;hp=375549d14aa9ab17b8d214ea356f498303c5eef3;hpb=8ea7e34cd4772c8be223e65799dfb5f56cdaff48;p=platform%2Fupstream%2Fisl.git diff --git a/basis_reduction_templ.c b/basis_reduction_templ.c index 375549d..46fd911 100644 --- a/basis_reduction_templ.c +++ b/basis_reduction_templ.c @@ -11,6 +11,9 @@ */ #include +#include +#include +#include #include "isl_basis_reduction.h" static void save_alpha(GBR_LP *lp, int first, int n, GBR_type *alpha) @@ -22,7 +25,7 @@ static void save_alpha(GBR_LP *lp, int first, int n, GBR_type *alpha) } /* Compute a reduced basis for the set represented by the tableau "tab". - * tab->basis, must be initialized by the calling function to an affine + * tab->basis, which must be initialized by the calling function to an affine * unimodular basis, is updated to reflect the reduced basis. * The first tab->n_zero rows of the basis (ignoring the constant row) * are assumed to correspond to equalities and are left untouched. @@ -326,7 +329,7 @@ struct isl_mat *isl_basic_set_reduced_basis(struct isl_basic_set *bset) isl_die(bset->ctx, isl_error_invalid, "no parameters allowed", return NULL); - tab = isl_tab_from_basic_set(bset); + tab = isl_tab_from_basic_set(bset, 0); if (!tab) return NULL; @@ -335,7 +338,7 @@ struct isl_mat *isl_basic_set_reduced_basis(struct isl_basic_set *bset) else { isl_mat *eq; unsigned nvar = isl_basic_set_total_dim(bset); - eq = isl_mat_sub_alloc(bset->ctx, bset->eq, 0, bset->n_eq, + eq = isl_mat_sub_alloc6(bset->ctx, bset->eq, 0, bset->n_eq, 1, nvar); eq = isl_mat_left_hermite(eq, 0, NULL, &tab->basis); tab->basis = isl_mat_lin_to_aff(tab->basis);