add isl_map_{lexmin,lexmax}_pw_multi_aff
[platform/upstream/isl.git] / doc / user.pod
index e82e294..46e5a4c 100644 (file)
@@ -565,8 +565,23 @@ corresponding C<isl_id> is alive.
 
 =head2 Spaces
 
-Whenever a new set or relation is created from scratch,
+Whenever a new set, relation or similiar object is created from scratch,
 the space in which it lives needs to be specified using an C<isl_space>.
+Each space involves zero or more parameters and zero, one or two
+tuples of set or input/output dimensions.  The parameters and dimensions
+are identified by an C<isl_dim_type> and a position.
+The type C<isl_dim_param> refers to parameters,
+the type C<isl_dim_set> refers to set dimensions (for spaces
+with a single tuple of dimensions) and the types C<isl_dim_in>
+and C<isl_dim_out> refer to input and output dimensions
+(for spaces with two tuples of dimensions).
+Local spaces (see L</"Local Spaces">) also contain dimensions
+of type C<isl_dim_div>.
+Note that parameters are only identified by their position within
+a given object.  Across different objects, parameters are (usually)
+identified by their names or identifiers.  Only unnamed parameters
+are identified by their positions across objects.  The use of unnamed
+parameters is discouraged.
 
        #include <isl/space.h>
        __isl_give isl_space *isl_space_alloc(isl_ctx *ctx,
@@ -658,6 +673,8 @@ of the original object.
                __isl_keep isl_pw_aff *pwaff);
        __isl_give isl_space *isl_pw_aff_get_space(
                __isl_keep isl_pw_aff *pwaff);
+       __isl_give isl_space *isl_multi_aff_get_domain_space(
+               __isl_keep isl_multi_aff *maff);
        __isl_give isl_space *isl_multi_aff_get_space(
                __isl_keep isl_multi_aff *maff);
        __isl_give isl_space *isl_pw_multi_aff_get_domain_space(
@@ -731,6 +748,8 @@ using the following functions.
        __isl_give isl_space *isl_space_set_tuple_name(
                __isl_take isl_space *space,
                enum isl_dim_type type, const char *s);
+       int isl_space_has_tuple_name(__isl_keep isl_space *space,
+               enum isl_dim_type type);
        const char *isl_space_get_tuple_name(__isl_keep isl_space *space,
                enum isl_dim_type type);
 
@@ -789,6 +808,8 @@ using the following functions.
                __isl_take isl_space *domain,
                __isl_take isl_space *range);
        __isl_give isl_space *isl_space_zip(__isl_take isl_space *space);
+       __isl_give isl_space *isl_space_curry(
+               __isl_take isl_space *space);
 
 Note that if dimensions are added or removed from a space, then
 the name and the internal structure are lost.
@@ -797,9 +818,13 @@ the name and the internal structure are lost.
 
 A local space is essentially a space with
 zero or more existentially quantified variables.
-The local space of a basic set or relation can be obtained
+The local space of a (constraint of a) basic set or relation can be obtained
 using the following functions.
 
+       #include <isl/constraint.h>
+       __isl_give isl_local_space *isl_constraint_get_local_space(
+               __isl_keep isl_constraint *constraint);
+
        #include <isl/set.h>
        __isl_give isl_local_space *isl_basic_set_get_local_space(
                __isl_keep isl_basic_set *bset);
@@ -822,6 +847,15 @@ They can be inspected, modified, copied and freed using the following functions.
        int isl_local_space_is_set(__isl_keep isl_local_space *ls);
        int isl_local_space_dim(__isl_keep isl_local_space *ls,
                enum isl_dim_type type);
+       int isl_local_space_has_dim_id(
+               __isl_keep isl_local_space *ls,
+               enum isl_dim_type type, unsigned pos);
+       __isl_give isl_id *isl_local_space_get_dim_id(
+               __isl_keep isl_local_space *ls,
+               enum isl_dim_type type, unsigned pos);
+       int isl_local_space_has_dim_name(
+               __isl_keep isl_local_space *ls,
+               enum isl_dim_type type, unsigned pos)
        const char *isl_local_space_get_dim_name(
                __isl_keep isl_local_space *ls,
                enum isl_dim_type type, unsigned pos);
