sycl:refine convert
Signed-off-by: zhentaoyu <zhentao.yu@intel.com>
This commit is contained in:
parent
bd960a67dc
commit
df3f1c1850
1 changed files with 1 additions and 2 deletions
|
@ -424,9 +424,8 @@ static void convert_unary(const void * __restrict__ vx, dst_t * __restrict__ y,
|
||||||
const int64_t global_id = item_ct1.get_local_id(2) + work_group_size * item_ct1.get_group(2);
|
const int64_t global_id = item_ct1.get_local_id(2) + work_group_size * item_ct1.get_group(2);
|
||||||
|
|
||||||
// make each work-item deal with more elements since sycl global range can not exceed max int
|
// make each work-item deal with more elements since sycl global range can not exceed max int
|
||||||
for (int64_t i = global_id; i < k; i += work_group_size * item_ct1.get_group_range(2)) {
|
|
||||||
const src_t * x = (src_t *) vx;
|
const src_t * x = (src_t *) vx;
|
||||||
|
for (int64_t i = global_id; i < k; i += work_group_size * item_ct1.get_group_range(2)) {
|
||||||
y[i] = x[i];
|
y[i] = x[i];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue