1 #ifndef ISL_AST_TYPE_H 2 #define ISL_AST_TYPE_H 3 4 #include <isl/list.h> 5 6 #if defined(__cplusplus) 7 extern "C" { 8 #endif 9 10 struct __isl_export isl_ast_expr; 11 typedef struct isl_ast_expr isl_ast_expr; 12 13 struct __isl_export isl_ast_node; 14 typedef struct isl_ast_node isl_ast_node; 15 16 enum isl_ast_expr_op_type { 17 isl_ast_expr_op_error = -1, 18 isl_ast_expr_op_and, 19 isl_ast_expr_op_and_then, 20 isl_ast_expr_op_or, 21 isl_ast_expr_op_or_else, 22 isl_ast_expr_op_max, 23 isl_ast_expr_op_min, 24 isl_ast_expr_op_minus, 25 isl_ast_expr_op_add, 26 isl_ast_expr_op_sub, 27 isl_ast_expr_op_mul, 28 isl_ast_expr_op_div, 29 isl_ast_expr_op_fdiv_q, /* Round towards -infty */ 30 isl_ast_expr_op_pdiv_q, /* Dividend is non-negative */ 31 isl_ast_expr_op_pdiv_r, /* Dividend is non-negative */ 32 isl_ast_expr_op_zdiv_r, /* Result only compared against zero */ 33 isl_ast_expr_op_cond, 34 isl_ast_expr_op_select, 35 isl_ast_expr_op_eq, 36 isl_ast_expr_op_le, 37 isl_ast_expr_op_lt, 38 isl_ast_expr_op_ge, 39 isl_ast_expr_op_gt, 40 isl_ast_expr_op_call, 41 isl_ast_expr_op_access, 42 isl_ast_expr_op_member, 43 isl_ast_expr_op_address_of 44 }; 45 46 #define isl_ast_op_type isl_ast_expr_op_type 47 #define isl_ast_op_error isl_ast_expr_op_error 48 #define isl_ast_op_and isl_ast_expr_op_and 49 #define isl_ast_op_and_then isl_ast_expr_op_and_then 50 #define isl_ast_op_or isl_ast_expr_op_or 51 #define isl_ast_op_or_else isl_ast_expr_op_or_else 52 #define isl_ast_op_max isl_ast_expr_op_max 53 #define isl_ast_op_min isl_ast_expr_op_min 54 #define isl_ast_op_minus isl_ast_expr_op_minus 55 #define isl_ast_op_add isl_ast_expr_op_add 56 #define isl_ast_op_sub isl_ast_expr_op_sub 57 #define isl_ast_op_mul isl_ast_expr_op_mul 58 #define isl_ast_op_div isl_ast_expr_op_div 59 #define isl_ast_op_fdiv_q isl_ast_expr_op_fdiv_q 60 #define isl_ast_op_pdiv_q isl_ast_expr_op_pdiv_q 61 #define isl_ast_op_pdiv_r isl_ast_expr_op_pdiv_r 62 #define isl_ast_op_zdiv_r isl_ast_expr_op_zdiv_r 63 #define isl_ast_op_cond isl_ast_expr_op_cond 64 #define isl_ast_op_select isl_ast_expr_op_select 65 #define isl_ast_op_eq isl_ast_expr_op_eq 66 #define isl_ast_op_le isl_ast_expr_op_le 67 #define isl_ast_op_lt isl_ast_expr_op_lt 68 #define isl_ast_op_ge isl_ast_expr_op_ge 69 #define isl_ast_op_gt isl_ast_expr_op_gt 70 #define isl_ast_op_call isl_ast_expr_op_call 71 #define isl_ast_op_access isl_ast_expr_op_access 72 #define isl_ast_op_member isl_ast_expr_op_member 73 #define isl_ast_op_address_of isl_ast_expr_op_address_of 74 75 enum isl_ast_expr_type { 76 isl_ast_expr_error = -1, 77 isl_ast_expr_op, 78 isl_ast_expr_id, 79 isl_ast_expr_int 80 }; 81 82 enum isl_ast_node_type { 83 isl_ast_node_error = -1, 84 isl_ast_node_for = 1, 85 isl_ast_node_if, 86 isl_ast_node_block, 87 isl_ast_node_mark, 88 isl_ast_node_user 89 }; 90 91 enum isl_ast_loop_type { 92 isl_ast_loop_error = -1, 93 isl_ast_loop_default = 0, 94 isl_ast_loop_atomic, 95 isl_ast_loop_unroll, 96 isl_ast_loop_separate 97 }; 98 99 struct isl_ast_print_options; 100 typedef struct isl_ast_print_options isl_ast_print_options; 101 102 ISL_DECLARE_LIST_TYPE(ast_expr) 103 ISL_DECLARE_EXPORTED_LIST_TYPE(ast_node) 104 105 #if defined(__cplusplus) 106 } 107 #endif 108 109 #endif 110