13 #ifndef KMP_COLLAPSE_H
14 #define KMP_COLLAPSE_H
16 #include <type_traits>
20 typedef kmp_int32 kmp_index_t;
23 typedef kmp_uint64 kmp_loop_nest_iv_t;
26 enum comparison_t : kmp_int32 {
28 comp_greater_or_eq = 1,
37 enum loop_type_t : kmp_int32 {
55 typedef typename traits_t<T>::signed_t ST;
57 loop_type_t loop_type;
58 loop_type_t loop_iv_type;
59 comparison_t comparison;
91 kmp_loop_nest_iv_t trip_count;
101 loop_type_t loop_type;
102 loop_type_t loop_iv_type;
103 comparison_t comparison;
107 kmp_index_t outer_iv;
117 kmp_loop_nest_iv_t trip_count;
127 typedef kmp_uint64* kmp_point_t;
134 typedef kmp_loop_nest_iv_t* kmp_iterations_t;
137 template <
typename T>
struct bounds_info_internalXX_template {
144 typename std::conditional<std::is_signed<T>::value, kmp_int64, kmp_uint64>
156 span_t span_smallest;
157 kmp_uint64 span_smallest_u64;
165 kmp_uint64 span_biggest_u64;
169 bool loop_bounds_adjusted;
173 struct bounds_info_internal_t {
178 kmp_uint64 span_smallest_u64;
181 kmp_uint64 span_biggest_u64;
184 bool loop_bounds_adjusted;
196 extern "C" kmp_loop_nest_iv_t
197 __kmpc_process_loop_nest_rectang(
ident_t *loc, kmp_int32 gtid,
209 __kmpc_calc_original_ivs_rectang(
ident_t *loc, kmp_loop_nest_iv_t new_iv,
211 kmp_uint64 *original_ivs,
234 __kmpc_for_collapsed_init(
ident_t *loc, kmp_int32 gtid,
238 kmp_int32 *plastiter);