Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
Note that the elements of a newly created matrix may have arbitrary values.
The elements can be changed and inspected using the following functions.
+ isl_ctx *isl_mat_get_ctx(__isl_keep isl_mat *mat);
int isl_mat_rows(__isl_keep isl_mat *mat);
int isl_mat_cols(__isl_keep isl_mat *mat);
int isl_mat_get_element(__isl_keep isl_mat *mat,
struct isl_mat;
typedef struct isl_mat isl_mat;
+isl_ctx *isl_mat_get_ctx(__isl_keep isl_mat *mat);
+
__isl_give isl_mat *isl_mat_alloc(struct isl_ctx *ctx,
unsigned n_row, unsigned n_col);
struct isl_mat *isl_mat_dup(struct isl_mat *mat);
#include "isl_map_private.h"
#include <isl_dim_private.h>
+isl_ctx *isl_mat_get_ctx(__isl_keep isl_mat *mat)
+{
+ return mat ? mat->ctx : NULL;
+}
+
struct isl_mat *isl_mat_alloc(struct isl_ctx *ctx,
unsigned n_row, unsigned n_col)
{