diff --git a/util/test/demos/d3d11/d3d11_groupshared.cpp b/util/test/demos/d3d11/d3d11_groupshared.cpp index 36c997f69..36e84611f 100644 --- a/util/test/demos/d3d11/d3d11_groupshared.cpp +++ b/util/test/demos/d3d11/d3d11_groupshared.cpp @@ -61,7 +61,7 @@ void main(uint3 tid : SV_GroupThreadID) outval.z = tmp[tid.x ^ 1]; // do calculation with our neighbour - tmp[tid.x] = tmp[tid.x] * tmp[tid.x ^ 1]; + tmp[tid.x] = (1.0f + tmp[tid.x]) * (1.0f + tmp[tid.x ^ 1]); GroupMemoryBarrierWithGroupSync(); diff --git a/util/test/demos/d3d12/d3d12_groupshared.cpp b/util/test/demos/d3d12/d3d12_groupshared.cpp index 8561190f1..c7b92a7b2 100644 --- a/util/test/demos/d3d12/d3d12_groupshared.cpp +++ b/util/test/demos/d3d12/d3d12_groupshared.cpp @@ -61,7 +61,7 @@ void main(uint3 tid : SV_GroupThreadID) outval.z = tmp[tid.x ^ 1]; // do calculation with our neighbour - tmp[tid.x] = tmp[tid.x] * tmp[tid.x ^ 1]; + tmp[tid.x] = (1.0f + tmp[tid.x]) * (1.0f + tmp[tid.x ^ 1]); GroupMemoryBarrierWithGroupSync(); diff --git a/util/test/demos/vk/vk_groupshared.cpp b/util/test/demos/vk/vk_groupshared.cpp index a99d76419..b0ff38fc4 100644 --- a/util/test/demos/vk/vk_groupshared.cpp +++ b/util/test/demos/vk/vk_groupshared.cpp @@ -45,7 +45,7 @@ shared float tmp[64]; layout(local_size_x = 64, local_size_y = 1, local_size_z = 1) in; -define GroupMemoryBarrierWithGroupSync() memoryBarrierShared();groupMemoryBarrier();barrier(); +#define GroupMemoryBarrierWithGroupSync() memoryBarrierShared();groupMemoryBarrier();barrier(); void main() { @@ -74,7 +74,7 @@ void main() outval.z = tmp[tid.x ^ 1]; // do calculation with our neighbour - tmp[tid.x] = tmp[tid.x] * tmp[tid.x ^ 1]; + tmp[tid.x] = (1.0f + tmp[tid.x]) * (1.0f + tmp[tid.x ^ 1]); GroupMemoryBarrierWithGroupSync();