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

using namespace metal;

typedef packed_float3 packed_rm_float3x3[3];

struct SSBOScalar
{
    packed_float3 a;
    packed_rm_float3x3 b;
    packed_rm_float3x3 c;
};

kernel void main0(device SSBOScalar& _4 [[buffer(0)]])
{
    float3x3 _20 = transpose(float3x3(float3(_4.b[0]), float3(_4.b[1]), float3(_4.b[2])));
    _4.b[0] = float3x3(float3(_4.c[0]), float3(_4.c[1]), float3(_4.c[2]))[0];
    _4.b[1] = float3x3(float3(_4.c[0]), float3(_4.c[1]), float3(_4.c[2]))[1];
    _4.b[2] = float3x3(float3(_4.c[0]), float3(_4.c[1]), float3(_4.c[2]))[2];
    _4.a = _20 * float3(_4.a);
}

