Skip to content

Commit 05f99d9

Browse files
authored
Fix ONSAM-1997 (#2398)
* replace shuffle() with select_from_group * Replace deprecated APIs with new APIs
1 parent ccf9df7 commit 05f99d9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Publications/GPU-Opt-Guide/sub-group/transpose.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,20 +59,20 @@ int main() {
5959
int aj = BLOCK_SIZE * gj;
6060

6161
for (uint k = 0; k < BLOCK_SIZE; k++) {
62-
bcol[k] = sg.load(marr.get_pointer() + (ai + k) * N + aj);
62+
bcol[k] = sg.load(marr.template get_multi_ptr<sycl::access::decorated::yes>() + (ai + k) * N + aj);
6363
}
6464

6565
uint tcol[BLOCK_SIZE];
6666
for (uint n = 0; n < BLOCK_SIZE; n++) {
6767
if (sgId == n) {
6868
for (uint k = 0; k < BLOCK_SIZE; k++) {
69-
tcol[k] = sg.shuffle(bcol[n], k);
69+
tcol[k] = sycl::select_from_group(sg, bcol[n], k);
7070
}
7171
}
7272
}
7373

7474
for (uint k = 0; k < BLOCK_SIZE; k++) {
75-
sg.store(marr.get_pointer() + (ai + k) * N + aj, tcol[k]);
75+
sg.store(marr.template get_multi_ptr<sycl::access::decorated::yes>() + (ai + k) * N + aj, tcol[k]);
7676
}
7777
});
7878
});

0 commit comments

Comments
 (0)