Coverage Report

Created: 2017-04-27 19:33

/Users/buildslave/jenkins/sharedspace/clang-stage2-coverage-R@2/llvm/tools/polly/lib/External/isl/include/isl-noexceptions.h
Line
Count
Source (jump to first uncovered line)
1
/// These are automatically generated C++ bindings for isl.
2
///
3
/// isl is a library for computing with integer sets and maps described by
4
/// Presburger formulas. On top of this, isl provides various tools for
5
/// Polyhedral compilation ranging from dependence analysis over scheduling
6
/// to AST generation.
7
8
#ifndef ISL_CPP_NOEXCEPTIONS
9
#define ISL_CPP_NOEXCEPTIONS
10
11
#include <isl/aff.h>
12
#include <isl/ast_build.h>
13
#include <isl/flow.h>
14
#include <isl/id.h>
15
#include <isl/ilp.h>
16
#include <isl/map.h>
17
#include <isl/schedule.h>
18
#include <isl/schedule_node.h>
19
#include <isl/set.h>
20
#include <isl/union_map.h>
21
#include <isl/union_set.h>
22
#include <isl/val.h>
23
24
#include <functional>
25
#include <string>
26
27
namespace isl {
28
29
inline namespace noexceptions {
30
31
#define ISLPP_STRINGIZE_(X) #X
32
#define ISLPP_STRINGIZE(X) ISLPP_STRINGIZE_(X)
33
34
#define ISLPP_ASSERT(test, message)                          \
35
1.16k
  
do 1.16k
{ \1.16k
36
1.16k
    if (test)                                                \
37
1.16k
      break;                                                 \
38
0
    fputs("Assertion \"" #test "\" failed at " __FILE__      \
39
0
      ":" ISLPP_STRINGIZE(__LINE__) "\n  " message "\n",     \
40
0
      stderr);                                               \
41
0
  } while (0)
42
43
class boolean {
44
private:
45
  isl_bool val;
46
47
  friend isl::boolean manage(isl_bool val);
48
0
  explicit boolean(isl_bool val): val(val) {}
49
public:
50
  boolean()
51
0
      : val(isl_bool_error) {}
52
53
  /* implicit */ boolean(bool val)
54
2.00k
      : val(val ? isl_bool_true : isl_bool_false) {}
55
56
2.00k
  bool is_error() const { return val == isl_bool_error; }
57
0
  bool is_false() const { return val == isl_bool_false; }
58
2.00k
  bool is_true() const { return val == isl_bool_true; }
59
60
1.16k
  explicit operator bool() const {
61
1.16k
    ISLPP_ASSERT(!is_error(), "IMPLEMENTATION ERROR: Unhandled error state");
62
1.16k
    return is_true();
63
1.16k
  }
64
65
845
  boolean operator!() const {
66
845
    if (is_error())
67
0
      return *this;
68
845
    return !is_true();
69
845
  }
70
};
71
72
0
inline isl::boolean manage(isl_bool val) {
73
0
  return isl::boolean(val);
74
0
}
75
76
class ctx {
77
  isl_ctx *ptr;
78
public:
79
  /* implicit */ ctx(isl_ctx *ctx)
80
624
      : ptr(ctx) {}
81
635
  isl_ctx *release() {
82
635
    auto tmp = ptr;
83
635
    ptr = nullptr;
84
635
    return tmp;
85
635
  }
86
0
  isl_ctx *get() {
87
0
    return ptr;
88
0
  }
89
};
90
91
enum class stat {
92
  ok = isl_stat_ok,
93
  error = isl_stat_error
94
};
95
96
enum class dim {
97
  cst = isl_dim_cst,
98
  param = isl_dim_param,
99
  in = isl_dim_in,
100
  out = isl_dim_out,
101
  set = isl_dim_set,
102
  div = isl_dim_div,
103
  all = isl_dim_all
104
};
105
106
}
107
} // namespace isl
108
109
namespace isl {
110
111
inline namespace noexceptions {
112
113
// forward declarations
114
class aff;
115
class ast_build;
116
class ast_expr;
117
class ast_node;
118
class basic_map;
119
class basic_set;
120
class id;
121
class local_space;
122
class map;
123
class multi_aff;
124
class multi_pw_aff;
125
class multi_union_pw_aff;
126
class multi_val;
127
class point;
128
class pw_aff;
129
class pw_multi_aff;
130
class schedule;
131
class schedule_constraints;
132
class schedule_node;
133
class set;
134
class space;
135
class union_access_info;
136
class union_flow;
137
class union_map;
138
class union_pw_aff;
139
class union_pw_multi_aff;
140
class union_set;
141
class val;
142
143
// declarations for isl::aff
144
inline isl::aff manage(__isl_take isl_aff *ptr);
145
146
inline isl::aff give(__isl_take isl_aff *ptr);
147
148
class aff {
149
  friend inline isl::aff manage(__isl_take isl_aff *ptr);
150
151
  isl_aff *ptr = nullptr;
152
153
  inline explicit aff(__isl_take isl_aff *ptr);
154
155
public:
156
  inline /* implicit */ aff();
157
  inline /* implicit */ aff(const isl::aff &obj);
158
  inline /* implicit */ aff(std::nullptr_t);
159
  inline explicit aff(isl::local_space ls);
160
  inline explicit aff(isl::local_space ls, isl::val val);
161
  inline explicit aff(isl::ctx ctx, const std::string &str);
162
  inline isl::aff &operator=(isl::aff obj);
163
  inline ~aff();
164
  inline __isl_give isl_aff *copy() const &;
165
  inline __isl_give isl_aff *copy() && = delete;
166
  inline __isl_keep isl_aff *get() const;
167
  inline __isl_give isl_aff *release();
168
  inline __isl_keep isl_aff *keep() const;
169
  inline __isl_give isl_aff *take();
170
  inline explicit operator bool() const;
171
  inline isl::ctx get_ctx() const;
172
  inline bool is_null() const;
173
  inline std::string to_str() const;
174
  inline isl::aff add(isl::aff aff2) const;
175
  inline isl::val get_constant() const;
176
  inline isl::boolean is_cst() const;
177
  inline isl::aff pullback(isl::multi_aff ma) const;
178
};
179
180
// declarations for isl::ast_build
181
inline isl::ast_build manage(__isl_take isl_ast_build *ptr);
182
183
inline isl::ast_build give(__isl_take isl_ast_build *ptr);
184
185
class ast_build {
186
  friend inline isl::ast_build manage(__isl_take isl_ast_build *ptr);
187
188
  isl_ast_build *ptr = nullptr;
189
190
  inline explicit ast_build(__isl_take isl_ast_build *ptr);
191
192
public:
193
  inline /* implicit */ ast_build();
194
  inline /* implicit */ ast_build(const isl::ast_build &obj);
195
  inline /* implicit */ ast_build(std::nullptr_t);
196
  inline explicit ast_build(isl::ctx ctx);
197
  inline isl::ast_build &operator=(isl::ast_build obj);
198
  inline ~ast_build();
199
  inline __isl_give isl_ast_build *copy() const &;
200
  inline __isl_give isl_ast_build *copy() && = delete;
201
  inline __isl_keep isl_ast_build *get() const;
202
  inline __isl_give isl_ast_build *release();
203
  inline __isl_keep isl_ast_build *keep() const;
204
  inline __isl_give isl_ast_build *take();
205
  inline explicit operator bool() const;
206
  inline isl::ctx get_ctx() const;
207
  inline bool is_null() const;
208
  inline isl::ast_expr access_from(isl::pw_multi_aff pma) const;
209
  inline isl::ast_expr access_from(isl::multi_pw_aff mpa) const;
210
  inline isl::ast_expr call_from(isl::pw_multi_aff pma) const;
211
  inline isl::ast_expr call_from(isl::multi_pw_aff mpa) const;
212
  inline isl::ast_expr expr_from(isl::set set) const;
213
  inline isl::ast_expr expr_from(isl::pw_aff pa) const;
214
  static inline isl::ast_build from_context(isl::set set);
215
  inline isl::ast_node node_from_schedule_map(isl::union_map schedule) const;
216
};
217
218
// declarations for isl::ast_expr
219
inline isl::ast_expr manage(__isl_take isl_ast_expr *ptr);
220
221
inline isl::ast_expr give(__isl_take isl_ast_expr *ptr);
222
223
class ast_expr {
224
  friend inline isl::ast_expr manage(__isl_take isl_ast_expr *ptr);
225
226
  isl_ast_expr *ptr = nullptr;
227
228
  inline explicit ast_expr(__isl_take isl_ast_expr *ptr);
229
230
public:
231
  inline /* implicit */ ast_expr();
232
  inline /* implicit */ ast_expr(const isl::ast_expr &obj);
233
  inline /* implicit */ ast_expr(std::nullptr_t);
234
  inline isl::ast_expr &operator=(isl::ast_expr obj);
235
  inline ~ast_expr();
236
  inline __isl_give isl_ast_expr *copy() const &;
237
  inline __isl_give isl_ast_expr *copy() && = delete;
238
  inline __isl_keep isl_ast_expr *get() const;
239
  inline __isl_give isl_ast_expr *release();
240
  inline __isl_keep isl_ast_expr *keep() const;
241
  inline __isl_give isl_ast_expr *take();
242
  inline explicit operator bool() const;
243
  inline isl::ctx get_ctx() const;
244
  inline bool is_null() const;
245
  inline std::string to_str() const;
246
  inline std::string to_C_str() const;
247
};
248
249
// declarations for isl::ast_node
250
inline isl::ast_node manage(__isl_take isl_ast_node *ptr);
251
252
inline isl::ast_node give(__isl_take isl_ast_node *ptr);
253
254
class ast_node {
255
  friend inline isl::ast_node manage(__isl_take isl_ast_node *ptr);
256
257
  isl_ast_node *ptr = nullptr;
258
259
  inline explicit ast_node(__isl_take isl_ast_node *ptr);
260
261
public:
262
  inline /* implicit */ ast_node();
263
  inline /* implicit */ ast_node(const isl::ast_node &obj);
264
  inline /* implicit */ ast_node(std::nullptr_t);
265
  inline isl::ast_node &operator=(isl::ast_node obj);
266
  inline ~ast_node();
267
  inline __isl_give isl_ast_node *copy() const &;
268
  inline __isl_give isl_ast_node *copy() && = delete;
269
  inline __isl_keep isl_ast_node *get() const;
270
  inline __isl_give isl_ast_node *release();
271
  inline __isl_keep isl_ast_node *keep() const;
272
  inline __isl_give isl_ast_node *take();
273
  inline explicit operator bool() const;
274
  inline isl::ctx get_ctx() const;
275
  inline bool is_null() const;
276
  inline std::string to_str() const;
277
  inline std::string to_C_str() const;
278
};
279
280
// declarations for isl::basic_map
281
inline isl::basic_map manage(__isl_take isl_basic_map *ptr);
282
283
inline isl::basic_map give(__isl_take isl_basic_map *ptr);
284
285
class basic_map {
286
  friend inline isl::basic_map manage(__isl_take isl_basic_map *ptr);
287
288
  isl_basic_map *ptr = nullptr;
289
290
  inline explicit basic_map(__isl_take isl_basic_map *ptr);
291
292
public:
293
  inline /* implicit */ basic_map();
294
  inline /* implicit */ basic_map(const isl::basic_map &obj);
295
  inline /* implicit */ basic_map(std::nullptr_t);
296
  inline explicit basic_map(isl::ctx ctx, const std::string &str);
297
  inline isl::basic_map &operator=(isl::basic_map obj);
298
  inline ~basic_map();
299
  inline __isl_give isl_basic_map *copy() const &;
300
  inline __isl_give isl_basic_map *copy() && = delete;
301
  inline __isl_keep isl_basic_map *get() const;
302
  inline __isl_give isl_basic_map *release();
303
  inline __isl_keep isl_basic_map *keep() const;
304
  inline __isl_give isl_basic_map *take();
305
  inline explicit operator bool() const;
306
  inline isl::ctx get_ctx() const;
307
  inline bool is_null() const;
308
  inline std::string to_str() const;
309
  inline isl::basic_map affine_hull() const;
310
  inline isl::basic_map apply_domain(isl::basic_map bmap2) const;
311
  inline isl::basic_map apply_range(isl::basic_map bmap2) const;
312
  inline isl::basic_set deltas() const;
313
  inline isl::basic_map detect_equalities() const;
314
  inline isl::basic_map fix_si(isl::dim type, unsigned int pos, int value) const;
315
  inline isl::basic_map flatten() const;
316
  inline isl::basic_map flatten_domain() const;
317
  inline isl::basic_map flatten_range() const;
318
  inline isl::basic_map gist(isl::basic_map context) const;
319
  inline isl::basic_map intersect(isl::basic_map bmap2) const;
320
  inline isl::basic_map intersect_domain(isl::basic_set bset) const;
321
  inline isl::basic_map intersect_range(isl::basic_set bset) const;
322
  inline isl::boolean is_empty() const;
323
  inline isl::boolean is_equal(const isl::basic_map &bmap2) const;
324
  inline isl::boolean is_subset(const isl::basic_map &bmap2) const;
325
  inline isl::map lexmax() const;
326
  inline isl::map lexmin() const;
327
  inline isl::val plain_get_val_if_fixed(isl::dim type, unsigned int pos) const;
328
  inline isl::basic_map project_out(isl::dim type, unsigned int first, unsigned int n) const;
329
  inline isl::basic_map reverse() const;
330
  inline isl::basic_map sample() const;
331
  inline isl::map unite(isl::basic_map bmap2) const;
332
  static inline isl::basic_map universe(isl::space dim);
333
};
334
335
// declarations for isl::basic_set
336
inline isl::basic_set manage(__isl_take isl_basic_set *ptr);
337
338
inline isl::basic_set give(__isl_take isl_basic_set *ptr);
339
340
class basic_set {
341
  friend inline isl::basic_set manage(__isl_take isl_basic_set *ptr);
342
343
  isl_basic_set *ptr = nullptr;
344
345
  inline explicit basic_set(__isl_take isl_basic_set *ptr);
346
347
public:
348
  inline /* implicit */ basic_set();
349
  inline /* implicit */ basic_set(const isl::basic_set &obj);
350
  inline /* implicit */ basic_set(std::nullptr_t);
351
  inline explicit basic_set(isl::ctx ctx, const std::string &str);
352
  inline /* implicit */ basic_set(isl::point pnt);
353
  inline isl::basic_set &operator=(isl::basic_set obj);
354
  inline ~basic_set();
355
  inline __isl_give isl_basic_set *copy() const &;
356
  inline __isl_give isl_basic_set *copy() && = delete;
357
  inline __isl_keep isl_basic_set *get() const;
358
  inline __isl_give isl_basic_set *release();
359
  inline __isl_keep isl_basic_set *keep() const;
360
  inline __isl_give isl_basic_set *take();
361
  inline explicit operator bool() const;
362
  inline isl::ctx get_ctx() const;
363
  inline bool is_null() const;
364
  inline std::string to_str() const;
365
  inline isl::basic_set affine_hull() const;
366
  inline isl::basic_set apply(isl::basic_map bmap) const;
367
  inline isl::basic_set detect_equalities() const;
368
  inline isl::basic_set flatten() const;
369
  inline isl::basic_set gist(isl::basic_set context) const;
370
  inline isl::basic_set intersect(isl::basic_set bset2) const;
371
  inline isl::basic_set intersect_params(isl::basic_set bset2) const;
372
  inline isl::boolean is_bounded() const;
373
  inline isl::boolean is_empty() const;
374
  inline isl::boolean is_equal(const isl::basic_set &bset2) const;
375
  inline isl::boolean is_subset(const isl::basic_set &bset2) const;
376
  inline isl::boolean is_wrapping() const;
377
  inline isl::set lexmax() const;
378
  inline isl::set lexmin() const;
379
  inline isl::basic_set project_out(isl::dim type, unsigned int first, unsigned int n) const;
380
  inline isl::basic_set sample() const;
381
  inline isl::point sample_point() const;
382
  inline isl::set unite(isl::basic_set bset2) const;
383
};
384
385
// declarations for isl::id
386
inline isl::id manage(__isl_take isl_id *ptr);
387
388
inline isl::id give(__isl_take isl_id *ptr);
389
390
class id {
391
  friend inline isl::id manage(__isl_take isl_id *ptr);
392
393
  isl_id *ptr = nullptr;
394
395
  inline explicit id(__isl_take isl_id *ptr);
396
397
public:
398
  inline /* implicit */ id();
399
  inline /* implicit */ id(const isl::id &obj);
400
  inline /* implicit */ id(std::nullptr_t);
401
  inline isl::id &operator=(isl::id obj);
402
  inline ~id();
403
  inline __isl_give isl_id *copy() const &;
404
  inline __isl_give isl_id *copy() && = delete;
405
  inline __isl_keep isl_id *get() const;
406
  inline __isl_give isl_id *release();
407
  inline __isl_keep isl_id *keep() const;
408
  inline __isl_give isl_id *take();
409
  inline explicit operator bool() const;
410
  inline isl::ctx get_ctx() const;
411
  inline bool is_null() const;
412
  inline std::string to_str() const;
413
};
414
415
// declarations for isl::local_space
416
inline isl::local_space manage(__isl_take isl_local_space *ptr);
417
418
inline isl::local_space give(__isl_take isl_local_space *ptr);
419
420
class local_space {
421
  friend inline isl::local_space manage(__isl_take isl_local_space *ptr);
422
423
  isl_local_space *ptr = nullptr;
424
425
  inline explicit local_space(__isl_take isl_local_space *ptr);
426
427
public:
428
  inline /* implicit */ local_space();
429
  inline /* implicit */ local_space(const isl::local_space &obj);
430
  inline /* implicit */ local_space(std::nullptr_t);
431
  inline explicit local_space(isl::space dim);
432
  inline isl::local_space &operator=(isl::local_space obj);
433
  inline ~local_space();
434
  inline __isl_give isl_local_space *copy() const &;
435
  inline __isl_give isl_local_space *copy() && = delete;
436
  inline __isl_keep isl_local_space *get() const;
437
  inline __isl_give isl_local_space *release();
438
  inline __isl_keep isl_local_space *keep() const;
439
  inline __isl_give isl_local_space *take();
440
  inline explicit operator bool() const;
441
  inline isl::ctx get_ctx() const;
442
  inline bool is_null() const;
443
};
444
445
// declarations for isl::map
446
inline isl::map manage(__isl_take isl_map *ptr);
447
448
inline isl::map give(__isl_take isl_map *ptr);
449
450
class map {
451
  friend inline isl::map manage(__isl_take isl_map *ptr);
452
453
  isl_map *ptr = nullptr;
454
455
  inline explicit map(__isl_take isl_map *ptr);
456
457
public:
458
  inline /* implicit */ map();
459
  inline /* implicit */ map(const isl::map &obj);
460
  inline /* implicit */ map(std::nullptr_t);
461
  inline explicit map(isl::ctx ctx, const std::string &str);
462
  inline /* implicit */ map(isl::basic_map bmap);
463
  inline isl::map &operator=(isl::map obj);
464
  inline ~map();
465
  inline __isl_give isl_map *copy() const &;
466
  inline __isl_give isl_map *copy() && = delete;
467
  inline __isl_keep isl_map *get() const;
468
  inline __isl_give isl_map *release();
469
  inline __isl_keep isl_map *keep() const;
470
  inline __isl_give isl_map *take();
471
  inline explicit operator bool() const;
472
  inline isl::ctx get_ctx() const;
473
  inline bool is_null() const;
474
  inline std::string to_str() const;
475
  inline isl::basic_map affine_hull() const;
476
  inline isl::map apply_domain(isl::map map2) const;
477
  inline isl::map apply_range(isl::map map2) const;
478
  inline isl::map coalesce() const;
479
  inline isl::map complement() const;
480
  inline isl::set deltas() const;
481
  inline isl::map detect_equalities() const;
482
  inline unsigned int dim(isl::dim type) const;
483
  inline isl::pw_aff dim_max(int pos) const;
484
  inline isl::pw_aff dim_min(int pos) const;
485
  inline isl::map flatten() const;
486
  inline isl::map flatten_domain() const;
487
  inline isl::map flatten_range() const;
488
  inline isl::stat foreach_basic_map(const std::function<isl::stat(isl::basic_map)> &fn) const;
489
  static inline isl::map from_range(isl::set set);
490
  inline isl::map gist(isl::map context) const;
491
  inline isl::map gist_domain(isl::set context) const;
492
  inline isl::map intersect(isl::map map2) const;
493
  inline isl::map intersect_domain(isl::set set) const;
494
  inline isl::map intersect_params(isl::set params) const;
495
  inline isl::map intersect_range(isl::set set) const;
496
  inline isl::boolean is_bijective() const;
497
  inline isl::boolean is_disjoint(const isl::map &map2) const;
498
  inline isl::boolean is_empty() const;
499
  inline isl::boolean is_equal(const isl::map &map2) const;
500
  inline isl::boolean is_injective() const;
501
  inline isl::boolean is_single_valued() const;
502
  inline isl::boolean is_strict_subset(const isl::map &map2) const;
503
  inline isl::boolean is_subset(const isl::map &map2) const;
504
  inline isl::map lexmax() const;
505
  inline isl::map lexmin() const;
506
  inline isl::basic_map polyhedral_hull() const;
507
  inline isl::map project_out(isl::dim type, unsigned int first, unsigned int n) const;
508
  inline isl::map reverse() const;
509
  inline isl::basic_map sample() const;
510
  inline isl::map subtract(isl::map map2) const;
511
  inline isl::map unite(isl::map map2) const;
512
  inline isl::basic_map unshifted_simple_hull() const;
513
};
514
515
// declarations for isl::multi_aff
516
inline isl::multi_aff manage(__isl_take isl_multi_aff *ptr);
517
518
inline isl::multi_aff give(__isl_take isl_multi_aff *ptr);
519
520
class multi_aff {
521
  friend inline isl::multi_aff manage(__isl_take isl_multi_aff *ptr);
522
523
  isl_multi_aff *ptr = nullptr;
524
525
  inline explicit multi_aff(__isl_take isl_multi_aff *ptr);
526
527
public:
528
  inline /* implicit */ multi_aff();
529
  inline /* implicit */ multi_aff(const isl::multi_aff &obj);
530
  inline /* implicit */ multi_aff(std::nullptr_t);
531
  inline /* implicit */ multi_aff(isl::aff aff);
532
  inline explicit multi_aff(isl::ctx ctx, const std::string &str);
533
  inline isl::multi_aff &operator=(isl::multi_aff obj);
534
  inline ~multi_aff();
535
  inline __isl_give isl_multi_aff *copy() const &;
536
  inline __isl_give isl_multi_aff *copy() && = delete;
537
  inline __isl_keep isl_multi_aff *get() const;
538
  inline __isl_give isl_multi_aff *release();
539
  inline __isl_keep isl_multi_aff *keep() const;
540
  inline __isl_give isl_multi_aff *take();
541
  inline explicit operator bool() const;
542
  inline isl::ctx get_ctx() const;
543
  inline bool is_null() const;
544
  inline std::string to_str() const;
545
  inline isl::multi_aff add(isl::multi_aff multi2) const;
546
  inline isl::multi_aff flat_range_product(isl::multi_aff multi2) const;
547
  inline isl::aff get_aff(int pos) const;
548
  inline isl::multi_aff product(isl::multi_aff multi2) const;
549
  inline isl::multi_aff pullback(isl::multi_aff ma2) const;
550
  inline isl::multi_aff range_product(isl::multi_aff multi2) const;
551
};
552
553
// declarations for isl::multi_pw_aff
554
inline isl::multi_pw_aff manage(__isl_take isl_multi_pw_aff *ptr);
555
556
inline isl::multi_pw_aff give(__isl_take isl_multi_pw_aff *ptr);
557
558
class multi_pw_aff {
559
  friend inline isl::multi_pw_aff manage(__isl_take isl_multi_pw_aff *ptr);
560
561
  isl_multi_pw_aff *ptr = nullptr;
562
563
  inline explicit multi_pw_aff(__isl_take isl_multi_pw_aff *ptr);
564
565
public:
566
  inline /* implicit */ multi_pw_aff();
567
  inline /* implicit */ multi_pw_aff(const isl::multi_pw_aff &obj);
568
  inline /* implicit */ multi_pw_aff(std::nullptr_t);
569
  inline /* implicit */ multi_pw_aff(isl::multi_aff ma);
570
  inline /* implicit */ multi_pw_aff(isl::pw_aff pa);
571
  inline /* implicit */ multi_pw_aff(isl::pw_multi_aff pma);
572
  inline explicit multi_pw_aff(isl::ctx ctx, const std::string &str);
573
  inline isl::multi_pw_aff &operator=(isl::multi_pw_aff obj);
574
  inline ~multi_pw_aff();
575
  inline __isl_give isl_multi_pw_aff *copy() const &;
576
  inline __isl_give isl_multi_pw_aff *copy() && = delete;
577
  inline __isl_keep isl_multi_pw_aff *get() const;
578
  inline __isl_give isl_multi_pw_aff *release();
579
  inline __isl_keep isl_multi_pw_aff *keep() const;
580
  inline __isl_give isl_multi_pw_aff *take();
581
  inline explicit operator bool() const;
582
  inline isl::ctx get_ctx() const;
583
  inline bool is_null() const;
584
  inline std::string to_str() const;
585
  inline isl::multi_pw_aff add(isl::multi_pw_aff multi2) const;
586
  inline isl::multi_pw_aff flat_range_product(isl::multi_pw_aff multi2) const;
587
  inline isl::pw_aff get_pw_aff(int pos) const;
588
  inline isl::multi_pw_aff product(isl::multi_pw_aff multi2) const;
589
  inline isl::multi_pw_aff pullback(isl::multi_aff ma) const;
590
  inline isl::multi_pw_aff pullback(isl::pw_multi_aff pma) const;
591
  inline isl::multi_pw_aff pullback(isl::multi_pw_aff mpa2) const;
592
  inline isl::multi_pw_aff range_product(isl::multi_pw_aff multi2) const;
593
};
594
595
// declarations for isl::multi_union_pw_aff
596
inline isl::multi_union_pw_aff manage(__isl_take isl_multi_union_pw_aff *ptr);
597
598
inline isl::multi_union_pw_aff give(__isl_take isl_multi_union_pw_aff *ptr);
599
600
class multi_union_pw_aff {
601
  friend inline isl::multi_union_pw_aff manage(__isl_take isl_multi_union_pw_aff *ptr);
602
603
  isl_multi_union_pw_aff *ptr = nullptr;
604
605
  inline explicit multi_union_pw_aff(__isl_take isl_multi_union_pw_aff *ptr);
606
607
public:
608
  inline /* implicit */ multi_union_pw_aff();
609
  inline /* implicit */ multi_union_pw_aff(const isl::multi_union_pw_aff &obj);
610
  inline /* implicit */ multi_union_pw_aff(std::nullptr_t);
611
  inline /* implicit */ multi_union_pw_aff(isl::union_pw_aff upa);
612
  inline /* implicit */ multi_union_pw_aff(isl::multi_pw_aff mpa);
613
  inline explicit multi_union_pw_aff(isl::union_pw_multi_aff upma);
614
  inline explicit multi_union_pw_aff(isl::ctx ctx, const std::string &str);
615
  inline isl::multi_union_pw_aff &operator=(isl::multi_union_pw_aff obj);
616
  inline ~multi_union_pw_aff();
617
  inline __isl_give isl_multi_union_pw_aff *copy() const &;
618
  inline __isl_give isl_multi_union_pw_aff *copy() && = delete;
619
  inline __isl_keep isl_multi_union_pw_aff *get() const;
620
  inline __isl_give isl_multi_union_pw_aff *release();
621
  inline __isl_keep isl_multi_union_pw_aff *keep() const;
622
  inline __isl_give isl_multi_union_pw_aff *take();
623
  inline explicit operator bool() const;
624
  inline isl::ctx get_ctx() const;
625
  inline bool is_null() const;
626
  inline std::string to_str() const;
627
  inline isl::multi_union_pw_aff add(isl::multi_union_pw_aff multi2) const;
628
  inline isl::multi_union_pw_aff flat_range_product(isl::multi_union_pw_aff multi2) const;
629
  inline isl::union_pw_aff get_union_pw_aff(int pos) const;
630
  inline isl::multi_union_pw_aff pullback(isl::union_pw_multi_aff upma) const;
631
  inline isl::multi_union_pw_aff range_product(isl::multi_union_pw_aff multi2) const;
632
  inline isl::multi_union_pw_aff union_add(isl::multi_union_pw_aff mupa2) const;
633
};
634
635
// declarations for isl::multi_val
636
inline isl::multi_val manage(__isl_take isl_multi_val *ptr);
637
638
inline isl::multi_val give(__isl_take isl_multi_val *ptr);
639
640
class multi_val {
641
  friend inline isl::multi_val manage(__isl_take isl_multi_val *ptr);
642
643
  isl_multi_val *ptr = nullptr;
644
645
  inline explicit multi_val(__isl_take isl_multi_val *ptr);
646
647
public:
648
  inline /* implicit */ multi_val();
649
  inline /* implicit */ multi_val(const isl::multi_val &obj);
650
  inline /* implicit */ multi_val(std::nullptr_t);
651
  inline isl::multi_val &operator=(isl::multi_val obj);
652
  inline ~multi_val();
653
  inline __isl_give isl_multi_val *copy() const &;
654
  inline __isl_give isl_multi_val *copy() && = delete;
655
  inline __isl_keep isl_multi_val *get() const;
656
  inline __isl_give isl_multi_val *release();
657
  inline __isl_keep isl_multi_val *keep() const;
658
  inline __isl_give isl_multi_val *take();
659
  inline explicit operator bool() const;
660
  inline isl::ctx get_ctx() const;
661
  inline bool is_null() const;
662
  inline std::string to_str() const;
663
  inline isl::multi_val add(isl::multi_val multi2) const;
664
  inline isl::multi_val flat_range_product(isl::multi_val multi2) const;
665
  inline isl::val get_val(int pos) const;
666
  inline isl::multi_val product(isl::multi_val multi2) const;
667
  inline isl::multi_val range_product(isl::multi_val multi2) const;
668
};
669
670
// declarations for isl::point
671
inline isl::point manage(__isl_take isl_point *ptr);
672
673
inline isl::point give(__isl_take isl_point *ptr);
674
675
class point {
676
  friend inline isl::point manage(__isl_take isl_point *ptr);
677
678
  isl_point *ptr = nullptr;
679
680
  inline explicit point(__isl_take isl_point *ptr);
681
682
public:
683
  inline /* implicit */ point();
684
  inline /* implicit */ point(const isl::point &obj);
685
  inline /* implicit */ point(std::nullptr_t);
686
  inline explicit point(isl::space dim);
687
  inline isl::point &operator=(isl::point obj);
688
  inline ~point();
689
  inline __isl_give isl_point *copy() const &;
690
  inline __isl_give isl_point *copy() && = delete;
691
  inline __isl_keep isl_point *get() const;
692
  inline __isl_give isl_point *release();
693
  inline __isl_keep isl_point *keep() const;
694
  inline __isl_give isl_point *take();
695
  inline explicit operator bool() const;
696
  inline isl::ctx get_ctx() const;
697
  inline bool is_null() const;
698
  inline std::string to_str() const;
699
};
700
701
// declarations for isl::pw_aff
702
inline isl::pw_aff manage(__isl_take isl_pw_aff *ptr);
703
704
inline isl::pw_aff give(__isl_take isl_pw_aff *ptr);
705
706
class pw_aff {
707
  friend inline isl::pw_aff manage(__isl_take isl_pw_aff *ptr);
708
709
  isl_pw_aff *ptr = nullptr;
710
711
  inline explicit pw_aff(__isl_take isl_pw_aff *ptr);
712
713
public:
714
  inline /* implicit */ pw_aff();
715
  inline /* implicit */ pw_aff(const isl::pw_aff &obj);
716
  inline /* implicit */ pw_aff(std::nullptr_t);
717
  inline /* implicit */ pw_aff(isl::aff aff);
718
  inline explicit pw_aff(isl::local_space ls);
719
  inline explicit pw_aff(isl::set domain, isl::val v);
720
  inline explicit pw_aff(isl::ctx ctx, const std::string &str);
721
  inline isl::pw_aff &operator=(isl::pw_aff obj);
722
  inline ~pw_aff();
723
  inline __isl_give isl_pw_aff *copy() const &;
724
  inline __isl_give isl_pw_aff *copy() && = delete;
725
  inline __isl_keep isl_pw_aff *get() const;
726
  inline __isl_give isl_pw_aff *release();
727
  inline __isl_keep isl_pw_aff *keep() const;
728
  inline __isl_give isl_pw_aff *take();
729
  inline explicit operator bool() const;
730
  inline isl::ctx get_ctx() const;
731
  inline bool is_null() const;
732
  inline std::string to_str() const;
733
  inline isl::pw_aff add(isl::pw_aff pwaff2) const;
734
  inline isl::stat foreach_piece(const std::function<isl::stat(isl::set, isl::aff)> &fn) const;
735
  inline isl::space get_space() const;
736
  inline isl::boolean is_cst() const;
737
  inline isl::pw_aff mul(isl::pw_aff pwaff2) const;
738
  inline isl::pw_aff neg() const;
739
  inline isl::pw_aff pullback(isl::multi_aff ma) const;
740
  inline isl::pw_aff pullback(isl::pw_multi_aff pma) const;
741
  inline isl::pw_aff pullback(isl::multi_pw_aff mpa) const;
742
  inline isl::pw_aff sub(isl::pw_aff pwaff2) const;
743
  inline isl::pw_aff union_add(isl::pw_aff pwaff2) const;
744
};
745
746
// declarations for isl::pw_multi_aff
747
inline isl::pw_multi_aff manage(__isl_take isl_pw_multi_aff *ptr);
748
749
inline isl::pw_multi_aff give(__isl_take isl_pw_multi_aff *ptr);
750
751
class pw_multi_aff {
752
  friend inline isl::pw_multi_aff manage(__isl_take isl_pw_multi_aff *ptr);
753
754
  isl_pw_multi_aff *ptr = nullptr;
755
756
  inline explicit pw_multi_aff(__isl_take isl_pw_multi_aff *ptr);
757
758
public:
759
  inline /* implicit */ pw_multi_aff();
760
  inline /* implicit */ pw_multi_aff(const isl::pw_multi_aff &obj);
761
  inline /* implicit */ pw_multi_aff(std::nullptr_t);
762
  inline explicit pw_multi_aff(isl::ctx ctx, const std::string &str);
763
  inline /* implicit */ pw_multi_aff(isl::multi_aff ma);
764
  inline /* implicit */ pw_multi_aff(isl::pw_aff pa);
765
  inline isl::pw_multi_aff &operator=(isl::pw_multi_aff obj);
766
  inline ~pw_multi_aff();
767
  inline __isl_give isl_pw_multi_aff *copy() const &;
768
  inline __isl_give isl_pw_multi_aff *copy() && = delete;
769
  inline __isl_keep isl_pw_multi_aff *get() const;
770
  inline __isl_give isl_pw_multi_aff *release();
771
  inline __isl_keep isl_pw_multi_aff *keep() const;
772
  inline __isl_give isl_pw_multi_aff *take();
773
  inline explicit operator bool() const;
774
  inline isl::ctx get_ctx() const;
775
  inline bool is_null() const;
776
  inline std::string to_str() const;
777
  inline isl::pw_multi_aff add(isl::pw_multi_aff pma2) const;
778
  inline isl::pw_multi_aff flat_range_product(isl::pw_multi_aff pma2) const;
779
  inline isl::pw_multi_aff product(isl::pw_multi_aff pma2) const;
780
  inline isl::pw_multi_aff pullback(isl::multi_aff ma) const;
781
  inline isl::pw_multi_aff pullback(isl::pw_multi_aff pma2) const;
782
  inline isl::pw_multi_aff range_product(isl::pw_multi_aff pma2) const;
783
  inline isl::pw_multi_aff union_add(isl::pw_multi_aff pma2) const;
784
};
785
786
// declarations for isl::schedule
787
inline isl::schedule manage(__isl_take isl_schedule *ptr);
788
789
inline isl::schedule give(__isl_take isl_schedule *ptr);
790
791
class schedule {
792
  friend inline isl::schedule manage(__isl_take isl_schedule *ptr);
793
794
  isl_schedule *ptr = nullptr;
795
796
  inline explicit schedule(__isl_take isl_schedule *ptr);
797
798
public:
799
  inline /* implicit */ schedule();
800
  inline /* implicit */ schedule(const isl::schedule &obj);
801
  inline /* implicit */ schedule(std::nullptr_t);
802
  inline explicit schedule(isl::ctx ctx, const std::string &str);
803
  inline isl::schedule &operator=(isl::schedule obj);
804
  inline ~schedule();
805
  inline __isl_give isl_schedule *copy() const &;
806
  inline __isl_give isl_schedule *copy() && = delete;
807
  inline __isl_keep isl_schedule *get() const;
808
  inline __isl_give isl_schedule *release();
809
  inline __isl_keep isl_schedule *keep() const;
810
  inline __isl_give isl_schedule *take();
811
  inline explicit operator bool() const;
812
  inline isl::ctx get_ctx() const;
813
  inline bool is_null() const;
814
  inline std::string to_str() const;
815
  inline isl::union_map get_map() const;
816
  inline isl::schedule_node get_root() const;
817
  inline isl::schedule pullback(isl::union_pw_multi_aff upma) const;
818
};
819
820
// declarations for isl::schedule_constraints
821
inline isl::schedule_constraints manage(__isl_take isl_schedule_constraints *ptr);
822
823
inline isl::schedule_constraints give(__isl_take isl_schedule_constraints *ptr);
824
825
class schedule_constraints {
826
  friend inline isl::schedule_constraints manage(__isl_take isl_schedule_constraints *ptr);
827
828
  isl_schedule_constraints *ptr = nullptr;
829
830
  inline explicit schedule_constraints(__isl_take isl_schedule_constraints *ptr);
831
832
public:
833
  inline /* implicit */ schedule_constraints();
834
  inline /* implicit */ schedule_constraints(const isl::schedule_constraints &obj);
835
  inline /* implicit */ schedule_constraints(std::nullptr_t);
836
  inline explicit schedule_constraints(isl::ctx ctx, const std::string &str);
837
  inline isl::schedule_constraints &operator=(isl::schedule_constraints obj);
838
  inline ~schedule_constraints();
839
  inline __isl_give isl_schedule_constraints *copy() const &;
840
  inline __isl_give isl_schedule_constraints *copy() && = delete;
841
  inline __isl_keep isl_schedule_constraints *get() const;
842
  inline __isl_give isl_schedule_constraints *release();
843
  inline __isl_keep isl_schedule_constraints *keep() const;
844
  inline __isl_give isl_schedule_constraints *take();
845
  inline explicit operator bool() const;
846
  inline isl::ctx get_ctx() const;
847
  inline bool is_null() const;
848
  inline std::string to_str() const;
849
  inline isl::union_map get_coincidence() const;
850
  inline isl::union_map get_conditional_validity() const;
851
  inline isl::union_map get_conditional_validity_condition() const;
852
  inline isl::set get_context() const;
853
  inline isl::union_set get_domain() const;
854
  inline isl::union_map get_proximity() const;
855
  inline isl::union_map get_validity() const;
856
};
857
858
// declarations for isl::schedule_node
859
inline isl::schedule_node manage(__isl_take isl_schedule_node *ptr);
860
861
inline isl::schedule_node give(__isl_take isl_schedule_node *ptr);
862
863
class schedule_node {
864
  friend inline isl::schedule_node manage(__isl_take isl_schedule_node *ptr);
865
866
  isl_schedule_node *ptr = nullptr;
867
868
  inline explicit schedule_node(__isl_take isl_schedule_node *ptr);
869
870
public:
871
  inline /* implicit */ schedule_node();
872
  inline /* implicit */ schedule_node(const isl::schedule_node &obj);
873
  inline /* implicit */ schedule_node(std::nullptr_t);
874
  inline isl::schedule_node &operator=(isl::schedule_node obj);
875
  inline ~schedule_node();
876
  inline __isl_give isl_schedule_node *copy() const &;
877
  inline __isl_give isl_schedule_node *copy() && = delete;
878
  inline __isl_keep isl_schedule_node *get() const;
879
  inline __isl_give isl_schedule_node *release();
880
  inline __isl_keep isl_schedule_node *keep() const;
881
  inline __isl_give isl_schedule_node *take();
882
  inline explicit operator bool() const;
883
  inline isl::ctx get_ctx() const;
884
  inline bool is_null() const;
885
  inline std::string to_str() const;
886
  inline isl::boolean band_member_get_coincident(int pos) const;
887
  inline isl::schedule_node band_member_set_coincident(int pos, int coincident) const;
888
  inline isl::schedule_node child(int pos) const;
889
  inline isl::multi_union_pw_aff get_prefix_schedule_multi_union_pw_aff() const;
890
  inline isl::union_map get_prefix_schedule_union_map() const;
891
  inline isl::union_pw_multi_aff get_prefix_schedule_union_pw_multi_aff() const;
892
  inline isl::schedule get_schedule() const;
893
  inline isl::schedule_node parent() const;
894
};
895
896
// declarations for isl::set
897
inline isl::set manage(__isl_take isl_set *ptr);
898
899
inline isl::set give(__isl_take isl_set *ptr);
900
901
class set {
902
  friend inline isl::set manage(__isl_take isl_set *ptr);
903
904
  isl_set *ptr = nullptr;
905
906
  inline explicit set(__isl_take isl_set *ptr);
907
908
public:
909
  inline /* implicit */ set();
910
  inline /* implicit */ set(const isl::set &obj);
911
  inline /* implicit */ set(std::nullptr_t);
912
  inline explicit set(isl::union_set uset);
913
  inline explicit set(isl::ctx ctx, const std::string &str);
914
  inline /* implicit */ set(isl::basic_set bset);
915
  inline /* implicit */ set(isl::point pnt);
916
  inline isl::set &operator=(isl::set obj);
917
  inline ~set();
918
  inline __isl_give isl_set *copy() const &;
919
  inline __isl_give isl_set *copy() && = delete;
920
  inline __isl_keep isl_set *get() const;
921
  inline __isl_give isl_set *release();
922
  inline __isl_keep isl_set *keep() const;
923
  inline __isl_give isl_set *take();
924
  inline explicit operator bool() const;
925
  inline isl::ctx get_ctx() const;
926
  inline bool is_null() const;
927
  inline std::string to_str() const;
928
  inline isl::set add_dims(isl::dim type, unsigned int n) const;
929
  inline isl::basic_set affine_hull() const;
930
  inline isl::set apply(isl::map map) const;
931
  inline isl::set coalesce() const;
932
  inline isl::set complement() const;
933
  inline isl::set detect_equalities() const;
934
  inline unsigned int dim(isl::dim type) const;
935
  inline isl::pw_aff dim_max(int pos) const;
936
  inline isl::pw_aff dim_min(int pos) const;
937
  inline isl::set flatten() const;
938
  inline isl::stat foreach_basic_set(const std::function<isl::stat(isl::basic_set)> &fn) const;
939
  inline isl::set gist(isl::set context) const;
940
  inline isl::map identity() const;
941
  inline isl::set intersect(isl::set set2) const;
942
  inline isl::set intersect_params(isl::set params) const;
943
  inline isl::boolean is_bounded() const;
944
  inline isl::boolean is_disjoint(const isl::set &set2) const;
945
  inline isl::boolean is_empty() const;
946
  inline isl::boolean is_equal(const isl::set &set2) const;
947
  inline isl::boolean is_strict_subset(const isl::set &set2) const;
948
  inline isl::boolean is_subset(const isl::set &set2) const;
949
  inline isl::boolean is_wrapping() const;
950
  inline isl::set lexmax() const;
951
  inline isl::set lexmin() const;
952
  inline isl::val max_val(const isl::aff &obj) const;
953
  inline isl::val min_val(const isl::aff &obj) const;
954
  inline isl::basic_set polyhedral_hull() const;
955
  inline isl::set project_out(isl::dim type, unsigned int first, unsigned int n) const;
956
  inline isl::basic_set sample() const;
957
  inline isl::point sample_point() const;
958
  inline isl::set subtract(isl::set set2) const;
959
  inline isl::set unite(isl::set set2) const;
960
  static inline isl::set universe(isl::space dim);
961
  inline isl::basic_set unshifted_simple_hull() const;
962
};
963
964
// declarations for isl::space
965
inline isl::space manage(__isl_take isl_space *ptr);
966
967
inline isl::space give(__isl_take isl_space *ptr);
968
969
class space {
970
  friend inline isl::space manage(__isl_take isl_space *ptr);
971
972
  isl_space *ptr = nullptr;
973
974
  inline explicit space(__isl_take isl_space *ptr);
975
976
public:
977
  inline /* implicit */ space();
978
  inline /* implicit */ space(const isl::space &obj);
979
  inline /* implicit */ space(std::nullptr_t);
980
  inline explicit space(isl::ctx ctx, unsigned int nparam, unsigned int n_in, unsigned int n_out);
981
  inline explicit space(isl::ctx ctx, unsigned int nparam, unsigned int dim);
982
  inline isl::space &operator=(isl::space obj);
983
  inline ~space();
984
  inline __isl_give isl_space *copy() const &;
985
  inline __isl_give isl_space *copy() && = delete;
986
  inline __isl_keep isl_space *get() const;
987
  inline __isl_give isl_space *release();
988
  inline __isl_keep isl_space *keep() const;
989
  inline __isl_give isl_space *take();
990
  inline explicit operator bool() const;
991
  inline isl::ctx get_ctx() const;
992
  inline bool is_null() const;
993
  inline std::string to_str() const;
994
  inline isl::space domain() const;
995
  inline isl::boolean is_equal(const isl::space &space2) const;
996
  inline isl::space params() const;
997
  inline isl::space set_from_params() const;
998
};
999
1000
// declarations for isl::union_access_info
1001
inline isl::union_access_info manage(__isl_take isl_union_access_info *ptr);
1002
1003
inline isl::union_access_info give(__isl_take isl_union_access_info *ptr);
1004
1005
class union_access_info {
1006
  friend inline isl::union_access_info manage(__isl_take isl_union_access_info *ptr);
1007
1008
  isl_union_access_info *ptr = nullptr;
1009
1010
  inline explicit union_access_info(__isl_take isl_union_access_info *ptr);
1011
1012
public:
1013
  inline /* implicit */ union_access_info();
1014
  inline /* implicit */ union_access_info(const isl::union_access_info &obj);
1015
  inline /* implicit */ union_access_info(std::nullptr_t);
1016
  inline explicit union_access_info(isl::union_map sink);
1017
  inline isl::union_access_info &operator=(isl::union_access_info obj);
1018
  inline ~union_access_info();
1019
  inline __isl_give isl_union_access_info *copy() const &;
1020
  inline __isl_give isl_union_access_info *copy() && = delete;
1021
  inline __isl_keep isl_union_access_info *get() const;
1022
  inline __isl_give isl_union_access_info *release();
1023
  inline __isl_keep isl_union_access_info *keep() const;
1024
  inline __isl_give isl_union_access_info *take();
1025
  inline explicit operator bool() const;
1026
  inline isl::ctx get_ctx() const;
1027
  inline bool is_null() const;
1028
  inline std::string to_str() const;
1029
  inline isl::union_flow compute_flow() const;
1030
  inline isl::union_access_info set_may_source(isl::union_map may_source) const;
1031
  inline isl::union_access_info set_must_source(isl::union_map must_source) const;
1032
  inline isl::union_access_info set_schedule(isl::schedule schedule) const;
1033
  inline isl::union_access_info set_schedule_map(isl::union_map schedule_map) const;
1034
};
1035
1036
// declarations for isl::union_flow
1037
inline isl::union_flow manage(__isl_take isl_union_flow *ptr);
1038
1039
inline isl::union_flow give(__isl_take isl_union_flow *ptr);
1040
1041
class union_flow {
1042
  friend inline isl::union_flow manage(__isl_take isl_union_flow *ptr);
1043
1044
  isl_union_flow *ptr = nullptr;
1045
1046
  inline explicit union_flow(__isl_take isl_union_flow *ptr);
1047
1048
public:
1049
  inline /* implicit */ union_flow();
1050
  inline /* implicit */ union_flow(const isl::union_flow &obj);
1051
  inline /* implicit */ union_flow(std::nullptr_t);
1052
  inline isl::union_flow &operator=(isl::union_flow obj);
1053
  inline ~union_flow();
1054
  inline __isl_give isl_union_flow *copy() const &;
1055
  inline __isl_give isl_union_flow *copy() && = delete;
1056
  inline __isl_keep isl_union_flow *get() const;
1057
  inline __isl_give isl_union_flow *release();
1058
  inline __isl_keep isl_union_flow *keep() const;
1059
  inline __isl_give isl_union_flow *take();
1060
  inline explicit operator bool() const;
1061
  inline isl::ctx get_ctx() const;
1062
  inline bool is_null() const;
1063
  inline std::string to_str() const;
1064
  inline isl::union_map get_full_may_dependence() const;
1065
  inline isl::union_map get_full_must_dependence() const;
1066
  inline isl::union_map get_may_dependence() const;
1067
  inline isl::union_map get_may_no_source() const;
1068
  inline isl::union_map get_must_dependence() const;
1069
  inline isl::union_map get_must_no_source() const;
1070
};
1071
1072
// declarations for isl::union_map
1073
inline isl::union_map manage(__isl_take isl_union_map *ptr);
1074
1075
inline isl::union_map give(__isl_take isl_union_map *ptr);
1076
1077
class union_map {
1078
  friend inline isl::union_map manage(__isl_take isl_union_map *ptr);
1079
1080
  isl_union_map *ptr = nullptr;
1081
1082
  inline explicit union_map(__isl_take isl_union_map *ptr);
1083
1084
public:
1085
  inline /* implicit */ union_map();
1086
  inline /* implicit */ union_map(const isl::union_map &obj);
1087
  inline /* implicit */ union_map(std::nullptr_t);
1088
  inline explicit union_map(isl::ctx ctx, const std::string &str);
1089
  inline explicit union_map(isl::union_pw_aff upa);
1090
  inline /* implicit */ union_map(isl::basic_map bmap);
1091
  inline /* implicit */ union_map(isl::map map);
1092
  inline isl::union_map &operator=(isl::union_map obj);
1093
  inline ~union_map();
1094
  inline __isl_give isl_union_map *copy() const &;
1095
  inline __isl_give isl_union_map *copy() && = delete;
1096
  inline __isl_keep isl_union_map *get() const;
1097
  inline __isl_give isl_union_map *release();
1098
  inline __isl_keep isl_union_map *keep() const;
1099
  inline __isl_give isl_union_map *take();
1100
  inline explicit operator bool() const;
1101
  inline isl::ctx get_ctx() const;
1102
  inline bool is_null() const;
1103
  inline std::string to_str() const;
1104
  inline isl::union_map add_map(isl::map map) const;
1105
  inline isl::union_map affine_hull() const;
1106
  inline isl::union_map apply_domain(isl::union_map umap2) const;
1107
  inline isl::union_map apply_range(isl::union_map umap2) const;
1108
  inline isl::union_map coalesce() const;
1109
  inline isl::union_map compute_divs() const;
1110
  inline isl::union_set deltas() const;
1111
  inline isl::union_map detect_equalities() const;
1112
  inline isl::union_set domain() const;
1113
  inline isl::union_map domain_factor_domain() const;
1114
  inline isl::union_map domain_factor_range() const;
1115
  inline isl::union_map domain_map() const;
1116
  inline isl::union_pw_multi_aff domain_map_union_pw_multi_aff() const;
1117
  inline isl::union_map domain_product(isl::union_map umap2) const;
1118
  static inline isl::union_map empty(isl::space dim);
1119
  inline isl::union_map factor_domain() const;
1120
  inline isl::union_map factor_range() const;
1121
  inline isl::union_map fixed_power(isl::val exp) const;
1122
  inline isl::union_map flat_range_product(isl::union_map umap2) const;
1123
  inline isl::stat foreach_map(const std::function<isl::stat(isl::map)> &fn) const;
1124
  static inline isl::union_map from(isl::union_pw_multi_aff upma);
1125
  static inline isl::union_map from(isl::multi_union_pw_aff mupa);
1126
  static inline isl::union_map from_domain_and_range(isl::union_set domain, isl::union_set range);
1127
  inline isl::space get_space() const;
1128
  inline isl::union_map gist(isl::union_map context) const;
1129
  inline isl::union_map gist_domain(isl::union_set uset) const;
1130
  inline isl::union_map gist_params(isl::set set) const;
1131
  inline isl::union_map gist_range(isl::union_set uset) const;
1132
  inline isl::union_map intersect(isl::union_map umap2) const;
1133
  inline isl::union_map intersect_domain(isl::union_set uset) const;
1134
  inline isl::union_map intersect_params(isl::set set) const;
1135
  inline isl::union_map intersect_range(isl::union_set uset) const;
1136
  inline isl::boolean is_bijective() const;
1137
  inline isl::boolean is_empty() const;
1138
  inline isl::boolean is_equal(const isl::union_map &umap2) const;
1139
  inline isl::boolean is_injective() const;
1140
  inline isl::boolean is_single_valued() const;
1141
  inline isl::boolean is_strict_subset(const isl::union_map &umap2) const;
1142
  inline isl::boolean is_subset(const isl::union_map &umap2) const;
1143
  inline isl::union_map lexmax() const;
1144
  inline isl::union_map lexmin() const;
1145
  inline isl::union_map polyhedral_hull() const;
1146
  inline isl::union_map product(isl::union_map umap2) const;
1147
  inline isl::union_set range() const;
1148
  inline isl::union_map range_factor_domain() const;
1149
  inline isl::union_map range_factor_range() const;
1150
  inline isl::union_map range_map() const;
1151
  inline isl::union_map range_product(isl::union_map umap2) const;
1152
  inline isl::union_map reverse() const;
1153
  inline isl::union_map subtract(isl::union_map umap2) const;
1154
  inline isl::union_map subtract_domain(isl::union_set dom) const;
1155
  inline isl::union_map subtract_range(isl::union_set dom) const;
1156
  inline isl::union_map unite(isl::union_map umap2) const;
1157
  inline isl::union_set wrap() const;
1158
  inline isl::union_map zip() const;
1159
};
1160
1161
// declarations for isl::union_pw_aff
1162
inline isl::union_pw_aff manage(__isl_take isl_union_pw_aff *ptr);
1163
1164
inline isl::union_pw_aff give(__isl_take isl_union_pw_aff *ptr);
1165
1166
class union_pw_aff {
1167
  friend inline isl::union_pw_aff manage(__isl_take isl_union_pw_aff *ptr);
1168
1169
  isl_union_pw_aff *ptr = nullptr;
1170
1171
  inline explicit union_pw_aff(__isl_take isl_union_pw_aff *ptr);
1172
1173
public:
1174
  inline /* implicit */ union_pw_aff();
1175
  inline /* implicit */ union_pw_aff(const isl::union_pw_aff &obj);
1176
  inline /* implicit */ union_pw_aff(std::nullptr_t);
1177
  inline /* implicit */ union_pw_aff(isl::pw_aff pa);
1178
  inline explicit union_pw_aff(isl::union_set domain, isl::val v);
1179
  inline explicit union_pw_aff(isl::ctx ctx, const std::string &str);
1180
  inline isl::union_pw_aff &operator=(isl::union_pw_aff obj);
1181
  inline ~union_pw_aff();
1182
  inline __isl_give isl_union_pw_aff *copy() const &;
1183
  inline __isl_give isl_union_pw_aff *copy() && = delete;
1184
  inline __isl_keep isl_union_pw_aff *get() const;
1185
  inline __isl_give isl_union_pw_aff *release();
1186
  inline __isl_keep isl_union_pw_aff *keep() const;
1187
  inline __isl_give isl_union_pw_aff *take();
1188
  inline explicit operator bool() const;
1189
  inline isl::ctx get_ctx() const;
1190
  inline bool is_null() const;
1191
  inline std::string to_str() const;
1192
  inline isl::union_pw_aff add(isl::union_pw_aff upa2) const;
1193
  static inline isl::union_pw_aff empty(isl::space space);
1194
  inline isl::stat foreach_pw_aff(const std::function<isl::stat(isl::pw_aff)> &fn) const;
1195
  inline isl::space get_space() const;
1196
  inline isl::union_pw_aff pullback(isl::union_pw_multi_aff upma) const;
1197
  inline isl::union_pw_aff sub(isl::union_pw_aff upa2) const;
1198
  inline isl::union_pw_aff union_add(isl::union_pw_aff upa2) const;
1199
};
1200
1201
// declarations for isl::union_pw_multi_aff
1202
inline isl::union_pw_multi_aff manage(__isl_take isl_union_pw_multi_aff *ptr);
1203
1204
inline isl::union_pw_multi_aff give(__isl_take isl_union_pw_multi_aff *ptr);
1205
1206
class union_pw_multi_aff {
1207
  friend inline isl::union_pw_multi_aff manage(__isl_take isl_union_pw_multi_aff *ptr);
1208
1209
  isl_union_pw_multi_aff *ptr = nullptr;
1210
1211
  inline explicit union_pw_multi_aff(__isl_take isl_union_pw_multi_aff *ptr);
1212
1213
public:
1214
  inline /* implicit */ union_pw_multi_aff();
1215
  inline /* implicit */ union_pw_multi_aff(const isl::union_pw_multi_aff &obj);
1216
  inline /* implicit */ union_pw_multi_aff(std::nullptr_t);
1217
  inline /* implicit */ union_pw_multi_aff(isl::pw_multi_aff pma);
1218
  inline explicit union_pw_multi_aff(isl::union_set uset);
1219
  inline explicit union_pw_multi_aff(isl::union_map umap);
1220
  inline explicit union_pw_multi_aff(isl::ctx ctx, const std::string &str);
1221
  inline /* implicit */ union_pw_multi_aff(isl::union_pw_aff upa);
1222
  inline isl::union_pw_multi_aff &operator=(isl::union_pw_multi_aff obj);
1223
  inline ~union_pw_multi_aff();
1224
  inline __isl_give isl_union_pw_multi_aff *copy() const &;
1225
  inline __isl_give isl_union_pw_multi_aff *copy() && = delete;
1226
  inline __isl_keep isl_union_pw_multi_aff *get() const;
1227
  inline __isl_give isl_union_pw_multi_aff *release();
1228
  inline __isl_keep isl_union_pw_multi_aff *keep() const;
1229
  inline __isl_give isl_union_pw_multi_aff *take();
1230
  inline explicit operator bool() const;
1231
  inline isl::ctx get_ctx() const;
1232
  inline bool is_null() const;
1233
  inline std::string to_str() const;
1234
  inline isl::union_pw_multi_aff add(isl::union_pw_multi_aff upma2) const;
1235
  inline isl::union_pw_multi_aff flat_range_product(isl::union_pw_multi_aff upma2) const;
1236
  inline isl::union_pw_multi_aff pullback(isl::union_pw_multi_aff upma2) const;
1237
  inline isl::union_pw_multi_aff union_add(isl::union_pw_multi_aff upma2) const;
1238
};
1239
1240
// declarations for isl::union_set
1241
inline isl::union_set manage(__isl_take isl_union_set *ptr);
1242
1243
inline isl::union_set give(__isl_take isl_union_set *ptr);
1244
1245
class union_set {
1246
  friend inline isl::union_set manage(__isl_take isl_union_set *ptr);
1247
1248
  isl_union_set *ptr = nullptr;
1249
1250
  inline explicit union_set(__isl_take isl_union_set *ptr);
1251
1252
public:
1253
  inline /* implicit */ union_set();
1254
  inline /* implicit */ union_set(const isl::union_set &obj);
1255
  inline /* implicit */ union_set(std::nullptr_t);
1256
  inline /* implicit */ union_set(isl::basic_set bset);
1257
  inline /* implicit */ union_set(isl::set set);
1258
  inline /* implicit */ union_set(isl::point pnt);
1259
  inline explicit union_set(isl::ctx ctx, const std::string &str);
1260
  inline isl::union_set &operator=(isl::union_set obj);
1261
  inline ~union_set();
1262
  inline __isl_give isl_union_set *copy() const &;
1263
  inline __isl_give isl_union_set *copy() && = delete;
1264
  inline __isl_keep isl_union_set *get() const;
1265
  inline __isl_give isl_union_set *release();
1266
  inline __isl_keep isl_union_set *keep() const;
1267
  inline __isl_give isl_union_set *take();
1268
  inline explicit operator bool() const;
1269
  inline isl::ctx get_ctx() const;
1270
  inline bool is_null() const;
1271
  inline std::string to_str() const;
1272
  inline isl::union_set affine_hull() const;
1273
  inline isl::union_set apply(isl::union_map umap) const;
1274
  inline isl::union_set coalesce() const;
1275
  inline isl::union_set compute_divs() const;
1276
  inline isl::union_set detect_equalities() const;
1277
  inline isl::stat foreach_point(const std::function<isl::stat(isl::point)> &fn) const;
1278
  inline isl::stat foreach_set(const std::function<isl::stat(isl::set)> &fn) const;
1279
  inline isl::union_set gist(isl::union_set context) const;
1280
  inline isl::union_set gist_params(isl::set set) const;
1281
  inline isl::union_map identity() const;
1282
  inline isl::union_set intersect(isl::union_set uset2) const;
1283
  inline isl::union_set intersect_params(isl::set set) const;
1284
  inline isl::boolean is_empty() const;
1285
  inline isl::boolean is_equal(const isl::union_set &uset2) const;
1286
  inline isl::boolean is_strict_subset(const isl::union_set &uset2) const;
1287
  inline isl::boolean is_subset(const isl::union_set &uset2) const;
1288
  inline isl::union_set lexmax() const;
1289
  inline isl::union_set lexmin() const;
1290
  inline isl::union_set polyhedral_hull() const;
1291
  inline isl::point sample_point() const;
1292
  inline isl::union_set subtract(isl::union_set uset2) const;
1293
  inline isl::union_set unite(isl::union_set uset2) const;
1294
  inline isl::union_map unwrap() const;
1295
};
1296
1297
// declarations for isl::val
1298
inline isl::val manage(__isl_take isl_val *ptr);
1299
1300
inline isl::val give(__isl_take isl_val *ptr);
1301
1302
class val {
1303
  friend inline isl::val manage(__isl_take isl_val *ptr);
1304
1305
  isl_val *ptr = nullptr;
1306
1307
  inline explicit val(__isl_take isl_val *ptr);
1308
1309
public:
1310
  inline /* implicit */ val();
1311
  inline /* implicit */ val(const isl::val &obj);
1312
  inline /* implicit */ val(std::nullptr_t);
1313
  inline explicit val(isl::ctx ctx, long i);
1314
  inline explicit val(isl::ctx ctx, const std::string &str);
1315
  inline isl::val &operator=(isl::val obj);
1316
  inline ~val();
1317
  inline __isl_give isl_val *copy() const &;
1318
  inline __isl_give isl_val *copy() && = delete;
1319
  inline __isl_keep isl_val *get() const;
1320
  inline __isl_give isl_val *release();
1321
  inline __isl_keep isl_val *keep() const;
1322
  inline __isl_give isl_val *take();
1323
  inline explicit operator bool() const;
1324
  inline isl::ctx get_ctx() const;
1325
  inline bool is_null() const;
1326
  inline std::string to_str() const;
1327
  inline isl::val two_exp() const;
1328
  inline isl::val abs() const;
1329
  inline isl::boolean abs_eq(const isl::val &v2) const;
1330
  inline isl::val add(isl::val v2) const;
1331
  inline isl::val add_ui(unsigned long v2) const;
1332
  inline isl::val ceil() const;
1333
  inline int cmp_si(long i) const;
1334
  inline isl::val div(isl::val v2) const;
1335
  inline isl::boolean eq(const isl::val &v2) const;
1336
  inline isl::val floor() const;
1337
  inline isl::val gcd(isl::val v2) const;
1338
  inline isl::boolean ge(const isl::val &v2) const;
1339
  inline isl::boolean gt(const isl::val &v2) const;
1340
  static inline isl::val infty(isl::ctx ctx);
1341
  inline isl::val inv() const;
1342
  inline isl::boolean is_divisible_by(const isl::val &v2) const;
1343
  inline isl::boolean is_infty() const;
1344
  inline isl::boolean is_int() const;
1345
  inline isl::boolean is_nan() const;
1346
  inline isl::boolean is_neg() const;
1347
  inline isl::boolean is_neginfty() const;
1348
  inline isl::boolean is_negone() const;
1349
  inline isl::boolean is_nonneg() const;
1350
  inline isl::boolean is_nonpos() const;
1351
  inline isl::boolean is_one() const;
1352
  inline isl::boolean is_pos() const;
1353
  inline isl::boolean is_rat() const;
1354
  inline isl::boolean is_zero() const;
1355
  inline isl::boolean le(const isl::val &v2) const;
1356
  inline isl::boolean lt(const isl::val &v2) const;
1357
  inline isl::val max(isl::val v2) const;
1358
  inline isl::val min(isl::val v2) const;
1359
  inline isl::val mod(isl::val v2) const;
1360
  inline isl::val mul(isl::val v2) const;
1361
  static inline isl::val nan(isl::ctx ctx);
1362
  inline isl::boolean ne(const isl::val &v2) const;
1363
  inline isl::val neg() const;
1364
  static inline isl::val neginfty(isl::ctx ctx);
1365
  static inline isl::val negone(isl::ctx ctx);
1366
  static inline isl::val one(isl::ctx ctx);
1367
  inline int sgn() const;
1368
  inline isl::val sub(isl::val v2) const;
1369
  inline isl::val sub_ui(unsigned long v2) const;
1370
  inline isl::val trunc() const;
1371
  static inline isl::val zero(isl::ctx ctx);
1372
};
1373
1374
// implementations for isl::aff
1375
1.06k
isl::aff manage(__isl_take isl_aff *ptr) {
1376
1.06k
  return aff(ptr);
1377
1.06k
}
1378
1379
1.04k
isl::aff give(__isl_take isl_aff *ptr) {
1380
1.04k
  return manage(ptr);
1381
1.04k
}
1382
1383
aff::aff()
1384
    : ptr(nullptr) {}
1385
1386
aff::aff(const isl::aff &obj)
1387
23
    : ptr(obj.copy()) {}
1388
1389
aff::aff(std::nullptr_t)
1390
    : ptr(nullptr) {}
1391
1392
aff::aff(__isl_take isl_aff *ptr)
1393
1.06k
    : ptr(ptr) {}
1394
1395
aff::aff(isl::local_space ls) {
1396
  auto res = isl_aff_zero_on_domain(ls.release());
1397
  ptr = res;
1398
}
1399
1400
aff::aff(isl::local_space ls, isl::val val) {
1401
  auto res = isl_aff_val_on_domain(ls.release(), val.release());
1402
  ptr = res;
1403
}
1404
1405
aff::aff(isl::ctx ctx, const std::string &str) {
1406
  auto res = isl_aff_read_from_str(ctx.release(), str.c_str());
1407
  ptr = res;
1408
}
1409
1410
521
aff &aff::operator=(isl::aff obj) {
1411
521
  std::swap(this->ptr, obj.ptr);
1412
521
  return *this;
1413
521
}
1414
1415
1.08k
aff::~aff() {
1416
1.08k
  if (ptr)
1417
46
    isl_aff_free(ptr);
1418
1.08k
}
1419
1420
23
__isl_give isl_aff *aff::copy() const & {
1421
23
  return isl_aff_copy(ptr);
1422
23
}
1423
1424
45
__isl_keep isl_aff *aff::get() const {
1425
45
  return ptr;
1426
45
}
1427
1428
1.04k
__isl_give isl_aff *aff::release() {
1429
1.04k
  isl_aff *tmp = ptr;
1430
1.04k
  ptr = nullptr;
1431
1.04k
  return tmp;
1432
1.04k
}
1433
1434
0
__isl_keep isl_aff *aff::keep() const {
1435
0
  return get();
1436
0
}
1437
1438
1.04k
__isl_give isl_aff *aff::take() {
1439
1.04k
  return release();
1440
1.04k
}
1441
1442
0
aff::operator bool() const {
1443
0
  return !is_null();
1444
0
}
1445
1446
0
isl::ctx aff::get_ctx() const {
1447
0
  return isl::ctx(isl_aff_get_ctx(ptr));
1448
0
}
1449
1450
0
bool aff::is_null() const {
1451
0
  return ptr == nullptr;
1452
0
}
1453
1454
0
std::string aff::to_str() const {
1455
0
  char *Tmp = isl_aff_to_str(get());
1456
0
  if (!Tmp)
1457
0
    return "";
1458
0
  std::string S(Tmp);
1459
0
  free(Tmp);
1460
0
  return S;
1461
0
}
1462
1463
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
1464
0
                                     const aff &Obj) {
1465
0
  OS << Obj.to_str();
1466
0
  return OS;
1467
0
}
1468
1469
0
isl::aff aff::add(isl::aff aff2) const {
1470
0
  auto res = isl_aff_add(copy(), aff2.release());
1471
0
  return manage(res);
1472
0
}
1473
1474
22
isl::val aff::get_constant() const {
1475
22
  auto res = isl_aff_get_constant_val(get());
1476
22
  return manage(res);
1477
22
}
1478
1479
23
isl::boolean aff::is_cst() const {
1480
23
  auto res = isl_aff_is_cst(get());
1481
23
  return res;
1482
23
}
1483
1484
0
isl::aff aff::pullback(isl::multi_aff ma) const {
1485
0
  auto res = isl_aff_pullback_multi_aff(copy(), ma.release());
1486
0
  return manage(res);
1487
0
}
1488
1489
// implementations for isl::ast_build
1490
0
isl::ast_build manage(__isl_take isl_ast_build *ptr) {
1491
0
  return ast_build(ptr);
1492
0
}
1493
1494
0
isl::ast_build give(__isl_take isl_ast_build *ptr) {
1495
0
  return manage(ptr);
1496
0
}
1497
1498
ast_build::ast_build()
1499
    : ptr(nullptr) {}
1500
1501
ast_build::ast_build(const isl::ast_build &obj)
1502
    : ptr(obj.copy()) {}
1503
1504
ast_build::ast_build(std::nullptr_t)
1505
    : ptr(nullptr) {}
1506
1507
ast_build::ast_build(__isl_take isl_ast_build *ptr)
1508
    : ptr(ptr) {}
1509
1510
ast_build::ast_build(isl::ctx ctx) {
1511
  auto res = isl_ast_build_alloc(ctx.release());
1512
  ptr = res;
1513
}
1514
1515
0
ast_build &ast_build::operator=(isl::ast_build obj) {
1516
0
  std::swap(this->ptr, obj.ptr);
1517
0
  return *this;
1518
0
}
1519
1520
ast_build::~ast_build() {
1521
  if (ptr)
1522
    isl_ast_build_free(ptr);
1523
}
1524
1525
0
__isl_give isl_ast_build *ast_build::copy() const & {
1526
0
  return isl_ast_build_copy(ptr);
1527
0
}
1528
1529
0
__isl_keep isl_ast_build *ast_build::get() const {
1530
0
  return ptr;
1531
0
}
1532
1533
0
__isl_give isl_ast_build *ast_build::release() {
1534
0
  isl_ast_build *tmp = ptr;
1535
0
  ptr = nullptr;
1536
0
  return tmp;
1537
0
}
1538
1539
0
__isl_keep isl_ast_build *ast_build::keep() const {
1540
0
  return get();
1541
0
}
1542
1543
0
__isl_give isl_ast_build *ast_build::take() {
1544
0
  return release();
1545
0
}
1546
1547
0
ast_build::operator bool() const {
1548
0
  return !is_null();
1549
0
}
1550
1551
0
isl::ctx ast_build::get_ctx() const {
1552
0
  return isl::ctx(isl_ast_build_get_ctx(ptr));
1553
0
}
1554
1555
0
bool ast_build::is_null() const {
1556
0
  return ptr == nullptr;
1557
0
}
1558
1559
0
isl::ast_expr ast_build::access_from(isl::pw_multi_aff pma) const {
1560
0
  auto res = isl_ast_build_access_from_pw_multi_aff(get(), pma.release());
1561
0
  return manage(res);
1562
0
}
1563
1564
0
isl::ast_expr ast_build::access_from(isl::multi_pw_aff mpa) const {
1565
0
  auto res = isl_ast_build_access_from_multi_pw_aff(get(), mpa.release());
1566
0
  return manage(res);
1567
0
}
1568
1569
0
isl::ast_expr ast_build::call_from(isl::pw_multi_aff pma) const {
1570
0
  auto res = isl_ast_build_call_from_pw_multi_aff(get(), pma.release());
1571
0
  return manage(res);
1572
0
}
1573
1574
0
isl::ast_expr ast_build::call_from(isl::multi_pw_aff mpa) const {
1575
0
  auto res = isl_ast_build_call_from_multi_pw_aff(get(), mpa.release());
1576
0
  return manage(res);
1577
0
}
1578
1579
0
isl::ast_expr ast_build::expr_from(isl::set set) const {
1580
0
  auto res = isl_ast_build_expr_from_set(get(), set.release());
1581
0
  return manage(res);
1582
0
}
1583
1584
0
isl::ast_expr ast_build::expr_from(isl::pw_aff pa) const {
1585
0
  auto res = isl_ast_build_expr_from_pw_aff(get(), pa.release());
1586
0
  return manage(res);
1587
0
}
1588
1589
0
isl::ast_build ast_build::from_context(isl::set set) {
1590
0
  auto res = isl_ast_build_from_context(set.release());
1591
0
  return manage(res);
1592
0
}
1593
1594
0
isl::ast_node ast_build::node_from_schedule_map(isl::union_map schedule) const {
1595
0
  auto res = isl_ast_build_node_from_schedule_map(get(), schedule.release());
1596
0
  return manage(res);
1597
0
}
1598
1599
// implementations for isl::ast_expr
1600
0
isl::ast_expr manage(__isl_take isl_ast_expr *ptr) {
1601
0
  return ast_expr(ptr);
1602
0
}
1603
1604
0
isl::ast_expr give(__isl_take isl_ast_expr *ptr) {
1605
0
  return manage(ptr);
1606
0
}
1607
1608
ast_expr::ast_expr()
1609
    : ptr(nullptr) {}
1610
1611
ast_expr::ast_expr(const isl::ast_expr &obj)
1612
    : ptr(obj.copy()) {}
1613
1614
ast_expr::ast_expr(std::nullptr_t)
1615
    : ptr(nullptr) {}
1616
1617
ast_expr::ast_expr(__isl_take isl_ast_expr *ptr)
1618
    : ptr(ptr) {}
1619
1620
0
ast_expr &ast_expr::operator=(isl::ast_expr obj) {
1621
0
  std::swap(this->ptr, obj.ptr);
1622
0
  return *this;
1623
0
}
1624
1625
ast_expr::~ast_expr() {
1626
  if (ptr)
1627
    isl_ast_expr_free(ptr);
1628
}
1629
1630
0
__isl_give isl_ast_expr *ast_expr::copy() const & {
1631
0
  return isl_ast_expr_copy(ptr);
1632
0
}
1633
1634
0
__isl_keep isl_ast_expr *ast_expr::get() const {
1635
0
  return ptr;
1636
0
}
1637
1638
0
__isl_give isl_ast_expr *ast_expr::release() {
1639
0
  isl_ast_expr *tmp = ptr;
1640
0
  ptr = nullptr;
1641
0
  return tmp;
1642
0
}
1643
1644
0
__isl_keep isl_ast_expr *ast_expr::keep() const {
1645
0
  return get();
1646
0
}
1647
1648
0
__isl_give isl_ast_expr *ast_expr::take() {
1649
0
  return release();
1650
0
}
1651
1652
0
ast_expr::operator bool() const {
1653
0
  return !is_null();
1654
0
}
1655
1656
0
isl::ctx ast_expr::get_ctx() const {
1657
0
  return isl::ctx(isl_ast_expr_get_ctx(ptr));
1658
0
}
1659
1660
0
bool ast_expr::is_null() const {
1661
0
  return ptr == nullptr;
1662
0
}
1663
1664
0
std::string ast_expr::to_str() const {
1665
0
  char *Tmp = isl_ast_expr_to_str(get());
1666
0
  if (!Tmp)
1667
0
    return "";
1668
0
  std::string S(Tmp);
1669
0
  free(Tmp);
1670
0
  return S;
1671
0
}
1672
1673
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
1674
0
                                     const ast_expr &Obj) {
1675
0
  OS << Obj.to_str();
1676
0
  return OS;
1677
0
}
1678
1679
0
std::string ast_expr::to_C_str() const {
1680
0
  auto res = isl_ast_expr_to_C_str(get());
1681
0
  std::string tmp(res);
1682
0
  free(res);
1683
0
  return tmp;
1684
0
}
1685
1686
// implementations for isl::ast_node
1687
0
isl::ast_node manage(__isl_take isl_ast_node *ptr) {
1688
0
  return ast_node(ptr);
1689
0
}
1690
1691
0
isl::ast_node give(__isl_take isl_ast_node *ptr) {
1692
0
  return manage(ptr);
1693
0
}
1694
1695
ast_node::ast_node()
1696
    : ptr(nullptr) {}
