Skip to content

Commit 01e5da4

Browse files
Restore some old names to reduce the amount of changes
1 parent 04bcd17 commit 01e5da4

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

include/oneapi/dpl/pstl/hetero/dpcpp/parallel_backend_sycl_radix_sort_one_wg.h

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -183,8 +183,8 @@ struct __subgroup_radix_sort
183183
oneapi::dpl::__ranges::__require_access(__cgh, __src);
184184

185185
// Get accessors to sycl::buffer (global memory) or sycl::local_accessor (local memory)
186-
auto __acc_buf_val = __buf_val.get_acc (__cgh);
187-
auto __acc_buf_count = __buf_count.get_acc(__cgh);
186+
auto __exchange_lacc = __buf_val.get_acc (__cgh);
187+
auto __counter_lacc = __buf_count.get_acc(__cgh);
188188

189189
const auto __fence_buf_val = __buf_val._space;
190190
const auto __fence_buf_count = __buf_count._space;
@@ -215,7 +215,7 @@ struct __subgroup_radix_sort
215215

216216
//1. "counting" phase
217217
//counter initialization
218-
_CounterT* __pcounter = __dpl_sycl::__get_accessor_ptr(__acc_buf_count) + __wi;
218+
_CounterT* __pcounter = __dpl_sycl::__get_accessor_ptr(__counter_lacc) + __wi;
219219

220220
_ONEDPL_PRAGMA_UNROLL
221221
for (uint16_t __i = 0; __i < __bin_count; ++__i)
@@ -245,11 +245,11 @@ struct __subgroup_radix_sort
245245

246246
//scan contiguous numbers
247247
uint16_t __bin_sum[__bin_count];
248-
__bin_sum[0] = __acc_buf_count[__wi * __bin_count];
248+
__bin_sum[0] = __counter_lacc[__wi * __bin_count];
249249

250250
_ONEDPL_PRAGMA_UNROLL
251251
for (uint16_t __i = 1; __i < __bin_count; ++__i)
252-
__bin_sum[__i] = __bin_sum[__i - 1] + __acc_buf_count[__wi * __bin_count + __i];
252+
__bin_sum[__i] = __bin_sum[__i - 1] + __counter_lacc[__wi * __bin_count + __i];
253253

254254
__dpl_sycl::__group_barrier(__it /*, sycl::access::fence_space::local_space */);
255255
//exclusive scan local sum
@@ -258,10 +258,10 @@ struct __subgroup_radix_sort
258258
//add to local sum, generate exclusive scan result
259259
_ONEDPL_PRAGMA_UNROLL
260260
for (uint16_t __i = 0; __i < __bin_count; ++__i)
261-
__acc_buf_count[__wi * __bin_count + __i + 1] = __sum_scan + __bin_sum[__i];
261+
__counter_lacc[__wi * __bin_count + __i + 1] = __sum_scan + __bin_sum[__i];
262262

263263
if (__wi == 0)
264-
__acc_buf_count[0] = 0;
264+
__counter_lacc[0] = 0;
265265
__dpl_sycl::__group_barrier(__it, __fence_buf_count);
266266
}
267267

@@ -298,7 +298,7 @@ struct __subgroup_radix_sort
298298
{
299299
const uint16_t __idx = __wi * __block_size + __i;
300300
if (__idx < __n)
301-
__acc_buf_val[__idx].~_ValT();
301+
__exchange_lacc[__idx].~_ValT();
302302
}
303303

304304
return;
@@ -312,7 +312,7 @@ struct __subgroup_radix_sort
312312
{
313313
const uint16_t __r = __indices[__i];
314314
if (__r < __n)
315-
new (&__acc_buf_val[__r]) _ValT(::std::move(__values.__v[__i]));
315+
new (&__exchange_lacc[__r]) _ValT(::std::move(__values.__v[__i]));
316316
}
317317
}
318318
else
@@ -322,7 +322,7 @@ struct __subgroup_radix_sort
322322
{
323323
const uint16_t __r = __indices[__i];
324324
if (__r < __n)
325-
__acc_buf_val[__r] = ::std::move(__values.__v[__i]);
325+
__exchange_lacc[__r] = ::std::move(__values.__v[__i]);
326326
}
327327
}
328328
__dpl_sycl::__group_barrier(__it, __fence_buf_val);
@@ -332,7 +332,7 @@ struct __subgroup_radix_sort
332332
{
333333
const uint16_t __idx = __wi * __block_size + __i;
334334
if (__idx < __n)
335-
__values.__v[__i] = ::std::move(__acc_buf_val[__idx]);
335+
__values.__v[__i] = ::std::move(__exchange_lacc[__idx]);
336336
}
337337
__dpl_sycl::__group_barrier(__it /*, sycl::access::fence_space::local_space */);
338338
}

0 commit comments

Comments
 (0)