File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -1349,7 +1349,10 @@ struct NDRangeReduction<
1349
1349
// We're done.
1350
1350
return ;
1351
1351
1352
- // Signal this work-group has finished after all values are reduced
1352
+ // Signal this work-group has finished after all values are reduced. We
1353
+ // had an implicit work-group barrier in reduce_over_group and all the
1354
+ // work since has been done in (LID == 0) work-item, so no extra sync is
1355
+ // needed.
1353
1356
if (LID == 0 ) {
1354
1357
auto NFinished =
1355
1358
sycl::atomic_ref<int , memory_order::acq_rel, memory_scope::device,
@@ -1561,7 +1564,10 @@ template <> struct NDRangeReduction<reduction::strategy::range_basic> {
1561
1564
}
1562
1565
}
1563
1566
1564
- // Signal this work-group has finished after all values are reduced
1567
+ // Signal this work-group has finished after all values are reduced. We
1568
+ // had an implicit work-group barrier in doTreeReduction and all the
1569
+ // work since has been done in (LID == 0) work-item, so no extra sync is
1570
+ // needed.
1565
1571
if (LID == 0 ) {
1566
1572
auto NFinished =
1567
1573
sycl::atomic_ref<int , memory_order::acq_rel, memory_scope::device,
You can’t perform that action at this time.
0 commit comments