summaryrefslogtreecommitdiff
path: root/tests/language-feature
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2024-09-20 20:21:18 -0700
committerGitHub <noreply@github.com>2024-09-20 20:21:18 -0700
commit53684ed919ff2f5f3656aed2e95a111207452392 (patch)
treecf6926f21797d99534f22da121beceb085b6035a /tests/language-feature
parentc42b5e24b5b9d6b03352d809e0a49485d361154f (diff)
Fix handling of pointer logic in wgsl backend. (#5129)
Diffstat (limited to 'tests/language-feature')
-rw-r--r--tests/language-feature/atomic-t/atomic-0.slang14
1 files changed, 0 insertions, 14 deletions
diff --git a/tests/language-feature/atomic-t/atomic-0.slang b/tests/language-feature/atomic-t/atomic-0.slang
index 6f2ce6418..591de490c 100644
--- a/tests/language-feature/atomic-t/atomic-0.slang
+++ b/tests/language-feature/atomic-t/atomic-0.slang
@@ -12,46 +12,32 @@ void computeMain()
bool result = true;
if (outputBuffer[0].add(1) != 0)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].sub(1) != 1)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].max(2) != 0)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].min(1) != 2)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].or(3) != 1)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].and(2) != 3)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].xor(3) != 2)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].exchange(4) != 1)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].compareExchange(4, 5) != 4)
{} //result = false; // for some reason this fails on Metal Github CI, so disabling.
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].load() != 5)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].increment() != 5)
result = false;
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].decrement() != 6)
result = false;
- AllMemoryBarrierWithGroupSync();
// CHECK: 6
outputBuffer[0].store(6);
- AllMemoryBarrierWithGroupSync();
if (outputBuffer[0].load() != 6)
result = false;
- AllMemoryBarrierWithGroupSync();
// CHECK: 1
if (result)
outputBuffer[1].store(1);