1697
1698
ast_node::ast_node(const isl::ast_node &obj)
1699
    : ptr(obj.copy()) {}
1700
1701
ast_node::ast_node(std::nullptr_t)
1702
    : ptr(nullptr) {}
1703
1704
ast_node::ast_node(__isl_take isl_ast_node *ptr)
1705
    : ptr(ptr) {}
1706
1707
0
ast_node &ast_node::operator=(isl::ast_node obj) {
1708
0
  std::swap(this->ptr, obj.ptr);
1709
0
  return *this;
1710
0
}
1711
1712
ast_node::~ast_node() {
1713
  if (ptr)
1714
    isl_ast_node_free(ptr);
1715
}
1716
1717
0
__isl_give isl_ast_node *ast_node::copy() const & {
1718
0
  return isl_ast_node_copy(ptr);
1719
0
}
1720
1721
0
__isl_keep isl_ast_node *ast_node::get() const {
1722
0
  return ptr;
1723
0
}
1724
1725
0
__isl_give isl_ast_node *ast_node::release() {
1726
0
  isl_ast_node *tmp = ptr;
1727
0
  ptr = nullptr;
1728
0
  return tmp;
1729
0
}
1730
1731
0
__isl_keep isl_ast_node *ast_node::keep() const {
1732
0
  return get();
1733
0
}
1734
1735
0
__isl_give isl_ast_node *ast_node::take() {
1736
0
  return release();
1737
0
}
1738
1739
0
ast_node::operator bool() const {
1740
0
  return !is_null();
1741
0
}
1742
1743
0
isl::ctx ast_node::get_ctx() const {
1744
0
  return isl::ctx(isl_ast_node_get_ctx(ptr));
1745
0
}
1746
1747
0
bool ast_node::is_null() const {
1748
0
  return ptr == nullptr;
1749
0
}
1750
1751
0
std::string ast_node::to_str() const {
1752
0
  char *Tmp = isl_ast_node_to_str(get());
1753
0
  if (!Tmp)
1754
0
    return "";
1755
0
  std::string S(Tmp);
1756
0
  free(Tmp);
1757
0
  return S;
1758
0
}
1759
1760
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
1761
0
                                     const ast_node &Obj) {
1762
0
  OS << Obj.to_str();
1763
0
  return OS;
1764
0
}
1765
1766
0
std::string ast_node::to_C_str() const {
1767
0
  auto res = isl_ast_node_to_C_str(get());
1768
0
  std::string tmp(res);
1769
0
  free(res);
1770
0
  return tmp;
1771
0
}
1772
1773
// implementations for isl::basic_map
1774
113
isl::basic_map manage(__isl_take isl_basic_map *ptr) {
1775
113
  return basic_map(ptr);
1776
113
}
1777
1778
58
isl::basic_map give(__isl_take isl_basic_map *ptr) {
1779
58
  return manage(ptr);
1780
58
}
1781
1782
basic_map::basic_map()
1783
    : ptr(nullptr) {}
