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 {
49 enum nested_loop_type_t : kmp_int32 {
50 nested_loop_type_unkown = 0,
51 nested_loop_type_lower_triangular_matrix = 1,
52 nested_loop_type_upper_triangular_matrix = 2
62 typedef typename traits_t<T>::signed_t ST;
64 loop_type_t loop_type;
65 loop_type_t loop_iv_type;
66 comparison_t comparison;
98 kmp_loop_nest_iv_t trip_count;
108 loop_type_t loop_type;
109 loop_type_t loop_iv_type;
110 comparison_t comparison;
114 kmp_index_t outer_iv;
124 kmp_loop_nest_iv_t trip_count;
134 typedef kmp_uint64 *kmp_point_t;
141 typedef kmp_loop_nest_iv_t *kmp_iterations_t;
144 template <
typename T>
struct bounds_info_internalXX_template {
151 typename std::conditional<std::is_signed<T>::value, kmp_int64, kmp_uint64>
163 span_t span_smallest;
164 kmp_uint64 span_smallest_u64;
172 kmp_uint64 span_biggest_u64;
176 bool loop_bounds_adjusted;
180 struct bounds_info_internal_t {
185 kmp_uint64 span_smallest_u64;
188 kmp_uint64 span_biggest_u64;
191 bool loop_bounds_adjusted;
203 extern "C" kmp_loop_nest_iv_t
204 __kmpc_process_loop_nest_rectang(
ident_t *loc, kmp_int32 gtid,
216 __kmpc_calc_original_ivs_rectang(
ident_t *loc, kmp_loop_nest_iv_t new_iv,
218 kmp_uint64 *original_ivs,
241 __kmpc_for_collapsed_init(
ident_t *loc, kmp_int32 gtid,
245 kmp_int32 *plastiter);