carray 3.0.5 → 3.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +233 -0
- data/README.md +1 -1
- data/carray.gemspec +3 -2
- data/ext/ca_axis_dispatch.c +6 -0
- data/ext/ca_axis_group.c +1 -1
- data/ext/ca_categorical_iterator.c +7 -7
- data/ext/ca_kernel_iterator.c +116 -231
- data/ext/ca_kernel_iterator.h +410 -254
- data/ext/ca_obj_bincmp.c +9 -1
- data/ext/ca_obj_binop.c +10 -1
- data/ext/ca_obj_bitfield.c +2 -0
- data/ext/ca_obj_byte_swap.c +2 -0
- data/ext/ca_obj_face.c +2 -0
- data/ext/ca_obj_fake.c +3 -1
- data/ext/ca_obj_grid.c +167 -12
- data/ext/ca_obj_meld.c +69 -113
- data/ext/ca_obj_moncmp.c +9 -1
- data/ext/ca_obj_monop.c +40 -2
- data/ext/ca_obj_object.c +54 -20
- data/ext/ca_obj_reduce.c +15 -1
- data/ext/ca_obj_refer.c +65 -20
- data/ext/ca_obj_remap.c +69 -10
- data/ext/ca_obj_roll.c +1 -0
- data/ext/ca_obj_select.c +4 -1
- data/ext/ca_obj_select_axis.c +1 -0
- data/ext/ca_obj_shift.c +1 -0
- data/ext/ca_obj_stack.c +310 -111
- data/ext/ca_obj_stride.c +131 -45
- data/ext/ca_obj_string.c +18 -2
- data/ext/ca_obj_tile.c +1 -0
- data/ext/ca_obj_triop.c +9 -1
- data/ext/ca_obj_window.c +1 -0
- data/ext/ca_op_ipower.c +8 -8
- data/ext/caframe_csv_reader.c +1 -1
- data/ext/carray.h +2 -1
- data/ext/carray_access.c +27 -64
- data/ext/carray_address_basis.c +134 -0
- data/ext/carray_attribute.c +8 -0
- data/ext/carray_broadcast.c +3 -4
- data/ext/carray_build_flags.h +1 -1
- data/ext/carray_cast.c +8 -11
- data/ext/carray_conversion.c +9 -5
- data/ext/carray_core.c +811 -72
- data/ext/carray_element.c +13 -9
- data/ext/carray_histogram.c +25 -3
- data/ext/carray_internal.h +147 -12
- data/ext/carray_kernels_bincmp.c +2007 -3
- data/ext/carray_kernels_binop.c +25365 -5199
- data/ext/carray_kernels_init.c +8 -8
- data/ext/carray_kernels_monop.c +10696 -3678
- data/ext/carray_kernels_reduce_aggregate.c +4429 -702
- data/ext/carray_kernels_reduce_boolean.c +1533 -15
- data/ext/carray_kernels_reduce_cumulative.c +1808 -248
- data/ext/carray_kernels_reduce_extreme.c +4508 -511
- data/ext/carray_kernels_reduce_variance.c +2284 -152
- data/ext/carray_kernels_scan.c +240 -240
- data/ext/carray_kernels_search.c +4211 -264
- data/ext/carray_kernels_sort.c +367 -450
- data/ext/carray_lazy.c +47 -0
- data/ext/carray_loop.c +1 -1
- data/ext/carray_mask.c +130 -139
- data/ext/carray_median_percentile.c +4 -4
- data/ext/carray_memory_view.c +13 -7
- data/ext/carray_operator.c +147 -44
- data/ext/carray_order.c +3 -2
- data/ext/carray_random.c +4 -1
- data/ext/carray_slab.c +97 -21
- data/ext/carray_sort.c +1 -1
- data/ext/carray_test.c +74 -19
- data/ext/carray_time_text.c +2 -2
- data/ext/extconf.rb +11 -0
- data/ext/mkkernel.rb +346 -94
- data/ext/ruby_carray.c +4 -1
- data/ext/version.h +4 -4
- data/lib/carray/attribute.rb +25 -1
- data/lib/carray/autoload_carray.rb +3 -3
- data/lib/carray/autoload_method_extension.rb +5 -3
- data/lib/carray/axis_group.rb +13 -7
- data/lib/carray/basics.rb +1 -1
- data/lib/carray/block_iterator.rb +17 -3
- data/lib/carray/categorical.rb +6 -8
- data/lib/carray/categorical_iterator.rb +2 -2
- data/lib/carray/complex.rb +2 -2
- data/lib/carray/conditional.rb +3 -2
- data/lib/carray/frame/column_verbs.rb +45 -14
- data/lib/carray/frame/convert.rb +19 -0
- data/lib/carray/frame/csv_parser.rb +32 -32
- data/lib/carray/frame/describe.rb +4 -2
- data/lib/carray/frame/frame.rb +399 -78
- data/lib/carray/frame/group.rb +679 -53
- data/lib/carray/frame/io.rb +209 -71
- data/lib/carray/frame/join.rb +146 -37
- data/lib/carray/frame/records.rb +3 -3
- data/lib/carray/frame/reshape.rb +89 -11
- data/lib/carray/frame/sort.rb +57 -9
- data/lib/carray/frame/verbs.rb +384 -49
- data/lib/carray/frame/windows.rb +44 -6
- data/lib/carray/inspect.rb +7 -2
- data/lib/carray/iterator.rb +32 -0
- data/lib/carray/lazy.rb +17 -8
- data/lib/carray/mask_gap_fill.rb +37 -17
- data/lib/carray/meld_reduce.rb +1 -1
- data/lib/carray/methods/choose.rb +3 -2
- data/lib/carray/methods/meshgrid.rb +3 -1
- data/lib/carray/runtime.rb +47 -8
- data/lib/carray/segment_iterator.rb +23 -8
- data/lib/carray/serialize.rb +34 -17
- data/lib/carray/stack.rb +18 -6
- data/lib/carray/time.rb +5 -0
- data/lib/carray/window_iterator.rb +16 -4
- data/yard-stubs/ca_obj_array.rb +26 -1
- data/yard-stubs/carray_cast.rb +8 -5
- data/yard-stubs/carray_conversion.rb +8 -2
- data/yard-stubs/carray_mask.rb +20 -1
- data/yard-stubs/carray_math.rb +31 -16
- data/yard-stubs/carray_memory_view.rb +7 -0
- data/yard-stubs/carray_test.rb +7 -4
- metadata +18 -4
data/ext/carray_kernels_scan.c
CHANGED
|
@@ -58,6 +58,7 @@ cumsum_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
58
58
|
INIT inside the macro. */
|
|
59
59
|
int8_t slab_axes[CA_RANK_MAX];
|
|
60
60
|
slab_axes[0] = (int8_t) axis;
|
|
61
|
+
|
|
61
62
|
ca_iter_state st_in, st_out;
|
|
62
63
|
int rc;
|
|
63
64
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -73,7 +74,6 @@ cumsum_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
73
74
|
rb_raise(rb_eRuntimeError,
|
|
74
75
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
75
76
|
}
|
|
76
|
-
|
|
77
77
|
char *pi, *po;
|
|
78
78
|
boolean8_t *mi, *mo;
|
|
79
79
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -100,6 +100,7 @@ cumsum_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
100
100
|
INIT inside the macro. */
|
|
101
101
|
int8_t slab_axes[CA_RANK_MAX];
|
|
102
102
|
slab_axes[0] = (int8_t) axis;
|
|
103
|
+
|
|
103
104
|
ca_iter_state st_in, st_out;
|
|
104
105
|
int rc;
|
|
105
106
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -115,7 +116,6 @@ cumsum_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
115
116
|
rb_raise(rb_eRuntimeError,
|
|
116
117
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
117
118
|
}
|
|
118
|
-
|
|
119
119
|
char *pi, *po;
|
|
120
120
|
boolean8_t *mi, *mo;
|
|
121
121
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -142,6 +142,7 @@ cumsum_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
142
142
|
INIT inside the macro. */
|
|
143
143
|
int8_t slab_axes[CA_RANK_MAX];
|
|
144
144
|
slab_axes[0] = (int8_t) axis;
|
|
145
|
+
|
|
145
146
|
ca_iter_state st_in, st_out;
|
|
146
147
|
int rc;
|
|
147
148
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -157,7 +158,6 @@ cumsum_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
157
158
|
rb_raise(rb_eRuntimeError,
|
|
158
159
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
159
160
|
}
|
|
160
|
-
|
|
161
161
|
char *pi, *po;
|
|
162
162
|
boolean8_t *mi, *mo;
|
|
163
163
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -184,6 +184,7 @@ cumsum_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
184
184
|
INIT inside the macro. */
|
|
185
185
|
int8_t slab_axes[CA_RANK_MAX];
|
|
186
186
|
slab_axes[0] = (int8_t) axis;
|
|
187
|
+
|
|
187
188
|
ca_iter_state st_in, st_out;
|
|
188
189
|
int rc;
|
|
189
190
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -199,7 +200,6 @@ cumsum_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
199
200
|
rb_raise(rb_eRuntimeError,
|
|
200
201
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
201
202
|
}
|
|
202
|
-
|
|
203
203
|
char *pi, *po;
|
|
204
204
|
boolean8_t *mi, *mo;
|
|
205
205
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -226,6 +226,7 @@ cumsum_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
226
226
|
INIT inside the macro. */
|
|
227
227
|
int8_t slab_axes[CA_RANK_MAX];
|
|
228
228
|
slab_axes[0] = (int8_t) axis;
|
|
229
|
+
|
|
229
230
|
ca_iter_state st_in, st_out;
|
|
230
231
|
int rc;
|
|
231
232
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -241,7 +242,6 @@ cumsum_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
241
242
|
rb_raise(rb_eRuntimeError,
|
|
242
243
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
243
244
|
}
|
|
244
|
-
|
|
245
245
|
char *pi, *po;
|
|
246
246
|
boolean8_t *mi, *mo;
|
|
247
247
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -268,6 +268,7 @@ cumsum_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
268
268
|
INIT inside the macro. */
|
|
269
269
|
int8_t slab_axes[CA_RANK_MAX];
|
|
270
270
|
slab_axes[0] = (int8_t) axis;
|
|
271
|
+
|
|
271
272
|
ca_iter_state st_in, st_out;
|
|
272
273
|
int rc;
|
|
273
274
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -283,7 +284,6 @@ cumsum_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
283
284
|
rb_raise(rb_eRuntimeError,
|
|
284
285
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
285
286
|
}
|
|
286
|
-
|
|
287
287
|
char *pi, *po;
|
|
288
288
|
boolean8_t *mi, *mo;
|
|
289
289
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -310,6 +310,7 @@ cumsum_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
310
310
|
INIT inside the macro. */
|
|
311
311
|
int8_t slab_axes[CA_RANK_MAX];
|
|
312
312
|
slab_axes[0] = (int8_t) axis;
|
|
313
|
+
|
|
313
314
|
ca_iter_state st_in, st_out;
|
|
314
315
|
int rc;
|
|
315
316
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -325,7 +326,6 @@ cumsum_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
325
326
|
rb_raise(rb_eRuntimeError,
|
|
326
327
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
327
328
|
}
|
|
328
|
-
|
|
329
329
|
char *pi, *po;
|
|
330
330
|
boolean8_t *mi, *mo;
|
|
331
331
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -352,6 +352,7 @@ cumsum_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
352
352
|
INIT inside the macro. */
|
|
353
353
|
int8_t slab_axes[CA_RANK_MAX];
|
|
354
354
|
slab_axes[0] = (int8_t) axis;
|
|
355
|
+
|
|
355
356
|
ca_iter_state st_in, st_out;
|
|
356
357
|
int rc;
|
|
357
358
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -367,7 +368,6 @@ cumsum_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
367
368
|
rb_raise(rb_eRuntimeError,
|
|
368
369
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
369
370
|
}
|
|
370
|
-
|
|
371
371
|
char *pi, *po;
|
|
372
372
|
boolean8_t *mi, *mo;
|
|
373
373
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -394,6 +394,7 @@ cumsum_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
394
394
|
INIT inside the macro. */
|
|
395
395
|
int8_t slab_axes[CA_RANK_MAX];
|
|
396
396
|
slab_axes[0] = (int8_t) axis;
|
|
397
|
+
|
|
397
398
|
ca_iter_state st_in, st_out;
|
|
398
399
|
int rc;
|
|
399
400
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -409,7 +410,6 @@ cumsum_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
409
410
|
rb_raise(rb_eRuntimeError,
|
|
410
411
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
411
412
|
}
|
|
412
|
-
|
|
413
413
|
char *pi, *po;
|
|
414
414
|
boolean8_t *mi, *mo;
|
|
415
415
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -436,6 +436,7 @@ cumsum_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
436
436
|
INIT inside the macro. */
|
|
437
437
|
int8_t slab_axes[CA_RANK_MAX];
|
|
438
438
|
slab_axes[0] = (int8_t) axis;
|
|
439
|
+
|
|
439
440
|
ca_iter_state st_in, st_out;
|
|
440
441
|
int rc;
|
|
441
442
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -451,7 +452,6 @@ cumsum_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
451
452
|
rb_raise(rb_eRuntimeError,
|
|
452
453
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
453
454
|
}
|
|
454
|
-
|
|
455
455
|
char *pi, *po;
|
|
456
456
|
boolean8_t *mi, *mo;
|
|
457
457
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -478,6 +478,7 @@ cumsum_ki_native_cmplx64 (VALUE self, CArray *ca, int axis)
|
|
|
478
478
|
INIT inside the macro. */
|
|
479
479
|
int8_t slab_axes[CA_RANK_MAX];
|
|
480
480
|
slab_axes[0] = (int8_t) axis;
|
|
481
|
+
|
|
481
482
|
ca_iter_state st_in, st_out;
|
|
482
483
|
int rc;
|
|
483
484
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -493,7 +494,6 @@ cumsum_ki_native_cmplx64 (VALUE self, CArray *ca, int axis)
|
|
|
493
494
|
rb_raise(rb_eRuntimeError,
|
|
494
495
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
495
496
|
}
|
|
496
|
-
|
|
497
497
|
char *pi, *po;
|
|
498
498
|
boolean8_t *mi, *mo;
|
|
499
499
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -520,6 +520,7 @@ cumsum_ki_native_cmplx128 (VALUE self, CArray *ca, int axis)
|
|
|
520
520
|
INIT inside the macro. */
|
|
521
521
|
int8_t slab_axes[CA_RANK_MAX];
|
|
522
522
|
slab_axes[0] = (int8_t) axis;
|
|
523
|
+
|
|
523
524
|
ca_iter_state st_in, st_out;
|
|
524
525
|
int rc;
|
|
525
526
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -535,7 +536,6 @@ cumsum_ki_native_cmplx128 (VALUE self, CArray *ca, int axis)
|
|
|
535
536
|
rb_raise(rb_eRuntimeError,
|
|
536
537
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
537
538
|
}
|
|
538
|
-
|
|
539
539
|
char *pi, *po;
|
|
540
540
|
boolean8_t *mi, *mo;
|
|
541
541
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -562,6 +562,7 @@ cumsum_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
562
562
|
INIT inside the macro. */
|
|
563
563
|
int8_t slab_axes[CA_RANK_MAX];
|
|
564
564
|
slab_axes[0] = (int8_t) axis;
|
|
565
|
+
|
|
565
566
|
ca_iter_state st_in, st_out;
|
|
566
567
|
int rc;
|
|
567
568
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -577,7 +578,6 @@ cumsum_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
577
578
|
rb_raise(rb_eRuntimeError,
|
|
578
579
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
579
580
|
}
|
|
580
|
-
|
|
581
581
|
char *pi, *po;
|
|
582
582
|
boolean8_t *mi, *mo;
|
|
583
583
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -591,9 +591,9 @@ cumsum_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
591
591
|
return vout;
|
|
592
592
|
}
|
|
593
593
|
|
|
594
|
-
/* The
|
|
595
|
-
|
|
596
|
-
finishes them however the body leaves. */
|
|
594
|
+
/* The walks can raise part way (a Ruby call per cell in the object
|
|
595
|
+
lane, an allocation in any lane). Their states live in the caller's
|
|
596
|
+
frame, and ca_iter_ensure finishes them however the body leaves. */
|
|
597
597
|
typedef struct {
|
|
598
598
|
ca_iter_state states[2];
|
|
599
599
|
VALUE self;
|
|
@@ -623,6 +623,7 @@ cumsum_ki_native_object_body (VALUE arg)
|
|
|
623
623
|
INIT inside the macro. */
|
|
624
624
|
int8_t slab_axes[CA_RANK_MAX];
|
|
625
625
|
slab_axes[0] = (int8_t) axis;
|
|
626
|
+
|
|
626
627
|
int rc;
|
|
627
628
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
628
629
|
slab_axes, 1, 0);
|
|
@@ -637,7 +638,6 @@ cumsum_ki_native_object_body (VALUE arg)
|
|
|
637
638
|
rb_raise(rb_eRuntimeError,
|
|
638
639
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
639
640
|
}
|
|
640
|
-
|
|
641
641
|
char *pi, *po;
|
|
642
642
|
boolean8_t *mi, *mo;
|
|
643
643
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -660,7 +660,7 @@ cumsum_ki_native_object (VALUE self, CArray *ca, int axis)
|
|
|
660
660
|
fr.self = self;
|
|
661
661
|
fr.ca = ca;
|
|
662
662
|
fr.axis = axis;
|
|
663
|
-
return
|
|
663
|
+
return ca_iter_ensure_computing(ca, 2, fr.states, cumsum_ki_native_object_body, (VALUE) &fr);
|
|
664
664
|
}
|
|
665
665
|
|
|
666
666
|
|
|
@@ -747,6 +747,7 @@ cumsum_in_own_type_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
747
747
|
INIT inside the macro. */
|
|
748
748
|
int8_t slab_axes[CA_RANK_MAX];
|
|
749
749
|
slab_axes[0] = (int8_t) axis;
|
|
750
|
+
|
|
750
751
|
ca_iter_state st_in, st_out;
|
|
751
752
|
int rc;
|
|
752
753
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -762,7 +763,6 @@ cumsum_in_own_type_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
762
763
|
rb_raise(rb_eRuntimeError,
|
|
763
764
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
764
765
|
}
|
|
765
|
-
|
|
766
766
|
char *pi, *po;
|
|
767
767
|
boolean8_t *mi, *mo;
|
|
768
768
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -789,6 +789,7 @@ cumsum_in_own_type_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
789
789
|
INIT inside the macro. */
|
|
790
790
|
int8_t slab_axes[CA_RANK_MAX];
|
|
791
791
|
slab_axes[0] = (int8_t) axis;
|
|
792
|
+
|
|
792
793
|
ca_iter_state st_in, st_out;
|
|
793
794
|
int rc;
|
|
794
795
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -804,7 +805,6 @@ cumsum_in_own_type_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
804
805
|
rb_raise(rb_eRuntimeError,
|
|
805
806
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
806
807
|
}
|
|
807
|
-
|
|
808
808
|
char *pi, *po;
|
|
809
809
|
boolean8_t *mi, *mo;
|
|
810
810
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -831,6 +831,7 @@ cumsum_in_own_type_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
831
831
|
INIT inside the macro. */
|
|
832
832
|
int8_t slab_axes[CA_RANK_MAX];
|
|
833
833
|
slab_axes[0] = (int8_t) axis;
|
|
834
|
+
|
|
834
835
|
ca_iter_state st_in, st_out;
|
|
835
836
|
int rc;
|
|
836
837
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -846,7 +847,6 @@ cumsum_in_own_type_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
846
847
|
rb_raise(rb_eRuntimeError,
|
|
847
848
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
848
849
|
}
|
|
849
|
-
|
|
850
850
|
char *pi, *po;
|
|
851
851
|
boolean8_t *mi, *mo;
|
|
852
852
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -873,6 +873,7 @@ cumsum_in_own_type_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
873
873
|
INIT inside the macro. */
|
|
874
874
|
int8_t slab_axes[CA_RANK_MAX];
|
|
875
875
|
slab_axes[0] = (int8_t) axis;
|
|
876
|
+
|
|
876
877
|
ca_iter_state st_in, st_out;
|
|
877
878
|
int rc;
|
|
878
879
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -888,7 +889,6 @@ cumsum_in_own_type_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
888
889
|
rb_raise(rb_eRuntimeError,
|
|
889
890
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
890
891
|
}
|
|
891
|
-
|
|
892
892
|
char *pi, *po;
|
|
893
893
|
boolean8_t *mi, *mo;
|
|
894
894
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -915,6 +915,7 @@ cumsum_in_own_type_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
915
915
|
INIT inside the macro. */
|
|
916
916
|
int8_t slab_axes[CA_RANK_MAX];
|
|
917
917
|
slab_axes[0] = (int8_t) axis;
|
|
918
|
+
|
|
918
919
|
ca_iter_state st_in, st_out;
|
|
919
920
|
int rc;
|
|
920
921
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -930,7 +931,6 @@ cumsum_in_own_type_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
930
931
|
rb_raise(rb_eRuntimeError,
|
|
931
932
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
932
933
|
}
|
|
933
|
-
|
|
934
934
|
char *pi, *po;
|
|
935
935
|
boolean8_t *mi, *mo;
|
|
936
936
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -957,6 +957,7 @@ cumsum_in_own_type_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
957
957
|
INIT inside the macro. */
|
|
958
958
|
int8_t slab_axes[CA_RANK_MAX];
|
|
959
959
|
slab_axes[0] = (int8_t) axis;
|
|
960
|
+
|
|
960
961
|
ca_iter_state st_in, st_out;
|
|
961
962
|
int rc;
|
|
962
963
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -972,7 +973,6 @@ cumsum_in_own_type_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
972
973
|
rb_raise(rb_eRuntimeError,
|
|
973
974
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
974
975
|
}
|
|
975
|
-
|
|
976
976
|
char *pi, *po;
|
|
977
977
|
boolean8_t *mi, *mo;
|
|
978
978
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -999,6 +999,7 @@ cumsum_in_own_type_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
999
999
|
INIT inside the macro. */
|
|
1000
1000
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1001
1001
|
slab_axes[0] = (int8_t) axis;
|
|
1002
|
+
|
|
1002
1003
|
ca_iter_state st_in, st_out;
|
|
1003
1004
|
int rc;
|
|
1004
1005
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1014,7 +1015,6 @@ cumsum_in_own_type_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
1014
1015
|
rb_raise(rb_eRuntimeError,
|
|
1015
1016
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1016
1017
|
}
|
|
1017
|
-
|
|
1018
1018
|
char *pi, *po;
|
|
1019
1019
|
boolean8_t *mi, *mo;
|
|
1020
1020
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1041,6 +1041,7 @@ cumsum_in_own_type_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
1041
1041
|
INIT inside the macro. */
|
|
1042
1042
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1043
1043
|
slab_axes[0] = (int8_t) axis;
|
|
1044
|
+
|
|
1044
1045
|
ca_iter_state st_in, st_out;
|
|
1045
1046
|
int rc;
|
|
1046
1047
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1056,7 +1057,6 @@ cumsum_in_own_type_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
1056
1057
|
rb_raise(rb_eRuntimeError,
|
|
1057
1058
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1058
1059
|
}
|
|
1059
|
-
|
|
1060
1060
|
char *pi, *po;
|
|
1061
1061
|
boolean8_t *mi, *mo;
|
|
1062
1062
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1141,6 +1141,7 @@ cumprod_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
1141
1141
|
INIT inside the macro. */
|
|
1142
1142
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1143
1143
|
slab_axes[0] = (int8_t) axis;
|
|
1144
|
+
|
|
1144
1145
|
ca_iter_state st_in, st_out;
|
|
1145
1146
|
int rc;
|
|
1146
1147
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1156,7 +1157,6 @@ cumprod_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
1156
1157
|
rb_raise(rb_eRuntimeError,
|
|
1157
1158
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1158
1159
|
}
|
|
1159
|
-
|
|
1160
1160
|
char *pi, *po;
|
|
1161
1161
|
boolean8_t *mi, *mo;
|
|
1162
1162
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1183,6 +1183,7 @@ cumprod_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
1183
1183
|
INIT inside the macro. */
|
|
1184
1184
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1185
1185
|
slab_axes[0] = (int8_t) axis;
|
|
1186
|
+
|
|
1186
1187
|
ca_iter_state st_in, st_out;
|
|
1187
1188
|
int rc;
|
|
1188
1189
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1198,7 +1199,6 @@ cumprod_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
1198
1199
|
rb_raise(rb_eRuntimeError,
|
|
1199
1200
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1200
1201
|
}
|
|
1201
|
-
|
|
1202
1202
|
char *pi, *po;
|
|
1203
1203
|
boolean8_t *mi, *mo;
|
|
1204
1204
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1225,6 +1225,7 @@ cumprod_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
1225
1225
|
INIT inside the macro. */
|
|
1226
1226
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1227
1227
|
slab_axes[0] = (int8_t) axis;
|
|
1228
|
+
|
|
1228
1229
|
ca_iter_state st_in, st_out;
|
|
1229
1230
|
int rc;
|
|
1230
1231
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1240,7 +1241,6 @@ cumprod_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
1240
1241
|
rb_raise(rb_eRuntimeError,
|
|
1241
1242
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1242
1243
|
}
|
|
1243
|
-
|
|
1244
1244
|
char *pi, *po;
|
|
1245
1245
|
boolean8_t *mi, *mo;
|
|
1246
1246
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1267,6 +1267,7 @@ cumprod_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
1267
1267
|
INIT inside the macro. */
|
|
1268
1268
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1269
1269
|
slab_axes[0] = (int8_t) axis;
|
|
1270
|
+
|
|
1270
1271
|
ca_iter_state st_in, st_out;
|
|
1271
1272
|
int rc;
|
|
1272
1273
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1282,7 +1283,6 @@ cumprod_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
1282
1283
|
rb_raise(rb_eRuntimeError,
|
|
1283
1284
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1284
1285
|
}
|
|
1285
|
-
|
|
1286
1286
|
char *pi, *po;
|
|
1287
1287
|
boolean8_t *mi, *mo;
|
|
1288
1288
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1309,6 +1309,7 @@ cumprod_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
1309
1309
|
INIT inside the macro. */
|
|
1310
1310
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1311
1311
|
slab_axes[0] = (int8_t) axis;
|
|
1312
|
+
|
|
1312
1313
|
ca_iter_state st_in, st_out;
|
|
1313
1314
|
int rc;
|
|
1314
1315
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1324,7 +1325,6 @@ cumprod_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
1324
1325
|
rb_raise(rb_eRuntimeError,
|
|
1325
1326
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1326
1327
|
}
|
|
1327
|
-
|
|
1328
1328
|
char *pi, *po;
|
|
1329
1329
|
boolean8_t *mi, *mo;
|
|
1330
1330
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1351,6 +1351,7 @@ cumprod_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
1351
1351
|
INIT inside the macro. */
|
|
1352
1352
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1353
1353
|
slab_axes[0] = (int8_t) axis;
|
|
1354
|
+
|
|
1354
1355
|
ca_iter_state st_in, st_out;
|
|
1355
1356
|
int rc;
|
|
1356
1357
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1366,7 +1367,6 @@ cumprod_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
1366
1367
|
rb_raise(rb_eRuntimeError,
|
|
1367
1368
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1368
1369
|
}
|
|
1369
|
-
|
|
1370
1370
|
char *pi, *po;
|
|
1371
1371
|
boolean8_t *mi, *mo;
|
|
1372
1372
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1393,6 +1393,7 @@ cumprod_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
1393
1393
|
INIT inside the macro. */
|
|
1394
1394
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1395
1395
|
slab_axes[0] = (int8_t) axis;
|
|
1396
|
+
|
|
1396
1397
|
ca_iter_state st_in, st_out;
|
|
1397
1398
|
int rc;
|
|
1398
1399
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1408,7 +1409,6 @@ cumprod_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
1408
1409
|
rb_raise(rb_eRuntimeError,
|
|
1409
1410
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1410
1411
|
}
|
|
1411
|
-
|
|
1412
1412
|
char *pi, *po;
|
|
1413
1413
|
boolean8_t *mi, *mo;
|
|
1414
1414
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1435,6 +1435,7 @@ cumprod_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
1435
1435
|
INIT inside the macro. */
|
|
1436
1436
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1437
1437
|
slab_axes[0] = (int8_t) axis;
|
|
1438
|
+
|
|
1438
1439
|
ca_iter_state st_in, st_out;
|
|
1439
1440
|
int rc;
|
|
1440
1441
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1450,7 +1451,6 @@ cumprod_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
1450
1451
|
rb_raise(rb_eRuntimeError,
|
|
1451
1452
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1452
1453
|
}
|
|
1453
|
-
|
|
1454
1454
|
char *pi, *po;
|
|
1455
1455
|
boolean8_t *mi, *mo;
|
|
1456
1456
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1477,6 +1477,7 @@ cumprod_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
1477
1477
|
INIT inside the macro. */
|
|
1478
1478
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1479
1479
|
slab_axes[0] = (int8_t) axis;
|
|
1480
|
+
|
|
1480
1481
|
ca_iter_state st_in, st_out;
|
|
1481
1482
|
int rc;
|
|
1482
1483
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1492,7 +1493,6 @@ cumprod_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
1492
1493
|
rb_raise(rb_eRuntimeError,
|
|
1493
1494
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1494
1495
|
}
|
|
1495
|
-
|
|
1496
1496
|
char *pi, *po;
|
|
1497
1497
|
boolean8_t *mi, *mo;
|
|
1498
1498
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1519,6 +1519,7 @@ cumprod_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
1519
1519
|
INIT inside the macro. */
|
|
1520
1520
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1521
1521
|
slab_axes[0] = (int8_t) axis;
|
|
1522
|
+
|
|
1522
1523
|
ca_iter_state st_in, st_out;
|
|
1523
1524
|
int rc;
|
|
1524
1525
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1534,7 +1535,6 @@ cumprod_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
1534
1535
|
rb_raise(rb_eRuntimeError,
|
|
1535
1536
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1536
1537
|
}
|
|
1537
|
-
|
|
1538
1538
|
char *pi, *po;
|
|
1539
1539
|
boolean8_t *mi, *mo;
|
|
1540
1540
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1561,6 +1561,7 @@ cumprod_ki_native_cmplx64 (VALUE self, CArray *ca, int axis)
|
|
|
1561
1561
|
INIT inside the macro. */
|
|
1562
1562
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1563
1563
|
slab_axes[0] = (int8_t) axis;
|
|
1564
|
+
|
|
1564
1565
|
ca_iter_state st_in, st_out;
|
|
1565
1566
|
int rc;
|
|
1566
1567
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1576,7 +1577,6 @@ cumprod_ki_native_cmplx64 (VALUE self, CArray *ca, int axis)
|
|
|
1576
1577
|
rb_raise(rb_eRuntimeError,
|
|
1577
1578
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1578
1579
|
}
|
|
1579
|
-
|
|
1580
1580
|
char *pi, *po;
|
|
1581
1581
|
boolean8_t *mi, *mo;
|
|
1582
1582
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1603,6 +1603,7 @@ cumprod_ki_native_cmplx128 (VALUE self, CArray *ca, int axis)
|
|
|
1603
1603
|
INIT inside the macro. */
|
|
1604
1604
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1605
1605
|
slab_axes[0] = (int8_t) axis;
|
|
1606
|
+
|
|
1606
1607
|
ca_iter_state st_in, st_out;
|
|
1607
1608
|
int rc;
|
|
1608
1609
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1618,7 +1619,6 @@ cumprod_ki_native_cmplx128 (VALUE self, CArray *ca, int axis)
|
|
|
1618
1619
|
rb_raise(rb_eRuntimeError,
|
|
1619
1620
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1620
1621
|
}
|
|
1621
|
-
|
|
1622
1622
|
char *pi, *po;
|
|
1623
1623
|
boolean8_t *mi, *mo;
|
|
1624
1624
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1645,6 +1645,7 @@ cumprod_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
1645
1645
|
INIT inside the macro. */
|
|
1646
1646
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1647
1647
|
slab_axes[0] = (int8_t) axis;
|
|
1648
|
+
|
|
1648
1649
|
ca_iter_state st_in, st_out;
|
|
1649
1650
|
int rc;
|
|
1650
1651
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1660,7 +1661,6 @@ cumprod_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
1660
1661
|
rb_raise(rb_eRuntimeError,
|
|
1661
1662
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1662
1663
|
}
|
|
1663
|
-
|
|
1664
1664
|
char *pi, *po;
|
|
1665
1665
|
boolean8_t *mi, *mo;
|
|
1666
1666
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1674,9 +1674,9 @@ cumprod_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
1674
1674
|
return vout;
|
|
1675
1675
|
}
|
|
1676
1676
|
|
|
1677
|
-
/* The
|
|
1678
|
-
|
|
1679
|
-
finishes them however the body leaves. */
|
|
1677
|
+
/* The walks can raise part way (a Ruby call per cell in the object
|
|
1678
|
+
lane, an allocation in any lane). Their states live in the caller's
|
|
1679
|
+
frame, and ca_iter_ensure finishes them however the body leaves. */
|
|
1680
1680
|
typedef struct {
|
|
1681
1681
|
ca_iter_state states[2];
|
|
1682
1682
|
VALUE self;
|
|
@@ -1706,6 +1706,7 @@ cumprod_ki_native_object_body (VALUE arg)
|
|
|
1706
1706
|
INIT inside the macro. */
|
|
1707
1707
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1708
1708
|
slab_axes[0] = (int8_t) axis;
|
|
1709
|
+
|
|
1709
1710
|
int rc;
|
|
1710
1711
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
1711
1712
|
slab_axes, 1, 0);
|
|
@@ -1720,7 +1721,6 @@ cumprod_ki_native_object_body (VALUE arg)
|
|
|
1720
1721
|
rb_raise(rb_eRuntimeError,
|
|
1721
1722
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1722
1723
|
}
|
|
1723
|
-
|
|
1724
1724
|
char *pi, *po;
|
|
1725
1725
|
boolean8_t *mi, *mo;
|
|
1726
1726
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1743,7 +1743,7 @@ cumprod_ki_native_object (VALUE self, CArray *ca, int axis)
|
|
|
1743
1743
|
fr.self = self;
|
|
1744
1744
|
fr.ca = ca;
|
|
1745
1745
|
fr.axis = axis;
|
|
1746
|
-
return
|
|
1746
|
+
return ca_iter_ensure_computing(ca, 2, fr.states, cumprod_ki_native_object_body, (VALUE) &fr);
|
|
1747
1747
|
}
|
|
1748
1748
|
|
|
1749
1749
|
|
|
@@ -1830,6 +1830,13 @@ cummax_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
1830
1830
|
INIT inside the macro. */
|
|
1831
1831
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1832
1832
|
slab_axes[0] = (int8_t) axis;
|
|
1833
|
+
|
|
1834
|
+
boolean8_t *op_mask = NULL;
|
|
1835
|
+
if ( ca_has_mask(ca) ) {
|
|
1836
|
+
ca_create_mask(co);
|
|
1837
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
1838
|
+
}
|
|
1839
|
+
|
|
1833
1840
|
ca_iter_state st_in, st_out;
|
|
1834
1841
|
int rc;
|
|
1835
1842
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1845,13 +1852,6 @@ cummax_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
1845
1852
|
rb_raise(rb_eRuntimeError,
|
|
1846
1853
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1847
1854
|
}
|
|
1848
|
-
|
|
1849
|
-
boolean8_t *op_mask = NULL;
|
|
1850
|
-
if ( ca_has_mask(ca) ) {
|
|
1851
|
-
ca_create_mask(co);
|
|
1852
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
1853
|
-
}
|
|
1854
|
-
|
|
1855
1855
|
char *pi, *po;
|
|
1856
1856
|
boolean8_t *mi, *mo;
|
|
1857
1857
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1881,6 +1881,13 @@ cummax_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
1881
1881
|
INIT inside the macro. */
|
|
1882
1882
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1883
1883
|
slab_axes[0] = (int8_t) axis;
|
|
1884
|
+
|
|
1885
|
+
boolean8_t *op_mask = NULL;
|
|
1886
|
+
if ( ca_has_mask(ca) ) {
|
|
1887
|
+
ca_create_mask(co);
|
|
1888
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
1889
|
+
}
|
|
1890
|
+
|
|
1884
1891
|
ca_iter_state st_in, st_out;
|
|
1885
1892
|
int rc;
|
|
1886
1893
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1896,13 +1903,6 @@ cummax_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
1896
1903
|
rb_raise(rb_eRuntimeError,
|
|
1897
1904
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1898
1905
|
}
|
|
1899
|
-
|
|
1900
|
-
boolean8_t *op_mask = NULL;
|
|
1901
|
-
if ( ca_has_mask(ca) ) {
|
|
1902
|
-
ca_create_mask(co);
|
|
1903
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
1904
|
-
}
|
|
1905
|
-
|
|
1906
1906
|
char *pi, *po;
|
|
1907
1907
|
boolean8_t *mi, *mo;
|
|
1908
1908
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1932,6 +1932,13 @@ cummax_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
1932
1932
|
INIT inside the macro. */
|
|
1933
1933
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1934
1934
|
slab_axes[0] = (int8_t) axis;
|
|
1935
|
+
|
|
1936
|
+
boolean8_t *op_mask = NULL;
|
|
1937
|
+
if ( ca_has_mask(ca) ) {
|
|
1938
|
+
ca_create_mask(co);
|
|
1939
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
1940
|
+
}
|
|
1941
|
+
|
|
1935
1942
|
ca_iter_state st_in, st_out;
|
|
1936
1943
|
int rc;
|
|
1937
1944
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1947,13 +1954,6 @@ cummax_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
1947
1954
|
rb_raise(rb_eRuntimeError,
|
|
1948
1955
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
1949
1956
|
}
|
|
1950
|
-
|
|
1951
|
-
boolean8_t *op_mask = NULL;
|
|
1952
|
-
if ( ca_has_mask(ca) ) {
|
|
1953
|
-
ca_create_mask(co);
|
|
1954
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
1955
|
-
}
|
|
1956
|
-
|
|
1957
1957
|
char *pi, *po;
|
|
1958
1958
|
boolean8_t *mi, *mo;
|
|
1959
1959
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -1983,6 +1983,13 @@ cummax_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
1983
1983
|
INIT inside the macro. */
|
|
1984
1984
|
int8_t slab_axes[CA_RANK_MAX];
|
|
1985
1985
|
slab_axes[0] = (int8_t) axis;
|
|
1986
|
+
|
|
1987
|
+
boolean8_t *op_mask = NULL;
|
|
1988
|
+
if ( ca_has_mask(ca) ) {
|
|
1989
|
+
ca_create_mask(co);
|
|
1990
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
1991
|
+
}
|
|
1992
|
+
|
|
1986
1993
|
ca_iter_state st_in, st_out;
|
|
1987
1994
|
int rc;
|
|
1988
1995
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -1998,13 +2005,6 @@ cummax_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
1998
2005
|
rb_raise(rb_eRuntimeError,
|
|
1999
2006
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2000
2007
|
}
|
|
2001
|
-
|
|
2002
|
-
boolean8_t *op_mask = NULL;
|
|
2003
|
-
if ( ca_has_mask(ca) ) {
|
|
2004
|
-
ca_create_mask(co);
|
|
2005
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2006
|
-
}
|
|
2007
|
-
|
|
2008
2008
|
char *pi, *po;
|
|
2009
2009
|
boolean8_t *mi, *mo;
|
|
2010
2010
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2034,6 +2034,13 @@ cummax_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
2034
2034
|
INIT inside the macro. */
|
|
2035
2035
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2036
2036
|
slab_axes[0] = (int8_t) axis;
|
|
2037
|
+
|
|
2038
|
+
boolean8_t *op_mask = NULL;
|
|
2039
|
+
if ( ca_has_mask(ca) ) {
|
|
2040
|
+
ca_create_mask(co);
|
|
2041
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2042
|
+
}
|
|
2043
|
+
|
|
2037
2044
|
ca_iter_state st_in, st_out;
|
|
2038
2045
|
int rc;
|
|
2039
2046
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2049,13 +2056,6 @@ cummax_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
2049
2056
|
rb_raise(rb_eRuntimeError,
|
|
2050
2057
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2051
2058
|
}
|
|
2052
|
-
|
|
2053
|
-
boolean8_t *op_mask = NULL;
|
|
2054
|
-
if ( ca_has_mask(ca) ) {
|
|
2055
|
-
ca_create_mask(co);
|
|
2056
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2057
|
-
}
|
|
2058
|
-
|
|
2059
2059
|
char *pi, *po;
|
|
2060
2060
|
boolean8_t *mi, *mo;
|
|
2061
2061
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2085,6 +2085,13 @@ cummax_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
2085
2085
|
INIT inside the macro. */
|
|
2086
2086
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2087
2087
|
slab_axes[0] = (int8_t) axis;
|
|
2088
|
+
|
|
2089
|
+
boolean8_t *op_mask = NULL;
|
|
2090
|
+
if ( ca_has_mask(ca) ) {
|
|
2091
|
+
ca_create_mask(co);
|
|
2092
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2093
|
+
}
|
|
2094
|
+
|
|
2088
2095
|
ca_iter_state st_in, st_out;
|
|
2089
2096
|
int rc;
|
|
2090
2097
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2100,13 +2107,6 @@ cummax_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
2100
2107
|
rb_raise(rb_eRuntimeError,
|
|
2101
2108
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2102
2109
|
}
|
|
2103
|
-
|
|
2104
|
-
boolean8_t *op_mask = NULL;
|
|
2105
|
-
if ( ca_has_mask(ca) ) {
|
|
2106
|
-
ca_create_mask(co);
|
|
2107
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2108
|
-
}
|
|
2109
|
-
|
|
2110
2110
|
char *pi, *po;
|
|
2111
2111
|
boolean8_t *mi, *mo;
|
|
2112
2112
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2136,6 +2136,13 @@ cummax_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
2136
2136
|
INIT inside the macro. */
|
|
2137
2137
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2138
2138
|
slab_axes[0] = (int8_t) axis;
|
|
2139
|
+
|
|
2140
|
+
boolean8_t *op_mask = NULL;
|
|
2141
|
+
if ( ca_has_mask(ca) ) {
|
|
2142
|
+
ca_create_mask(co);
|
|
2143
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2144
|
+
}
|
|
2145
|
+
|
|
2139
2146
|
ca_iter_state st_in, st_out;
|
|
2140
2147
|
int rc;
|
|
2141
2148
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2151,13 +2158,6 @@ cummax_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
2151
2158
|
rb_raise(rb_eRuntimeError,
|
|
2152
2159
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2153
2160
|
}
|
|
2154
|
-
|
|
2155
|
-
boolean8_t *op_mask = NULL;
|
|
2156
|
-
if ( ca_has_mask(ca) ) {
|
|
2157
|
-
ca_create_mask(co);
|
|
2158
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2159
|
-
}
|
|
2160
|
-
|
|
2161
2161
|
char *pi, *po;
|
|
2162
2162
|
boolean8_t *mi, *mo;
|
|
2163
2163
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2187,6 +2187,13 @@ cummax_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
2187
2187
|
INIT inside the macro. */
|
|
2188
2188
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2189
2189
|
slab_axes[0] = (int8_t) axis;
|
|
2190
|
+
|
|
2191
|
+
boolean8_t *op_mask = NULL;
|
|
2192
|
+
if ( ca_has_mask(ca) ) {
|
|
2193
|
+
ca_create_mask(co);
|
|
2194
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2195
|
+
}
|
|
2196
|
+
|
|
2190
2197
|
ca_iter_state st_in, st_out;
|
|
2191
2198
|
int rc;
|
|
2192
2199
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2202,13 +2209,6 @@ cummax_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
2202
2209
|
rb_raise(rb_eRuntimeError,
|
|
2203
2210
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2204
2211
|
}
|
|
2205
|
-
|
|
2206
|
-
boolean8_t *op_mask = NULL;
|
|
2207
|
-
if ( ca_has_mask(ca) ) {
|
|
2208
|
-
ca_create_mask(co);
|
|
2209
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2210
|
-
}
|
|
2211
|
-
|
|
2212
2212
|
char *pi, *po;
|
|
2213
2213
|
boolean8_t *mi, *mo;
|
|
2214
2214
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2238,6 +2238,13 @@ cummax_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
2238
2238
|
INIT inside the macro. */
|
|
2239
2239
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2240
2240
|
slab_axes[0] = (int8_t) axis;
|
|
2241
|
+
|
|
2242
|
+
boolean8_t *op_mask = NULL;
|
|
2243
|
+
if ( ca_has_mask(ca) ) {
|
|
2244
|
+
ca_create_mask(co);
|
|
2245
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2246
|
+
}
|
|
2247
|
+
|
|
2241
2248
|
ca_iter_state st_in, st_out;
|
|
2242
2249
|
int rc;
|
|
2243
2250
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2253,13 +2260,6 @@ cummax_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
2253
2260
|
rb_raise(rb_eRuntimeError,
|
|
2254
2261
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2255
2262
|
}
|
|
2256
|
-
|
|
2257
|
-
boolean8_t *op_mask = NULL;
|
|
2258
|
-
if ( ca_has_mask(ca) ) {
|
|
2259
|
-
ca_create_mask(co);
|
|
2260
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2261
|
-
}
|
|
2262
|
-
|
|
2263
2263
|
char *pi, *po;
|
|
2264
2264
|
boolean8_t *mi, *mo;
|
|
2265
2265
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2289,6 +2289,13 @@ cummax_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
2289
2289
|
INIT inside the macro. */
|
|
2290
2290
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2291
2291
|
slab_axes[0] = (int8_t) axis;
|
|
2292
|
+
|
|
2293
|
+
boolean8_t *op_mask = NULL;
|
|
2294
|
+
if ( ca_has_mask(ca) ) {
|
|
2295
|
+
ca_create_mask(co);
|
|
2296
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2297
|
+
}
|
|
2298
|
+
|
|
2292
2299
|
ca_iter_state st_in, st_out;
|
|
2293
2300
|
int rc;
|
|
2294
2301
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2304,13 +2311,6 @@ cummax_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
2304
2311
|
rb_raise(rb_eRuntimeError,
|
|
2305
2312
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2306
2313
|
}
|
|
2307
|
-
|
|
2308
|
-
boolean8_t *op_mask = NULL;
|
|
2309
|
-
if ( ca_has_mask(ca) ) {
|
|
2310
|
-
ca_create_mask(co);
|
|
2311
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2312
|
-
}
|
|
2313
|
-
|
|
2314
2314
|
char *pi, *po;
|
|
2315
2315
|
boolean8_t *mi, *mo;
|
|
2316
2316
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2340,6 +2340,13 @@ cummax_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
2340
2340
|
INIT inside the macro. */
|
|
2341
2341
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2342
2342
|
slab_axes[0] = (int8_t) axis;
|
|
2343
|
+
|
|
2344
|
+
boolean8_t *op_mask = NULL;
|
|
2345
|
+
if ( ca_has_mask(ca) ) {
|
|
2346
|
+
ca_create_mask(co);
|
|
2347
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2348
|
+
}
|
|
2349
|
+
|
|
2343
2350
|
ca_iter_state st_in, st_out;
|
|
2344
2351
|
int rc;
|
|
2345
2352
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2355,13 +2362,6 @@ cummax_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
2355
2362
|
rb_raise(rb_eRuntimeError,
|
|
2356
2363
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2357
2364
|
}
|
|
2358
|
-
|
|
2359
|
-
boolean8_t *op_mask = NULL;
|
|
2360
|
-
if ( ca_has_mask(ca) ) {
|
|
2361
|
-
ca_create_mask(co);
|
|
2362
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2363
|
-
}
|
|
2364
|
-
|
|
2365
2365
|
char *pi, *po;
|
|
2366
2366
|
boolean8_t *mi, *mo;
|
|
2367
2367
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2378,9 +2378,9 @@ cummax_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
2378
2378
|
return vout;
|
|
2379
2379
|
}
|
|
2380
2380
|
|
|
2381
|
-
/* The
|
|
2382
|
-
|
|
2383
|
-
finishes them however the body leaves. */
|
|
2381
|
+
/* The walks can raise part way (a Ruby call per cell in the object
|
|
2382
|
+
lane, an allocation in any lane). Their states live in the caller's
|
|
2383
|
+
frame, and ca_iter_ensure finishes them however the body leaves. */
|
|
2384
2384
|
typedef struct {
|
|
2385
2385
|
ca_iter_state states[2];
|
|
2386
2386
|
VALUE self;
|
|
@@ -2410,6 +2410,13 @@ cummax_ki_native_object_body (VALUE arg)
|
|
|
2410
2410
|
INIT inside the macro. */
|
|
2411
2411
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2412
2412
|
slab_axes[0] = (int8_t) axis;
|
|
2413
|
+
|
|
2414
|
+
boolean8_t *op_mask = NULL;
|
|
2415
|
+
if ( ca_has_mask(ca) ) {
|
|
2416
|
+
ca_create_mask(co);
|
|
2417
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2418
|
+
}
|
|
2419
|
+
|
|
2413
2420
|
int rc;
|
|
2414
2421
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
2415
2422
|
slab_axes, 1, 0);
|
|
@@ -2424,13 +2431,6 @@ cummax_ki_native_object_body (VALUE arg)
|
|
|
2424
2431
|
rb_raise(rb_eRuntimeError,
|
|
2425
2432
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2426
2433
|
}
|
|
2427
|
-
|
|
2428
|
-
boolean8_t *op_mask = NULL;
|
|
2429
|
-
if ( ca_has_mask(ca) ) {
|
|
2430
|
-
ca_create_mask(co);
|
|
2431
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2432
|
-
}
|
|
2433
|
-
|
|
2434
2434
|
char *pi, *po;
|
|
2435
2435
|
boolean8_t *mi, *mo;
|
|
2436
2436
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2456,7 +2456,7 @@ cummax_ki_native_object (VALUE self, CArray *ca, int axis)
|
|
|
2456
2456
|
fr.self = self;
|
|
2457
2457
|
fr.ca = ca;
|
|
2458
2458
|
fr.axis = axis;
|
|
2459
|
-
return
|
|
2459
|
+
return ca_iter_ensure_computing(ca, 2, fr.states, cummax_ki_native_object_body, (VALUE) &fr);
|
|
2460
2460
|
}
|
|
2461
2461
|
|
|
2462
2462
|
|
|
@@ -2592,6 +2592,13 @@ cummin_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
2592
2592
|
INIT inside the macro. */
|
|
2593
2593
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2594
2594
|
slab_axes[0] = (int8_t) axis;
|
|
2595
|
+
|
|
2596
|
+
boolean8_t *op_mask = NULL;
|
|
2597
|
+
if ( ca_has_mask(ca) ) {
|
|
2598
|
+
ca_create_mask(co);
|
|
2599
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2600
|
+
}
|
|
2601
|
+
|
|
2595
2602
|
ca_iter_state st_in, st_out;
|
|
2596
2603
|
int rc;
|
|
2597
2604
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2607,13 +2614,6 @@ cummin_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
2607
2614
|
rb_raise(rb_eRuntimeError,
|
|
2608
2615
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2609
2616
|
}
|
|
2610
|
-
|
|
2611
|
-
boolean8_t *op_mask = NULL;
|
|
2612
|
-
if ( ca_has_mask(ca) ) {
|
|
2613
|
-
ca_create_mask(co);
|
|
2614
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2615
|
-
}
|
|
2616
|
-
|
|
2617
2617
|
char *pi, *po;
|
|
2618
2618
|
boolean8_t *mi, *mo;
|
|
2619
2619
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2643,6 +2643,13 @@ cummin_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
2643
2643
|
INIT inside the macro. */
|
|
2644
2644
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2645
2645
|
slab_axes[0] = (int8_t) axis;
|
|
2646
|
+
|
|
2647
|
+
boolean8_t *op_mask = NULL;
|
|
2648
|
+
if ( ca_has_mask(ca) ) {
|
|
2649
|
+
ca_create_mask(co);
|
|
2650
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2651
|
+
}
|
|
2652
|
+
|
|
2646
2653
|
ca_iter_state st_in, st_out;
|
|
2647
2654
|
int rc;
|
|
2648
2655
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2658,13 +2665,6 @@ cummin_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
2658
2665
|
rb_raise(rb_eRuntimeError,
|
|
2659
2666
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2660
2667
|
}
|
|
2661
|
-
|
|
2662
|
-
boolean8_t *op_mask = NULL;
|
|
2663
|
-
if ( ca_has_mask(ca) ) {
|
|
2664
|
-
ca_create_mask(co);
|
|
2665
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2666
|
-
}
|
|
2667
|
-
|
|
2668
2668
|
char *pi, *po;
|
|
2669
2669
|
boolean8_t *mi, *mo;
|
|
2670
2670
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2694,6 +2694,13 @@ cummin_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
2694
2694
|
INIT inside the macro. */
|
|
2695
2695
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2696
2696
|
slab_axes[0] = (int8_t) axis;
|
|
2697
|
+
|
|
2698
|
+
boolean8_t *op_mask = NULL;
|
|
2699
|
+
if ( ca_has_mask(ca) ) {
|
|
2700
|
+
ca_create_mask(co);
|
|
2701
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2702
|
+
}
|
|
2703
|
+
|
|
2697
2704
|
ca_iter_state st_in, st_out;
|
|
2698
2705
|
int rc;
|
|
2699
2706
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2709,13 +2716,6 @@ cummin_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
2709
2716
|
rb_raise(rb_eRuntimeError,
|
|
2710
2717
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2711
2718
|
}
|
|
2712
|
-
|
|
2713
|
-
boolean8_t *op_mask = NULL;
|
|
2714
|
-
if ( ca_has_mask(ca) ) {
|
|
2715
|
-
ca_create_mask(co);
|
|
2716
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2717
|
-
}
|
|
2718
|
-
|
|
2719
2719
|
char *pi, *po;
|
|
2720
2720
|
boolean8_t *mi, *mo;
|
|
2721
2721
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2745,6 +2745,13 @@ cummin_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
2745
2745
|
INIT inside the macro. */
|
|
2746
2746
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2747
2747
|
slab_axes[0] = (int8_t) axis;
|
|
2748
|
+
|
|
2749
|
+
boolean8_t *op_mask = NULL;
|
|
2750
|
+
if ( ca_has_mask(ca) ) {
|
|
2751
|
+
ca_create_mask(co);
|
|
2752
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2753
|
+
}
|
|
2754
|
+
|
|
2748
2755
|
ca_iter_state st_in, st_out;
|
|
2749
2756
|
int rc;
|
|
2750
2757
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2760,13 +2767,6 @@ cummin_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
2760
2767
|
rb_raise(rb_eRuntimeError,
|
|
2761
2768
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2762
2769
|
}
|
|
2763
|
-
|
|
2764
|
-
boolean8_t *op_mask = NULL;
|
|
2765
|
-
if ( ca_has_mask(ca) ) {
|
|
2766
|
-
ca_create_mask(co);
|
|
2767
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2768
|
-
}
|
|
2769
|
-
|
|
2770
2770
|
char *pi, *po;
|
|
2771
2771
|
boolean8_t *mi, *mo;
|
|
2772
2772
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2796,6 +2796,13 @@ cummin_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
2796
2796
|
INIT inside the macro. */
|
|
2797
2797
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2798
2798
|
slab_axes[0] = (int8_t) axis;
|
|
2799
|
+
|
|
2800
|
+
boolean8_t *op_mask = NULL;
|
|
2801
|
+
if ( ca_has_mask(ca) ) {
|
|
2802
|
+
ca_create_mask(co);
|
|
2803
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2804
|
+
}
|
|
2805
|
+
|
|
2799
2806
|
ca_iter_state st_in, st_out;
|
|
2800
2807
|
int rc;
|
|
2801
2808
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2811,13 +2818,6 @@ cummin_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
2811
2818
|
rb_raise(rb_eRuntimeError,
|
|
2812
2819
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2813
2820
|
}
|
|
2814
|
-
|
|
2815
|
-
boolean8_t *op_mask = NULL;
|
|
2816
|
-
if ( ca_has_mask(ca) ) {
|
|
2817
|
-
ca_create_mask(co);
|
|
2818
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2819
|
-
}
|
|
2820
|
-
|
|
2821
2821
|
char *pi, *po;
|
|
2822
2822
|
boolean8_t *mi, *mo;
|
|
2823
2823
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2847,6 +2847,13 @@ cummin_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
2847
2847
|
INIT inside the macro. */
|
|
2848
2848
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2849
2849
|
slab_axes[0] = (int8_t) axis;
|
|
2850
|
+
|
|
2851
|
+
boolean8_t *op_mask = NULL;
|
|
2852
|
+
if ( ca_has_mask(ca) ) {
|
|
2853
|
+
ca_create_mask(co);
|
|
2854
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2855
|
+
}
|
|
2856
|
+
|
|
2850
2857
|
ca_iter_state st_in, st_out;
|
|
2851
2858
|
int rc;
|
|
2852
2859
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2862,13 +2869,6 @@ cummin_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
2862
2869
|
rb_raise(rb_eRuntimeError,
|
|
2863
2870
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2864
2871
|
}
|
|
2865
|
-
|
|
2866
|
-
boolean8_t *op_mask = NULL;
|
|
2867
|
-
if ( ca_has_mask(ca) ) {
|
|
2868
|
-
ca_create_mask(co);
|
|
2869
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2870
|
-
}
|
|
2871
|
-
|
|
2872
2872
|
char *pi, *po;
|
|
2873
2873
|
boolean8_t *mi, *mo;
|
|
2874
2874
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2898,6 +2898,13 @@ cummin_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
2898
2898
|
INIT inside the macro. */
|
|
2899
2899
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2900
2900
|
slab_axes[0] = (int8_t) axis;
|
|
2901
|
+
|
|
2902
|
+
boolean8_t *op_mask = NULL;
|
|
2903
|
+
if ( ca_has_mask(ca) ) {
|
|
2904
|
+
ca_create_mask(co);
|
|
2905
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2906
|
+
}
|
|
2907
|
+
|
|
2901
2908
|
ca_iter_state st_in, st_out;
|
|
2902
2909
|
int rc;
|
|
2903
2910
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2913,13 +2920,6 @@ cummin_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
2913
2920
|
rb_raise(rb_eRuntimeError,
|
|
2914
2921
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2915
2922
|
}
|
|
2916
|
-
|
|
2917
|
-
boolean8_t *op_mask = NULL;
|
|
2918
|
-
if ( ca_has_mask(ca) ) {
|
|
2919
|
-
ca_create_mask(co);
|
|
2920
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2921
|
-
}
|
|
2922
|
-
|
|
2923
2923
|
char *pi, *po;
|
|
2924
2924
|
boolean8_t *mi, *mo;
|
|
2925
2925
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -2949,6 +2949,13 @@ cummin_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
2949
2949
|
INIT inside the macro. */
|
|
2950
2950
|
int8_t slab_axes[CA_RANK_MAX];
|
|
2951
2951
|
slab_axes[0] = (int8_t) axis;
|
|
2952
|
+
|
|
2953
|
+
boolean8_t *op_mask = NULL;
|
|
2954
|
+
if ( ca_has_mask(ca) ) {
|
|
2955
|
+
ca_create_mask(co);
|
|
2956
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2957
|
+
}
|
|
2958
|
+
|
|
2952
2959
|
ca_iter_state st_in, st_out;
|
|
2953
2960
|
int rc;
|
|
2954
2961
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -2964,13 +2971,6 @@ cummin_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
2964
2971
|
rb_raise(rb_eRuntimeError,
|
|
2965
2972
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
2966
2973
|
}
|
|
2967
|
-
|
|
2968
|
-
boolean8_t *op_mask = NULL;
|
|
2969
|
-
if ( ca_has_mask(ca) ) {
|
|
2970
|
-
ca_create_mask(co);
|
|
2971
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
2972
|
-
}
|
|
2973
|
-
|
|
2974
2974
|
char *pi, *po;
|
|
2975
2975
|
boolean8_t *mi, *mo;
|
|
2976
2976
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3000,6 +3000,13 @@ cummin_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
3000
3000
|
INIT inside the macro. */
|
|
3001
3001
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3002
3002
|
slab_axes[0] = (int8_t) axis;
|
|
3003
|
+
|
|
3004
|
+
boolean8_t *op_mask = NULL;
|
|
3005
|
+
if ( ca_has_mask(ca) ) {
|
|
3006
|
+
ca_create_mask(co);
|
|
3007
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
3008
|
+
}
|
|
3009
|
+
|
|
3003
3010
|
ca_iter_state st_in, st_out;
|
|
3004
3011
|
int rc;
|
|
3005
3012
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3015,13 +3022,6 @@ cummin_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
3015
3022
|
rb_raise(rb_eRuntimeError,
|
|
3016
3023
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3017
3024
|
}
|
|
3018
|
-
|
|
3019
|
-
boolean8_t *op_mask = NULL;
|
|
3020
|
-
if ( ca_has_mask(ca) ) {
|
|
3021
|
-
ca_create_mask(co);
|
|
3022
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
3023
|
-
}
|
|
3024
|
-
|
|
3025
3025
|
char *pi, *po;
|
|
3026
3026
|
boolean8_t *mi, *mo;
|
|
3027
3027
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3051,6 +3051,13 @@ cummin_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
3051
3051
|
INIT inside the macro. */
|
|
3052
3052
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3053
3053
|
slab_axes[0] = (int8_t) axis;
|
|
3054
|
+
|
|
3055
|
+
boolean8_t *op_mask = NULL;
|
|
3056
|
+
if ( ca_has_mask(ca) ) {
|
|
3057
|
+
ca_create_mask(co);
|
|
3058
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
3059
|
+
}
|
|
3060
|
+
|
|
3054
3061
|
ca_iter_state st_in, st_out;
|
|
3055
3062
|
int rc;
|
|
3056
3063
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3066,13 +3073,6 @@ cummin_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
3066
3073
|
rb_raise(rb_eRuntimeError,
|
|
3067
3074
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3068
3075
|
}
|
|
3069
|
-
|
|
3070
|
-
boolean8_t *op_mask = NULL;
|
|
3071
|
-
if ( ca_has_mask(ca) ) {
|
|
3072
|
-
ca_create_mask(co);
|
|
3073
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
3074
|
-
}
|
|
3075
|
-
|
|
3076
3076
|
char *pi, *po;
|
|
3077
3077
|
boolean8_t *mi, *mo;
|
|
3078
3078
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3102,6 +3102,13 @@ cummin_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
3102
3102
|
INIT inside the macro. */
|
|
3103
3103
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3104
3104
|
slab_axes[0] = (int8_t) axis;
|
|
3105
|
+
|
|
3106
|
+
boolean8_t *op_mask = NULL;
|
|
3107
|
+
if ( ca_has_mask(ca) ) {
|
|
3108
|
+
ca_create_mask(co);
|
|
3109
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
3110
|
+
}
|
|
3111
|
+
|
|
3105
3112
|
ca_iter_state st_in, st_out;
|
|
3106
3113
|
int rc;
|
|
3107
3114
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3117,13 +3124,6 @@ cummin_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
3117
3124
|
rb_raise(rb_eRuntimeError,
|
|
3118
3125
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3119
3126
|
}
|
|
3120
|
-
|
|
3121
|
-
boolean8_t *op_mask = NULL;
|
|
3122
|
-
if ( ca_has_mask(ca) ) {
|
|
3123
|
-
ca_create_mask(co);
|
|
3124
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
3125
|
-
}
|
|
3126
|
-
|
|
3127
3127
|
char *pi, *po;
|
|
3128
3128
|
boolean8_t *mi, *mo;
|
|
3129
3129
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3140,9 +3140,9 @@ cummin_ki_native_bool (VALUE self, CArray *ca, int axis)
|
|
|
3140
3140
|
return vout;
|
|
3141
3141
|
}
|
|
3142
3142
|
|
|
3143
|
-
/* The
|
|
3144
|
-
|
|
3145
|
-
finishes them however the body leaves. */
|
|
3143
|
+
/* The walks can raise part way (a Ruby call per cell in the object
|
|
3144
|
+
lane, an allocation in any lane). Their states live in the caller's
|
|
3145
|
+
frame, and ca_iter_ensure finishes them however the body leaves. */
|
|
3146
3146
|
typedef struct {
|
|
3147
3147
|
ca_iter_state states[2];
|
|
3148
3148
|
VALUE self;
|
|
@@ -3172,6 +3172,13 @@ cummin_ki_native_object_body (VALUE arg)
|
|
|
3172
3172
|
INIT inside the macro. */
|
|
3173
3173
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3174
3174
|
slab_axes[0] = (int8_t) axis;
|
|
3175
|
+
|
|
3176
|
+
boolean8_t *op_mask = NULL;
|
|
3177
|
+
if ( ca_has_mask(ca) ) {
|
|
3178
|
+
ca_create_mask(co);
|
|
3179
|
+
op_mask = (boolean8_t *) co->mask->ptr;
|
|
3180
|
+
}
|
|
3181
|
+
|
|
3175
3182
|
int rc;
|
|
3176
3183
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
3177
3184
|
slab_axes, 1, 0);
|
|
@@ -3186,13 +3193,6 @@ cummin_ki_native_object_body (VALUE arg)
|
|
|
3186
3193
|
rb_raise(rb_eRuntimeError,
|
|
3187
3194
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3188
3195
|
}
|
|
3189
|
-
|
|
3190
|
-
boolean8_t *op_mask = NULL;
|
|
3191
|
-
if ( ca_has_mask(ca) ) {
|
|
3192
|
-
ca_create_mask(co);
|
|
3193
|
-
op_mask = (boolean8_t *) co->mask->ptr;
|
|
3194
|
-
}
|
|
3195
|
-
|
|
3196
3196
|
char *pi, *po;
|
|
3197
3197
|
boolean8_t *mi, *mo;
|
|
3198
3198
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3218,7 +3218,7 @@ cummin_ki_native_object (VALUE self, CArray *ca, int axis)
|
|
|
3218
3218
|
fr.self = self;
|
|
3219
3219
|
fr.ca = ca;
|
|
3220
3220
|
fr.axis = axis;
|
|
3221
|
-
return
|
|
3221
|
+
return ca_iter_ensure_computing(ca, 2, fr.states, cummin_ki_native_object_body, (VALUE) &fr);
|
|
3222
3222
|
}
|
|
3223
3223
|
|
|
3224
3224
|
|
|
@@ -3354,6 +3354,7 @@ cumcount_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
3354
3354
|
INIT inside the macro. */
|
|
3355
3355
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3356
3356
|
slab_axes[0] = (int8_t) axis;
|
|
3357
|
+
|
|
3357
3358
|
ca_iter_state st_in, st_out;
|
|
3358
3359
|
int rc;
|
|
3359
3360
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3369,7 +3370,6 @@ cumcount_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
3369
3370
|
rb_raise(rb_eRuntimeError,
|
|
3370
3371
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3371
3372
|
}
|
|
3372
|
-
|
|
3373
3373
|
char *pi, *po;
|
|
3374
3374
|
boolean8_t *mi, *mo;
|
|
3375
3375
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3396,6 +3396,7 @@ cumcount_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
3396
3396
|
INIT inside the macro. */
|
|
3397
3397
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3398
3398
|
slab_axes[0] = (int8_t) axis;
|
|
3399
|
+
|
|
3399
3400
|
ca_iter_state st_in, st_out;
|
|
3400
3401
|
int rc;
|
|
3401
3402
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3411,7 +3412,6 @@ cumcount_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
3411
3412
|
rb_raise(rb_eRuntimeError,
|
|
3412
3413
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3413
3414
|
}
|
|
3414
|
-
|
|
3415
3415
|
char *pi, *po;
|
|
3416
3416
|
boolean8_t *mi, *mo;
|
|
3417
3417
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3438,6 +3438,7 @@ cumcount_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
3438
3438
|
INIT inside the macro. */
|
|
3439
3439
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3440
3440
|
slab_axes[0] = (int8_t) axis;
|
|
3441
|
+
|
|
3441
3442
|
ca_iter_state st_in, st_out;
|
|
3442
3443
|
int rc;
|
|
3443
3444
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3453,7 +3454,6 @@ cumcount_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
3453
3454
|
rb_raise(rb_eRuntimeError,
|
|
3454
3455
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3455
3456
|
}
|
|
3456
|
-
|
|
3457
3457
|
char *pi, *po;
|
|
3458
3458
|
boolean8_t *mi, *mo;
|
|
3459
3459
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3480,6 +3480,7 @@ cumcount_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
3480
3480
|
INIT inside the macro. */
|
|
3481
3481
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3482
3482
|
slab_axes[0] = (int8_t) axis;
|
|
3483
|
+
|
|
3483
3484
|
ca_iter_state st_in, st_out;
|
|
3484
3485
|
int rc;
|
|
3485
3486
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3495,7 +3496,6 @@ cumcount_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
3495
3496
|
rb_raise(rb_eRuntimeError,
|
|
3496
3497
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3497
3498
|
}
|
|
3498
|
-
|
|
3499
3499
|
char *pi, *po;
|
|
3500
3500
|
boolean8_t *mi, *mo;
|
|
3501
3501
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3522,6 +3522,7 @@ cumcount_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
3522
3522
|
INIT inside the macro. */
|
|
3523
3523
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3524
3524
|
slab_axes[0] = (int8_t) axis;
|
|
3525
|
+
|
|
3525
3526
|
ca_iter_state st_in, st_out;
|
|
3526
3527
|
int rc;
|
|
3527
3528
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3537,7 +3538,6 @@ cumcount_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
3537
3538
|
rb_raise(rb_eRuntimeError,
|
|
3538
3539
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3539
3540
|
}
|
|
3540
|
-
|
|
3541
3541
|
char *pi, *po;
|
|
3542
3542
|
boolean8_t *mi, *mo;
|
|
3543
3543
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3564,6 +3564,7 @@ cumcount_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
3564
3564
|
INIT inside the macro. */
|
|
3565
3565
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3566
3566
|
slab_axes[0] = (int8_t) axis;
|
|
3567
|
+
|
|
3567
3568
|
ca_iter_state st_in, st_out;
|
|
3568
3569
|
int rc;
|
|
3569
3570
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3579,7 +3580,6 @@ cumcount_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
3579
3580
|
rb_raise(rb_eRuntimeError,
|
|
3580
3581
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3581
3582
|
}
|
|
3582
|
-
|
|
3583
3583
|
char *pi, *po;
|
|
3584
3584
|
boolean8_t *mi, *mo;
|
|
3585
3585
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3606,6 +3606,7 @@ cumcount_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
3606
3606
|
INIT inside the macro. */
|
|
3607
3607
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3608
3608
|
slab_axes[0] = (int8_t) axis;
|
|
3609
|
+
|
|
3609
3610
|
ca_iter_state st_in, st_out;
|
|
3610
3611
|
int rc;
|
|
3611
3612
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3621,7 +3622,6 @@ cumcount_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
3621
3622
|
rb_raise(rb_eRuntimeError,
|
|
3622
3623
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3623
3624
|
}
|
|
3624
|
-
|
|
3625
3625
|
char *pi, *po;
|
|
3626
3626
|
boolean8_t *mi, *mo;
|
|
3627
3627
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3648,6 +3648,7 @@ cumcount_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
3648
3648
|
INIT inside the macro. */
|
|
3649
3649
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3650
3650
|
slab_axes[0] = (int8_t) axis;
|
|
3651
|
+
|
|
3651
3652
|
ca_iter_state st_in, st_out;
|
|
3652
3653
|
int rc;
|
|
3653
3654
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3663,7 +3664,6 @@ cumcount_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
3663
3664
|
rb_raise(rb_eRuntimeError,
|
|
3664
3665
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3665
3666
|
}
|
|
3666
|
-
|
|
3667
3667
|
char *pi, *po;
|
|
3668
3668
|
boolean8_t *mi, *mo;
|
|
3669
3669
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3690,6 +3690,7 @@ cumcount_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
3690
3690
|
INIT inside the macro. */
|
|
3691
3691
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3692
3692
|
slab_axes[0] = (int8_t) axis;
|
|
3693
|
+
|
|
3693
3694
|
ca_iter_state st_in, st_out;
|
|
3694
3695
|
int rc;
|
|
3695
3696
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3705,7 +3706,6 @@ cumcount_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
3705
3706
|
rb_raise(rb_eRuntimeError,
|
|
3706
3707
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3707
3708
|
}
|
|
3708
|
-
|
|
3709
3709
|
char *pi, *po;
|
|
3710
3710
|
boolean8_t *mi, *mo;
|
|
3711
3711
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3732,6 +3732,7 @@ cumcount_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
3732
3732
|
INIT inside the macro. */
|
|
3733
3733
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3734
3734
|
slab_axes[0] = (int8_t) axis;
|
|
3735
|
+
|
|
3735
3736
|
ca_iter_state st_in, st_out;
|
|
3736
3737
|
int rc;
|
|
3737
3738
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3747,7 +3748,6 @@ cumcount_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
3747
3748
|
rb_raise(rb_eRuntimeError,
|
|
3748
3749
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3749
3750
|
}
|
|
3750
|
-
|
|
3751
3751
|
char *pi, *po;
|
|
3752
3752
|
boolean8_t *mi, *mo;
|
|
3753
3753
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3834,6 +3834,7 @@ uniq_scan_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
3834
3834
|
INIT inside the macro. */
|
|
3835
3835
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3836
3836
|
slab_axes[0] = (int8_t) axis;
|
|
3837
|
+
|
|
3837
3838
|
ca_iter_state st_in, st_out;
|
|
3838
3839
|
int rc;
|
|
3839
3840
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3849,7 +3850,6 @@ uniq_scan_ki_native_i8 (VALUE self, CArray *ca, int axis)
|
|
|
3849
3850
|
rb_raise(rb_eRuntimeError,
|
|
3850
3851
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3851
3852
|
}
|
|
3852
|
-
|
|
3853
3853
|
char *pi, *po;
|
|
3854
3854
|
boolean8_t *mi, *mo;
|
|
3855
3855
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3876,6 +3876,7 @@ uniq_scan_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
3876
3876
|
INIT inside the macro. */
|
|
3877
3877
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3878
3878
|
slab_axes[0] = (int8_t) axis;
|
|
3879
|
+
|
|
3879
3880
|
ca_iter_state st_in, st_out;
|
|
3880
3881
|
int rc;
|
|
3881
3882
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3891,7 +3892,6 @@ uniq_scan_ki_native_u8 (VALUE self, CArray *ca, int axis)
|
|
|
3891
3892
|
rb_raise(rb_eRuntimeError,
|
|
3892
3893
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3893
3894
|
}
|
|
3894
|
-
|
|
3895
3895
|
char *pi, *po;
|
|
3896
3896
|
boolean8_t *mi, *mo;
|
|
3897
3897
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3918,6 +3918,7 @@ uniq_scan_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
3918
3918
|
INIT inside the macro. */
|
|
3919
3919
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3920
3920
|
slab_axes[0] = (int8_t) axis;
|
|
3921
|
+
|
|
3921
3922
|
ca_iter_state st_in, st_out;
|
|
3922
3923
|
int rc;
|
|
3923
3924
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3933,7 +3934,6 @@ uniq_scan_ki_native_i16 (VALUE self, CArray *ca, int axis)
|
|
|
3933
3934
|
rb_raise(rb_eRuntimeError,
|
|
3934
3935
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3935
3936
|
}
|
|
3936
|
-
|
|
3937
3937
|
char *pi, *po;
|
|
3938
3938
|
boolean8_t *mi, *mo;
|
|
3939
3939
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -3960,6 +3960,7 @@ uniq_scan_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
3960
3960
|
INIT inside the macro. */
|
|
3961
3961
|
int8_t slab_axes[CA_RANK_MAX];
|
|
3962
3962
|
slab_axes[0] = (int8_t) axis;
|
|
3963
|
+
|
|
3963
3964
|
ca_iter_state st_in, st_out;
|
|
3964
3965
|
int rc;
|
|
3965
3966
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -3975,7 +3976,6 @@ uniq_scan_ki_native_u16 (VALUE self, CArray *ca, int axis)
|
|
|
3975
3976
|
rb_raise(rb_eRuntimeError,
|
|
3976
3977
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
3977
3978
|
}
|
|
3978
|
-
|
|
3979
3979
|
char *pi, *po;
|
|
3980
3980
|
boolean8_t *mi, *mo;
|
|
3981
3981
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -4002,6 +4002,7 @@ uniq_scan_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
4002
4002
|
INIT inside the macro. */
|
|
4003
4003
|
int8_t slab_axes[CA_RANK_MAX];
|
|
4004
4004
|
slab_axes[0] = (int8_t) axis;
|
|
4005
|
+
|
|
4005
4006
|
ca_iter_state st_in, st_out;
|
|
4006
4007
|
int rc;
|
|
4007
4008
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -4017,7 +4018,6 @@ uniq_scan_ki_native_i32 (VALUE self, CArray *ca, int axis)
|
|
|
4017
4018
|
rb_raise(rb_eRuntimeError,
|
|
4018
4019
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
4019
4020
|
}
|
|
4020
|
-
|
|
4021
4021
|
char *pi, *po;
|
|
4022
4022
|
boolean8_t *mi, *mo;
|
|
4023
4023
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -4044,6 +4044,7 @@ uniq_scan_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
4044
4044
|
INIT inside the macro. */
|
|
4045
4045
|
int8_t slab_axes[CA_RANK_MAX];
|
|
4046
4046
|
slab_axes[0] = (int8_t) axis;
|
|
4047
|
+
|
|
4047
4048
|
ca_iter_state st_in, st_out;
|
|
4048
4049
|
int rc;
|
|
4049
4050
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -4059,7 +4060,6 @@ uniq_scan_ki_native_u32 (VALUE self, CArray *ca, int axis)
|
|
|
4059
4060
|
rb_raise(rb_eRuntimeError,
|
|
4060
4061
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
4061
4062
|
}
|
|
4062
|
-
|
|
4063
4063
|
char *pi, *po;
|
|
4064
4064
|
boolean8_t *mi, *mo;
|
|
4065
4065
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -4086,6 +4086,7 @@ uniq_scan_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
4086
4086
|
INIT inside the macro. */
|
|
4087
4087
|
int8_t slab_axes[CA_RANK_MAX];
|
|
4088
4088
|
slab_axes[0] = (int8_t) axis;
|
|
4089
|
+
|
|
4089
4090
|
ca_iter_state st_in, st_out;
|
|
4090
4091
|
int rc;
|
|
4091
4092
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -4101,7 +4102,6 @@ uniq_scan_ki_native_i64 (VALUE self, CArray *ca, int axis)
|
|
|
4101
4102
|
rb_raise(rb_eRuntimeError,
|
|
4102
4103
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
4103
4104
|
}
|
|
4104
|
-
|
|
4105
4105
|
char *pi, *po;
|
|
4106
4106
|
boolean8_t *mi, *mo;
|
|
4107
4107
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -4128,6 +4128,7 @@ uniq_scan_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
4128
4128
|
INIT inside the macro. */
|
|
4129
4129
|
int8_t slab_axes[CA_RANK_MAX];
|
|
4130
4130
|
slab_axes[0] = (int8_t) axis;
|
|
4131
|
+
|
|
4131
4132
|
ca_iter_state st_in, st_out;
|
|
4132
4133
|
int rc;
|
|
4133
4134
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -4143,7 +4144,6 @@ uniq_scan_ki_native_u64 (VALUE self, CArray *ca, int axis)
|
|
|
4143
4144
|
rb_raise(rb_eRuntimeError,
|
|
4144
4145
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
4145
4146
|
}
|
|
4146
|
-
|
|
4147
4147
|
char *pi, *po;
|
|
4148
4148
|
boolean8_t *mi, *mo;
|
|
4149
4149
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -4170,6 +4170,7 @@ uniq_scan_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
4170
4170
|
INIT inside the macro. */
|
|
4171
4171
|
int8_t slab_axes[CA_RANK_MAX];
|
|
4172
4172
|
slab_axes[0] = (int8_t) axis;
|
|
4173
|
+
|
|
4173
4174
|
ca_iter_state st_in, st_out;
|
|
4174
4175
|
int rc;
|
|
4175
4176
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -4185,7 +4186,6 @@ uniq_scan_ki_native_f32 (VALUE self, CArray *ca, int axis)
|
|
|
4185
4186
|
rb_raise(rb_eRuntimeError,
|
|
4186
4187
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
4187
4188
|
}
|
|
4188
|
-
|
|
4189
4189
|
char *pi, *po;
|
|
4190
4190
|
boolean8_t *mi, *mo;
|
|
4191
4191
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|
|
@@ -4212,6 +4212,7 @@ uniq_scan_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
4212
4212
|
INIT inside the macro. */
|
|
4213
4213
|
int8_t slab_axes[CA_RANK_MAX];
|
|
4214
4214
|
slab_axes[0] = (int8_t) axis;
|
|
4215
|
+
|
|
4215
4216
|
ca_iter_state st_in, st_out;
|
|
4216
4217
|
int rc;
|
|
4217
4218
|
rc = ca_iter_state_init_l2(&st_in, ca, CA_SLAB_AXES,
|
|
@@ -4227,7 +4228,6 @@ uniq_scan_ki_native_f64 (VALUE self, CArray *ca, int axis)
|
|
|
4227
4228
|
rb_raise(rb_eRuntimeError,
|
|
4228
4229
|
"%s: output init failed rc=%d", ca_calling_method_name(), rc);
|
|
4229
4230
|
}
|
|
4230
|
-
|
|
4231
4231
|
char *pi, *po;
|
|
4232
4232
|
boolean8_t *mi, *mo;
|
|
4233
4233
|
while ( ca_iter_state_next_slab_axes(&st_in, &pi, &mi) &&
|