1784
1785
basic_map::basic_map(const isl::basic_map &obj)
1786
53
    : ptr(obj.copy()) {}
1787
1788
basic_map::basic_map(std::nullptr_t)
1789
    : ptr(nullptr) {}
1790
1791
basic_map::basic_map(__isl_take isl_basic_map *ptr)
1792
113
    : ptr(ptr) {}
1793
1794
basic_map::basic_map(isl::ctx ctx, const std::string &str) {
1795
  auto res = isl_basic_map_read_from_str(ctx.release(), str.c_str());
1796
  ptr = res;
1797
}
1798
1799
42
basic_map &basic_map::operator=(isl::basic_map obj) {
1800
42
  std::swap(this->ptr, obj.ptr);
1801
42
  return *this;
1802
42
}
1803
1804
166
basic_map::~basic_map() {
1805
166
  if (ptr)
1806
111
    isl_basic_map_free(ptr);
1807
166
}
1808
1809
59
__isl_give isl_basic_map *basic_map::copy() const & {
1810
59
  return isl_basic_map_copy(ptr);
1811
59
}
1812
1813
54
__isl_keep isl_basic_map *basic_map::get() const {
1814
54
  return ptr;
1815
54
}
1816
1817
55
__isl_give isl_basic_map *basic_map::release() {
1818
55
  isl_basic_map *tmp = ptr;
1819
55
  ptr = nullptr;
1820
55
  return tmp;
1821
55
}
1822
1823
0
__isl_keep isl_basic_map *basic_map::keep() const {
1824
0
  return get();
1825
0
}
1826
1827
54
__isl_give isl_basic_map *basic_map::take() {
1828
54
  return release();
1829
54
}
1830
1831
0
basic_map::operator bool() const {
1832
0
  return !is_null();
1833
0
}
1834
1835
0
isl::ctx basic_map::get_ctx() const {
1836
0
  return isl::ctx(isl_basic_map_get_ctx(ptr));
1837
0
}
1838
1839
0
bool basic_map::is_null() const {
1840
0
  return ptr == nullptr;
1841
0
}
1842
1843
0
std::string basic_map::to_str() const {
1844
0
  char *Tmp = isl_basic_map_to_str(get());
1845
0
  if (!Tmp)
1846
0
    return "";
1847
0
  std::string S(Tmp);
1848
0
  free(Tmp);
1849
0
  return S;
1850
0
}
1851
1852
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
1853
0
                                     const basic_map &Obj) {
1854
0
  OS << Obj.to_str();
1855
0
  return OS;
1856
0
}
1857
1858
0
isl::basic_map basic_map::affine_hull() const {
1859
0
  auto res = isl_basic_map_affine_hull(copy());
1860
0
  return manage(res);
1861
0
}
1862
1863
0
isl::basic_map basic_map::apply_domain(isl::basic_map bmap2) const {
1864
0
  auto res = isl_basic_map_apply_domain(copy(), bmap2.release());
1865
0
  return manage(res);
1866
0
}
1867
1868
0
isl::basic_map basic_map::apply_range(isl::basic_map bmap2) const {
1869
0
  auto res = isl_basic_map_apply_range(copy(), bmap2.release());
1870
0
  return manage(res);
1871
0
}
1872
1873
0
isl::basic_set basic_map::deltas() const {
1874
0
  auto res = isl_basic_map_deltas(copy());
1875
0
  return manage(res);
1876
0
}
1877
1878
0
isl::basic_map basic_map::detect_equalities() const {
1879
0
  auto res = isl_basic_map_detect_equalities(copy());
1880
0
  return manage(res);
1881
0
}
1882
1883
0
isl::basic_map basic_map::fix_si(isl::dim type, unsigned int pos, int value) const {
1884
0
  auto res = isl_basic_map_fix_si(copy(), static_cast<enum isl_dim_type>(type), pos, value);
1885
0
  return manage(res);
1886
0
}
1887
1888
0
isl::basic_map basic_map::flatten() const {
1889
0
  auto res = isl_basic_map_flatten(copy());
1890
0
  return manage(res);
1891
0
}
1892
1893
0
isl::basic_map basic_map::flatten_domain() const {
1894
0
  auto res = isl_basic_map_flatten_domain(copy());
1895
0
  return manage(res);
1896
0
}
1897
1898
0
isl::basic_map basic_map::flatten_range() const {
1899
0
  auto res = isl_basic_map_flatten_range(copy());
1900
0
  return manage(res);
1901
0
}
1902
1903
0
isl::basic_map basic_map::gist(isl::basic_map context) const {
1904
0
  auto res = isl_basic_map_gist(copy(), context.release());
1905
0
  return manage(res);
1906
0
}
1907
1908
0
isl::basic_map basic_map::intersect(isl::basic_map bmap2) const {
1909
0
  auto res = isl_basic_map_intersect(copy(), bmap2.release());
1910
0
  return manage(res);
1911
0
}
1912
1913
0
isl::basic_map basic_map::intersect_domain(isl::basic_set bset) const {
1914
0
  auto res = isl_basic_map_intersect_domain(copy(), bset.release());
1915
0
  return manage(res);
1916
0
}
1917
1918
0
isl::basic_map basic_map::intersect_range(isl::basic_set bset) const {
1919
0
  auto res = isl_basic_map_intersect_range(copy(), bset.release());
1920
0
  return manage(res);
1921
0
}
1922
1923
0
isl::boolean basic_map::is_empty() const {
1924
0
  auto res = isl_basic_map_is_empty(get());
1925
0
  return res;
1926
0
}
1927
1928
0
isl::boolean basic_map::is_equal(const isl::basic_map &bmap2) const {
1929
0
  auto res = isl_basic_map_is_equal(get(), bmap2.get());
1930
0
  return res;
1931
0
}
1932
1933
0
isl::boolean basic_map::is_subset(const isl::basic_map &bmap2) const {
1934
0
  auto res = isl_basic_map_is_subset(get(), bmap2.get());
1935
0
  return res;
1936
0
}
1937
1938
0
isl::map basic_map::lexmax() const {
1939
0
  auto res = isl_basic_map_lexmax(copy());
1940
0
  return manage(res);
1941
0
}
1942
1943
0
isl::map basic_map::lexmin() const {
1944
0
  auto res = isl_basic_map_lexmin(copy());
1945
0
  return manage(res);
1946
0
}
1947
1948
50
isl::val basic_map::plain_get_val_if_fixed(isl::dim type, unsigned int pos) const {
1949
50
  auto res = isl_basic_map_plain_get_val_if_fixed(get(), static_cast<enum isl_dim_type>(type), pos);
1950
50
  return manage(res);
1951
50
}
1952
1953
0
isl::basic_map basic_map::project_out(isl::dim type, unsigned int first, unsigned int n) const {
1954
0
  auto res = isl_basic_map_project_out(copy(), static_cast<enum isl_dim_type>(type), first, n);
1955
0
  return manage(res);
1956
0
}
1957
1958
0
isl::basic_map basic_map::reverse() const {
1959
0
  auto res = isl_basic_map_reverse(copy());
1960
0
  return manage(res);
1961
0
}
1962
1963
0
isl::basic_map basic_map::sample() const {
1964
0
  auto res = isl_basic_map_sample(copy());
1965
0
  return manage(res);
1966
0
}
1967
1968
0
isl::map basic_map::unite(isl::basic_map bmap2) const {
1969
0
  auto res = isl_basic_map_union(copy(), bmap2.release());
1970
0
  return manage(res);
1971
0
}
1972
1973
0
isl::basic_map basic_map::universe(isl::space dim) {
1974
0
  auto res = isl_basic_map_universe(dim.release());
1975
0
  return manage(res);
1976
0
}
1977
1978
// implementations for isl::basic_set
1979
0
isl::basic_set manage(__isl_take isl_basic_set *ptr) {
1980
0
  return basic_set(ptr);
1981
0
}
1982
1983
0
isl::basic_set give(__isl_take isl_basic_set *ptr) {
1984
0
  return manage(ptr);
1985
0
}
1986
1987
basic_set::basic_set()
1988
    : ptr(nullptr) {}