@@ -974,6 +1008,13 @@ be created.
        __isl_give char *isl_printer_get_str(
                __isl_keep isl_printer *printer);
 
+The printer can be inspected using the following functions.
+
+       FILE *isl_printer_get_file(
+               __isl_keep isl_printer *printer);
+       int isl_printer_get_output_format(
+               __isl_keep isl_printer *p);
+
 The behavior of the printer can be modified in various ways
 
        __isl_give isl_printer *isl_printer_set_output_format(
@@ -1002,6 +1043,10 @@ by the specified amount (which may be negative).
 
 To actually print something, use
 
+       #include <isl/printer.h>
+       __isl_give isl_printer *isl_printer_print_double(
+               __isl_take isl_printer *p, double d);
+
        #include <isl/set.h>
        __isl_give isl_printer *isl_printer_print_basic_set(
                __isl_take isl_printer *printer,
@@ -1141,10 +1186,14 @@ using the following functions.
 Sets and relations can be converted to union sets and relations
 using the following functions.
 
-       __isl_give isl_union_map *isl_union_map_from_map(
-               __isl_take isl_map *map);
+       __isl_give isl_union_set *isl_union_set_from_basic_set(
+               __isl_take isl_basic_set *bset);
+       __isl_give isl_union_map *isl_union_map_from_basic_map(
+               __isl_take isl_basic_map *bmap);
        __isl_give isl_union_set *isl_union_set_from_set(
                __isl_take isl_set *set);
+       __isl_give isl_union_map *isl_union_map_from_map(
+               __isl_take isl_map *map);
 
 The inverse conversions below can only be used if the input
 union set or relation is known to contain elements in exactly one
@@ -1175,7 +1224,7 @@ functions.
        __isl_give isl_union_map *isl_union_map_copy(
                __isl_keep isl_union_map *umap);
        void isl_basic_set_free(__isl_take isl_basic_set *bset);
-       void isl_set_free(__isl_take isl_set *set);
+       void *isl_set_free(__isl_take isl_set *set);
        void *isl_union_set_free(__isl_take isl_union_set *uset);
        void isl_basic_map_free(__isl_take isl_basic_map *bmap);
        void isl_map_free(__isl_take isl_map *map);
@@ -1278,14 +1327,16 @@ C<isl_dim_set> and C<isl_dim_div> for sets and
 of C<isl_dim_cst>, C<isl_dim_param>,
 C<isl_dim_in>, C<isl_dim_out> and C<isl_dim_div> for relations.
 
-A (basic) set or relation can also be constructed from a (piecewise)
-(multiple) affine expression
+A (basic or union) set or relation can also be constructed from a
+(union) (piecewise) (multiple) affine expression
 or a list of affine expressions
 (See L<"Piecewise Quasi Affine Expressions"> and
 L<"Piecewise Multiple Quasi Affine Expressions">).
 
        __isl_give isl_basic_map *isl_basic_map_from_aff(
                __isl_take isl_aff *aff);
+       __isl_give isl_map *isl_map_from_aff(
+               __isl_take isl_aff *aff);
        __isl_give isl_set *isl_set_from_pw_aff(
                __isl_take isl_pw_aff *pwaff);
        __isl_give isl_map *isl_map_from_pw_aff(
@@ -1301,6 +1352,9 @@ L<"Piecewise Multiple Quasi Affine Expressions">).
                __isl_take isl_pw_multi_aff *pma);
        __isl_give isl_map *isl_map_from_pw_multi_aff(
                __isl_take isl_pw_multi_aff *pma);
+       __isl_give isl_union_map *
+       isl_union_map_from_union_pw_multi_aff(
+               __isl_take isl_union_pw_multi_aff *upma);
 
 The C<domain_dim> argument describes the domain of the resulting
 basic relation.  It is required because the C<list> may consist
@@ -1352,6 +1406,27 @@ using the following functions, which compute an overapproximation.
        __isl_give isl_map *isl_map_remove_divs(
                __isl_take isl_map *map);
 
+It is also possible to only remove those divs that are defined
+in terms of a given range of dimensions or only those for which
+no explicit representation is known.
+
+       __isl_give isl_basic_set *
+       isl_basic_set_remove_divs_involving_dims(
+               __isl_take isl_basic_set *bset,
+               enum isl_dim_type type,
+               unsigned first, unsigned n);
+       __isl_give isl_set *isl_set_remove_divs_involving_dims(
+               __isl_take isl_set *set, enum isl_dim_type type,
+               unsigned first, unsigned n);
+       __isl_give isl_map *isl_map_remove_divs_involving_dims(
+               __isl_take isl_map *map, enum isl_dim_type type,
+               unsigned first, unsigned n);
+
+       __isl_give isl_set *isl_set_remove_unknown_divs(
+               __isl_take isl_set *set);
+       __isl_give isl_map *isl_map_remove_unknown_divs(
+               __isl_take isl_map *map);
+
 To iterate over all the sets or maps in a union set or map, use
 
        int isl_union_set_foreach_set(__isl_keep isl_union_set *uset,
@@ -1408,6 +1483,12 @@ To iterate over the constraints of a basic set or map, use
 
        #include <isl/constraint.h>
 
+       int isl_basic_set_n_constraint(
+               __isl_keep isl_basic_set *bset);
+       int isl_basic_set_foreach_constraint(
+               __isl_keep isl_basic_set *bset,
+               int (*fn)(__isl_take isl_constraint *c, void *user),
+               void *user);
        int isl_basic_map_foreach_constraint(
                __isl_keep isl_basic_map *bmap,
                int (*fn)(__isl_take isl_constraint *c, void *user),
@@ -1427,6 +1508,12 @@ represents an equality.  If not, it represents an inequality.
 The coefficients of the constraints can be inspected using
 the following functions.
 
+       int isl_constraint_is_lower_bound(
+               __isl_keep isl_constraint *constraint,
+               enum isl_dim_type type, unsigned pos);
+       int isl_constraint_is_upper_bound(
+               __isl_keep isl_constraint *constraint,
+               enum isl_dim_type type, unsigned pos);
        void isl_constraint_get_constant(
                __isl_keep isl_constraint *constraint, isl_int *v);
        void isl_constraint_get_coefficient(
@@ -1535,6 +1622,7 @@ or relation can be read off or set using the following functions.
                __isl_keep isl_basic_set *bset);
        __isl_give isl_basic_set *isl_basic_set_set_tuple_name(
                __isl_take isl_basic_set *set, const char *s);
+       int isl_set_has_tuple_name(__isl_keep isl_set *set);
        const char *isl_set_get_tuple_name(
                __isl_keep isl_set *set);
        const char *isl_basic_map_get_tuple_name(
@@ -1552,6 +1640,9 @@ an internal data structure.
 The identifiers, positions or names of individual dimensions can be
 read off using the following functions.
 
+       __isl_give isl_id *isl_basic_set_get_dim_id(
+               __isl_keep isl_basic_set *bset,
+               enum isl_dim_type type, unsigned pos);
        __isl_give isl_set *isl_set_set_dim_id(
                __isl_take isl_set *set, enum isl_dim_type type,
                unsigned pos, __isl_take isl_id *id);
@@ -1595,6 +1686,8 @@ read off using the following functions.
        const char *isl_basic_map_get_dim_name(
                __isl_keep isl_basic_map *bmap,
                enum isl_dim_type type, unsigned pos);
+       int isl_map_has_dim_name(__isl_keep isl_map *map,
+               enum isl_dim_type type, unsigned pos);
        const char *isl_map_get_dim_name(
                __isl_keep isl_map *map,
                enum isl_dim_type type, unsigned pos);
@@ -1636,6 +1729,8 @@ is already known to be empty.
 
 =item * Single-valuedness
 
+       int isl_basic_map_is_single_valued(
+               __isl_keep isl_basic_map *bmap);
        int isl_map_plain_is_single_valued(
                __isl_keep isl_map *map);
        int isl_map_is_single_valued(__isl_keep isl_map *map);
@@ -1698,6 +1793,14 @@ Check whether the product of domain and range of the given relation
 can be computed,
 i.e., whether both domain and range are nested relations.
 
+=item * Currying
+
+       int isl_basic_map_can_curry(
+               __isl_keep isl_basic_map *bmap);
+       int isl_map_can_curry(__isl_keep isl_map *map);
+
+Check whether the domain of the (basic) relation is a wrapped relation.
+
 =back
 
 =head3 Binary Properties
@@ -1764,6 +1867,9 @@ i.e., whether both domain and range are nested relations.
                __isl_keep isl_union_map *umap1,
                __isl_keep isl_union_map *umap2);
 
+Check whether the first argument is a (strict) subset of the
+second argument.
+
 =back
 
 =head2 Unary Operations
@@ -1835,6 +1941,10 @@ that maps (a wrapped version of) the input relation to its domain or range.
 
 =item * Elimination
 
+       __isl_give isl_basic_set *isl_basic_set_eliminate(
+               __isl_take isl_basic_set *bset,
+               enum isl_dim_type type,
+               unsigned first, unsigned n);
        __isl_give isl_set *isl_set_eliminate(
                __isl_take isl_set *set, enum isl_dim_type type,
                unsigned first, unsigned n);
@@ -1902,6 +2012,10 @@ dimension has a value bounded by the fixed given value.
        __isl_give isl_set *isl_set_equate(__isl_take isl_set *set,
                enum isl_dim_type type1, int pos1,
                enum isl_dim_type type2, int pos2);
+       __isl_give isl_basic_map *isl_basic_map_equate(
+               __isl_take isl_basic_map *bmap,
+               enum isl_dim_type type1, int pos1,
+               enum isl_dim_type type2, int pos2);
        __isl_give isl_map *isl_map_equate(__isl_take isl_map *map,
                enum isl_dim_type type1, int pos1,
                enum isl_dim_type type2, int pos2);
@@ -1916,6 +2030,16 @@ dimensions are equal to each other.
 Intersect the relation with the hyperplane where the given
 dimensions have opposite values.
 
+       __isl_give isl_map *isl_map_order_lt(__isl_take isl_map *map,
+               enum isl_dim_type type1, int pos1,
+               enum isl_dim_type type2, int pos2);
+       __isl_give isl_map *isl_map_order_gt(__isl_take isl_map *map,
+               enum isl_dim_type type1, int pos1,
+               enum isl_dim_type type2, int pos2);
+
+Intersect the relation with the half-space where the given
+dimensions satisfy the given ordering.
+
 =item * Identity
 
        __isl_give isl_map *isl_set_identity(
@@ -2266,11 +2390,31 @@ can be constructed using the following function.
 Given a relation with nested relations for domain and range,
 interchange the range of the domain with the domain of the range.
 
+=item * Currying
+
+       __isl_give isl_basic_map *isl_basic_map_curry(
+               __isl_take isl_basic_map *bmap);
+       __isl_give isl_map *isl_map_curry(
+               __isl_take isl_map *map);
+       __isl_give isl_union_map *isl_union_map_curry(
+               __isl_take isl_union_map *umap);
+
+Given a relation with a nested relation for domain,
+move the range of the nested relation out of the domain
+and use it as the domain of a nested relation in the range,
+with the original range as range of this nested relation.
+
 =item * Aligning parameters
 
+       __isl_give isl_basic_set *isl_basic_set_align_params(
+               __isl_take isl_basic_set *bset,
+               __isl_take isl_space *model);
        __isl_give isl_set *isl_set_align_params(
                __isl_take isl_set *set,
                __isl_take isl_space *model);
+       __isl_give isl_basic_map *isl_basic_map_align_params(
+               __isl_take isl_basic_map *bmap,
+               __isl_take isl_space *model);
        __isl_give isl_map *isl_map_align_params(
                __isl_take isl_map *map,
                __isl_take isl_space *model);
@@ -2288,6 +2432,14 @@ All parameters need to be named.
        __isl_give isl_map *isl_map_add_dims(
                __isl_take isl_map *map,
                enum isl_dim_type type, unsigned n);
+       __isl_give isl_basic_set *isl_basic_set_insert_dims(
+               __isl_take isl_basic_set *bset,
+               enum isl_dim_type type, unsigned pos,
+               unsigned n);
+       __isl_give isl_basic_map *isl_basic_map_insert_dims(
+               __isl_take isl_basic_map *bmap,
+               enum isl_dim_type type, unsigned pos,
+               unsigned n);
        __isl_give isl_set *isl_set_insert_dims(
                __isl_take isl_set *set,
                enum isl_dim_type type, unsigned pos, unsigned n);
@@ -2388,6 +2540,11 @@ the same (number of) parameters.
                __isl_take isl_union_map *umap1,
                __isl_take isl_union_map *umap2);
 
+The second argument to the C<_params> functions needs to be
+a parametric (basic) set.  For the other functions, a parametric set
+for either argument is only allowed if the other argument is
+a parametric set as well.
+
 =item * Union
 
        __isl_give isl_set *isl_basic_set_union(
@@ -2474,12 +2631,18 @@ the same (number of) parameters.
        __isl_give isl_basic_map *isl_basic_map_range_product(
                __isl_take isl_basic_map *bmap1,
                __isl_take isl_basic_map *bmap2);
+       __isl_give isl_basic_map *isl_basic_map_product(
+               __isl_take isl_basic_map *bmap1,
+               __isl_take isl_basic_map *bmap2);
        __isl_give isl_map *isl_map_domain_product(
                __isl_take isl_map *map1,
                __isl_take isl_map *map2);
        __isl_give isl_map *isl_map_range_product(
                __isl_take isl_map *map1,
                __isl_take isl_map *map2);
+       __isl_give isl_union_map *isl_union_map_domain_product(
+               __isl_take isl_union_map *umap1,
+               __isl_take isl_union_map *umap2);
        __isl_give isl_union_map *isl_union_map_range_product(
                __isl_take isl_union_map *umap1,
                __isl_take isl_union_map *umap2);
@@ -2696,13 +2859,17 @@ returning a basic set or relation.
                __isl_take isl_basic_map *bmap,
                __isl_take isl_basic_set *dom,
                __isl_give isl_set **empty);
+       __isl_give isl_pw_multi_aff *isl_map_lexmin_pw_multi_aff(
+               __isl_take isl_map *map);
+       __isl_give isl_pw_multi_aff *isl_map_lexmax_pw_multi_aff(
+               __isl_take isl_map *map);
 
 =head2 Lists
 
 Lists are defined over several element types, including
-C<isl_aff>, C<isl_pw_aff>, C<isl_basic_set> and C<isl_set>.
+C<isl_id>, C<isl_aff>, C<isl_pw_aff>, C<isl_basic_set> and C<isl_set>.
 Here we take lists of C<isl_set>s as an example.
-Lists can be created, copied and freed using the following functions.
+Lists can be created, copied, modified and freed using the following functions.
 
        #include <isl/list.h>
        __isl_give isl_set_list *isl_set_list_from_set(
@@ -2714,6 +2881,9 @@ Lists can be created, copied and freed using the following functions.
        __isl_give isl_set_list *isl_set_list_add(
                __isl_take isl_set_list *list,
                __isl_take isl_set *el);
+       __isl_give isl_set_list *isl_set_list_set_set(
+               __isl_take isl_set_list *list, int index,
+               __isl_take isl_set *set);
        __isl_give isl_set_list *isl_set_list_concat(
                __isl_take isl_set_list *list1,
                __isl_take isl_set_list *list2);
@@ -2893,6 +3063,9 @@ The expression can be inspected using
        __isl_give isl_id *isl_pw_aff_get_dim_id(
                __isl_keep isl_pw_aff *pa,
                enum isl_dim_type type, unsigned pos);
+       __isl_give isl_id *isl_pw_aff_get_tuple_id(
+               __isl_keep isl_pw_aff *pa,
+               enum isl_dim_type type);
        int isl_aff_get_constant(__isl_keep isl_aff *aff,
                isl_int *v);
        int isl_aff_get_coefficient(__isl_keep isl_aff *aff,
@@ -2954,6 +3127,10 @@ It can be modified using
                __isl_take isl_aff *aff, isl_int v);
        __isl_give isl_aff *isl_aff_add_constant_si(
                __isl_take isl_aff *aff, int v);
+       __isl_give isl_aff *isl_aff_add_constant_num(
+               __isl_take isl_aff *aff, isl_int v);
+       __isl_give isl_aff *isl_aff_add_constant_num_si(
+               __isl_take isl_aff *aff, int v);
        __isl_give isl_aff *isl_aff_add_coefficient(
                __isl_take isl_aff *aff,
                enum isl_dim_type type, int pos, isl_int v);
@@ -2984,6 +3161,8 @@ Note that the C<set_constant> and C<set_coefficient> functions
 set the I<numerator> of the constant or coefficient, while
 C<add_constant> and C<add_coefficient> add an integer value to
 the possibly rational constant or coefficient.
+The C<add_constant_num> functions add an integer value to
+the numerator.
 
 To check whether an affine expressions is obviously zero
 or obviously equal to some other affine expression, use
@@ -3088,6 +3267,8 @@ When multiplying two affine expressions, at least one of the two needs
 to be a constant.
 
        #include <isl/aff.h>
+       __isl_give isl_basic_set *isl_aff_neg_basic_set(
+               __isl_take isl_aff *aff);
        __isl_give isl_basic_set *isl_aff_le_basic_set(
                __isl_take isl_aff *aff1, __isl_take isl_aff *aff2);
        __isl_give isl_basic_set *isl_aff_ge_basic_set(
@@ -3130,10 +3311,13 @@ to be a constant.
                __isl_take isl_pw_aff_list *list1,
                __isl_take isl_pw_aff_list *list2);
 
+The function C<isl_aff_neg_basic_set> returns a basic set
+containing those elements in the domain space
+of C<aff> where C<aff> is negative.
 The function C<isl_aff_ge_basic_set> returns a basic set
 containing those elements in the shared space
 of C<aff1> and C<aff2> where C<aff1> is greater than or equal to C<aff2>.
-The function C<isl_aff_ge_set> returns a set
+The function C<isl_pw_aff_ge_set> returns a set
 containing those elements in the shared domain
 of C<pwaff1> and C<pwaff2> where C<pwaff1> is greater than or equal to C<pwaff2>.
 The functions operating on C<isl_pw_aff_list> apply the corresponding
@@ -3225,6 +3409,8 @@ can be created using the following functions.
                __isl_take isl_space *space);
        __isl_give isl_multi_aff *isl_multi_aff_zero(
                __isl_take isl_space *space);
+       __isl_give isl_multi_aff *isl_multi_aff_identity(
+               __isl_take isl_space *space);
        __isl_give isl_pw_multi_aff *
        isl_pw_multi_aff_from_multi_aff(
                __isl_take isl_multi_aff *ma);
@@ -3299,6 +3485,9 @@ The expression can be inspected using
        const char *isl_multi_aff_get_tuple_name(
                __isl_keep isl_multi_aff *multi,
                enum isl_dim_type type);
+       int isl_pw_multi_aff_has_tuple_name(
+               __isl_keep isl_pw_multi_aff *pma,
+               enum isl_dim_type type);
        const char *isl_pw_multi_aff_get_tuple_name(
                __isl_keep isl_pw_multi_aff *pma,
                enum isl_dim_type type);
@@ -3352,6 +3541,12 @@ obviously equal to each other, use
 Operations include
 
        #include <isl/aff.h>
+       __isl_give isl_pw_multi_aff *isl_pw_multi_aff_union_lexmin(
+               __isl_take isl_pw_multi_aff *pma1,
+               __isl_take isl_pw_multi_aff *pma2);
+       __isl_give isl_pw_multi_aff *isl_pw_multi_aff_union_lexmax(
+               __isl_take isl_pw_multi_aff *pma1,
+               __isl_take isl_pw_multi_aff *pma2);
        __isl_give isl_multi_aff *isl_multi_aff_add(
                __isl_take isl_multi_aff *maff1,
                __isl_take isl_multi_aff *maff2);
@@ -3394,11 +3589,40 @@ Operations include
                __isl_take isl_pw_multi_aff *pma);
        __isl_give isl_union_set *isl_union_pw_multi_aff_domain(
                __isl_take isl_union_pw_multi_aff *upma);
+       __isl_give isl_multi_aff *isl_multi_aff_flat_range_product(
+               __isl_take isl_multi_aff *ma1,
+               __isl_take isl_multi_aff *ma2);
+       __isl_give isl_multi_aff *isl_multi_aff_product(
+               __isl_take isl_multi_aff *ma1,
+               __isl_take isl_multi_aff *ma2);
+       __isl_give isl_pw_multi_aff *
+       isl_pw_multi_aff_flat_range_product(
+               __isl_take isl_pw_multi_aff *pma1,
+               __isl_take isl_pw_multi_aff *pma2);
+       __isl_give isl_pw_multi_aff *isl_pw_multi_aff_product(
+               __isl_take isl_pw_multi_aff *pma1,
+               __isl_take isl_pw_multi_aff *pma2);
+       __isl_give isl_union_pw_multi_aff *
+       isl_union_pw_multi_aff_flat_range_product(
+               __isl_take isl_union_pw_multi_aff *upma1,
+               __isl_take isl_union_pw_multi_aff *upma2);
 
 If the C<ls> argument of C<isl_multi_aff_lift> is not C<NULL>,
 then it is assigned the local space that lies at the basis of
 the lifting applied.
 
+       __isl_give isl_set *isl_multi_aff_lex_le_set(
+               __isl_take isl_multi_aff *ma1,
+               __isl_take isl_multi_aff *ma2);
+       __isl_give isl_set *isl_multi_aff_lex_ge_set(
+               __isl_take isl_multi_aff *ma1,
+               __isl_take isl_multi_aff *ma2);
+
+The function C<isl_multi_aff_lex_le_set> returns a set
+containing those elements in the shared domain space
+where C<ma1> is lexicographically smaller than or
+equal to C<ma2>.
+
 An expression can be read from input using
 
        #include <isl/aff.h>
@@ -3995,7 +4219,7 @@ obviously equal, use
                __isl_take isl_point *pnt);
 
        __isl_give isl_pw_qpolynomial_fold *
-       sl_pw_qpolynomial_fold_intersect_params(
+       isl_pw_qpolynomial_fold_intersect_params(
                __isl_take isl_pw_qpolynomial_fold *pwf,
                __isl_take isl_set *set);
 
@@ -4111,7 +4335,7 @@ then value based dependence analysis is performed.
                __isl_take isl_access_info *acc,
                __isl_take isl_map *source, int must,
                void *source_user);
-       void isl_access_info_free(__isl_take isl_access_info *acc);
+       void *isl_access_info_free(__isl_take isl_access_info *acc);
 
        __isl_give isl_flow *isl_access_info_compute_flow(
                __isl_take isl_access_info *acc);
@@ -4211,7 +4435,7 @@ any of the other arguments is treated as an error.
 
 During the dependence analysis, we frequently need to perform
 the following operation.  Given a relation between sink iterations
-and potential soure iterations from a particular source domain,
+and potential source iterations from a particular source domain,
 what is the last potential source iteration corresponding to each
 sink iteration.  It can sometimes be convenient to adjust
 the set of potential source iterations before or after each such operation.
@@ -4251,8 +4475,8 @@ and the potential source iterations will be intersected with these sets.
 If the output needs to be restricted then only a restriction on the source
 iterations is required.
 If any error occurs, the callback should return C<NULL>.
-An C<isl_restriction> object can be created and freed using the following
-functions.
+An C<isl_restriction> object can be created, freed and inspected
+using the following functions.
 
        #include <isl/flow.h>
 
@@ -4262,11 +4486,13 @@ functions.
        __isl_give isl_restriction *isl_restriction_output(
                __isl_take isl_set *source_restr);
        __isl_give isl_restriction *isl_restriction_none(
-               __isl_keep isl_map *source_map);
+               __isl_take isl_map *source_map);
        __isl_give isl_restriction *isl_restriction_empty(
-               __isl_keep isl_map *source_map);
+               __isl_take isl_map *source_map);
        void *isl_restriction_free(
                __isl_take isl_restriction *restr);
