blob: 4391e259100091b3e4e9c3abf1767dcf6845806a [file] [log] [blame] [edit]
int tint_ftoi(float v) {
return ((v < 2147483520.0f) ? ((v < -2147483648.0f) ? -2147483648 : int(v)) : 2147483647);
}
RWByteAddressBuffer s : register(u0);
groupshared int g1;
struct S {
int a;
int b;
};
int accept_value(int val) {
return val;
}
int accept_ptr_deref_call_func(inout int val) {
const int tint_symbol_2 = val;
const int tint_symbol_3 = accept_value(val);
return (tint_symbol_2 + tint_symbol_3);
}
int accept_ptr_deref_pass_through(inout int val) {
const int tint_symbol = val;
const int tint_symbol_1 = accept_ptr_deref_call_func(val);
return (tint_symbol + tint_symbol_1);
}
int accept_ptr_to_struct_and_access(inout S val) {
return (val.a + val.b);
}
int accept_ptr_to_struct_access_pass_ptr(inout S val) {
val.a = 2;
return val.a;
}
int accept_ptr_vec_access_elements(inout float3 v1) {
v1.x = cross(v1, v1).x;
return tint_ftoi(v1.x);
}
int call_builtin_with_mod_scope_ptr() {
int atomic_result = 0;
InterlockedOr(g1, 0, atomic_result);
return atomic_result;
}
struct tint_symbol_11 {
uint local_invocation_index : SV_GroupIndex;
};
void main_inner(uint local_invocation_index) {
{
int atomic_result_1 = 0;
InterlockedExchange(g1, 0, atomic_result_1);
}
GroupMemoryBarrierWithGroupSync();
int v1 = 0;
S v2 = (S)0;
float3 v4 = (0.0f).xxx;
int atomic_result_2 = 0;
InterlockedOr(g1, 0, atomic_result_2);
const int t1 = atomic_result_2;
const int tint_symbol_4 = accept_ptr_deref_pass_through(v1);
const int tint_symbol_5 = accept_ptr_to_struct_and_access(v2);
const int tint_symbol_6 = accept_ptr_to_struct_and_access(v2);
const int tint_symbol_7 = accept_ptr_vec_access_elements(v4);
const int tint_symbol_8 = accept_ptr_to_struct_access_pass_ptr(v2);
const int tint_symbol_9 = call_builtin_with_mod_scope_ptr();
s.Store(0u, asuint(((((((tint_symbol_4 + tint_symbol_5) + tint_symbol_6) + tint_symbol_7) + tint_symbol_8) + tint_symbol_9) + t1)));
}
[numthreads(1, 1, 1)]
void main(tint_symbol_11 tint_symbol_10) {
main_inner(tint_symbol_10.local_invocation_index);
return;
}