1989
1990
basic_set::basic_set(const isl::basic_set &obj)
1991
    : ptr(obj.copy()) {}
1992
1993
basic_set::basic_set(std::nullptr_t)
1994
    : ptr(nullptr) {}
1995
1996
basic_set::basic_set(__isl_take isl_basic_set *ptr)
1997
    : ptr(ptr) {}
1998
1999
basic_set::basic_set(isl::ctx ctx, const std::string &str) {
2000
  auto res = isl_basic_set_read_from_str(ctx.release(), str.c_str());
2001
  ptr = res;
2002
}
2003
2004
basic_set::basic_set(isl::point pnt) {
2005
  auto res = isl_basic_set_from_point(pnt.release());
2006
  ptr = res;
2007
}
2008
2009
0
basic_set &basic_set::operator=(isl::basic_set obj) {
2010
0
  std::swap(this->ptr, obj.ptr);
2011
0
  return *this;
2012
0
}
2013
2014
basic_set::~basic_set() {
2015
  if (ptr)
2016
    isl_basic_set_free(ptr);
2017
}
2018
2019
0
__isl_give isl_basic_set *basic_set::copy() const & {
2020
0
  return isl_basic_set_copy(ptr);
2021
0
}
2022
2023
0
__isl_keep isl_basic_set *basic_set::get() const {
2024
0
  return ptr;
2025
0
}
2026
2027
0
__isl_give isl_basic_set *basic_set::release() {
2028
0
  isl_basic_set *tmp = ptr;
2029
0
  ptr = nullptr;
2030
0
  return tmp;
2031
0
}
2032
2033
0
__isl_keep isl_basic_set *basic_set::keep() const {
2034
0
  return get();
2035
0
}
2036
2037
0
__isl_give isl_basic_set *basic_set::take() {
2038
0
  return release();
2039
0
}
2040
2041
0
basic_set::operator bool() const {
2042
0
  return !is_null();
2043
0
}
2044
2045
0
isl::ctx basic_set::get_ctx() const {
2046
0
  return isl::ctx(isl_basic_set_get_ctx(ptr));
2047
0
}
2048
2049
0
bool basic_set::is_null() const {
2050
0
  return ptr == nullptr;
2051
0
}
2052
2053
0
std::string basic_set::to_str() const {
2054
0
  char *Tmp = isl_basic_set_to_str(get());
2055
0
  if (!Tmp)
2056
0
    return "";
2057
0
  std::string S(Tmp);
2058
0
  free(Tmp);
2059
0
  return S;
2060
0
}
2061
2062
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
2063
0
                                     const basic_set &Obj) {
2064
0
  OS << Obj.to_str();
2065
0
  return OS;
2066
0
}
2067
2068
0
isl::basic_set basic_set::affine_hull() const {
2069
0
  auto res = isl_basic_set_affine_hull(copy());
2070
0
  return manage(res);
2071
0
}
2072
2073
0
isl::basic_set basic_set::apply(isl::basic_map bmap) const {
2074
0
  auto res = isl_basic_set_apply(copy(), bmap.release());
2075
0
  return manage(res);
2076
0
}
2077
2078
0
isl::basic_set basic_set::detect_equalities() const {
2079
0
  auto res = isl_basic_set_detect_equalities(copy());
2080
0
  return manage(res);
2081
0
}
2082
2083
0
isl::basic_set basic_set::flatten() const {
2084
0
  auto res = isl_basic_set_flatten(copy());
2085
0
  return manage(res);
2086
0
}
2087
2088
0
isl::basic_set basic_set::gist(isl::basic_set context) const {
2089
0
  auto res = isl_basic_set_gist(copy(), context.release());
2090
0
  return manage(res);
2091
0
}
2092
2093
0
isl::basic_set basic_set::intersect(isl::basic_set bset2) const {
2094
0
  auto res = isl_basic_set_intersect(copy(), bset2.release());
2095
0
  return manage(res);
2096
0
}
2097
2098
0
isl::basic_set basic_set::intersect_params(isl::basic_set bset2) const {
2099
0
  auto res = isl_basic_set_intersect_params(copy(), bset2.release());
2100
0
  return manage(res);
2101
0
}
2102
2103
0
isl::boolean basic_set::is_bounded() const {
2104
0
  auto res = isl_basic_set_is_bounded(get());
2105
0
  return res;
2106
0
}
2107
2108
0
isl::boolean basic_set::is_empty() const {
2109
0
  auto res = isl_basic_set_is_empty(get());
2110
0
  return res;
2111
0
}
2112
2113
0
isl::boolean basic_set::is_equal(const isl::basic_set &bset2) const {
2114
0
  auto res = isl_basic_set_is_equal(get(), bset2.get());
2115
0
  return res;
2116
0
}
2117
2118
0
isl::boolean basic_set::is_subset(const isl::basic_set &bset2) const {
2119
0
  auto res = isl_basic_set_is_subset(get(), bset2.get());
2120
0
  return res;
2121
0
}
2122
2123
0
isl::boolean basic_set::is_wrapping() const {
2124
0
  auto res = isl_basic_set_is_wrapping(get());
2125
0
  return res;
2126
0
}
2127
2128
0
isl::set basic_set::lexmax() const {
2129
0
  auto res = isl_basic_set_lexmax(copy());
2130
0
  return manage(res);
2131
0
}
2132
2133
0
isl::set basic_set::lexmin() const {
2134
0
  auto res = isl_basic_set_lexmin(copy());
2135
0
  return manage(res);
2136
0
}
2137
2138
0
isl::basic_set basic_set::project_out(isl::dim type, unsigned int first, unsigned int n) const {
2139
0
  auto res = isl_basic_set_project_out(copy(), static_cast<enum isl_dim_type>(type), first, n);
2140
0
  return manage(res);
2141
0
}
2142
2143
0
isl::basic_set basic_set::sample() const {
2144
0
  auto res = isl_basic_set_sample(copy());
2145
0
  return manage(res);
2146
0
}
2147
2148
0
isl::point basic_set::sample_point() const {
2149
0
  auto res = isl_basic_set_sample_point(copy());
2150
0
  return manage(res);
2151
0
}
2152
2153
0
isl::set basic_set::unite(isl::basic_set bset2) const {
2154
0
  auto res = isl_basic_set_union(copy(), bset2.release());
2155
0
  return manage(res);
2156
0
}
2157
2158
// implementations for isl::id
2159
0
isl::id manage(__isl_take isl_id *ptr) {
2160
0
  return id(ptr);
2161
0
}
2162
2163
0
isl::id give(__isl_take isl_id *ptr) {
2164
0
  return manage(ptr);
2165
0
}
2166
2167
id::id()
2168
    : ptr(nullptr) {}
2169
2170
id::id(const isl::id &obj)
2171
    : ptr(obj.copy()) {}
2172
2173
id::id(std::nullptr_t)
2174
    : ptr(nullptr) {}
2175
2176
id::id(__isl_take isl_id *ptr)
2177
    : ptr(ptr) {}
2178
2179
0
id &id::operator=(isl::id obj) {
2180
0
  std::swap(this->ptr, obj.ptr);
2181
0
  return *this;
2182
0
}
2183
2184
id::~id() {
2185
  if (ptr)
2186
    isl_id_free(ptr);
2187
}
2188
2189
0
__isl_give isl_id *id::copy() const & {
2190
0
  return isl_id_copy(ptr);
2191
0
}
2192
2193
0
__isl_keep isl_id *id::get() const {
2194
0
  return ptr;
2195
0
}
2196
2197
0
__isl_give isl_id *id::release() {
2198
0
  isl_id *tmp = ptr;
2199
0
  ptr = nullptr;
2200
0
  return tmp;
2201
0
}
2202
2203
0
__isl_keep isl_id *id::keep() const {
2204
0
  return get();
2205
0
}
2206
2207
0
__isl_give isl_id *id::take() {
2208
0
  return release();
2209
0
}
2210
2211
0
id::operator bool() const {
2212
0
  return !is_null();
2213
0
}
2214
2215
0
isl::ctx id::get_ctx() const {
2216
0
  return isl::ctx(isl_id_get_ctx(ptr));
2217
0
}
2218
2219
0
bool id::is_null() const {
2220
0
  return ptr == nullptr;
2221
0
}
2222
2223
0
std::string id::to_str() const {
2224
0
  char *Tmp = isl_id_to_str(get());
2225
0
  if (!Tmp)
2226
0
    return "";
2227
0
  std::string S(Tmp);
2228
0
  free(Tmp);
2229
0
  return S;
2230
0
}
2231
2232
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
2233
0
                                     const id &Obj) {
2234
0
  OS << Obj.to_str();
2235
0
  return OS;
2236
0
}
2237
2238
// implementations for isl::local_space
2239
0
isl::local_space manage(__isl_take isl_local_space *ptr) {
2240
0
  return local_space(ptr);
2241
0
}
2242
2243
0
isl::local_space give(__isl_take isl_local_space *ptr) {
2244
0
  return manage(ptr);
2245
0
}
2246
2247
local_space::local_space()
2248
    : ptr(nullptr) {}
2249
2250
local_space::local_space(const isl::local_space &obj)
2251
    : ptr(obj.copy()) {}
2252
2253
local_space::local_space(std::nullptr_t)
2254
    : ptr(nullptr) {}
2255
2256
local_space::local_space(__isl_take isl_local_space *ptr)
2257
    : ptr(ptr) {}
2258
2259
15
local_space::local_space(isl::space dim) {
2260
15
  auto res = isl_local_space_from_space(dim.release());
2261
15
  ptr = res;
2262
15
}
2263
2264
0
local_space &local_space::operator=(isl::local_space obj) {
2265
0
  std::swap(this->ptr, obj.ptr);
2266
0
  return *this;
2267
0
}
2268
2269
15
local_space::~local_space() {
2270
15
  if (ptr)
2271
0
    isl_local_space_free(ptr);
2272
15
}
2273
2274
0
__isl_give isl_local_space *local_space::copy() const & {
2275
0
  return isl_local_space_copy(ptr);
2276
0
}
2277
2278
0
__isl_keep isl_local_space *local_space::get() const {
2279
0
  return ptr;
2280
0
}
2281
2282
15
__isl_give isl_local_space *local_space::release() {
2283
15
  isl_local_space *tmp = ptr;
2284
15
  ptr = nullptr;
2285
15
  return tmp;
2286
15
}
2287
2288
0
__isl_keep isl_local_space *local_space::keep() const {
2289
0
  return get();
2290
0
}
2291
2292
0
__isl_give isl_local_space *local_space::take() {
2293
0
  return release();
2294
0
}
2295
2296
0
local_space::operator bool() const {
2297
0
  return !is_null();
2298
0
}
2299
2300
0
isl::ctx local_space::get_ctx() const {
2301
0
  return isl::ctx(isl_local_space_get_ctx(ptr));
2302
0
}
2303
2304
0
bool local_space::is_null() const {
2305
0
  return ptr == nullptr;
2306
0
}
2307
2308
2309
// implementations for isl::map
2310
3.33k
isl::map manage(__isl_take isl_map *ptr) {
2311
3.33k
  return map(ptr);
2312
3.33k
}
2313
2314
1.44k
isl::map give(__isl_take isl_map *ptr) {
2315
1.44k
  return manage(ptr);
2316
1.44k
}
2317
2318
map::map()
2319
90
    : ptr(nullptr) {}
2320
2321
map::map(const isl::map &obj)
2322
2.30k
    : ptr(obj.copy()) {}
2323
2324
map::map(std::nullptr_t)
2325
0
    : ptr(nullptr) {}
2326
2327
map::map(__isl_take isl_map *ptr)
2328
3.33k
    : ptr(ptr) {}
2329
2330
map::map(isl::ctx ctx, const std::string &str) {
2331
  auto res = isl_map_read_from_str(ctx.release(), str.c_str());
2332
  ptr = res;
2333
}
2334
2335
map::map(isl::basic_map bmap) {
2336
  auto res = isl_map_from_basic_map(bmap.release());
2337
  ptr = res;
2338
}
2339
2340
330
map &map::operator=(isl::map obj) {
2341
330
  std::swap(this->ptr, obj.ptr);
2342
330
  return *this;
2343
330
}
2344
2345
5.76k
map::~map() {
2346
5.76k
  if (ptr)
2347
3.71k
    isl_map_free(ptr);
2348
5.76k
}
2349
2350
2.94k
__isl_give isl_map *map::copy() const & {
2351
2.94k
  return isl_map_copy(ptr);
2352
2.94k
}
2353
2354
1.78k
__isl_keep isl_map *map::get() const {
2355
1.78k
  return ptr;
2356
1.78k
}
2357
2358
1.96k
__isl_give isl_map *map::release() {
2359
1.96k
  isl_map *tmp = ptr;
2360
1.96k
  ptr = nullptr;
2361
1.96k
  return tmp;
2362
1.96k
}
2363
2364
1.28k
__isl_keep isl_map *map::keep() const {
2365
1.28k
  return get();
2366
1.28k
}
2367
2368
1.51k
__isl_give isl_map *map::take() {
2369
1.51k
  return release();
2370
1.51k
}
2371
2372
11
map::operator bool() const {
2373
11
  return !is_null();
2374
11
}
2375
2376
0
isl::ctx map::get_ctx() const {
2377
0
  return isl::ctx(isl_map_get_ctx(ptr));
2378
0
}
2379
2380
11
bool map::is_null() const {
2381
11
  return ptr == nullptr;
2382
11
}
2383
2384
38
std::string map::to_str() const {
2385
38
  char *Tmp = isl_map_to_str(get());
2386
38
  if (!Tmp)
2387
0
    return "";
2388
38
  std::string S(Tmp);
2389
38
  free(Tmp);
2390
38
  return S;
2391
38
}
2392
2393
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
2394
38
                                     const map &Obj) {
2395
38
  OS << Obj.to_str();
2396
38
  return OS;
2397
38
}
2398
2399
0
isl::basic_map map::affine_hull() const {
2400
0
  auto res = isl_map_affine_hull(copy());
2401
0
  return manage(res);
2402
0
}
2403
2404
101
isl::map map::apply_domain(isl::map map2) const {
2405
101
  auto res = isl_map_apply_domain(copy(), map2.release());
2406
101
  return manage(res);
2407
101
}
2408
2409
5
isl::map map::apply_range(isl::map map2) const {
2410
5
  auto res = isl_map_apply_range(copy(), map2.release());
2411
5
  return manage(res);
2412
5
}
2413
2414
0
isl::map map::coalesce() const {
2415
0
  auto res = isl_map_coalesce(copy());
2416
0
  return manage(res);
2417
0
}
2418
2419
0
isl::map map::complement() const {
2420
0
  auto res = isl_map_complement(copy());
2421
0
  return manage(res);
2422
0
}
2423
2424
0
isl::set map::deltas() const {
2425
0
  auto res = isl_map_deltas(copy());
2426
0
  return manage(res);
2427
0
}
2428
2429
0
isl::map map::detect_equalities() const {
2430
0
  auto res = isl_map_detect_equalities(copy());
2431
0
  return manage(res);
2432
0
}
2433
2434
372
unsigned int map::dim(isl::dim type) const {
2435
372
  auto res = isl_map_dim(get(), static_cast<enum isl_dim_type>(type));
2436
372
  return res;
2437
372
}
2438
2439
26
isl::pw_aff map::dim_max(int pos) const {
2440
26
  auto res = isl_map_dim_max(copy(), pos);
2441
26
  return manage(res);
2442
26
}
2443
2444
26
isl::pw_aff map::dim_min(int pos) const {
2445
26
  auto res = isl_map_dim_min(copy(), pos);
2446
26
  return manage(res);
2447
26
}
2448
2449
0
isl::map map::flatten() const {
2450
0
  auto res = isl_map_flatten(copy());
2451
0
  return manage(res);
2452
0
}
2453
2454
0
isl::map map::flatten_domain() const {
2455
0
  auto res = isl_map_flatten_domain(copy());
2456
0
  return manage(res);
2457
0
}
2458
2459
0
isl::map map::flatten_range() const {
2460
0
  auto res = isl_map_flatten_range(copy());
2461
0
  return manage(res);
2462
0
}
2463
2464
52
isl::stat map::foreach_basic_map(const std::function<isl::stat(isl::basic_map)> &fn) const {
2465
52
  auto fn_lambda = [](isl_basic_map *arg_0, void *arg_1) -> isl_stat {
2466
52
    auto *func = (std::function<isl::stat(isl::basic_map)> *)arg_1;
2467
52
    stat ret = (*func) (isl::manage(arg_0));
2468
52
    return isl_stat(ret);
2469
52
  };
2470
52
  auto res = isl_map_foreach_basic_map(get(), fn_lambda, const_cast<void*>((const void *) &fn));
2471
52
  return isl::stat(res);
2472
52
}
2473
2474
26
isl::map map::from_range(isl::set set) {
2475
26
  auto res = isl_map_from_range(set.release());
2476
26
  return manage(res);
2477
26
}
2478
2479
0
isl::map map::gist(isl::map context) const {
2480
0
  auto res = isl_map_gist(copy(), context.release());
2481
0
  return manage(res);
2482
0
}
2483
2484
0
isl::map map::gist_domain(isl::set context) const {
2485
0
  auto res = isl_map_gist_domain(copy(), context.release());
2486
0
  return manage(res);
2487
0
}
2488
2489
0
isl::map map::intersect(isl::map map2) const {
2490
0
  auto res = isl_map_intersect(copy(), map2.release());
2491
0
  return manage(res);
2492
0
}
2493
2494
0
isl::map map::intersect_domain(isl::set set) const {
2495
0
  auto res = isl_map_intersect_domain(copy(), set.release());
2496
0
  return manage(res);
2497
0
}
2498
2499
0
isl::map map::intersect_params(isl::set params) const {
2500
0
  auto res = isl_map_intersect_params(copy(), params.release());
2501
0
  return manage(res);
2502
0
}
2503
2504
0
isl::map map::intersect_range(isl::set set) const {
2505
0
  auto res = isl_map_intersect_range(copy(), set.release());
2506
0
  return manage(res);
2507
0
}
2508
2509
0
isl::boolean map::is_bijective() const {
2510
0
  auto res = isl_map_is_bijective(get());
2511
0
  return res;
2512
0
}
2513
2514
0
isl::boolean map::is_disjoint(const isl::map &map2) const {
2515
0
  auto res = isl_map_is_disjoint(get(), map2.get());
2516
0
  return res;
2517
0
}
2518
2519
0
isl::boolean map::is_empty() const {
2520
0
  auto res = isl_map_is_empty(get());
2521
0
  return res;
2522
0
}
2523
2524
0
isl::boolean map::is_equal(const isl::map &map2) const {
2525
0
  auto res = isl_map_is_equal(get(), map2.get());
2526
0
  return res;
2527
0
}
2528
2529
0
isl::boolean map::is_injective() const {
2530
0
  auto res = isl_map_is_injective(get());
2531
0
  return res;
2532
0
}
2533
2534
0
isl::boolean map::is_single_valued() const {
2535
0
  auto res = isl_map_is_single_valued(get());
2536
0
  return res;
2537
0
}
2538
2539
0
isl::boolean map::is_strict_subset(const isl::map &map2) const {
2540
0
  auto res = isl_map_is_strict_subset(get(), map2.get());
2541
0
  return res;
2542
0
}
2543
2544
0
isl::boolean map::is_subset(const isl::map &map2) const {
2545
0
  auto res = isl_map_is_subset(get(), map2.get());
2546
0
  return res;
2547
0
}
2548
2549
0
isl::map map::lexmax() const {
2550
0
  auto res = isl_map_lexmax(copy());
2551
0
  return manage(res);
2552
0
}
2553
2554
0
isl::map map::lexmin() const {
2555
0
  auto res = isl_map_lexmin(copy());
2556
0
  return manage(res);
2557
0
}
2558
2559
0
isl::basic_map map::polyhedral_hull() const {
2560
0
  auto res = isl_map_polyhedral_hull(copy());
2561
0
  return manage(res);
2562
0
}
2563
2564
338
isl::map map::project_out(isl::dim type, unsigned int first, unsigned int n) const {
2565
338
  auto res = isl_map_project_out(copy(), static_cast<enum isl_dim_type>(type), first, n);
2566
338
  return manage(res);
2567
338
}
2568
2569
0
isl::map map::reverse() const {
2570
0
  auto res = isl_map_reverse(copy());
2571
0
  return manage(res);
2572
0
}
2573
2574
0
isl::basic_map map::sample() const {
2575
0
  auto res = isl_map_sample(copy());
2576
0
  return manage(res);
2577
0
}
2578
2579
0
isl::map map::subtract(isl::map map2) const {
2580
0
  auto res = isl_map_subtract(copy(), map2.release());
2581
0
  return manage(res);
2582
0
}
2583
2584
0
isl::map map::unite(isl::map map2) const {
2585
0
  auto res = isl_map_union(copy(), map2.release());
2586
0
  return manage(res);
2587
0
}
2588
2589
0
isl::basic_map map::unshifted_simple_hull() const {
2590
0
  auto res = isl_map_unshifted_simple_hull(copy());
2591
0
  return manage(res);
2592
0
}
2593
2594
// implementations for isl::multi_aff
2595
1.04k
isl::multi_aff manage(__isl_take isl_multi_aff *ptr) {
2596
1.04k
  return multi_aff(ptr);
2597
1.04k
}
2598
2599
1.04k
isl::multi_aff give(__isl_take isl_multi_aff *ptr) {
2600
1.04k
  return manage(ptr);
2601
1.04k
}
2602
2603
multi_aff::multi_aff()
2604
    : ptr(nullptr) {}