+       isl_ctx *isl_restriction_get_ctx(
+               __isl_keep isl_restriction *restr);
 
 C<isl_restriction_none> and C<isl_restriction_empty> are special
 cases of C<isl_restriction_input>.  C<isl_restriction_none>
@@ -4332,6 +4558,15 @@ using the following function.
        __isl_give isl_band_list *isl_schedule_get_band_forest(
                __isl_keep isl_schedule *schedule);
 
+The individual bands can be visited in depth-first post-order
+using the following function.
+
+       #include <isl/schedule.h>
+       int isl_schedule_foreach_band(
+               __isl_keep isl_schedule *sched,
+               int (*fn)(__isl_keep isl_band *band, void *user),
+               void *user);
+
 The list can be manipulated as explained in L<"Lists">.
 The bands inside the list can be copied and freed using the following
 functions.
@@ -4372,12 +4607,37 @@ The properties of a band can be inspected using the following functions.
        int isl_band_member_is_zero_distance(
                __isl_keep isl_band *band, int pos);
 
+       int isl_band_list_foreach_band(
+               __isl_keep isl_band_list *list,
+               int (*fn)(__isl_keep isl_band *band, void *user),
+               void *user);
+
 Note that a scheduling dimension is considered to be ``zero
 distance'' if it does not carry any proximity dependences
 within its band.
 That is, if the dependence distances of the proximity
 dependences are all zero in that direction (for fixed
 iterations of outer bands).
