#include <isl_ctx.h>
#include <isl_blk.h>
#include <isl_dim.h>
+#include <isl_vec.h>
#if defined(__cplusplus)
extern "C" {
* n_out is the number of out variables
* n_in + n_out should be equal to set.dim
*/
-struct isl_vec;
struct isl_dim;
struct isl_basic_map {
int ref;
struct isl_blk block;
};
+typedef struct isl_vec isl_vec;
struct isl_vec *isl_vec_alloc(struct isl_ctx *ctx, unsigned size);
struct isl_vec *isl_vec_copy(struct isl_vec *vec);
if (isl_basic_set_is_empty(bset))
return bset;
- sample = isl_basic_set_sample(isl_basic_set_copy(bset));
+ sample = isl_basic_set_sample_vec(isl_basic_set_copy(bset));
if (!sample)
goto error;
if (sample->size == 0) {
isl_basic_set_free(unit_box);
- return isl_basic_set_sample(isl_basic_set_copy(bset));
+ return isl_basic_set_sample_vec(isl_basic_set_copy(bset));
}
/* Restrict "bset" to those points with values for f in the interval [l, u].
isl_int_add(tmp, tmp, l);
}
slice = add_bounds(isl_basic_set_copy(bset), f, l, tmp);
- sample = isl_basic_set_sample(slice);
+ sample = isl_basic_set_sample_vec(slice);
if (!sample) {
isl_vec_free(sol);
sol = NULL;
bset = isl_basic_map_underlying_set(isl_basic_map_copy(bmap));
if (!bset)
return -1;
- sample = isl_basic_set_sample(bset);
+ sample = isl_basic_set_sample_vec(bset);
if (!sample)
return -1;
empty = sample->size == 0;
bset->sample = NULL;
if (bset->n_eq > 0)
- return sample_eq(bset, isl_basic_set_sample);
+ return sample_eq(bset, isl_basic_set_sample_vec);
if (dim == 0)
return zero_sample(bset);
if (dim == 1)
return NULL;
}
-struct isl_vec *isl_basic_set_sample(struct isl_basic_set *bset)
+__isl_give isl_vec *isl_basic_set_sample_vec(__isl_take isl_basic_set *bset)
{
return basic_set_sample(bset, 0);
}
extern "C" {
#endif
-struct isl_vec *isl_basic_set_sample(struct isl_basic_set *bset);
+__isl_give isl_vec *isl_basic_set_sample_vec(__isl_take isl_basic_set *bset);
struct isl_vec *isl_basic_set_sample_bounded(struct isl_basic_set *bset);
#if defined(__cplusplus)
struct isl_vec *sample;
bset = isl_basic_set_read_from_file(ctx, stdin, 0, ISL_FORMAT_POLYLIB);
- sample = isl_basic_set_sample(isl_basic_set_copy(bset));
+ sample = isl_basic_set_sample_vec(isl_basic_set_copy(bset));
isl_vec_dump(sample, stdout, 0);
assert(sample);
if (sample->size > 0)