From 2528191d36ed4f02a70b310543d822e852af7b84 Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Tue, 4 May 2010 08:26:05 +0200 Subject: [PATCH] iscc: add lexicographic operators --- doc/isl.tex | 40 ++++++++++++++++++++++++++++++++++++++++ iscc.c | 24 ++++++++++++++++++++++++ 2 files changed, 64 insertions(+) diff --git a/doc/isl.tex b/doc/isl.tex index 39f9311..d32c5a2 100644 --- a/doc/isl.tex +++ b/doc/isl.tex @@ -345,4 +345,44 @@ $b$ := $s_1$ \ai[\tt]{>} $s_2$ & is $s_1$ a proper superset of $s_2$? \\ $b$ := $m_1$ \ai[\tt]{>} $m_2$ & is $m_1$ a proper superset of $m_2$? \\ +$m$ := $s_1$ \ai[\tt]{<<} $s_2$ & a map from +$s_1$ to $s_2$ of those elements that live in the same space and +such that the elements of $s_1$ are lexicographically strictly smaller +than those of $s_2$. +\\ +$m_3$ := $m_1$ \ai[\tt]{<<} $m_2$ & a map from the domain of +$m_1$ to the domain of $m_2$ of those elements such that their images +live in the same space and such that the images of the elements of +$m_1$ are lexicographically strictly smaller than those of $m_2$. +\\ +$m$ := $s_1$ \ai[\tt]{<<=} $s_2$ & a map from +$s_1$ to $s_2$ of those elements that live in the same space and +such that the elements of $s_1$ are lexicographically smaller +than those of $s_2$. +\\ +$m_3$ := $m_1$ \ai[\tt]{<<=} $m_2$ & a map from the domain of +$m_1$ to the domain of $m_2$ of those elements such that their images +live in the same space and such that the images of the elements of +$m_1$ are lexicographically smaller than those of $m_2$. +\\ +$m$ := $s_1$ \ai[\tt]{>>} $s_2$ & a map from +$s_1$ to $s_2$ of those elements that live in the same space and +such that the elements of $s_1$ are lexicographically strictly greater +than those of $s_2$. +\\ +$m_3$ := $m_1$ \ai[\tt]{>>} $m_2$ & a map from the domain of +$m_1$ to the domain of $m_2$ of those elements such that their images +live in the same space and such that the images of the elements of +$m_1$ are lexicographically strictly greater than those of $m_2$. +\\ +$m$ := $s_1$ \ai[\tt]{>>=} $s_2$ & a map from +$s_1$ to $s_2$ of those elements that live in the same space and +such that the elements of $s_1$ are lexicographically greater +than those of $s_2$. +\\ +$m_3$ := $m_1$ \ai[\tt]{>>=} $m_2$ & a map from the domain of +$m_1$ to the domain of $m_2$ of those elements such that their images +live in the same space and such that the images of the elements of +$m_1$ are lexicographically greater than those of $m_2$. +\\ \end{supertabular} diff --git a/iscc.c b/iscc.c index 6fd09cc..d675ca1 100644 --- a/iscc.c +++ b/iscc.c @@ -335,6 +335,30 @@ struct isc_bin_op bin_ops[] = { isl_obj_bool, (isc_bin_op_fn) &union_set_is_strict_superset }, { ISL_TOKEN_GT, isl_obj_union_map, isl_obj_union_map, isl_obj_bool, (isc_bin_op_fn) &union_map_is_strict_superset }, + { ISL_TOKEN_LEX_LE, isl_obj_union_set, isl_obj_union_set, + isl_obj_union_map, + (isc_bin_op_fn) &isl_union_set_lex_le_union_set }, + { ISL_TOKEN_LEX_LT, isl_obj_union_set, isl_obj_union_set, + isl_obj_union_map, + (isc_bin_op_fn) &isl_union_set_lex_lt_union_set }, + { ISL_TOKEN_LEX_GE, isl_obj_union_set, isl_obj_union_set, + isl_obj_union_map, + (isc_bin_op_fn) &isl_union_set_lex_ge_union_set }, + { ISL_TOKEN_LEX_GT, isl_obj_union_set, isl_obj_union_set, + isl_obj_union_map, + (isc_bin_op_fn) &isl_union_set_lex_gt_union_set }, + { ISL_TOKEN_LEX_LE, isl_obj_union_map, isl_obj_union_map, + isl_obj_union_map, + (isc_bin_op_fn) &isl_union_map_lex_le_union_map }, + { ISL_TOKEN_LEX_LT, isl_obj_union_map, isl_obj_union_map, + isl_obj_union_map, + (isc_bin_op_fn) &isl_union_map_lex_lt_union_map }, + { ISL_TOKEN_LEX_GE, isl_obj_union_map, isl_obj_union_map, + isl_obj_union_map, + (isc_bin_op_fn) &isl_union_map_lex_ge_union_map }, + { ISL_TOKEN_LEX_GT, isl_obj_union_map, isl_obj_union_map, + isl_obj_union_map, + (isc_bin_op_fn) &isl_union_map_lex_gt_union_map }, { '.', isl_obj_union_pw_qpolynomial_fold, isl_obj_union_pw_qpolynomial_fold, isl_obj_union_pw_qpolynomial_fold, -- 2.11.4.GIT