File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
dpctl/tensor/libtensor/include/kernels Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -198,8 +198,9 @@ struct SequentialBooleanReduction
198198 // must convert to boolean first to handle nans
199199 using dpctl::tensor::type_utils::convert_impl;
200200 outT val = convert_impl<bool , argT>(inp_[inp_offset]);
201+ ReductionOp op = reduction_op_;
201202
202- red_val = reduction_op_ (red_val, val);
203+ red_val = op (red_val, val);
203204 }
204205
205206 out_[out_iter_offset] = red_val;
@@ -452,9 +453,9 @@ struct StridedBooleanReduction
452453 // must convert to boolean first to handle nans
453454 using dpctl::tensor::type_utils::convert_impl;
454455 bool val = convert_impl<bool , argT>(inp_[inp_offset]);
456+ ReductionOp op = reduction_op_;
455457
456- local_red_val =
457- reduction_op_ (local_red_val, static_cast <outT>(val));
458+ local_red_val = op (local_red_val, static_cast <outT>(val));
458459 }
459460 }
460461 // reduction and atomic operations are performed
You can’t perform that action at this time.
0 commit comments