+Like C<isl_schedule_foreach_band>,
+the function C<isl_band_list_foreach_band> calls C<fn> on the bands
+in depth-first post-order.
+
+A band can be tiled using the following function.
+
+       #include <isl/band.h>
+       int isl_band_tile(__isl_keep isl_band *band,
+               __isl_take isl_vec *sizes);
+
+       int isl_options_set_tile_scale_tile_loops(isl_ctx *ctx,
+               int val);
+       int isl_options_get_tile_scale_tile_loops(isl_ctx *ctx);
+
+The C<isl_band_tile> function tiles the band using the given tile sizes
+inside its schedule.
+A new child band is created to represent the point loops and it is
+inserted between the modified band and its children.
+The C<tile_scale_tile_loops> option specifies whether the tile
+loops iterators should be scaled by the tile sizes.
 
 A representation of the band can be printed using
 
@@ -4397,6 +4657,8 @@ A representation of the band can be printed using
                isl_ctx *ctx, int val);
        int isl_options_get_schedule_max_constant_term(
                isl_ctx *ctx);
+       int isl_options_set_schedule_fuse(isl_ctx *ctx, int val);
+       int isl_options_get_schedule_fuse(isl_ctx *ctx);
        int isl_options_set_schedule_maximize_band_depth(
                isl_ctx *ctx, int val);
        int isl_options_get_schedule_maximize_band_depth(
@@ -4413,7 +4675,10 @@ A representation of the band can be printed using
                isl_ctx *ctx, int val);
        int isl_options_get_schedule_algorithm(
                isl_ctx *ctx);