2605
2606
multi_aff::multi_aff(const isl::multi_aff &obj)
2607
0
    : ptr(obj.copy()) {}
2608
2609
multi_aff::multi_aff(std::nullptr_t)
2610
    : ptr(nullptr) {}
2611
2612
multi_aff::multi_aff(__isl_take isl_multi_aff *ptr)
2613
1.04k
    : ptr(ptr) {}
2614
2615
multi_aff::multi_aff(isl::aff aff) {
2616
  auto res = isl_multi_aff_from_aff(aff.release());
2617
  ptr = res;
2618
}
2619
2620
multi_aff::multi_aff(isl::ctx ctx, const std::string &str) {
2621
  auto res = isl_multi_aff_read_from_str(ctx.release(), str.c_str());
2622
  ptr = res;
2623
}
2624
2625
0
multi_aff &multi_aff::operator=(isl::multi_aff obj) {
2626
0
  std::swap(this->ptr, obj.ptr);
2627
0
  return *this;
2628
0
}
2629
2630
1.04k
multi_aff::~multi_aff() {
2631
1.04k
  if (ptr)
2632
0
    isl_multi_aff_free(ptr);
2633
1.04k
}
2634
2635
0
__isl_give isl_multi_aff *multi_aff::copy() const & {
2636
0
  return isl_multi_aff_copy(ptr);
2637
0
}
2638
2639
521
__isl_keep isl_multi_aff *multi_aff::get() const {
2640
521
  return ptr;
2641
521
}
2642
2643
1.04k
__isl_give isl_multi_aff *multi_aff::release() {
2644
1.04k
  isl_multi_aff *tmp = ptr;
2645
1.04k
  ptr = nullptr;
2646
1.04k
  return tmp;
2647
1.04k
}
2648
2649
521
__isl_keep isl_multi_aff *multi_aff::keep() const {
2650
521
  return get();
2651
521
}
2652
2653
1.04k
__isl_give isl_multi_aff *multi_aff::take() {
2654
1.04k
  return release();
2655
1.04k
}
2656
2657
0
multi_aff::operator bool() const {
2658
0
  return !is_null();
2659
0
}
2660
2661
0
isl::ctx multi_aff::get_ctx() const {
2662
0
  return isl::ctx(isl_multi_aff_get_ctx(ptr));
2663
0
}
2664
2665
0
bool multi_aff::is_null() const {
2666
0
  return ptr == nullptr;
2667
0
}
2668
2669
0
std::string multi_aff::to_str() const {
2670
0
  char *Tmp = isl_multi_aff_to_str(get());
2671
0
  if (!Tmp)
2672
0
    return "";
2673
0
  std::string S(Tmp);
2674
0
  free(Tmp);
2675
0
  return S;
2676
0
}
2677
2678
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
2679
0
                                     const multi_aff &Obj) {
2680
0
  OS << Obj.to_str();
2681
0
  return OS;
2682
0
}
2683
2684
0
isl::multi_aff multi_aff::add(isl::multi_aff multi2) const {
2685
0
  auto res = isl_multi_aff_add(copy(), multi2.release());
2686
0
  return manage(res);
2687
0
}
2688
2689
0
isl::multi_aff multi_aff::flat_range_product(isl::multi_aff multi2) const {
2690
0
  auto res = isl_multi_aff_flat_range_product(copy(), multi2.release());
2691
0
  return manage(res);
2692
0
}
2693
2694
0
isl::aff multi_aff::get_aff(int pos) const {
2695
0
  auto res = isl_multi_aff_get_aff(get(), pos);
2696
0
  return manage(res);
2697
0
}
2698
2699
0
isl::multi_aff multi_aff::product(isl::multi_aff multi2) const {
2700
0
  auto res = isl_multi_aff_product(copy(), multi2.release());
2701
0
  return manage(res);
2702
0
}
2703
2704
0
isl::multi_aff multi_aff::pullback(isl::multi_aff ma2) const {
2705
0
  auto res = isl_multi_aff_pullback_multi_aff(copy(), ma2.release());
2706
0
  return manage(res);
2707
0
}
2708
2709
0
isl::multi_aff multi_aff::range_product(isl::multi_aff multi2) const {
2710
0
  auto res = isl_multi_aff_range_product(copy(), multi2.release());
2711
0
  return manage(res);
2712
0
}
2713
2714
// implementations for isl::multi_pw_aff
2715
0
isl::multi_pw_aff manage(__isl_take isl_multi_pw_aff *ptr) {
2716
0
  return multi_pw_aff(ptr);
2717
0
}
2718
2719
0
isl::multi_pw_aff give(__isl_take isl_multi_pw_aff *ptr) {
2720
0
  return manage(ptr);
2721
0
}
2722
2723
multi_pw_aff::multi_pw_aff()
2724
    : ptr(nullptr) {}
2725
2726
multi_pw_aff::multi_pw_aff(const isl::multi_pw_aff &obj)
2727
    : ptr(obj.copy()) {}
2728
2729
multi_pw_aff::multi_pw_aff(std::nullptr_t)
2730
    : ptr(nullptr) {}
2731
2732
multi_pw_aff::multi_pw_aff(__isl_take isl_multi_pw_aff *ptr)
2733
    : ptr(ptr) {}
2734
2735
multi_pw_aff::multi_pw_aff(isl::multi_aff ma) {
2736
  auto res = isl_multi_pw_aff_from_multi_aff(ma.release());
2737
  ptr = res;
2738
}
2739
2740
multi_pw_aff::multi_pw_aff(isl::pw_aff pa) {
2741
  auto res = isl_multi_pw_aff_from_pw_aff(pa.release());
2742
  ptr = res;
2743
}
2744
2745
multi_pw_aff::multi_pw_aff(isl::pw_multi_aff pma) {
2746
  auto res = isl_multi_pw_aff_from_pw_multi_aff(pma.release());
2747
  ptr = res;
2748
}
2749
2750
multi_pw_aff::multi_pw_aff(isl::ctx ctx, const std::string &str) {
2751
  auto res = isl_multi_pw_aff_read_from_str(ctx.release(), str.c_str());
2752
  ptr = res;
2753
}
2754
2755
0
multi_pw_aff &multi_pw_aff::operator=(isl::multi_pw_aff obj) {
2756
0
  std::swap(this->ptr, obj.ptr);
2757
0
  return *this;
2758
0
}
2759
2760
multi_pw_aff::~multi_pw_aff() {
2761
  if (ptr)
2762
    isl_multi_pw_aff_free(ptr);
2763
}
2764
2765
0
__isl_give isl_multi_pw_aff *multi_pw_aff::copy() const & {
2766
0
  return isl_multi_pw_aff_copy(ptr);
2767
0
}
2768
2769
0
__isl_keep isl_multi_pw_aff *multi_pw_aff::get() const {
2770
0
  return ptr;
2771
0
}
2772
2773
0
__isl_give isl_multi_pw_aff *multi_pw_aff::release() {
2774
0
  isl_multi_pw_aff *tmp = ptr;
2775
0
  ptr = nullptr;
2776
0
  return tmp;
2777
0
}
2778
2779
0
__isl_keep isl_multi_pw_aff *multi_pw_aff::keep() const {
2780
0
  return get();
2781
0
}
2782
2783
0
__isl_give isl_multi_pw_aff *multi_pw_aff::take() {
2784
0
  return release();
2785
0
}
2786
2787
0
multi_pw_aff::operator bool() const {
2788
0
  return !is_null();
2789
0
}
2790
2791
0
isl::ctx multi_pw_aff::get_ctx() const {
2792
0
  return isl::ctx(isl_multi_pw_aff_get_ctx(ptr));
2793
0
}
2794
2795
0
bool multi_pw_aff::is_null() const {
2796
0
  return ptr == nullptr;
2797
0
}
2798
2799
0
std::string multi_pw_aff::to_str() const {
2800
0
  char *Tmp = isl_multi_pw_aff_to_str(get());
2801
0
  if (!Tmp)
2802
0
    return "";
2803
0
  std::string S(Tmp);
2804
0
  free(Tmp);
2805
0
  return S;
2806
0
}
2807
2808
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
2809
0
                                     const multi_pw_aff &Obj) {
2810
0
  OS << Obj.to_str();
2811
0
  return OS;
2812
0
}
2813
2814
0
isl::multi_pw_aff multi_pw_aff::add(isl::multi_pw_aff multi2) const {
2815
0
  auto res = isl_multi_pw_aff_add(copy(), multi2.release());
2816
0
  return manage(res);
2817
0
}
2818
2819
0
isl::multi_pw_aff multi_pw_aff::flat_range_product(isl::multi_pw_aff multi2) const {
2820
0
  auto res = isl_multi_pw_aff_flat_range_product(copy(), multi2.release());
2821
0
  return manage(res);
2822
0
}
2823
2824
0
isl::pw_aff multi_pw_aff::get_pw_aff(int pos) const {
2825
0
  auto res = isl_multi_pw_aff_get_pw_aff(get(), pos);
2826
0
  return manage(res);
2827
0
}
2828
2829
0
isl::multi_pw_aff multi_pw_aff::product(isl::multi_pw_aff multi2) const {
2830
0
  auto res = isl_multi_pw_aff_product(copy(), multi2.release());
2831
0
  return manage(res);
2832
0
}
2833
2834
0
isl::multi_pw_aff multi_pw_aff::pullback(isl::multi_aff ma) const {
2835
0
  auto res = isl_multi_pw_aff_pullback_multi_aff(copy(), ma.release());
2836
0
  return manage(res);
2837
0
}
2838
2839
0
isl::multi_pw_aff multi_pw_aff::pullback(isl::pw_multi_aff pma) const {
2840
0
  auto res = isl_multi_pw_aff_pullback_pw_multi_aff(copy(), pma.release());
2841
0
  return manage(res);
2842
0
}
2843
2844
0
isl::multi_pw_aff multi_pw_aff::pullback(isl::multi_pw_aff mpa2) const {
2845
0
  auto res = isl_multi_pw_aff_pullback_multi_pw_aff(copy(), mpa2.release());
2846
0
  return manage(res);
2847
0
}
2848
2849
0
isl::multi_pw_aff multi_pw_aff::range_product(isl::multi_pw_aff multi2) const {
2850
0
  auto res = isl_multi_pw_aff_range_product(copy(), multi2.release());
2851
0
  return manage(res);
2852
0
}
2853
2854
// implementations for isl::multi_union_pw_aff
2855
11
isl::multi_union_pw_aff manage(__isl_take isl_multi_union_pw_aff *ptr) {
2856
11
  return multi_union_pw_aff(ptr);
2857
11
}
2858
2859
0
isl::multi_union_pw_aff give(__isl_take isl_multi_union_pw_aff *ptr) {
2860
0
  return manage(ptr);
2861
0
}
2862
2863
multi_union_pw_aff::multi_union_pw_aff()
2864
    : ptr(nullptr) {}
2865
2866
multi_union_pw_aff::multi_union_pw_aff(const isl::multi_union_pw_aff &obj)
2867
    : ptr(obj.copy()) {}
2868
2869
multi_union_pw_aff::multi_union_pw_aff(std::nullptr_t)
2870
    : ptr(nullptr) {}
2871
2872
multi_union_pw_aff::multi_union_pw_aff(__isl_take isl_multi_union_pw_aff *ptr)
2873
11
    : ptr(ptr) {}
2874
2875
multi_union_pw_aff::multi_union_pw_aff(isl::union_pw_aff upa) {
2876
  auto res = isl_multi_union_pw_aff_from_union_pw_aff(upa.release());
2877
  ptr = res;
2878
}
2879
2880
multi_union_pw_aff::multi_union_pw_aff(isl::multi_pw_aff mpa) {
2881
  auto res = isl_multi_union_pw_aff_from_multi_pw_aff(mpa.release());
2882
  ptr = res;
2883
}
2884
2885
59
multi_union_pw_aff::multi_union_pw_aff(isl::union_pw_multi_aff upma) {
2886
59
  auto res = isl_multi_union_pw_aff_from_union_pw_multi_aff(upma.release());
2887
59
  ptr = res;
2888
59
}
2889
2890
multi_union_pw_aff::multi_union_pw_aff(isl::ctx ctx, const std::string &str) {
2891
  auto res = isl_multi_union_pw_aff_read_from_str(ctx.release(), str.c_str());
2892
  ptr = res;
2893
}
2894
2895
11
multi_union_pw_aff &multi_union_pw_aff::operator=(isl::multi_union_pw_aff obj) {
2896
11
  std::swap(this->ptr, obj.ptr);
2897
11
  return *this;
2898
11
}
2899
2900
70
multi_union_pw_aff::~multi_union_pw_aff() {
2901
70
  if (ptr)
2902
48
    isl_multi_union_pw_aff_free(ptr);
2903
70
}
2904
2905
0
__isl_give isl_multi_union_pw_aff *multi_union_pw_aff::copy() const & {
2906
0
  return isl_multi_union_pw_aff_copy(ptr);
2907
0
}
2908
2909
48
__isl_keep isl_multi_union_pw_aff *multi_union_pw_aff::get() const {
2910
48
  return ptr;
2911
48
}
2912
2913
22
__isl_give isl_multi_union_pw_aff *multi_union_pw_aff::release() {
2914
22
  isl_multi_union_pw_aff *tmp = ptr;
2915
22
  ptr = nullptr;
2916
22
  return tmp;
2917
22
}
2918
2919
0
__isl_keep isl_multi_union_pw_aff *multi_union_pw_aff::keep() const {
2920
0
  return get();
2921
0
}
2922
2923
22
__isl_give isl_multi_union_pw_aff *multi_union_pw_aff::take() {
2924
22
  return release();
2925
22
}
2926
2927
0
multi_union_pw_aff::operator bool() const {
2928
0
  return !is_null();
2929
0
}
2930
2931
0
isl::ctx multi_union_pw_aff::get_ctx() const {
2932
0
  return isl::ctx(isl_multi_union_pw_aff_get_ctx(ptr));
2933
0
}
2934
2935
0
bool multi_union_pw_aff::is_null() const {
2936
0
  return ptr == nullptr;
2937
0
}
2938
2939
0
std::string multi_union_pw_aff::to_str() const {
2940
0
  char *Tmp = isl_multi_union_pw_aff_to_str(get());
2941
0
  if (!Tmp)
2942
0
    return "";
2943
0
  std::string S(Tmp);
2944
0
  free(Tmp);
2945
0
  return S;
2946
0
}
2947
2948
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
2949
0
                                     const multi_union_pw_aff &Obj) {
2950
0
  OS << Obj.to_str();
2951
0
  return OS;
2952
0
}
2953
2954
0
isl::multi_union_pw_aff multi_union_pw_aff::add(isl::multi_union_pw_aff multi2) const {
2955
0
  auto res = isl_multi_union_pw_aff_add(copy(), multi2.release());
2956
0
  return manage(res);
2957
0
}
2958
2959
0
isl::multi_union_pw_aff multi_union_pw_aff::flat_range_product(isl::multi_union_pw_aff multi2) const {
2960
0
  auto res = isl_multi_union_pw_aff_flat_range_product(copy(), multi2.release());
2961
0
  return manage(res);
2962
0
}
2963
2964
48
isl::union_pw_aff multi_union_pw_aff::get_union_pw_aff(int pos) const {
2965
48
  auto res = isl_multi_union_pw_aff_get_union_pw_aff(get(), pos);
2966
48
  return manage(res);
2967
48
}
2968
2969
0
isl::multi_union_pw_aff multi_union_pw_aff::pullback(isl::union_pw_multi_aff upma) const {
2970
0
  auto res = isl_multi_union_pw_aff_pullback_union_pw_multi_aff(copy(), upma.release());
2971
0
  return manage(res);
2972
0
}
2973
2974
0
isl::multi_union_pw_aff multi_union_pw_aff::range_product(isl::multi_union_pw_aff multi2) const {
2975
0
  auto res = isl_multi_union_pw_aff_range_product(copy(), multi2.release());
2976
0
  return manage(res);
2977
0
}
2978
2979
0
isl::multi_union_pw_aff multi_union_pw_aff::union_add(isl::multi_union_pw_aff mupa2) const {
2980
0
  auto res = isl_multi_union_pw_aff_union_add(copy(), mupa2.release());
2981
0
  return manage(res);
2982
0
}
2983
2984
// implementations for isl::multi_val
2985
0
isl::multi_val manage(__isl_take isl_multi_val *ptr) {
2986
0
  return multi_val(ptr);
2987
0
}
2988
2989
0
isl::multi_val give(__isl_take isl_multi_val *ptr) {
2990
0
  return manage(ptr);
2991
0
}
2992
2993
multi_val::multi_val()
2994
    : ptr(nullptr) {}
2995
2996
multi_val::multi_val(const isl::multi_val &obj)
2997
    : ptr(obj.copy()) {}
2998
2999
multi_val::multi_val(std::nullptr_t)
3000
    : ptr(nullptr) {}
3001
3002
multi_val::multi_val(__isl_take isl_multi_val *ptr)
3003
    : ptr(ptr) {}
3004
3005
0
multi_val &multi_val::operator=(isl::multi_val obj) {
3006
0
  std::swap(this->ptr, obj.ptr);
3007
0
  return *this;
3008
0
}
3009
3010
multi_val::~multi_val() {
3011
  if (ptr)
3012
    isl_multi_val_free(ptr);
3013
}
3014
3015
0
__isl_give isl_multi_val *multi_val::copy() const & {
3016
0
  return isl_multi_val_copy(ptr);
3017
0
}
3018
3019
0
__isl_keep isl_multi_val *multi_val::get() const {
3020
0
  return ptr;
3021
0
}
3022
3023
0
__isl_give isl_multi_val *multi_val::release() {
3024
0
  isl_multi_val *tmp = ptr;
3025
0
  ptr = nullptr;
3026
0
  return tmp;
3027
0
}
3028
3029
0
__isl_keep isl_multi_val *multi_val::keep() const {
3030
0
  return get();
3031
0
}
3032
3033
0
__isl_give isl_multi_val *multi_val::take() {
3034
0
  return release();
3035
0
}
3036
3037
0
multi_val::operator bool() const {
3038
0
  return !is_null();
3039
0
}
3040
3041
0
isl::ctx multi_val::get_ctx() const {
3042
0
  return isl::ctx(isl_multi_val_get_ctx(ptr));
3043
0
}
3044
3045
0
bool multi_val::is_null() const {
3046
0
  return ptr == nullptr;
3047
0
}
3048
3049
0
std::string multi_val::to_str() const {
3050
0
  char *Tmp = isl_multi_val_to_str(get());
3051
0
  if (!Tmp)
3052
0
    return "";
3053
0
  std::string S(Tmp);
3054
0
  free(Tmp);
3055
0
  return S;
3056
0
}
3057
3058
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
3059
0
                                     const multi_val &Obj) {
3060
0
  OS << Obj.to_str();
3061
0
  return OS;
3062
0
}
3063
3064
0
isl::multi_val multi_val::add(isl::multi_val multi2) const {
3065
0
  auto res = isl_multi_val_add(copy(), multi2.release());
3066
0
  return manage(res);
3067
0
}
3068
3069
0
isl::multi_val multi_val::flat_range_product(isl::multi_val multi2) const {
3070
0
  auto res = isl_multi_val_flat_range_product(copy(), multi2.release());
3071
0
  return manage(res);
3072
0
}
3073
3074
0
isl::val multi_val::get_val(int pos) const {
3075
0
  auto res = isl_multi_val_get_val(get(), pos);
3076
0
  return manage(res);
3077
0
}
3078
3079
0
isl::multi_val multi_val::product(isl::multi_val multi2) const {
3080
0
  auto res = isl_multi_val_product(copy(), multi2.release());
3081
0
  return manage(res);
3082
0
}
3083
3084
0
isl::multi_val multi_val::range_product(isl::multi_val multi2) const {
3085
0
  auto res = isl_multi_val_range_product(copy(), multi2.release());
3086
0
  return manage(res);
3087
0
}
3088
3089
// implementations for isl::point
3090
0
isl::point manage(__isl_take isl_point *ptr) {
3091
0
  return point(ptr);
3092
0
}
3093
3094
0
isl::point give(__isl_take isl_point *ptr) {
3095
0
  return manage(ptr);
3096
0
}
3097
3098
point::point()
3099
    : ptr(nullptr) {}
3100
3101
point::point(const isl::point &obj)
3102
    : ptr(obj.copy()) {}
3103
3104
point::point(std::nullptr_t)
3105
    : ptr(nullptr) {}
3106
3107
point::point(__isl_take isl_point *ptr)
3108
    : ptr(ptr) {}
3109
3110
point::point(isl::space dim) {
3111
  auto res = isl_point_zero(dim.release());
3112
  ptr = res;
3113
}
3114
3115
0
point &point::operator=(isl::point obj) {
3116
0
  std::swap(this->ptr, obj.ptr);
3117
0
  return *this;
3118
0
}
3119
3120
point::~point() {
3121
  if (ptr)
3122
    isl_point_free(ptr);
3123
}
3124
3125
0
__isl_give isl_point *point::copy() const & {
3126
0
  return isl_point_copy(ptr);
3127
0
}
3128
3129
0
__isl_keep isl_point *point::get() const {
3130
0
  return ptr;
3131
0
}
3132
3133
0
__isl_give isl_point *point::release() {
3134
0
  isl_point *tmp = ptr;
3135
0
  ptr = nullptr;
3136
0
  return tmp;
3137
0
}
3138
3139
0
__isl_keep isl_point *point::keep() const {
3140
0
  return get();
3141
0
}
3142
3143
0
__isl_give isl_point *point::take() {
3144
0
  return release();
3145
0
}
3146
3147
0
point::operator bool() const {
3148
0
  return !is_null();
3149
0
}
3150
3151
0
isl::ctx point::get_ctx() const {
3152
0
  return isl::ctx(isl_point_get_ctx(ptr));
3153
0
}
3154
3155
0
bool point::is_null() const {
3156
0
  return ptr == nullptr;
3157
0
}
3158
3159
0
std::string point::to_str() const {
3160
0
  char *Tmp = isl_point_to_str(get());
3161
0
  if (!Tmp)
3162
0
    return "";
3163
0
  std::string S(Tmp);
3164
0
  free(Tmp);
3165
0
  return S;
3166
0
}
3167
3168
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
3169
0
                                     const point &Obj) {
3170
0
  OS << Obj.to_str();
3171
0
  return OS;
3172
0
}
3173
3174
// implementations for isl::pw_aff
3175
247
isl::pw_aff manage(__isl_take isl_pw_aff *ptr) {
3176
247
  return pw_aff(ptr);
3177
247
}
3178
3179
0
isl::pw_aff give(__isl_take isl_pw_aff *ptr) {
3180
0
  return manage(ptr);
3181
0
}
3182
3183
pw_aff::pw_aff()
3184
    : ptr(nullptr) {}
3185
3186
pw_aff::pw_aff(const isl::pw_aff &obj)
3187
229
    : ptr(obj.copy()) {}
3188
3189
pw_aff::pw_aff(std::nullptr_t)
3190
    : ptr(nullptr) {}
3191
3192
pw_aff::pw_aff(__isl_take isl_pw_aff *ptr)
3193
247
    : ptr(ptr) {}
