Skip to content

Commit

Permalink
include/oneapi/dpl/pstl/hetero/dpcpp/parallel_backend_sycl_merge.h - …
Browse files Browse the repository at this point in the history
…fix review comment: remove if conditions checks from __parallel_merge_submitter_large::eval_split_points_for_groups

Signed-off-by: Sergey Kopienko <[email protected]>
  • Loading branch information
SergeyKopienko committed Dec 19, 2024
1 parent 2c09ccf commit 2123664
Showing 1 changed file with 8 additions and 11 deletions.
19 changes: 8 additions & 11 deletions include/oneapi/dpl/pstl/hetero/dpcpp/parallel_backend_sycl_merge.h
Original file line number Diff line number Diff line change
Expand Up @@ -319,17 +319,14 @@ struct __parallel_merge_submitter_large<_IdType, _CustomName,
auto __base_diagonals_sp_global_ptr =
_Storage::__get_usm_or_buffer_accessor_ptr(__base_diagonals_sp_global_acc);

_split_point_t<_IdType> __sp =
__global_idx == 0 ? _split_point_t<_IdType>{0, 0} : _split_point_t<_IdType>{__n1, __n2};

if (0 < __global_idx && __global_idx < __nd_range_params.base_diag_count)
{
const _IdType __i_elem = __global_idx * __base_diag_chunk;
if (__i_elem < __n)
__sp = __find_start_point(__rng1, __rng2, __i_elem, __n1, __n2, __comp);
}

__base_diagonals_sp_global_ptr[__global_idx] = __sp;
const _IdType __i_elem = __global_idx * __base_diag_chunk;

__base_diagonals_sp_global_ptr[__global_idx] =
__i_elem == 0
? _split_point_t<_IdType>{0, 0}
: __i_elem < __n
? __find_start_point(__rng1, __rng2, __i_elem, __n1, __n2, __comp)
: _split_point_t<_IdType>{__n1, __n2};
});
});
}
Expand Down

0 comments on commit 2123664

Please sign in to comment.