21 #include <unordered_set>
31 namespace polyhedral {
39 std::vector<detail::ScheduleTree*> collectScheduleTreesPath(
40 std::function<detail::ScheduleTree*(detail::ScheduleTree*)> next,
41 detail::ScheduleTree* start);
42 std::vector<const detail::ScheduleTree*> collectScheduleTreesPath(
43 std::function<
const detail::ScheduleTree*(
const detail::ScheduleTree*)>
45 const detail::ScheduleTree* start);
53 detail::ScheduleTree* joinBands(
54 detail::ScheduleTree* tree,
55 bool permutable =
false);
63 detail::ScheduleTree* joinBandsIterative(
64 detail::ScheduleTree* tree,
65 bool permutable =
false);
72 detail::ScheduleTree* bandSplit(
73 detail::ScheduleTree* relativeRoot,
74 detail::ScheduleTree* tree,
82 detail::ScheduleTree* bandSplitOut(
83 detail::ScheduleTree* relativeRoot,
84 detail::ScheduleTree* tree,
103 detail::ScheduleTree* bandTile(
104 detail::ScheduleTree* tree,
105 const std::vector<size_t>& tileSizes,
106 TileOptions tileOptions);
113 detail::ScheduleTree* bandScale(
114 detail::ScheduleTree* tree,
115 const std::vector<size_t>& scales);
126 template <
typename MappingIdType>
127 detail::ScheduleTree* mapToParameterWithExtent(
128 detail::ScheduleTree* root,
129 detail::ScheduleTree* tree,
140 detail::ScheduleTree* insertBandAbove(
141 detail::ScheduleTree* root,
142 detail::ScheduleTree* tree,
143 isl::multi_union_pw_aff mupa);
151 detail::ScheduleTree* insertBandBelow(
152 detail::ScheduleTree* tree,
153 isl::multi_union_pw_aff mupa);
158 void updateTopLevelContext(detail::ScheduleTree* root, isl::set context);
166 detail::ScheduleTree* insertSequenceAbove(
167 detail::ScheduleTree* root,
168 detail::ScheduleTree* tree);
176 detail::ScheduleTree* insertExtensionAbove(
177 detail::ScheduleTree* root,
178 detail::ScheduleTree* tree,
179 isl::union_map extension);
187 template <
typename MappingIdType>
188 inline detail::ScheduleTree* insertMappingFilterAbove(
189 detail::ScheduleTree* root,
190 detail::ScheduleTree* tree,
191 isl::union_set filter,
192 const std::unordered_set<MappingIdType, typename MappingIdType::Hash>&
200 template <
typename MappingIdType>
201 inline void insertMappingFilterBelow(
202 detail::ScheduleTree* tree,
203 isl::union_set filter,
204 const std::unordered_set<MappingIdType, typename MappingIdType::Hash>&
212 void insertExtensionLabelAt(
213 detail::ScheduleTree* root,
214 detail::ScheduleTree* seqNode,
224 void insertExtensionLabelBefore(
225 detail::ScheduleTree* root,
226 detail::ScheduleTree* tree,
235 void insertExtensionLabelAfter(
236 detail::ScheduleTree* root,
237 detail::ScheduleTree* tree,
243 detail::ScheduleTree* root,
244 detail::ScheduleTree* tree,
245 isl::union_set filter);
249 detail::ScheduleTree* root,
250 detail::ScheduleTree* tree,
251 isl::union_set filter);
255 isl::union_map extendSchedule(
256 const detail::ScheduleTree* node,
257 isl::union_map schedule);
261 isl::union_map partialSchedule(
262 const detail::ScheduleTree* root,
263 const detail::ScheduleTree* node);
266 isl::union_map prefixSchedule(
267 const detail::ScheduleTree* root,
268 const detail::ScheduleTree* node);
275 isl::multi_union_pw_aff prefixScheduleMupa(
276 const detail::ScheduleTree* root,
277 const detail::ScheduleTree* tree);
283 isl::union_set activeDomainPoints(
284 const detail::ScheduleTree* root,
285 const detail::ScheduleTree* node);
290 std::unordered_set<isl::id, isl::IslIdIslHash> activeStatements(
291 const detail::ScheduleTree* root,
292 const detail::ScheduleTree* node);
299 detail::ScheduleTree* mergeConsecutiveMappingFilters(
300 detail::ScheduleTree* root,
301 detail::ScheduleTree* node);