3194
3195
pw_aff::pw_aff(isl::aff aff) {
3196
  auto res = isl_pw_aff_from_aff(aff.release());
3197
  ptr = res;
3198
}
3199
3200
15
pw_aff::pw_aff(isl::local_space ls) {
3201
15
  auto res = isl_pw_aff_zero_on_domain(ls.release());
3202
15
  ptr = res;
3203
15
}
3204
3205
61
pw_aff::pw_aff(isl::set domain, isl::val v) {
3206
61
  auto res = isl_pw_aff_val_on_domain(domain.release(), v.release());
3207
61
  ptr = res;
3208
61
}
3209
3210
pw_aff::pw_aff(isl::ctx ctx, const std::string &str) {
3211
  auto res = isl_pw_aff_read_from_str(ctx.release(), str.c_str());
3212
  ptr = res;
3213
}
3214
3215
26
pw_aff &pw_aff::operator=(isl::pw_aff obj) {
3216
26
  std::swap(this->ptr, obj.ptr);
3217
26
  return *this;
3218
26
}
3219
3220
552
pw_aff::~pw_aff() {
3221
552
  if (ptr)
3222
354
    isl_pw_aff_free(ptr);
3223
552
}
3224
3225
367
__isl_give isl_pw_aff *pw_aff::copy() const & {
3226
367
  return isl_pw_aff_copy(ptr);
3227
367
}
3228
3229
58
__isl_keep isl_pw_aff *pw_aff::get() const {
3230
58
  return ptr;
3231
58
}
3232
3233
198
__isl_give isl_pw_aff *pw_aff::release() {
3234
198
  isl_pw_aff *tmp = ptr;
3235
198
  ptr = nullptr;
3236
198
  return tmp;
3237
198
}
3238
3239
0
__isl_keep isl_pw_aff *pw_aff::keep() const {
3240
0
  return get();
3241
0
}
3242
3243
0
__isl_give isl_pw_aff *pw_aff::take() {
3244
0
  return release();
3245
0
}
3246
3247
0
pw_aff::operator bool() const {
3248
0
  return !is_null();
3249
0
}
3250
3251
0
isl::ctx pw_aff::get_ctx() const {
3252
0
  return isl::ctx(isl_pw_aff_get_ctx(ptr));
3253
0
}
3254
3255
0
bool pw_aff::is_null() const {
3256
0
  return ptr == nullptr;
3257
0
}
3258
3259
0
std::string pw_aff::to_str() const {
3260
0
  char *Tmp = isl_pw_aff_to_str(get());
3261
0
  if (!Tmp)
3262
0
    return "";
3263
0
  std::string S(Tmp);
3264
0
  free(Tmp);
3265
0
  return S;
3266
0
}
3267
3268
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
3269
0
                                     const pw_aff &Obj) {
3270
0
  OS << Obj.to_str();
3271
0
  return OS;
3272
0
}
3273
3274
78
isl::pw_aff pw_aff::add(isl::pw_aff pwaff2) const {
3275
78
  auto res = isl_pw_aff_add(copy(), pwaff2.release());
3276
78
  return manage(res);
3277
78
}
3278
3279
23
isl::stat pw_aff::foreach_piece(const std::function<isl::stat(isl::set, isl::aff)> &fn) const {
3280
23
  auto fn_lambda = [](isl_set *arg_0, isl_aff *arg_1, void *arg_2) -> isl_stat {
3281
23
    auto *func = (std::function<isl::stat(isl::set, isl::aff)> *)arg_2;
3282
23
    stat ret = (*func) (isl::manage(arg_0), isl::manage(arg_1));
3283
23
    return isl_stat(ret);
3284
23
  };
3285
23
  auto res = isl_pw_aff_foreach_piece(get(), fn_lambda, const_cast<void*>((const void *) &fn));
3286
23
  return isl::stat(res);
3287
23
}
3288
3289
34
isl::space pw_aff::get_space() const {
3290
34
  auto res = isl_pw_aff_get_space(get());
3291
34
  return manage(res);
3292
34
}
3293
3294
0
isl::boolean pw_aff::is_cst() const {
3295
0
  auto res = isl_pw_aff_is_cst(get());
3296
0
  return res;
3297
0
}
3298
3299
34
isl::pw_aff pw_aff::mul(isl::pw_aff pwaff2) const {
3300
34
  auto res = isl_pw_aff_mul(copy(), pwaff2.release());
3301
34
  return manage(res);
3302
34
}
3303
3304
26
isl::pw_aff pw_aff::neg() const {
3305
26
  auto res = isl_pw_aff_neg(copy());
3306
26
  return manage(res);
3307
26
}
3308
3309
0
isl::pw_aff pw_aff::pullback(isl::multi_aff ma) const {
3310
0
  auto res = isl_pw_aff_pullback_multi_aff(copy(), ma.release());
3311
0
  return manage(res);
3312
0
}
3313
3314
0
isl::pw_aff pw_aff::pullback(isl::pw_multi_aff pma) const {
3315
0
  auto res = isl_pw_aff_pullback_pw_multi_aff(copy(), pma.release());
3316
0
  return manage(res);
3317
0
}
3318
3319
0
isl::pw_aff pw_aff::pullback(isl::multi_pw_aff mpa) const {
3320
0
  auto res = isl_pw_aff_pullback_multi_pw_aff(copy(), mpa.release());
3321
0
  return manage(res);
3322
0
}
3323
3324
0
isl::pw_aff pw_aff::sub(isl::pw_aff pwaff2) const {
3325
0
  auto res = isl_pw_aff_sub(copy(), pwaff2.release());
3326
0
  return manage(res);
3327
0
}
3328
3329
0
isl::pw_aff pw_aff::union_add(isl::pw_aff pwaff2) const {
3330
0
  auto res = isl_pw_aff_union_add(copy(), pwaff2.release());
3331
0
  return manage(res);
3332
0
}
3333
3334
// implementations for isl::pw_multi_aff
3335
0
isl::pw_multi_aff manage(__isl_take isl_pw_multi_aff *ptr) {
3336
0
  return pw_multi_aff(ptr);
3337
0
}
3338
3339
0
isl::pw_multi_aff give(__isl_take isl_pw_multi_aff *ptr) {
3340
0
  return manage(ptr);
3341
0
}
3342
3343
pw_multi_aff::pw_multi_aff()
3344
    : ptr(nullptr) {}
3345
3346
pw_multi_aff::pw_multi_aff(const isl::pw_multi_aff &obj)
3347
    : ptr(obj.copy()) {}
3348
3349
pw_multi_aff::pw_multi_aff(std::nullptr_t)
3350
    : ptr(nullptr) {}
3351
3352
pw_multi_aff::pw_multi_aff(__isl_take isl_pw_multi_aff *ptr)
3353
    : ptr(ptr) {}
3354
3355
pw_multi_aff::pw_multi_aff(isl::ctx ctx, const std::string &str) {
3356
  auto res = isl_pw_multi_aff_read_from_str(ctx.release(), str.c_str());
3357
  ptr = res;
3358
}
3359
3360
pw_multi_aff::pw_multi_aff(isl::multi_aff ma) {
3361
  auto res = isl_pw_multi_aff_from_multi_aff(ma.release());
3362
  ptr = res;
3363
}
3364
3365
pw_multi_aff::pw_multi_aff(isl::pw_aff pa) {
3366
  auto res = isl_pw_multi_aff_from_pw_aff(pa.release());
3367
  ptr = res;
3368
}
3369
3370
0
pw_multi_aff &pw_multi_aff::operator=(isl::pw_multi_aff obj) {
3371
0
  std::swap(this->ptr, obj.ptr);
3372
0
  return *this;
3373
0
}
3374
3375
pw_multi_aff::~pw_multi_aff() {
3376
  if (ptr)
3377
    isl_pw_multi_aff_free(ptr);
3378
}
3379
3380
0
__isl_give isl_pw_multi_aff *pw_multi_aff::copy() const & {
3381
0
  return isl_pw_multi_aff_copy(ptr);
3382
0
}
3383
3384
0
__isl_keep isl_pw_multi_aff *pw_multi_aff::get() const {
3385
0
  return ptr;
3386
0
}
3387
3388
0
__isl_give isl_pw_multi_aff *pw_multi_aff::release() {
3389
0
  isl_pw_multi_aff *tmp = ptr;
3390
0
  ptr = nullptr;
3391
0
  return tmp;
3392
0
}
3393
3394
0
__isl_keep isl_pw_multi_aff *pw_multi_aff::keep() const {
3395
0
  return get();
3396
0
}
3397
3398
0
__isl_give isl_pw_multi_aff *pw_multi_aff::take() {
3399
0
  return release();
3400
0
}
3401
3402
0
pw_multi_aff::operator bool() const {
3403
0
  return !is_null();
3404
0
}
3405
3406
0
isl::ctx pw_multi_aff::get_ctx() const {
3407
0
  return isl::ctx(isl_pw_multi_aff_get_ctx(ptr));
3408
0
}
3409
3410
0
bool pw_multi_aff::is_null() const {
3411
0
  return ptr == nullptr;
3412
0
}
3413
3414
0
std::string pw_multi_aff::to_str() const {
3415
0
  char *Tmp = isl_pw_multi_aff_to_str(get());
3416
0
  if (!Tmp)
3417
0
    return "";
3418
0
  std::string S(Tmp);
3419
0
  free(Tmp);
3420
0
  return S;
3421
0
}
3422
3423
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
3424
0
                                     const pw_multi_aff &Obj) {
3425
0
  OS << Obj.to_str();
3426
0
  return OS;
3427
0
}
3428
3429
0
isl::pw_multi_aff pw_multi_aff::add(isl::pw_multi_aff pma2) const {
3430
0
  auto res = isl_pw_multi_aff_add(copy(), pma2.release());
3431
0
  return manage(res);
3432
0
}
3433
3434
0
isl::pw_multi_aff pw_multi_aff::flat_range_product(isl::pw_multi_aff pma2) const {
3435
0
  auto res = isl_pw_multi_aff_flat_range_product(copy(), pma2.release());
3436
0
  return manage(res);
3437
0
}
3438
3439
0
isl::pw_multi_aff pw_multi_aff::product(isl::pw_multi_aff pma2) const {
3440
0
  auto res = isl_pw_multi_aff_product(copy(), pma2.release());
3441
0
  return manage(res);
3442
0
}
3443
3444
0
isl::pw_multi_aff pw_multi_aff::pullback(isl::multi_aff ma) const {
3445
0
  auto res = isl_pw_multi_aff_pullback_multi_aff(copy(), ma.release());
3446
0
  return manage(res);
3447
0
}
3448
3449
0
isl::pw_multi_aff pw_multi_aff::pullback(isl::pw_multi_aff pma2) const {
3450
0
  auto res = isl_pw_multi_aff_pullback_pw_multi_aff(copy(), pma2.release());
3451
0
  return manage(res);
3452
0
}
3453
3454
0
isl::pw_multi_aff pw_multi_aff::range_product(isl::pw_multi_aff pma2) const {
3455
0
  auto res = isl_pw_multi_aff_range_product(copy(), pma2.release());
3456
0
  return manage(res);
3457
0
}
3458
3459
0
isl::pw_multi_aff pw_multi_aff::union_add(isl::pw_multi_aff pma2) const {
3460
0
  auto res = isl_pw_multi_aff_union_add(copy(), pma2.release());
3461
0
  return manage(res);
3462
0
}
3463
3464
// implementations for isl::schedule
3465
0
isl::schedule manage(__isl_take isl_schedule *ptr) {
3466
0
  return schedule(ptr);
3467
0
}
3468
3469
0
isl::schedule give(__isl_take isl_schedule *ptr) {
3470
0
  return manage(ptr);
3471
0
}
3472
3473
schedule::schedule()
3474
    : ptr(nullptr) {}
3475
3476
schedule::schedule(const isl::schedule &obj)
3477
    : ptr(obj.copy()) {}
3478
3479
schedule::schedule(std::nullptr_t)
3480
    : ptr(nullptr) {}
3481
3482
schedule::schedule(__isl_take isl_schedule *ptr)
3483
    : ptr(ptr) {}
3484
3485
schedule::schedule(isl::ctx ctx, const std::string &str) {
3486
  auto res = isl_schedule_read_from_str(ctx.release(), str.c_str());
3487
  ptr = res;
3488
}
3489
3490
0
schedule &schedule::operator=(isl::schedule obj) {
3491
0
  std::swap(this->ptr, obj.ptr);
3492
0
  return *this;
3493
0
}
3494
3495
schedule::~schedule() {
3496
  if (ptr)
3497
    isl_schedule_free(ptr);
3498
}
3499
3500
0
__isl_give isl_schedule *schedule::copy() const & {
3501
0
  return isl_schedule_copy(ptr);
3502
0
}
3503
3504
0
__isl_keep isl_schedule *schedule::get() const {
3505
0
  return ptr;
3506
0
}
3507
3508
0
__isl_give isl_schedule *schedule::release() {
3509
0
  isl_schedule *tmp = ptr;
3510
0
  ptr = nullptr;
3511
0
  return tmp;
3512
0
}
3513
3514
0
__isl_keep isl_schedule *schedule::keep() const {
3515
0
  return get();
3516
0
}
3517
3518
0
__isl_give isl_schedule *schedule::take() {
3519
0
  return release();
3520
0
}
3521
3522
0
schedule::operator bool() const {
3523
0
  return !is_null();
3524
0
}
3525
3526
0
isl::ctx schedule::get_ctx() const {
3527
0
  return isl::ctx(isl_schedule_get_ctx(ptr));
3528
0
}
3529
3530
0
bool schedule::is_null() const {
3531
0
  return ptr == nullptr;
3532
0
}
3533
3534
0
std::string schedule::to_str() const {
3535
0
  char *Tmp = isl_schedule_to_str(get());
3536
0
  if (!Tmp)
3537
0
    return "";
3538
0
  std::string S(Tmp);
3539
0
  free(Tmp);
3540
0
  return S;
3541
0
}
3542
3543
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
3544
0
                                     const schedule &Obj) {
3545
0
  OS << Obj.to_str();
3546
0
  return OS;
3547
0
}
3548
3549
0
isl::union_map schedule::get_map() const {
3550
0
  auto res = isl_schedule_get_map(get());
3551
0
  return manage(res);
3552
0
}
3553
3554
0
isl::schedule_node schedule::get_root() const {
3555
0
  auto res = isl_schedule_get_root(get());
3556
0
  return manage(res);
3557
0
}
3558
3559
0
isl::schedule schedule::pullback(isl::union_pw_multi_aff upma) const {
3560
0
  auto res = isl_schedule_pullback_union_pw_multi_aff(copy(), upma.release());
3561
0
  return manage(res);
3562
0
}
3563
3564
// implementations for isl::schedule_constraints
3565
0
isl::schedule_constraints manage(__isl_take isl_schedule_constraints *ptr) {
3566
0
  return schedule_constraints(ptr);
3567
0
}
3568
3569
0
isl::schedule_constraints give(__isl_take isl_schedule_constraints *ptr) {
3570
0
  return manage(ptr);
3571
0
}
3572
3573
schedule_constraints::schedule_constraints()
3574
    : ptr(nullptr) {}
3575
3576
schedule_constraints::schedule_constraints(const isl::schedule_constraints &obj)
3577
    : ptr(obj.copy()) {}
3578
3579
schedule_constraints::schedule_constraints(std::nullptr_t)
3580
    : ptr(nullptr) {}
3581
3582
schedule_constraints::schedule_constraints(__isl_take isl_schedule_constraints *ptr)
3583
    : ptr(ptr) {}
3584
3585
schedule_constraints::schedule_constraints(isl::ctx ctx, const std::string &str) {
3586
  auto res = isl_schedule_constraints_read_from_str(ctx.release(), str.c_str());
3587
  ptr = res;
3588
}
3589
3590
0
schedule_constraints &schedule_constraints::operator=(isl::schedule_constraints obj) {
3591
0
  std::swap(this->ptr, obj.ptr);
3592
0
  return *this;
3593
0
}
3594
3595
schedule_constraints::~schedule_constraints() {
3596
  if (ptr)
3597
    isl_schedule_constraints_free(ptr);
3598
}
3599
3600
0
__isl_give isl_schedule_constraints *schedule_constraints::copy() const & {
3601
0
  return isl_schedule_constraints_copy(ptr);
3602
0
}
3603
3604
0
__isl_keep isl_schedule_constraints *schedule_constraints::get() const {
3605
0
  return ptr;
3606
0
}
3607
3608
0
__isl_give isl_schedule_constraints *schedule_constraints::release() {
3609
0
  isl_schedule_constraints *tmp = ptr;
3610
0
  ptr = nullptr;
3611
0
  return tmp;
3612
0
}
3613
3614
0
__isl_keep isl_schedule_constraints *schedule_constraints::keep() const {
3615
0
  return get();
3616
0
}
3617
3618
0
__isl_give isl_schedule_constraints *schedule_constraints::take() {
3619
0
  return release();
3620
0
}
3621
3622
0
schedule_constraints::operator bool() const {
3623
0
  return !is_null();
3624
0
}
3625
3626
0
isl::ctx schedule_constraints::get_ctx() const {
3627
0
  return isl::ctx(isl_schedule_constraints_get_ctx(ptr));
3628
0
}
3629
3630
0
bool schedule_constraints::is_null() const {
3631
0
  return ptr == nullptr;
3632
0
}
3633
3634
0
std::string schedule_constraints::to_str() const {
3635
0
  char *Tmp = isl_schedule_constraints_to_str(get());
3636
0
  if (!Tmp)
3637
0
    return "";
3638
0
  std::string S(Tmp);
3639
0
  free(Tmp);
3640
0
  return S;
3641
0
}
3642
3643
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
3644
0
                                     const schedule_constraints &Obj) {
3645
0
  OS << Obj.to_str();
3646
0
  return OS;
3647
0
}
3648
3649
0
isl::union_map schedule_constraints::get_coincidence() const {
3650
0
  auto res = isl_schedule_constraints_get_coincidence(get());
3651
0
  return manage(res);
3652
0
}
3653
3654
0
isl::union_map schedule_constraints::get_conditional_validity() const {
3655
0
  auto res = isl_schedule_constraints_get_conditional_validity(get());
3656
0
  return manage(res);
3657
0
}
3658
3659
0
isl::union_map schedule_constraints::get_conditional_validity_condition() const {
3660
0
  auto res = isl_schedule_constraints_get_conditional_validity_condition(get());
3661
0
  return manage(res);
3662
0
}
3663
3664
0
isl::set schedule_constraints::get_context() const {
3665
0
  auto res = isl_schedule_constraints_get_context(get());
3666
0
  return manage(res);
3667
0
}
3668
3669
0
isl::union_set schedule_constraints::get_domain() const {
3670
0
  auto res = isl_schedule_constraints_get_domain(get());
3671
0
  return manage(res);
3672
0
}
3673
3674
0
isl::union_map schedule_constraints::get_proximity() const {
3675
0
  auto res = isl_schedule_constraints_get_proximity(get());
3676
0
  return manage(res);
3677
0
}
3678
3679
0
isl::union_map schedule_constraints::get_validity() const {
3680
0
  auto res = isl_schedule_constraints_get_validity(get());
3681
0
  return manage(res);
3682
0
}
3683
3684
// implementations for isl::schedule_node
3685
193
isl::schedule_node manage(__isl_take isl_schedule_node *ptr) {
3686
193
  return schedule_node(ptr);
3687
193
}
3688
3689
0
isl::schedule_node give(__isl_take isl_schedule_node *ptr) {
3690
0
  return manage(ptr);
3691
0
}
3692
3693
schedule_node::schedule_node()
3694
    : ptr(nullptr) {}
3695
3696
schedule_node::schedule_node(const isl::schedule_node &obj)
3697
0
    : ptr(obj.copy()) {}
3698
3699
schedule_node::schedule_node(std::nullptr_t)
3700
    : ptr(nullptr) {}
3701
3702
schedule_node::schedule_node(__isl_take isl_schedule_node *ptr)
3703
193
    : ptr(ptr) {}
3704
3705
11
schedule_node &schedule_node::operator=(isl::schedule_node obj) {
3706
11
  std::swap(this->ptr, obj.ptr);
3707
11
  return *this;
3708
11
}
3709
3710
193
schedule_node::~schedule_node() {
3711
193
  if (ptr)
3712
160
    isl_schedule_node_free(ptr);
3713
193
}
3714
3715
88
__isl_give isl_schedule_node *schedule_node::copy() const & {
3716
88
  return isl_schedule_node_copy(ptr);
3717
88
}
3718
3719
121
__isl_keep isl_schedule_node *schedule_node::get() const {
3720
121
  return ptr;
3721
121
}
3722
3723
33
__isl_give isl_schedule_node *schedule_node::release() {
3724
33
  isl_schedule_node *tmp = ptr;
3725
33
  ptr = nullptr;
3726
33
  return tmp;
3727
33
}
3728
3729
121
__isl_keep isl_schedule_node *schedule_node::keep() const {
3730
121
  return get();
3731
121
}
3732
3733
33
__isl_give isl_schedule_node *schedule_node::take() {
3734
33
  return release();
3735
33
}
3736
3737
0
schedule_node::operator bool() const {
3738
0
  return !is_null();
3739
0
}
3740
3741
0
isl::ctx schedule_node::get_ctx() const {
3742
0
  return isl::ctx(isl_schedule_node_get_ctx(ptr));
3743
0
}
3744
3745
0
bool schedule_node::is_null() const {
3746
0
  return ptr == nullptr;
3747
0
}
3748
3749
0
std::string schedule_node::to_str() const {
3750
0
  char *Tmp = isl_schedule_node_to_str(get());
3751
0
  if (!Tmp)
3752
0
    return "";
3753
0
  std::string S(Tmp);
3754
0
  free(Tmp);
3755
0
  return S;
3756
0
}
3757
3758
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
3759
0
                                     const schedule_node &Obj) {
3760
0
  OS << Obj.to_str();
3761
0
  return OS;
3762
0
}
3763
3764
0
isl::boolean schedule_node::band_member_get_coincident(int pos) const {
3765
0
  auto res = isl_schedule_node_band_member_get_coincident(get(), pos);
3766
0
  return res;
3767
0
}
3768
3769
0
isl::schedule_node schedule_node::band_member_set_coincident(int pos, int coincident) const {
3770
0
  auto res = isl_schedule_node_band_member_set_coincident(copy(), pos, coincident);
3771
0
  return manage(res);
3772
0
}
3773
3774
88
isl::schedule_node schedule_node::child(int pos) const {
3775
88
  auto res = isl_schedule_node_child(copy(), pos);
3776
88
  return manage(res);
3777
88
}
3778
3779
0
isl::multi_union_pw_aff schedule_node::get_prefix_schedule_multi_union_pw_aff() const {
3780
0
  auto res = isl_schedule_node_get_prefix_schedule_multi_union_pw_aff(get());
3781
0
  return manage(res);
3782
0
}
3783
3784
0
isl::union_map schedule_node::get_prefix_schedule_union_map() const {
3785
0
  auto res = isl_schedule_node_get_prefix_schedule_union_map(get());
3786
0
  return manage(res);
3787
0
}
3788
3789
0
isl::union_pw_multi_aff schedule_node::get_prefix_schedule_union_pw_multi_aff() const {
3790
0
  auto res = isl_schedule_node_get_prefix_schedule_union_pw_multi_aff(get());
3791
0
  return manage(res);
3792
0
}
3793
3794
0
isl::schedule schedule_node::get_schedule() const {
3795
0
  auto res = isl_schedule_node_get_schedule(get());
3796
0
  return manage(res);
3797
0
}
3798
3799
0
isl::schedule_node schedule_node::parent() const {
3800
0
  auto res = isl_schedule_node_parent(copy());
3801
0
  return manage(res);
3802
0
}
3803
3804
// implementations for isl::set
3805
1.64k
isl::set manage(__isl_take isl_set *ptr) {
3806
1.64k
  return set(ptr);
3807
1.64k
}
3808
3809
816
isl::set give(__isl_take isl_set *ptr) {
3810
816
  return manage(ptr);
3811
816
}
3812
3813
set::set()
3814
    : ptr(nullptr) {}
3815
3816
set::set(const isl::set &obj)
3817
1.11k
    : ptr(obj.copy()) {}
3818
3819
set::set(std::nullptr_t)
3820
0
    : ptr(nullptr) {}
3821
3822
set::set(__isl_take isl_set *ptr)
3823
1.64k
    : ptr(ptr) {}
3824
3825
63
set::set(isl::union_set uset) {
3826
63
  auto res = isl_set_from_union_set(uset.release());
3827
63
  ptr = res;
3828
63
}
3829
3830
set::set(isl::ctx ctx, const std::string &str) {
3831
  auto res = isl_set_read_from_str(ctx.release(), str.c_str());
3832
  ptr = res;
3833
}
3834
3835
set::set(isl::basic_set bset) {
3836
  auto res = isl_set_from_basic_set(bset.release());
3837
  ptr = res;
3838
}
3839
3840
set::set(isl::point pnt) {
3841
  auto res = isl_set_from_point(pnt.release());
3842
  ptr = res;
3843
}
3844
3845
244
set &set::operator=(isl::set obj) {
3846
244
  std::swap(this->ptr, obj.ptr);
3847
244
  return *this;
3848
244
}
3849
3850
2.83k
set::~set() {
3851
2.83k
  if (ptr)
3852
1.51k
    isl_set_free(ptr);
3853
2.83k
}
3854
3855
1.40k
__isl_give isl_set *set::copy() const & {
3856
1.40k
  return isl_set_copy(ptr);
3857
1.40k
}
3858
3859
1.21k
__isl_keep isl_set *set::get() const {
3860
1.21k
  return ptr;
3861
1.21k
}
3862
3863
1.32k
__isl_give isl_set *set::release() {
3864
1.32k
  isl_set *tmp = ptr;
3865
1.32k
  ptr = nullptr;
3866
1.32k
  return tmp;
3867
1.32k
}
3868
3869
991
__isl_keep isl_set *set::keep() const {
3870
991
  return get();
3871
991
}
3872
3873
1.15k
__isl_give isl_set *set::take() {
3874
1.15k
  return release();
3875
1.15k
}
3876
3877
0
set::operator bool() const {
3878
0
  return !is_null();
3879
0
}
3880
3881
0
isl::ctx set::get_ctx() const {
3882
0
  return isl::ctx(isl_set_get_ctx(ptr));
3883
0
}
3884
3885
0
bool set::is_null() const {
3886
0
  return ptr == nullptr;
3887
0
}
3888
3889
0
std::string set::to_str() const {
3890
0
  char *Tmp = isl_set_to_str(get());
3891
0
  if (!Tmp)
3892
0
    return "";
3893
0
  std::string S(Tmp);
3894
0
  free(Tmp);
3895
0
  return S;
3896
0
}
3897
3898
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
3899
0
                                     const set &Obj) {
3900
0
  OS << Obj.to_str();
3901
0
  return OS;
3902
0
}
3903
3904
26
isl::set set::add_dims(isl::dim type, unsigned int n) const {
3905
26
  auto res = isl_set_add_dims(copy(), static_cast<enum isl_dim_type>(type), n);
3906
26
  return manage(res);
3907
26
}
3908
3909
0
isl::basic_set set::affine_hull() const {
3910
0
  auto res = isl_set_affine_hull(copy());
3911
0
  return manage(res);
3912
0
}
3913
3914
0
isl::set set::apply(isl::map map) const {
3915
0
  auto res = isl_set_apply(copy(), map.release());
3916
0
  return manage(res);
3917
0
}
3918
3919
0
isl::set set::coalesce() const {
3920
0
  auto res = isl_set_coalesce(copy());
3921
0
  return manage(res);
3922
0
}
3923
3924
0
isl::set set::complement() const {
3925
0
  auto res = isl_set_complement(copy());
3926
0
  return manage(res);
3927
0
}
3928
3929
0
isl::set set::detect_equalities() const {
3930
0
  auto res = isl_set_detect_equalities(copy());
3931
0
  return manage(res);
3932
0
}
3933
3934
115
unsigned int set::dim(isl::dim type) const {
3935
115
  auto res = isl_set_dim(get(), static_cast<enum isl_dim_type>(type));
3936
115
  return res;
3937
115
}
3938
3939
11
isl::pw_aff set::dim_max(int pos) const {
3940
11
  auto res = isl_set_dim_max(copy(), pos);
3941
11
  return manage(res);
3942
11
}
3943
3944
11
isl::pw_aff set::dim_min(int pos) const {
3945
11
  auto res = isl_set_dim_min(copy(), pos);
3946
11
  return manage(res);
3947
11
}
3948
3949
0
isl::set set::flatten() const {
3950
0
  auto res = isl_set_flatten(copy());
3951
0
  return manage(res);
3952
0
}
3953
3954
0
isl::stat set::foreach_basic_set(const std::function<isl::stat(isl::basic_set)> &fn) const {
3955
0
  auto fn_lambda = [](isl_basic_set *arg_0, void *arg_1) -> isl_stat {
3956
0
    auto *func = (std::function<isl::stat(isl::basic_set)> *)arg_1;
3957
0
    stat ret = (*func) (isl::manage(arg_0));
3958
0
    return isl_stat(ret);
3959
0
  };
3960
0
  auto res = isl_set_foreach_basic_set(get(), fn_lambda, const_cast<void*>((const void *) &fn));
3961
0
  return isl::stat(res);
3962
0
}
3963
3964
0
isl::set set::gist(isl::set context) const {
3965
0
  auto res = isl_set_gist(copy(), context.release());
3966
0
  return manage(res);
3967
0
}
3968
3969
0
isl::map set::identity() const {
3970
0
  auto res = isl_set_identity(copy());
3971
0
  return manage(res);
3972
0
}
3973
3974
0
isl::set set::intersect(isl::set set2) const {
3975
0
  auto res = isl_set_intersect(copy(), set2.release());
3976
0
  return manage(res);
3977
0
}
3978
3979
0
isl::set set::intersect_params(isl::set params) const {
3980
0
  auto res = isl_set_intersect_params(copy(), params.release());
3981
0
  return manage(res);
3982
0
}
3983
3984
52
isl::boolean set::is_bounded() const {
3985
52
  auto res = isl_set_is_bounded(get());
3986
52
  return res;
3987
52
}
3988
3989
0
isl::boolean set::is_disjoint(const isl::set &set2) const {
3990
0
  auto res = isl_set_is_disjoint(get(), set2.get());
3991
0
  return res;
3992
0
}
3993
3994
41
isl::boolean set::is_empty() const {
3995
41
  auto res = isl_set_is_empty(get());
3996
41
  return res;
3997
41
}
3998
3999
0
isl::boolean set::is_equal(const isl::set &set2) const {
4000
0
  auto res = isl_set_is_equal(get(), set2.get());
4001
0
  return res;
4002
0
}
4003
4004
0
isl::boolean set::is_strict_subset(const isl::set &set2) const {
4005
0
  auto res = isl_set_is_strict_subset(get(), set2.get());
4006
0
  return res;
4007
0
}
4008
4009
0
isl::boolean set::is_subset(const isl::set &set2) const {
4010
0
  auto res = isl_set_is_subset(get(), set2.get());
4011
0
  return res;
4012
0
}
4013
4014
0
isl::boolean set::is_wrapping() const {
4015
0
  auto res = isl_set_is_wrapping(get());
4016
0
  return res;
4017
0
}
4018
4019
0
isl::set set::lexmax() const {
4020
0
  auto res = isl_set_lexmax(copy());
4021
0
  return manage(res);
4022
0
}
4023
4024
26
isl::set set::lexmin() const {
4025
26
  auto res = isl_set_lexmin(copy());
4026
26
  return manage(res);
4027
26
}
4028
4029
0
isl::val set::max_val(const isl::aff &obj) const {
4030
0
  auto res = isl_set_max_val(get(), obj.get());
4031
0
  return manage(res);
4032
0
}
4033
4034
0
isl::val set::min_val(const isl::aff &obj) const {
4035
0
  auto res = isl_set_min_val(get(), obj.get());
4036
0
  return manage(res);
4037
0
}
4038
4039
0
isl::basic_set set::polyhedral_hull() const {
4040
0
  auto res = isl_set_polyhedral_hull(copy());
4041
0
  return manage(res);
4042
0
}
4043
4044
178
isl::set set::project_out(isl::dim type, unsigned int first, unsigned int n) const {
4045
178
  auto res = isl_set_project_out(copy(), static_cast<enum isl_dim_type>(type), first, n);
4046
178
  return manage(res);
4047
178
}
4048
4049
0
isl::basic_set set::sample() const {
4050
0
  auto res = isl_set_sample(copy());
4051
0
  return manage(res);
4052
0
}
4053
4054
0
isl::point set::sample_point() const {
4055
0
  auto res = isl_set_sample_point(copy());
4056
0
  return manage(res);
4057
0
}
4058
4059
26
isl::set set::subtract(isl::set set2) const {
4060
26
  auto res = isl_set_subtract(copy(), set2.release());
4061
26
  return manage(res);
4062
26
}
4063
4064
0
isl::set set::unite(isl::set set2) const {
4065
0
  auto res = isl_set_union(copy(), set2.release());
4066
0
  return manage(res);
4067
0
}
4068
4069
60
isl::set set::universe(isl::space dim) {
4070
60
  auto res = isl_set_universe(dim.release());
4071
60
  return manage(res);
4072
60
}
4073
4074
0
isl::basic_set set::unshifted_simple_hull() const {
4075
0
  auto res = isl_set_unshifted_simple_hull(copy());
4076
0
  return manage(res);
4077
0
}
4078
4079
// implementations for isl::space
4080
2.92k
isl::space manage(__isl_take isl_space *ptr) {
4081
2.92k
  return space(ptr);
4082
2.92k
}
4083
4084
2.16k
isl::space give(__isl_take isl_space *ptr) {
4085
2.16k
  return manage(ptr);
4086
2.16k
}
4087
4088
space::space()
4089
54
    : ptr(nullptr) {}
