Skip to content

Commit c1d2b30

Browse files
committed
correction in logic for min, max
1 parent 4554dd1 commit c1d2b30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

algorithms/sycl/Reduction.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ namespace {
3333
void atomicUpdate(AtomicRef& atomic, AccT value){
3434

3535
constexpr auto MO = sycl::memory_order::relaxed;
36-
AccT expected = value;
36+
AccT expected = neutral<Type, AccT>();
3737

3838
if constexpr(Type == ReductionType::Add) {
3939
// Explicity pass MO to fetch_add

0 commit comments

Comments
 (0)