#include #include using namespace metal; struct StorageBuffer { uint values[1]; }; constant int local_size_x_val_tmp [[function_constant(0)]]; constant int local_size_x_val = is_function_constant_defined(local_size_x_val_tmp) ? local_size_x_val_tmp : 1; constant int local_size_y_val_tmp [[function_constant(1)]]; constant int local_size_y_val = is_function_constant_defined(local_size_y_val_tmp) ? local_size_y_val_tmp : 1; constant int local_size_z_val_tmp [[function_constant(2)]]; constant int local_size_z_val = is_function_constant_defined(local_size_z_val_tmp) ? local_size_z_val_tmp : 1; constant uint _22 = is_function_constant_defined(local_size_x_val_tmp) ? uint(local_size_x_val_tmp) : 1u; constant uint _23 = is_function_constant_defined(local_size_y_val_tmp) ? uint(local_size_y_val_tmp) : 1u; constant uint _24 = is_function_constant_defined(local_size_z_val_tmp) ? uint(local_size_z_val_tmp) : 1u; constant uint3 gl_WorkGroupSize [[maybe_unused]] = uint3(_22, _23, _24); kernel void main0(device StorageBuffer& ssbo [[buffer(0)]], uint gl_LocalInvocationIndex [[thread_index_in_threadgroup]]) { ssbo.values[gl_LocalInvocationIndex] = 1u; }