4090
4091
space::space(const isl::space &obj)
4092
746
    : ptr(obj.copy()) {}
4093
4094
space::space(std::nullptr_t)
4095
0
    : ptr(nullptr) {}
4096
4097
space::space(__isl_take isl_space *ptr)
4098
2.92k
    : ptr(ptr) {}
4099
4100
space::space(isl::ctx ctx, unsigned int nparam, unsigned int n_in, unsigned int n_out) {
4101
  auto res = isl_space_alloc(ctx.release(), nparam, n_in, n_out);
4102
  ptr = res;
4103
}
4104
4105
space::space(isl::ctx ctx, unsigned int nparam, unsigned int dim) {
4106
  auto res = isl_space_set_alloc(ctx.release(), nparam, dim);
4107
  ptr = res;
4108
}
4109
4110
739
space &space::operator=(isl::space obj) {
4111
739
  std::swap(this->ptr, obj.ptr);
4112
739
  return *this;
4113
739
}
4114
4115
3.72k
space::~space() {
4116
3.72k
  if (ptr)
4117
1.73k
    isl_space_free(ptr);
4118
3.72k
}
4119
4120
2.36k
__isl_give isl_space *space::copy() const & {
4121
2.36k
  return isl_space_copy(ptr);
4122
2.36k
}
4123
4124
154
__isl_keep isl_space *space::get() const {
4125
154
  return ptr;
4126
154
}
4127
4128
1.93k
__isl_give isl_space *space::release() {
4129
1.93k
  isl_space *tmp = ptr;
4130
1.93k
  ptr = nullptr;
4131
1.93k
  return tmp;
4132
1.93k
}
4133
4134
138
__isl_keep isl_space *space::keep() const {
4135
138
  return get();
4136
138
}
4137
4138
1.20k
__isl_give isl_space *space::take() {
4139
1.20k
  return release();
4140
1.20k
}
4141
4142
0
space::operator bool() const {
4143
0
  return !is_null();
4144
0
}
4145
4146
0
isl::ctx space::get_ctx() const {
4147
0
  return isl::ctx(isl_space_get_ctx(ptr));
4148
0
}
4149
4150
0
bool space::is_null() const {
4151
0
  return ptr == nullptr;
4152
0
}
4153
4154
0
std::string space::to_str() const {
4155
0
  char *Tmp = isl_space_to_str(get());
4156
0
  if (!Tmp)
4157
0
    return "";
4158
0
  std::string S(Tmp);
4159
0
  free(Tmp);
4160
0
  return S;
4161
0
}
4162
4163
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
4164
0
                                     const space &Obj) {
4165
0
  OS << Obj.to_str();
4166
0
  return OS;
4167
0
}
4168
4169
135
isl::space space::domain() const {
4170
135
  auto res = isl_space_domain(copy());
4171
135
  return manage(res);
4172
135
}
4173
4174
0
isl::boolean space::is_equal(const isl::space &space2) const {
4175
0
  auto res = isl_space_is_equal(get(), space2.get());
4176
0
  return res;
4177
0
}
4178
4179
15
isl::space space::params() const {
4180
15
  auto res = isl_space_params(copy());
4181
15
  return manage(res);
4182
15
}
4183
4184
41
isl::space space::set_from_params() const {
4185
41
  auto res = isl_space_set_from_params(copy());
4186
41
  return manage(res);
4187
41
}
4188
4189
// implementations for isl::union_access_info
4190
0
isl::union_access_info manage(__isl_take isl_union_access_info *ptr) {
4191
0
  return union_access_info(ptr);
4192
0
}
4193
4194
0
isl::union_access_info give(__isl_take isl_union_access_info *ptr) {
4195
0
  return manage(ptr);
4196
0
}
4197
4198
union_access_info::union_access_info()
4199
    : ptr(nullptr) {}
4200
4201
union_access_info::union_access_info(const isl::union_access_info &obj)
4202
    : ptr(obj.copy()) {}
4203
4204
union_access_info::union_access_info(std::nullptr_t)
4205
    : ptr(nullptr) {}
4206
4207
union_access_info::union_access_info(__isl_take isl_union_access_info *ptr)
4208
    : ptr(ptr) {}
4209
4210
union_access_info::union_access_info(isl::union_map sink) {
4211
  auto res = isl_union_access_info_from_sink(sink.release());
4212
  ptr = res;
4213
}
4214
4215
0
union_access_info &union_access_info::operator=(isl::union_access_info obj) {
4216
0
  std::swap(this->ptr, obj.ptr);
4217
0
  return *this;
4218
0
}
4219
4220
union_access_info::~union_access_info() {
4221
  if (ptr)
4222
    isl_union_access_info_free(ptr);
4223
}
4224
4225
0
__isl_give isl_union_access_info *union_access_info::copy() const & {
4226
0
  return isl_union_access_info_copy(ptr);
4227
0
}
4228
4229
0
__isl_keep isl_union_access_info *union_access_info::get() const {
4230
0
  return ptr;
4231
0
}
4232
4233
0
__isl_give isl_union_access_info *union_access_info::release() {
4234
0
  isl_union_access_info *tmp = ptr;
4235
0
  ptr = nullptr;
4236
0
  return tmp;
4237
0
}
4238
4239
0
__isl_keep isl_union_access_info *union_access_info::keep() const {
4240
0
  return get();
4241
0
}
4242
4243
0
__isl_give isl_union_access_info *union_access_info::take() {
4244
0
  return release();
4245
0
}
4246
4247
0
union_access_info::operator bool() const {
4248
0
  return !is_null();
4249
0
}
4250
4251
0
isl::ctx union_access_info::get_ctx() const {
4252
0
  return isl::ctx(isl_union_access_info_get_ctx(ptr));
4253
0
}
4254
4255
0
bool union_access_info::is_null() const {
4256
0
  return ptr == nullptr;
4257
0
}
4258
4259
0
std::string union_access_info::to_str() const {
4260
0
  char *Tmp = isl_union_access_info_to_str(get());
4261
0
  if (!Tmp)
4262
0
    return "";
4263
0
  std::string S(Tmp);
4264
0
  free(Tmp);
4265
0
  return S;
4266
0
}
4267
4268
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
4269
0
                                     const union_access_info &Obj) {
4270
0
  OS << Obj.to_str();
4271
0
  return OS;
4272
0
}
4273
4274
0
isl::union_flow union_access_info::compute_flow() const {
4275
0
  auto res = isl_union_access_info_compute_flow(copy());
4276
0
  return manage(res);
4277
0
}
4278
4279
0
isl::union_access_info union_access_info::set_may_source(isl::union_map may_source) const {
4280
0
  auto res = isl_union_access_info_set_may_source(copy(), may_source.release());
4281
0
  return manage(res);
4282
0
}
4283
4284
0
isl::union_access_info union_access_info::set_must_source(isl::union_map must_source) const {
4285
0
  auto res = isl_union_access_info_set_must_source(copy(), must_source.release());
4286
0
  return manage(res);
4287
0
}
4288
4289
0
isl::union_access_info union_access_info::set_schedule(isl::schedule schedule) const {
4290
0
  auto res = isl_union_access_info_set_schedule(copy(), schedule.release());
4291
0
  return manage(res);
4292
0
}
4293
4294
0
isl::union_access_info union_access_info::set_schedule_map(isl::union_map schedule_map) const {
4295
0
  auto res = isl_union_access_info_set_schedule_map(copy(), schedule_map.release());
4296
0
  return manage(res);
4297
0
}
4298
4299
// implementations for isl::union_flow
4300
0
isl::union_flow manage(__isl_take isl_union_flow *ptr) {
4301
0
  return union_flow(ptr);
4302
0
}
4303
4304
0
isl::union_flow give(__isl_take isl_union_flow *ptr) {
4305
0
  return manage(ptr);
4306
0
}
4307
4308
union_flow::union_flow()
4309
    : ptr(nullptr) {}
4310
4311
union_flow::union_flow(const isl::union_flow &obj)
4312
    : ptr(obj.copy()) {}
4313
4314
union_flow::union_flow(std::nullptr_t)
4315
    : ptr(nullptr) {}
4316
4317
union_flow::union_flow(__isl_take isl_union_flow *ptr)
4318
    : ptr(ptr) {}
4319
4320
0
union_flow &union_flow::operator=(isl::union_flow obj) {
4321
0
  std::swap(this->ptr, obj.ptr);
4322
0
  return *this;
4323
0
}
4324
4325
union_flow::~union_flow() {
4326
  if (ptr)
4327
    isl_union_flow_free(ptr);
4328
}
4329
4330
0
__isl_give isl_union_flow *union_flow::copy() const & {
4331
0
  return isl_union_flow_copy(ptr);
4332
0
}
4333
4334
0
__isl_keep isl_union_flow *union_flow::get() const {
4335
0
  return ptr;
4336
0
}
4337
4338
0
__isl_give isl_union_flow *union_flow::release() {
4339
0
  isl_union_flow *tmp = ptr;
4340
0
  ptr = nullptr;
4341
0
  return tmp;
4342
0
}
4343
4344
0
__isl_keep isl_union_flow *union_flow::keep() const {
4345
0
  return get();
4346
0
}
4347
4348
0
__isl_give isl_union_flow *union_flow::take() {
4349
0
  return release();
4350
0
}
4351
4352
0
union_flow::operator bool() const {
4353
0
  return !is_null();
4354
0
}
4355
4356
0
isl::ctx union_flow::get_ctx() const {
4357
0
  return isl::ctx(isl_union_flow_get_ctx(ptr));
4358
0
}
4359
4360
0
bool union_flow::is_null() const {
4361
0
  return ptr == nullptr;
4362
0
}
4363
4364
0
std::string union_flow::to_str() const {
4365
0
  char *Tmp = isl_union_flow_to_str(get());
4366
0
  if (!Tmp)
4367
0
    return "";
4368
0
  std::string S(Tmp);
4369
0
  free(Tmp);
4370
0
  return S;
4371
0
}
4372
4373
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
4374
0
                                     const union_flow &Obj) {
4375
0
  OS << Obj.to_str();
4376
0
  return OS;
4377
0
}
4378
4379
0
isl::union_map union_flow::get_full_may_dependence() const {
4380
0
  auto res = isl_union_flow_get_full_may_dependence(get());
4381
0
  return manage(res);
4382
0
}
4383
4384
0
isl::union_map union_flow::get_full_must_dependence() const {
4385
0
  auto res = isl_union_flow_get_full_must_dependence(get());
4386
0
  return manage(res);
4387
0
}
4388
4389
0
isl::union_map union_flow::get_may_dependence() const {
4390
0
  auto res = isl_union_flow_get_may_dependence(get());
4391
0
  return manage(res);
4392
0
}
4393
4394
0
isl::union_map union_flow::get_may_no_source() const {
4395
0
  auto res = isl_union_flow_get_may_no_source(get());
4396
0
  return manage(res);
4397
0
}
4398
4399
0
isl::union_map union_flow::get_must_dependence() const {
4400
0
  auto res = isl_union_flow_get_must_dependence(get());
4401
0
  return manage(res);
4402
0
}
4403
4404
0
isl::union_map union_flow::get_must_no_source() const {
4405
0
  auto res = isl_union_flow_get_must_no_source(get());
4406
0
  return manage(res);
4407
0
}
4408
4409
// implementations for isl::union_map
4410
5.51k
isl::union_map manage(__isl_take isl_union_map *ptr) {
4411
5.51k
  return union_map(ptr);
4412
5.51k
}
4413
4414
2.71k
isl::union_map give(__isl_take isl_union_map *ptr) {
4415
2.71k
  return manage(ptr);
4416
2.71k
}
4417
4418
union_map::union_map()
4419
264
    : ptr(nullptr) {}
4420
4421
union_map::union_map(const isl::union_map &obj)
4422
6.42k
    : ptr(obj.copy()) {}
4423
4424
union_map::union_map(std::nullptr_t)
4425
21
    : ptr(nullptr) {}
4426
4427
union_map::union_map(__isl_take isl_union_map *ptr)
4428
5.51k
    : ptr(ptr) {}
4429
4430
union_map::union_map(isl::ctx ctx, const std::string &str) {
4431
  auto res = isl_union_map_read_from_str(ctx.release(), str.c_str());
4432
  ptr = res;
4433
}
4434
4435
37
union_map::union_map(isl::union_pw_aff upa) {
4436
37
  auto res = isl_union_map_from_union_pw_aff(upa.release());
4437
37
  ptr = res;
4438
37
}
4439
4440
union_map::union_map(isl::basic_map bmap) {
4441
  auto res = isl_union_map_from_basic_map(bmap.release());
4442
  ptr = res;
4443
}
4444
4445
union_map::union_map(isl::map map) {
4446
  auto res = isl_union_map_from_map(map.release());
4447
  ptr = res;
4448
}
4449
4450
1.18k
union_map &union_map::operator=(isl::union_map obj) {
4451
1.18k
  std::swap(this->ptr, obj.ptr);
4452
1.18k
  return *this;
4453
1.18k
}
4454
4455
12.6k
union_map::~union_map() {
4456
12.6k
  if (ptr)
4457
9.51k
    isl_union_map_free(ptr);
4458
12.6k
}
4459
4460
11.0k
__isl_give isl_union_map *union_map::copy() const & {
4461
11.0k
  return isl_union_map_copy(ptr);
4462
11.0k
}
4463
4464
2.85k
__isl_keep isl_union_map *union_map::get() const {
4465
2.85k
  return ptr;
4466
2.85k
}
4467
4468
2.80k
__isl_give isl_union_map *union_map::release() {
4469
2.80k
  isl_union_map *tmp = ptr;
4470
2.80k
  ptr = nullptr;
4471
2.80k
  return tmp;
4472
2.80k
}
4473
4474
783
__isl_keep isl_union_map *union_map::keep() const {
4475
783
  return get();
4476
783
}
4477
4478
1.38k
__isl_give isl_union_map *union_map::take() {
4479
1.38k
  return release();
4480
1.38k
}
4481
4482
679
union_map::operator bool() const {
4483
679
  return !is_null();
4484
679
}
4485
4486
15
isl::ctx union_map::get_ctx() const {
4487
15
  return isl::ctx(isl_union_map_get_ctx(ptr));
4488
15
}
4489
4490
679
bool union_map::is_null() const {
4491
679
  return ptr == nullptr;
4492
679
}
4493
4494
4
std::string union_map::to_str() const {
4495
4
  char *Tmp = isl_union_map_to_str(get());
4496
4
  if (!Tmp)
4497
0
    return "";
4498
4
  std::string S(Tmp);
4499
4
  free(Tmp);
4500
4
  return S;
4501
4
}
4502
4503
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
4504
0
                                     const union_map &Obj) {
4505
0
  OS << Obj.to_str();
4506
0
  return OS;
4507
0
}
4508
4509
340
isl::union_map union_map::add_map(isl::map map) const {
4510
340
  auto res = isl_union_map_add_map(copy(), map.release());
4511
340
  return manage(res);
4512
340
}
4513
4514
0
isl::union_map union_map::affine_hull() const {
4515
0
  auto res = isl_union_map_affine_hull(copy());
4516
0
  return manage(res);
4517
0
}
4518
4519
3
isl::union_map union_map::apply_domain(isl::union_map umap2) const {
4520
3
  auto res = isl_union_map_apply_domain(copy(), umap2.release());
4521
3
  return manage(res);
4522
3
}
4523
4524
14
isl::union_map union_map::apply_range(isl::union_map umap2) const {
4525
14
  auto res = isl_union_map_apply_range(copy(), umap2.release());
4526
14
  return manage(res);
4527
14
}
4528
4529
0
isl::union_map union_map::coalesce() const {
4530
0
  auto res = isl_union_map_coalesce(copy());
4531
0
  return manage(res);
4532
0
}
4533
4534
0
isl::union_map union_map::compute_divs() const {
4535
0
  auto res = isl_union_map_compute_divs(copy());
4536
0
  return manage(res);
4537
0
}
4538
4539
0
isl::union_set union_map::deltas() const {
4540
0
  auto res = isl_union_map_deltas(copy());
4541
0
  return manage(res);
4542
0
}
4543
4544
0
isl::union_map union_map::detect_equalities() const {
4545
0
  auto res = isl_union_map_detect_equalities(copy());
4546
0
  return manage(res);
4547
0
}
4548
4549
1.82k
isl::union_set union_map::domain() const {
4550
1.82k
  auto res = isl_union_map_domain(copy());
4551
1.82k
  return manage(res);
4552
1.82k
}
4553
4554
0
isl::union_map union_map::domain_factor_domain() const {
4555
0
  auto res = isl_union_map_domain_factor_domain(copy());
4556
0
  return manage(res);
4557
0
}
4558
4559
0
isl::union_map union_map::domain_factor_range() const {
4560
0
  auto res = isl_union_map_domain_factor_range(copy());
4561
0
  return manage(res);
4562
0
}
4563
4564
0
isl::union_map union_map::domain_map() const {
4565
0
  auto res = isl_union_map_domain_map(copy());
4566
0
  return manage(res);
4567
0
}
4568
4569
0
isl::union_pw_multi_aff union_map::domain_map_union_pw_multi_aff() const {
4570
0
  auto res = isl_union_map_domain_map_union_pw_multi_aff(copy());
4571
0
  return manage(res);
4572
0
}
4573
4574
0
isl::union_map union_map::domain_product(isl::union_map umap2) const {
4575
0
  auto res = isl_union_map_domain_product(copy(), umap2.release());
4576
0
  return manage(res);
4577
0
}
4578
4579
642
isl::union_map union_map::empty(isl::space dim) {
4580
642
  auto res = isl_union_map_empty(dim.release());
4581
642
  return manage(res);
4582
642
}
4583
4584
0
isl::union_map union_map::factor_domain() const {
4585
0
  auto res = isl_union_map_factor_domain(copy());
4586
0
  return manage(res);
4587
0
}
4588
4589
0
isl::union_map union_map::factor_range() const {
4590
0
  auto res = isl_union_map_factor_range(copy());
4591
0
  return manage(res);
4592
0
}
4593
4594
0
isl::union_map union_map::fixed_power(isl::val exp) const {
4595
0
  auto res = isl_union_map_fixed_power_val(copy(), exp.release());
4596
0
  return manage(res);
4597
0
}
4598
4599
37
isl::union_map union_map::flat_range_product(isl::union_map umap2) const {
4600
37
  auto res = isl_union_map_flat_range_product(copy(), umap2.release());
4601
37
  return manage(res);
4602
37
}
4603
4604
1.36k
isl::stat union_map::foreach_map(const std::function<isl::stat(isl::map)> &fn) const {
4605
1.42k
  auto fn_lambda = [](isl_map *arg_0, void *arg_1) -> isl_stat {
4606
1.42k
    auto *func = (std::function<isl::stat(isl::map)> *)arg_1;
4607
1.42k
    stat ret = (*func) (isl::manage(arg_0));
4608
1.42k
    return isl_stat(ret);
4609
1.42k
  };
4610
1.36k
  auto res = isl_union_map_foreach_map(get(), fn_lambda, const_cast<void*>((const void *) &fn));
4611
1.36k
  return isl::stat(res);
4612
1.36k
}
4613
4614
0
isl::union_map union_map::from(isl::union_pw_multi_aff upma) {
4615
0
  auto res = isl_union_map_from_union_pw_multi_aff(upma.release());
4616
0
  return manage(res);
4617
0
}
4618
4619
0
isl::union_map union_map::from(isl::multi_union_pw_aff mupa) {
4620
0
  auto res = isl_union_map_from_multi_union_pw_aff(mupa.release());
4621
0
  return manage(res);
4622
0
}
4623
4624
0
isl::union_map union_map::from_domain_and_range(isl::union_set domain, isl::union_set range) {
4625
0
  auto res = isl_union_map_from_domain_and_range(domain.release(), range.release());
4626
0
  return manage(res);
4627
0
}
4628
4629
526
isl::space union_map::get_space() const {
4630
526
  auto res = isl_union_map_get_space(get());
4631
526
  return manage(res);
4632
526
}
4633
4634
0
isl::union_map union_map::gist(isl::union_map context) const {
4635
0
  auto res = isl_union_map_gist(copy(), context.release());
4636
0
  return manage(res);
4637
0
}
4638
4639
4
isl::union_map union_map::gist_domain(isl::union_set uset) const {
4640
4
  auto res = isl_union_map_gist_domain(copy(), uset.release());
4641
4
  return manage(res);
4642
4
}
4643
4644
0
isl::union_map union_map::gist_params(isl::set set) const {
4645
0
  auto res = isl_union_map_gist_params(copy(), set.release());
4646
0
  return manage(res);
4647
0
}
4648
4649
0
isl::union_map union_map::gist_range(isl::union_set uset) const {
4650
0
  auto res = isl_union_map_gist_range(copy(), uset.release());
4651
0
  return manage(res);
4652
0
}
4653
4654
782
isl::union_map union_map::intersect(isl::union_map umap2) const {
4655
782
  auto res = isl_union_map_intersect(copy(), umap2.release());
4656
782
  return manage(res);
4657
782
}
4658
4659
208
isl::union_map union_map::intersect_domain(isl::union_set uset) const {
4660
208
  auto res = isl_union_map_intersect_domain(copy(), uset.release());
4661
208
  return manage(res);
4662
208
}
4663
4664
0
isl::union_map union_map::intersect_params(isl::set set) const {
4665
0
  auto res = isl_union_map_intersect_params(copy(), set.release());
4666
0
  return manage(res);
4667
0
}
4668
4669
26
isl::union_map union_map::intersect_range(isl::union_set uset) const {
4670
26
  auto res = isl_union_map_intersect_range(copy(), uset.release());
4671
26
  return manage(res);
4672
26
}
4673
4674
0
isl::boolean union_map::is_bijective() const {
4675
0
  auto res = isl_union_map_is_bijective(get());
4676
0
  return res;
4677
0
}
4678
4679
0
isl::boolean union_map::is_empty() const {
4680
0
  auto res = isl_union_map_is_empty(get());
4681
0
  return res;
4682
0
}
4683
4684
0
isl::boolean union_map::is_equal(const isl::union_map &umap2) const {
4685
0
  auto res = isl_union_map_is_equal(get(), umap2.get());
4686
0
  return res;
4687
0
}
4688
4689
0
isl::boolean union_map::is_injective() const {
4690
0
  auto res = isl_union_map_is_injective(get());
4691
0
  return res;
4692
0
}
4693
4694
0
isl::boolean union_map::is_single_valued() const {
4695
0
  auto res = isl_union_map_is_single_valued(get());
4696
0
  return res;
4697
0
}
4698
4699
0
isl::boolean union_map::is_strict_subset(const isl::union_map &umap2) const {
4700
0
  auto res = isl_union_map_is_strict_subset(get(), umap2.get());
4701
0
  return res;
4702
0
}
4703
4704
0
isl::boolean union_map::is_subset(const isl::union_map &umap2) const {
4705
0
  auto res = isl_union_map_is_subset(get(), umap2.get());
4706
0
  return res;
4707
0
}
4708
4709
7
isl::union_map union_map::lexmax() const {
4710
7
  auto res = isl_union_map_lexmax(copy());
4711
7
  return manage(res);
4712
7
}
4713
4714
0
isl::union_map union_map::lexmin() const {
4715
0
  auto res = isl_union_map_lexmin(copy());
4716
0
  return manage(res);
4717
0
}
4718
4719
0
isl::union_map union_map::polyhedral_hull() const {
4720
0
  auto res = isl_union_map_polyhedral_hull(copy());
4721
0
  return manage(res);
4722
0
}
4723
4724
6
isl::union_map union_map::product(isl::union_map umap2) const {
4725
6
  auto res = isl_union_map_product(copy(), umap2.release());
4726
6
  return manage(res);
4727
6
}
4728
4729
59
isl::union_set union_map::range() const {
4730
59
  auto res = isl_union_map_range(copy());
4731
59
  return manage(res);
4732
59
}
4733
4734
0
isl::union_map union_map::range_factor_domain() const {
4735
0
  auto res = isl_union_map_range_factor_domain(copy());
4736
0
  return manage(res);
4737
0
}
4738
4739
0
isl::union_map union_map::range_factor_range() const {
4740
0
  auto res = isl_union_map_range_factor_range(copy());
4741
0
  return manage(res);
4742
0
}
4743
4744
0
isl::union_map union_map::range_map() const {
4745
0
  auto res = isl_union_map_range_map(copy());
4746
0
  return manage(res);
4747
0
}
4748
4749
0
isl::union_map union_map::range_product(isl::union_map umap2) const {
4750
0
  auto res = isl_union_map_range_product(copy(), umap2.release());
4751
0
  return manage(res);
4752
0
}
4753
4754
21
isl::union_map union_map::reverse() const {
4755
21
  auto res = isl_union_map_reverse(copy());
4756
21
  return manage(res);
4757
21
}
4758
4759
0
isl::union_map union_map::subtract(isl::union_map umap2) const {
4760
0
  auto res = isl_union_map_subtract(copy(), umap2.release());
4761
0
  return manage(res);
4762
0
}
4763
4764
0
isl::union_map union_map::subtract_domain(isl::union_set dom) const {
4765
0
  auto res = isl_union_map_subtract_domain(copy(), dom.release());
4766
0
  return manage(res);
4767
0
}
4768
4769
0
isl::union_map union_map::subtract_range(isl::union_set dom) const {
4770
0
  auto res = isl_union_map_subtract_range(copy(), dom.release());
4771
0
  return manage(res);
4772
0
}
4773
4774
522
isl::union_map union_map::unite(isl::union_map umap2) const {
4775
522
  auto res = isl_union_map_union(copy(), umap2.release());
4776
522
  return manage(res);
4777
522
}
4778
4779
0
isl::union_set union_map::wrap() const {
4780
0
  auto res = isl_union_map_wrap(copy());
4781
0
  return manage(res);
4782
0
}
4783
4784
0
isl::union_map union_map::zip() const {
4785
0
  auto res = isl_union_map_zip(copy());
4786
0
  return manage(res);
4787
0
}
4788
4789
// implementations for isl::union_pw_aff
4790
207
isl::union_pw_aff manage(__isl_take isl_union_pw_aff *ptr) {
4791
207
  return union_pw_aff(ptr);
4792
207
}
4793
4794
0
isl::union_pw_aff give(__isl_take isl_union_pw_aff *ptr) {
4795
0
  return manage(ptr);
4796
0
}
4797
4798
union_pw_aff::union_pw_aff()
4799
    : ptr(nullptr) {}
