Zhaoming Jiang | 9443ceb | 2022-08-05 15:15:17 +0000 | [diff] [blame] | 1 | enable f16; |
| 2 | |
| 3 | fn select_10e73b() { |
dan sinclair | d9b68eb | 2022-11-10 00:32:12 +0000 | [diff] [blame] | 4 | var arg_0 = 1.0h; |
| 5 | var arg_1 = 1.0h; |
Zhaoming Jiang | 9443ceb | 2022-08-05 15:15:17 +0000 | [diff] [blame] | 6 | var arg_2 = true; |
| 7 | var res : f16 = select(arg_0, arg_1, arg_2); |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 8 | prevent_dce = res; |
Zhaoming Jiang | 9443ceb | 2022-08-05 15:15:17 +0000 | [diff] [blame] | 9 | } |
| 10 | |
Ben Clayton | 77a90cb | 2023-03-06 18:25:08 +0000 | [diff] [blame] | 11 | @group(2) @binding(0) var<storage, read_write> prevent_dce : f16; |
| 12 | |
Zhaoming Jiang | 9443ceb | 2022-08-05 15:15:17 +0000 | [diff] [blame] | 13 | @vertex |
| 14 | fn vertex_main() -> @builtin(position) vec4<f32> { |
| 15 | select_10e73b(); |
| 16 | return vec4<f32>(); |
| 17 | } |
| 18 | |
| 19 | @fragment |
| 20 | fn fragment_main() { |
| 21 | select_10e73b(); |
| 22 | } |
| 23 | |
| 24 | @compute @workgroup_size(1) |
| 25 | fn compute_main() { |
| 26 | select_10e73b(); |
| 27 | } |