-
+       int isl_options_set_schedule_separate_components(
+               isl_ctx *ctx, int val);
+       int isl_options_get_schedule_separate_components(
+               isl_ctx *ctx);
 
 =over
 
@@ -4434,6 +4699,14 @@ increase the speed of the scheduling calculation and may also prevent fusing of
 unrelated dimensions. A value of -1 means that this option does not introduce
 bounds on the constant coefficients.
 
+=item * schedule_fuse
+
+This option controls the level of fusion.
+If this option is set to C<ISL_SCHEDULE_FUSE_MIN>, then loops in the
+resulting schedule will be distributed as much as possible.
+If this option is set to C<ISL_SCHEDULE_FUSE_MAX>, then C<isl> will
+try to fuse loops in the resulting schedule.
+
 =item * schedule_maximize_band_depth
 
 If this option is set, we do not split bands at the point
@@ -4441,6 +4714,9 @@ where we detect splitting is necessary. Instead, we
 backtrack and split bands as early as possible. This
 reduces the number of splits and maximizes the width of
 the bands. Wider bands give more possibilities for tiling.
+Note that if the C<schedule_fuse> option is set to C<ISL_SCHEDULE_FUSE_MIN>,
+then bands will be split as early as possible, even if there is no need.
+The C<schedule_maximize_band_depth> option therefore has no effect in this case.
 
 =item * schedule_outer_zero_distance
 
@@ -4464,6 +4740,15 @@ Selects the scheduling algorithm to be used.
 Available scheduling algorithms are C<ISL_SCHEDULE_ALGORITHM_ISL>
 and C<ISL_SCHEDULE_ALGORITHM_FEAUTRIER>.
 
+=item * schedule_separate_components
+
+If at any point the dependence graph contains any (weakly connected) components,
+then these components are scheduled separately.
+If this option is not set, then some iterations of the domains
+in these components may be scheduled together.
+If this option is set, then the components are given consecutive
+schedules.
+
 =back
 
 =head2 Parametric Vertex Enumeration