4800
4801
union_pw_aff::union_pw_aff(const isl::union_pw_aff &obj)
4802
144
    : ptr(obj.copy()) {}
4803
4804
union_pw_aff::union_pw_aff(std::nullptr_t)
4805
    : ptr(nullptr) {}
4806
4807
union_pw_aff::union_pw_aff(__isl_take isl_union_pw_aff *ptr)
4808
207
    : ptr(ptr) {}
4809
4810
86
union_pw_aff::union_pw_aff(isl::pw_aff pa) {
4811
86
  auto res = isl_union_pw_aff_from_pw_aff(pa.release());
4812
86
  ptr = res;
4813
86
}
4814
4815
union_pw_aff::union_pw_aff(isl::union_set domain, isl::val v) {
4816
  auto res = isl_union_pw_aff_val_on_domain(domain.release(), v.release());
4817
  ptr = res;
4818
}
4819
4820
union_pw_aff::union_pw_aff(isl::ctx ctx, const std::string &str) {
4821
  auto res = isl_union_pw_aff_read_from_str(ctx.release(), str.c_str());
4822
  ptr = res;
4823
}
4824
4825
34
union_pw_aff &union_pw_aff::operator=(isl::union_pw_aff obj) {
4826
34
  std::swap(this->ptr, obj.ptr);
4827
34
  return *this;
4828
34
}
4829
4830
438
union_pw_aff::~union_pw_aff() {
4831
438
  if (ptr)
4832
304
    isl_union_pw_aff_free(ptr);
4833
438
}
4834
4835
293
__isl_give isl_union_pw_aff *union_pw_aff::copy() const & {
4836
293
  return isl_union_pw_aff_copy(ptr);
4837
293
}
4838
4839
21
__isl_keep isl_union_pw_aff *union_pw_aff::get() const {
4840
21
  return ptr;
4841
21
}
4842
4843
134
__isl_give isl_union_pw_aff *union_pw_aff::release() {
4844
134
  isl_union_pw_aff *tmp = ptr;
4845
134
  ptr = nullptr;
4846
134
  return tmp;
4847
134
}
4848
4849
0
__isl_keep isl_union_pw_aff *union_pw_aff::keep() const {
4850
0
  return get();
4851
0
}
4852
4853
0
__isl_give isl_union_pw_aff *union_pw_aff::take() {
4854
0
  return release();
4855
0
}
4856
4857
0
union_pw_aff::operator bool() const {
4858
0
  return !is_null();
4859
0
}
4860
4861
0
isl::ctx union_pw_aff::get_ctx() const {
4862
0
  return isl::ctx(isl_union_pw_aff_get_ctx(ptr));
4863
0
}
4864
4865
0
bool union_pw_aff::is_null() const {
4866
0
  return ptr == nullptr;
4867
0
}
4868
4869
0
std::string union_pw_aff::to_str() const {
4870
0
  char *Tmp = isl_union_pw_aff_to_str(get());
4871
0
  if (!Tmp)
4872
0
    return "";
4873
0
  std::string S(Tmp);
4874
0
  free(Tmp);
4875
0
  return S;
4876
0
}
4877
4878
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
4879
0
                                     const union_pw_aff &Obj) {
4880
0
  OS << Obj.to_str();
4881
0
  return OS;
4882
0
}
4883
4884
37
isl::union_pw_aff union_pw_aff::add(isl::union_pw_aff upa2) const {
4885
37
  auto res = isl_union_pw_aff_add(copy(), upa2.release());
4886
37
  return manage(res);
4887
37
}
4888
4889
10
isl::union_pw_aff union_pw_aff::empty(isl::space space) {
4890
10
  auto res = isl_union_pw_aff_empty(space.release());
4891
10
  return manage(res);
4892
10
}
4893
4894
11
isl::stat union_pw_aff::foreach_pw_aff(const std::function<isl::stat(isl::pw_aff)> &fn) const {
4895
35
  auto fn_lambda = [](isl_pw_aff *arg_0, void *arg_1) -> isl_stat {
4896
35
    auto *func = (std::function<isl::stat(isl::pw_aff)> *)arg_1;
4897
35
    stat ret = (*func) (isl::manage(arg_0));
4898
35
    return isl_stat(ret);
4899
35
  };
4900
11
  auto res = isl_union_pw_aff_foreach_pw_aff(get(), fn_lambda, const_cast<void*>((const void *) &fn));
4901
11
  return isl::stat(res);
4902
11
}
4903
4904
10
isl::space union_pw_aff::get_space() const {
4905
10
  auto res = isl_union_pw_aff_get_space(get());
4906
10
  return manage(res);
4907
10
}
4908
4909
52
isl::union_pw_aff union_pw_aff::pullback(isl::union_pw_multi_aff upma) const {
4910
52
  auto res = isl_union_pw_aff_pullback_union_pw_multi_aff(copy(), upma.release());
4911
52
  return manage(res);
4912
52
}
4913
4914
26
isl::union_pw_aff union_pw_aff::sub(isl::union_pw_aff upa2) const {
4915
26
  auto res = isl_union_pw_aff_sub(copy(), upa2.release());
4916
26
  return manage(res);
4917
26
}
4918
4919
34
isl::union_pw_aff union_pw_aff::union_add(isl::union_pw_aff upa2) const {
4920
34
  auto res = isl_union_pw_aff_union_add(copy(), upa2.release());
4921
34
  return manage(res);
4922
34
}
4923
4924
// implementations for isl::union_pw_multi_aff
4925
11
isl::union_pw_multi_aff manage(__isl_take isl_union_pw_multi_aff *ptr) {
4926
11
  return union_pw_multi_aff(ptr);
4927
11
}
4928
4929
0
isl::union_pw_multi_aff give(__isl_take isl_union_pw_multi_aff *ptr) {
4930
0
  return manage(ptr);
4931
0
}
4932
4933
union_pw_multi_aff::union_pw_multi_aff()
4934
    : ptr(nullptr) {}
4935
4936
union_pw_multi_aff::union_pw_multi_aff(const isl::union_pw_multi_aff &obj)
4937
111
    : ptr(obj.copy()) {}
4938
4939
union_pw_multi_aff::union_pw_multi_aff(std::nullptr_t)
4940
    : ptr(nullptr) {}
4941
4942
union_pw_multi_aff::union_pw_multi_aff(__isl_take isl_union_pw_multi_aff *ptr)
4943
11
    : ptr(ptr) {}
4944
4945
union_pw_multi_aff::union_pw_multi_aff(isl::pw_multi_aff pma) {
4946
  auto res = isl_union_pw_multi_aff_from_pw_multi_aff(pma.release());
4947
  ptr = res;
4948
}
4949
4950
15
union_pw_multi_aff::union_pw_multi_aff(isl::union_set uset) {
4951
15
  auto res = isl_union_pw_multi_aff_from_domain(uset.release());
4952
15
  ptr = res;
4953
15
}
4954
4955
48
union_pw_multi_aff::union_pw_multi_aff(isl::union_map umap) {
4956
48
  auto res = isl_union_pw_multi_aff_from_union_map(umap.release());
4957
48
  ptr = res;
4958
48
}
4959
4960
union_pw_multi_aff::union_pw_multi_aff(isl::ctx ctx, const std::string &str) {
4961
  auto res = isl_union_pw_multi_aff_read_from_str(ctx.release(), str.c_str());
4962
  ptr = res;
4963
}
4964
4965
union_pw_multi_aff::union_pw_multi_aff(isl::union_pw_aff upa) {
4966
  auto res = isl_union_pw_multi_aff_from_union_pw_aff(upa.release());
4967
  ptr = res;
4968
}
4969
4970
0
union_pw_multi_aff &union_pw_multi_aff::operator=(isl::union_pw_multi_aff obj) {
4971
0
  std::swap(this->ptr, obj.ptr);
4972
0
  return *this;
4973
0
}
4974
4975
185
union_pw_multi_aff::~union_pw_multi_aff() {
4976
185
  if (ptr)
4977
74
    isl_union_pw_multi_aff_free(ptr);
4978
185
}
4979
4980
111
__isl_give isl_union_pw_multi_aff *union_pw_multi_aff::copy() const & {
4981
111
  return isl_union_pw_multi_aff_copy(ptr);
4982
111
}
4983
4984
0
__isl_keep isl_union_pw_multi_aff *union_pw_multi_aff::get() const {
4985
0
  return ptr;
4986
0
}
4987
4988
111
__isl_give isl_union_pw_multi_aff *union_pw_multi_aff::release() {
4989
111
  isl_union_pw_multi_aff *tmp = ptr;
4990
111
  ptr = nullptr;
4991
111
  return tmp;
4992
111
}
4993
4994
0
__isl_keep isl_union_pw_multi_aff *union_pw_multi_aff::keep() const {
4995
0
  return get();
4996
0
}
4997
4998
0
__isl_give isl_union_pw_multi_aff *union_pw_multi_aff::take() {
4999
0
  return release();
5000
0
}
5001
5002
0
union_pw_multi_aff::operator bool() const {
5003
0
  return !is_null();
5004
0
}
5005
5006
0
isl::ctx union_pw_multi_aff::get_ctx() const {
5007
0
  return isl::ctx(isl_union_pw_multi_aff_get_ctx(ptr));
5008
0
}
5009
5010
0
bool union_pw_multi_aff::is_null() const {
5011
0
  return ptr == nullptr;
5012
0
}
5013
5014
0
std::string union_pw_multi_aff::to_str() const {
5015
0
  char *Tmp = isl_union_pw_multi_aff_to_str(get());
5016
0
  if (!Tmp)
5017
0
    return "";
5018
0
  std::string S(Tmp);
5019
0
  free(Tmp);
5020
0
  return S;
5021
0
}
5022
5023
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
5024
0
                                     const union_pw_multi_aff &Obj) {
5025
0
  OS << Obj.to_str();
5026
0
  return OS;
5027
0
}
5028
5029
0
isl::union_pw_multi_aff union_pw_multi_aff::add(isl::union_pw_multi_aff upma2) const {
5030
0
  auto res = isl_union_pw_multi_aff_add(copy(), upma2.release());
5031
0
  return manage(res);
5032
0
}
5033
5034
0
isl::union_pw_multi_aff union_pw_multi_aff::flat_range_product(isl::union_pw_multi_aff upma2) const {
5035
0
  auto res = isl_union_pw_multi_aff_flat_range_product(copy(), upma2.release());
5036
0
  return manage(res);
5037
0
}
5038
5039
0
isl::union_pw_multi_aff union_pw_multi_aff::pullback(isl::union_pw_multi_aff upma2) const {
5040
0
  auto res = isl_union_pw_multi_aff_pullback_union_pw_multi_aff(copy(), upma2.release());
5041
0
  return manage(res);
5042
0
}
5043
5044
0
isl::union_pw_multi_aff union_pw_multi_aff::union_add(isl::union_pw_multi_aff upma2) const {
5045
0
  auto res = isl_union_pw_multi_aff_union_add(copy(), upma2.release());
5046
0
  return manage(res);
5047
0
}
5048
5049
// implementations for isl::union_set
5050
4.12k
isl::union_set manage(__isl_take isl_union_set *ptr) {
5051
4.12k
  return union_set(ptr);
5052
4.12k
}
5053
5054
1.69k
isl::union_set give(__isl_take isl_union_set *ptr) {
5055
1.69k
  return manage(ptr);
5056
1.69k
}
5057
5058
union_set::union_set()
5059
454
    : ptr(nullptr) {}
5060
5061
union_set::union_set(const isl::union_set &obj)
5062
4.91k
    : ptr(obj.copy()) {}
5063
5064
union_set::union_set(std::nullptr_t)
5065
142
    : ptr(nullptr) {}
5066
5067
union_set::union_set(__isl_take isl_union_set *ptr)
5068
4.12k
    : ptr(ptr) {}
5069
5070
union_set::union_set(isl::basic_set bset) {
5071
  auto res = isl_union_set_from_basic_set(bset.release());
5072
  ptr = res;
5073
}
5074
5075
49
union_set::union_set(isl::set set) {
5076
49
  auto res = isl_union_set_from_set(set.release());
5077
49
  ptr = res;
5078
49
}
5079
5080
union_set::union_set(isl::point pnt) {
5081
  auto res = isl_union_set_from_point(pnt.release());
5082
  ptr = res;
5083
}
5084
5085
union_set::union_set(isl::ctx ctx, const std::string &str) {
5086
  auto res = isl_union_set_read_from_str(ctx.release(), str.c_str());
5087
  ptr = res;
5088
}
5089
5090
1.31k
union_set &union_set::operator=(isl::union_set obj) {
5091
1.31k
  std::swap(this->ptr, obj.ptr);
5092
1.31k
  return *this;
5093
1.31k
}
5094
5095
9.85k
union_set::~union_set() {
5096
9.85k
  if (ptr)
5097
6.07k
    isl_union_set_free(ptr);
5098
9.85k
}
5099
5100
5.55k
__isl_give isl_union_set *union_set::copy() const & {
5101
5.55k
  return isl_union_set_copy(ptr);
5102
5.55k
}
5103
5104
2.74k
__isl_keep isl_union_set *union_set::get() const {
5105
2.74k
  return ptr;
5106
2.74k
}
5107
5108
2.53k
__isl_give isl_union_set *union_set::release() {
5109
2.53k
  isl_union_set *tmp = ptr;
5110
2.53k
  ptr = nullptr;
5111
2.53k
  return tmp;
5112
2.53k
}
5113
5114
639
__isl_keep isl_union_set *union_set::keep() const {
5115
639
  return get();
5116
639
}
5117
5118
1.88k
__isl_give isl_union_set *union_set::take() {
5119
1.88k
  return release();
5120
1.88k
}
5121
5122
543
union_set::operator bool() const {
5123
543
  return !is_null();
5124
543
}
5125
5126
0
isl::ctx union_set::get_ctx() const {
5127
0
  return isl::ctx(isl_union_set_get_ctx(ptr));
5128
0
}
5129
5130
543
bool union_set::is_null() const {
5131
543
  return ptr == nullptr;
5132
543
}
5133
5134
0
std::string union_set::to_str() const {
5135
0
  char *Tmp = isl_union_set_to_str(get());
5136
0
  if (!Tmp)
5137
0
    return "";
5138
0
  std::string S(Tmp);
5139
0
  free(Tmp);
5140
0
  return S;
5141
0
}
5142
5143
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
5144
0
                                     const union_set &Obj) {
5145
0
  OS << Obj.to_str();
5146
0
  return OS;
5147
0
}
5148
5149
6
isl::union_set union_set::affine_hull() const {
5150
6
  auto res = isl_union_set_affine_hull(copy());
5151
6
  return manage(res);
5152
6
}
5153
5154
8
isl::union_set union_set::apply(isl::union_map umap) const {
5155
8
  auto res = isl_union_set_apply(copy(), umap.release());
5156
8
  return manage(res);
5157
8
}
5158
5159
14
isl::union_set union_set::coalesce() const {
5160
14
  auto res = isl_union_set_coalesce(copy());
5161
14
  return manage(res);
5162
14
}
5163
5164
0
isl::union_set union_set::compute_divs() const {
5165
0
  auto res = isl_union_set_compute_divs(copy());
5166
0
  return manage(res);
5167
0
}
5168
5169
0
isl::union_set union_set::detect_equalities() const {
5170
0
  auto res = isl_union_set_detect_equalities(copy());
5171
0
  return manage(res);
5172
0
}
5173
5174
0
isl::stat union_set::foreach_point(const std::function<isl::stat(isl::point)> &fn) const {
5175
0
  auto fn_lambda = [](isl_point *arg_0, void *arg_1) -> isl_stat {
5176
0
    auto *func = (std::function<isl::stat(isl::point)> *)arg_1;
5177
0
    stat ret = (*func) (isl::manage(arg_0));
5178
0
    return isl_stat(ret);
5179
0
  };
5180
0
  auto res = isl_union_set_foreach_point(get(), fn_lambda, const_cast<void*>((const void *) &fn));
5181
0
  return isl::stat(res);
5182
0
}
5183
5184
472
isl::stat union_set::foreach_set(const std::function<isl::stat(isl::set)> &fn) const {
5185
489
  auto fn_lambda = [](isl_set *arg_0, void *arg_1) -> isl_stat {
5186
489
    auto *func = (std::function<isl::stat(isl::set)> *)arg_1;
5187
489
    stat ret = (*func) (isl::manage(arg_0));
5188
489
    return isl_stat(ret);
5189
489
  };
5190
472
  auto res = isl_union_set_foreach_set(get(), fn_lambda, const_cast<void*>((const void *) &fn));
5191
472
  return isl::stat(res);
5192
472
}
5193
5194
0
isl::union_set union_set::gist(isl::union_set context) const {
5195
0
  auto res = isl_union_set_gist(copy(), context.release());
5196
0
  return manage(res);
5197
0
}
5198
5199
0
isl::union_set union_set::gist_params(isl::set set) const {
5200
0
  auto res = isl_union_set_gist_params(copy(), set.release());
5201
0
  return manage(res);
5202
0
}
5203
5204
0
isl::union_map union_set::identity() const {
5205
0
  auto res = isl_union_set_identity(copy());
5206
0
  return manage(res);
5207
0
}
5208
5209
154
isl::union_set union_set::intersect(isl::union_set uset2) const {
5210
154
  auto res = isl_union_set_intersect(copy(), uset2.release());
5211
154
  return manage(res);
5212
154
}
5213
5214
0
isl::union_set union_set::intersect_params(isl::set set) const {
5215
0
  auto res = isl_union_set_intersect_params(copy(), set.release());
5216
0
  return manage(res);
5217
0
}
5218
5219
0
isl::boolean union_set::is_empty() const {
5220
0
  auto res = isl_union_set_is_empty(get());
5221
0
  return res;
5222
0
}
5223
5224
0
isl::boolean union_set::is_equal(const isl::union_set &uset2) const {
5225
0
  auto res = isl_union_set_is_equal(get(), uset2.get());
5226
0
  return res;
5227
0
}
5228
5229
0
isl::boolean union_set::is_strict_subset(const isl::union_set &uset2) const {
5230
0
  auto res = isl_union_set_is_strict_subset(get(), uset2.get());
5231
0
  return res;
5232
0
}
5233
5234
790
isl::boolean union_set::is_subset(const isl::union_set &uset2) const {
5235
790
  auto res = isl_union_set_is_subset(get(), uset2.get());
5236
790
  return res;
5237
790
}
5238
5239
0
isl::union_set union_set::lexmax() const {
5240
0
  auto res = isl_union_set_lexmax(copy());
5241
0
  return manage(res);
5242
0
}
5243
5244
0
isl::union_set union_set::lexmin() const {
5245
0
  auto res = isl_union_set_lexmin(copy());
5246
0
  return manage(res);
5247
0
}
5248
5249
0
isl::union_set union_set::polyhedral_hull() const {
5250
0
  auto res = isl_union_set_polyhedral_hull(copy());
5251
0
  return manage(res);
5252
0
}
5253
5254
0
isl::point union_set::sample_point() const {
5255
0
  auto res = isl_union_set_sample_point(copy());
5256
0
  return manage(res);
5257
0
}
5258
5259
0
isl::union_set union_set::subtract(isl::union_set uset2) const {
5260
0
  auto res = isl_union_set_subtract(copy(), uset2.release());
5261
0
  return manage(res);
5262
0
}
5263
5264
185
isl::union_set union_set::unite(isl::union_set uset2) const {
5265
185
  auto res = isl_union_set_union(copy(), uset2.release());
5266
185
  return manage(res);
5267
185
}
5268
5269
3
isl::union_map union_set::unwrap() const {
5270
3
  auto res = isl_union_set_unwrap(copy());
5271
3
  return manage(res);
5272
3
}
5273
5274
// implementations for isl::val
5275
146
isl::val manage(__isl_take isl_val *ptr) {
5276
146
  return val(ptr);
5277
146
}
5278
5279
0
isl::val give(__isl_take isl_val *ptr) {
5280
0
  return manage(ptr);
5281
0
}
5282
5283
val::val()
5284
22
    : ptr(nullptr) {}
5285
5286
val::val(const isl::val &obj)
5287
124
    : ptr(obj.copy()) {}
5288
5289
val::val(std::nullptr_t)
5290
    : ptr(nullptr) {}
5291
5292
val::val(__isl_take isl_val *ptr)
5293
146
    : ptr(ptr) {}
5294
5295
val::val(isl::ctx ctx, long i) {
5296
  auto res = isl_val_int_from_si(ctx.release(), i);
5297
  ptr = res;
5298
}
5299
5300
val::val(isl::ctx ctx, const std::string &str) {
5301
  auto res = isl_val_read_from_str(ctx.release(), str.c_str());
5302
  ptr = res;
5303
}
5304
5305
25
val &val::operator=(isl::val obj) {
5306
25
  std::swap(this->ptr, obj.ptr);
5307
25
  return *this;
5308
25
}
5309
5310
310
val::~val() {
5311
310
  if (ptr)
5312
200
    isl_val_free(ptr);
5313
310
}
5314
5315
159
__isl_give isl_val *val::copy() const & {
5316
159
  return isl_val_copy(ptr);
5317
159
}
5318
5319
108
__isl_keep isl_val *val::get() const {
5320
108
  return ptr;
5321
108
}
5322
5323
88
__isl_give isl_val *val::release() {
5324
88
  isl_val *tmp = ptr;
5325
88
  ptr = nullptr;
5326
88
  return tmp;
5327
88
}
5328
5329
0
__isl_keep isl_val *val::keep() const {
5330
0
  return get();
5331
0
}
5332
5333
0
__isl_give isl_val *val::take() {
5334
0
  return release();
5335
0
}
5336
5337
116
val::operator bool() const {
5338
116
  return !is_null();
5339
116
}
5340
5341
0
isl::ctx val::get_ctx() const {
5342
0
  return isl::ctx(isl_val_get_ctx(ptr));
5343
0
}
5344
5345
116
bool val::is_null() const {
5346
116
  return ptr == nullptr;
5347
116
}
5348
5349
0
std::string val::to_str() const {
5350
0
  char *Tmp = isl_val_to_str(get());
5351
0
  if (!Tmp)
5352
0
    return "";
5353
0
  std::string S(Tmp);
5354
0
  free(Tmp);
5355
0
  return S;
5356
0
}
5357
5358
inline llvm::raw_ostream &operator<<(llvm::raw_ostream &OS,
5359
0
                                     const val &Obj) {
5360
0
  OS << Obj.to_str();
5361
0
  return OS;
5362
0
}
5363
5364
0
isl::val val::two_exp() const {
5365
0
  auto res = isl_val_2exp(copy());
5366
0
  return manage(res);
5367
0
}
5368
5369
0
isl::val val::abs() const {
5370
0
  auto res = isl_val_abs(copy());
5371
0
  return manage(res);
5372
0
}
5373
5374
0
isl::boolean val::abs_eq(const isl::val &v2) const {
5375
0
  auto res = isl_val_abs_eq(get(), v2.get());
5376
0
  return res;
5377
0
}
5378
5379
0
isl::val val::add(isl::val v2) const {
5380
0
  auto res = isl_val_add(copy(), v2.release());
5381
0
  return manage(res);
5382
0
}
5383
5384
11
isl::val val::add_ui(unsigned long v2) const {
5385
11
  auto res = isl_val_add_ui(copy(), v2);
5386
11
  return manage(res);
5387
11
}
5388