isl_ast_build_node_from_schedule: handle basic AST build options
[isl.git] / isl_schedule_band.h
bloba3d8fd4277a8cbe62923da4cdad33a3c39d5c6e2
1 #ifndef ISL_SCHEDULE_BAND_H
2 #define ISL_SCHEDULE_BAND_H
4 #include <isl/aff.h>
5 #include <isl/ast_type.h>
6 #include <isl/union_map.h>
8 /* Information about a band within a schedule.
10 * n is the number of scheduling dimensions within the band.
11 * coincident is an array of length n, indicating whether a scheduling dimension
12 * satisfies the coincidence constraints in the sense that
13 * the corresponding dependence distances are zero.
14 * permutable is set if the band is permutable.
15 * mupa is the partial schedule corresponding to this band. The dimension
16 * of mupa is equal to n.
17 * loop_type contains the loop AST generation types for the members
18 * in the band. It may be NULL, if all members are
19 * of type isl_ast_loop_default.
20 * ast_build_options are the remaining AST build options associated
21 * to the band.
23 struct isl_schedule_band {
24 int ref;
26 int n;
27 int *coincident;
28 int permutable;
30 isl_multi_union_pw_aff *mupa;
32 isl_union_set *ast_build_options;
33 enum isl_ast_loop_type *loop_type;
35 typedef struct isl_schedule_band isl_schedule_band;
37 __isl_give isl_schedule_band *isl_schedule_band_from_multi_union_pw_aff(
38 __isl_take isl_multi_union_pw_aff *mupa);
39 __isl_give isl_schedule_band *isl_schedule_band_copy(
40 __isl_keep isl_schedule_band *band);
41 __isl_null isl_schedule_band *isl_schedule_band_free(
42 __isl_take isl_schedule_band *band);
44 isl_ctx *isl_schedule_band_get_ctx(__isl_keep isl_schedule_band *band);
46 int isl_schedule_band_plain_is_equal(__isl_keep isl_schedule_band *band1,
47 __isl_keep isl_schedule_band *band2);
49 __isl_give isl_space *isl_schedule_band_get_space(
50 __isl_keep isl_schedule_band *band);
51 __isl_give isl_multi_union_pw_aff *isl_schedule_band_get_partial_schedule(
52 __isl_keep isl_schedule_band *band);
53 enum isl_ast_loop_type isl_schedule_band_member_get_ast_loop_type(
54 __isl_keep isl_schedule_band *band, int pos);
55 __isl_give isl_schedule_band *isl_schedule_band_member_set_ast_loop_type(
56 __isl_take isl_schedule_band *band, int pos,
57 enum isl_ast_loop_type type);
58 __isl_give isl_union_set *isl_schedule_band_get_ast_build_options(
59 __isl_keep isl_schedule_band *band);
60 __isl_give isl_schedule_band *isl_schedule_band_set_ast_build_options(
61 __isl_take isl_schedule_band *band, __isl_take isl_union_set *options);
63 int isl_schedule_band_n_member(__isl_keep isl_schedule_band *band);
64 int isl_schedule_band_member_get_coincident(
65 __isl_keep isl_schedule_band *band, int pos);
66 __isl_give isl_schedule_band *isl_schedule_band_member_set_coincident(
67 __isl_take isl_schedule_band *band, int pos, int coincident);
68 int isl_schedule_band_get_permutable(__isl_keep isl_schedule_band *band);
69 __isl_give isl_schedule_band *isl_schedule_band_set_permutable(
70 __isl_take isl_schedule_band *band, int permutable);
72 __isl_give isl_schedule_band *isl_schedule_band_scale(
73 __isl_take isl_schedule_band *band, __isl_take isl_multi_val *mv);
74 __isl_give isl_schedule_band *isl_schedule_band_scale_down(
75 __isl_take isl_schedule_band *band, __isl_take isl_multi_val *mv);
76 __isl_give isl_schedule_band *isl_schedule_band_tile(
77 __isl_take isl_schedule_band *band, __isl_take isl_multi_val *sizes);
78 __isl_give isl_schedule_band *isl_schedule_band_point(
79 __isl_take isl_schedule_band *band, __isl_keep isl_schedule_band *tile,
80 __isl_take isl_multi_val *sizes);
81 __isl_give isl_schedule_band *isl_schedule_band_drop(
82 __isl_take isl_schedule_band *band, int pos, int n);
83 __isl_give isl_schedule_band *isl_schedule_band_gist(
84 __isl_take isl_schedule_band *band, __isl_take isl_union_set *context);
86 __isl_give isl_schedule_band *isl_schedule_band_reset_user(
87 __isl_take isl_schedule_band *band);
88 __isl_give isl_schedule_band *isl_schedule_band_align_params(
89 __isl_take isl_schedule_band *band, __isl_take isl_space *space);
90 __isl_give isl_schedule_band *isl_schedule_band_pullback_union_pw_multi_aff(
91 __isl_take isl_schedule_band *band,
92 __isl_take isl_union_pw_multi_aff *upma);
94 #endif