Stephen White | 2fe0f4b | 2021-11-16 15:15:36 +0000 | [diff] [blame] | 1 | #version 310 es |
| 2 | precision mediump float; |
| 3 | |
Stephen White | 943c410 | 2021-11-19 17:46:13 +0000 | [diff] [blame] | 4 | shared uint arg_0; |
Stephen White | 2fe0f4b | 2021-11-16 15:15:36 +0000 | [diff] [blame] | 5 | |
| 6 | void atomicExchange_0a5dca() { |
Stephen White | 943c410 | 2021-11-19 17:46:13 +0000 | [diff] [blame] | 7 | uint res = atomicExchange(arg_0, 1u); |
Stephen White | 2fe0f4b | 2021-11-16 15:15:36 +0000 | [diff] [blame] | 8 | } |
| 9 | |
| 10 | struct tint_symbol_1 { |
| 11 | uint local_invocation_index; |
| 12 | }; |
| 13 | |
| 14 | void compute_main_inner(uint local_invocation_index) { |
| 15 | { |
Stephen White | 943c410 | 2021-11-19 17:46:13 +0000 | [diff] [blame] | 16 | atomicExchange(arg_0, 0u); |
Stephen White | 2fe0f4b | 2021-11-16 15:15:36 +0000 | [diff] [blame] | 17 | } |
Stephen White | 943c410 | 2021-11-19 17:46:13 +0000 | [diff] [blame] | 18 | memoryBarrierShared(); |
Stephen White | 2fe0f4b | 2021-11-16 15:15:36 +0000 | [diff] [blame] | 19 | atomicExchange_0a5dca(); |
| 20 | } |
| 21 | |
| 22 | layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in; |
| 23 | void compute_main(tint_symbol_1 tint_symbol) { |
| 24 | compute_main_inner(tint_symbol.local_invocation_index); |
| 25 | return; |
| 26 | } |
| 27 | void main() { |
| 28 | tint_symbol_1 inputs; |
| 29 | inputs.local_invocation_index = uint(gl_LocalInvocationIndex); |
| 30 | compute_main(inputs); |
| 31 | } |
| 32 | |
| 33 | |