#include <metal_stdlib>
#include <simd/simd.h>

using namespace metal;

struct TaskPayload
{
    float a;
    float b;
    int c;
};

constant uint3 gl_WorkGroupSize [[maybe_unused]] = uint3(1u);

[[object]] void main0(mesh_grid_properties spvMgp, object_data TaskPayload& payload [[payload]])
{
    payload.a = 1.2000000476837158203125;
    payload.b = 2.2999999523162841796875;
    payload.c = 3;
    threadgroup_barrier(mem_flags::mem_threadgroup);
    spvMgp.set_threadgroups_per_grid(uint3(1u, 2u, 3u));
    return;
}

