| #include <metal_stdlib> | |
| using namespace metal; | |
| struct tint_module_vars_struct { | |
| const constant uint* value; | |
| device uint* output; | |
| }; | |
| void foo(const constant uint* const p, tint_module_vars_struct tint_module_vars) { | |
| (*tint_module_vars.output) = (*p); | |
| } | |
| kernel void v(const constant uint* value [[buffer(30)]], device uint* output [[buffer(0)]]) { | |
| tint_module_vars_struct const tint_module_vars = tint_module_vars_struct{.value=value, .output=output}; | |
| foo(tint_module_vars.value, tint_module_vars); | |
| } |