blob: 97c0f58cb1d8eb8d97f13d1fd287f1e7c837080b [file] [log] [blame]
@group(0) @binding(0) var<storage, read_write> S : atomic<i32>;
@fragment
fn main() -> @location(0) vec4f {
if (false) {
discard;
}
let old_value = atomicCompareExchangeWeak(&S, 0i, 1i).old_value;
return vec4f(f32(old_value));
}