blob: 03c819862c70debbbe468c1e2f430312ad970cab [file] [log] [blame]
#include <metal_stdlib>
using namespace metal;
struct tint_module_vars_struct {
threadgroup int* a;
threadgroup float4* b;
threadgroup float2x2* c;
};
int tint_div_i32(int lhs, int rhs) {
return (lhs / select(rhs, 1, ((rhs == 0) | ((lhs == (-2147483647 - 1)) & (rhs == -1)))));
}
void foo(tint_module_vars_struct tint_module_vars) {
(*tint_module_vars.a) = tint_div_i32((*tint_module_vars.a), 2);
(*tint_module_vars.b) = ((*tint_module_vars.b) * float4x4(float4(0.0f), float4(0.0f), float4(0.0f), float4(0.0f)));
(*tint_module_vars.c) = ((*tint_module_vars.c) * 2.0f);
}