// File: rossy[P]crossc/SPIRV-Cross/spirv_msl.cpp
// Function: spirv_cross::CompilerMSL::CompilerMSL(spirv_cross::ParsedIR&&, spirv_cross::MSLVertexAttr*, unsigned long, spirv_cross::MSLResourceBinding*, unsigned long)
CompilerMSL::CompilerMSL(ParsedIR &&ir_, MSLVertexAttr *p_vtx_attrs, size_t vtx_attrs_count,
                         MSLResourceBinding *p_res_bindings, size_t res_bindings_count)
    : CompilerGLSL(std::move(ir_))
{
	if (p_vtx_attrs)
		for (size_t i = 0; i < vtx_attrs_count; i++)
			vtx_attrs_by_location[p_vtx_attrs[i].location] = &p_vtx_attrs[i];

	if (p_res_bindings)
		for (size_t i = 0; i < res_bindings_count; i++)
			resource_bindings.push_back(&p_res_bindings[i]);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x100, %rsp            # imm = 0x100
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0x60(%rbp)
movq -0x10(%rbp), %rsi
callq 0x113230
movq -0x60(%rbp), %rdi
leaq 0xbe0a9(%rip), %rax     # 0x1ae988
addq $0x10, %rax
movq %rax, (%rdi)
addq $0x788, %rdi            # imm = 0x788
movq %rdi, -0x68(%rbp)
callq 0x112910
movq -0x60(%rbp), %rdi
movl $0x0, 0x7c0(%rdi)
movl $0x0, 0x7c4(%rdi)
movl $0x0, 0x7c8(%rdi)
addq $0x7cc, %rdi            # imm = 0x7CC
callq 0x112930
jmp 0xf0926
movq -0x60(%rbp), %rdi
addq $0x7e0, %rdi            # imm = 0x7E0
movq %rdi, -0xb8(%rbp)
callq 0x112990
movq -0x60(%rbp), %rdi
addq $0x810, %rdi            # imm = 0x810
movq %rdi, -0xb0(%rbp)
callq 0x1129b0
movq -0x60(%rbp), %rdi
addq $0x848, %rdi            # imm = 0x848
movq %rdi, -0xa8(%rbp)
callq 0x1129d0
movq -0x60(%rbp), %rdi
addq $0x880, %rdi            # imm = 0x880
movq %rdi, -0xa0(%rbp)
callq 0x1129f0
movq -0x60(%rbp), %rdi
addq $0x8b0, %rdi            # imm = 0x8B0
movq %rdi, -0x98(%rbp)
callq 0x1129f0
movq -0x60(%rbp), %rdi
addq $0x8e0, %rdi            # imm = 0x8E0
movq %rdi, -0x90(%rbp)
callq 0x8210
movq -0x60(%rbp), %rdi
addq $0x8f8, %rdi            # imm = 0x8F8
movq %rdi, -0x88(%rbp)
callq 0x112a10
movq -0x60(%rbp), %rdi
addq $0x910, %rdi            # imm = 0x910
callq 0x112a30
movq -0x60(%rbp), %rdi
movl $0x0, 0x92c(%rdi)
movl $0x0, 0x930(%rdi)
movb $0x0, 0x934(%rdi)
movb $0x0, 0x935(%rdi)
movb $0x0, 0x936(%rdi)
movb $0x0, 0x937(%rdi)
movb $0x0, 0x938(%rdi)
addq $0x940, %rdi            # imm = 0x940
movq %rdi, -0x80(%rbp)
callq 0x7530
movq -0x60(%rbp), %rax
addq $0x960, %rax            # imm = 0x960
movq %rax, -0x78(%rbp)
leaq -0x3d(%rbp), %rdi
movq %rdi, -0x70(%rbp)
callq 0x7650
movq -0x78(%rbp), %rdi
movq -0x70(%rbp), %rdx
leaq 0x5d05a(%rip), %rsi     # 0x14daa6
callq 0x7520
jmp 0xf0a53
leaq -0x3d(%rbp), %rdi
callq 0x73d0
movq -0x60(%rbp), %rax
addq $0x980, %rax            # imm = 0x980
movq %rax, -0xc8(%rbp)
leaq -0x3e(%rbp), %rdi
movq %rdi, -0xc0(%rbp)
callq 0x7650
movq -0xc8(%rbp), %rdi
movq -0xc0(%rbp), %rdx
leaq 0x5198e(%rip), %rsi     # 0x142420
callq 0x7520
jmp 0xf0a99
leaq -0x3e(%rbp), %rdi
callq 0x73d0
movq -0x60(%rbp), %rax
addq $0x9a0, %rax            # imm = 0x9A0
movq %rax, -0xd8(%rbp)
leaq -0x3f(%rbp), %rdi
movq %rdi, -0xd0(%rbp)
callq 0x7650
movq -0xd8(%rbp), %rdi
movq -0xd0(%rbp), %rdx
leaq 0x59d20(%rip), %rsi     # 0x14a7f8
callq 0x7520
jmp 0xf0adf
leaq -0x3f(%rbp), %rdi
callq 0x73d0
movq -0x60(%rbp), %rdi
movl $0x0, 0x9c0(%rdi)
addq $0x9c8, %rdi            # imm = 0x9C8
movq %rdi, -0xe8(%rbp)
callq 0x112a70
movq -0x60(%rbp), %rdi
addq $0xa00, %rdi            # imm = 0xA00
movq %rdi, -0xe0(%rbp)
callq 0x8210
cmpq $0x0, -0x18(%rbp)
je 0xf0c23
movq $0x0, -0x48(%rbp)
movq -0x48(%rbp), %rax
cmpq -0x20(%rbp), %rax
jae 0xf0c21
movq -0x60(%rbp), %rdi
movq -0x18(%rbp), %rax
movq -0x48(%rbp), %rcx
leaq (%rcx,%rcx,4), %rcx
leaq (%rax,%rcx,4), %rsi
movq %rsi, -0xf8(%rbp)
addq $0x810, %rdi            # imm = 0x810
callq 0x112b50
movq %rax, -0xf0(%rbp)
jmp 0xf0b71
movq -0xf0(%rbp), %rax
movq -0xf8(%rbp), %rcx
movq %rcx, (%rax)
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0xf0b33
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0xf0cf9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x3d(%rbp), %rdi
callq 0x73d0
jmp 0xf0c9c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x3e(%rbp), %rdi
callq 0x73d0
jmp 0xf0c93
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x3f(%rbp), %rdi
callq 0x73d0
jmp 0xf0c87
movq -0xe0(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
callq 0x8430
movq -0xe8(%rbp), %rdi
callq 0x112cb0
movq -0xd8(%rbp), %rdi
callq 0x7708
jmp 0xf0c87
jmp 0xf0c23
cmpq $0x0, -0x28(%rbp)
je 0xf0c7e
movq $0x0, -0x50(%rbp)
movq -0x50(%rbp), %rax
cmpq -0x30(%rbp), %rax
jae 0xf0c7c
movq -0x60(%rbp), %rdi
addq $0x8f8, %rdi            # imm = 0x8F8
movq -0x28(%rbp), %rax
movq -0x50(%rbp), %rdx
leaq (%rdx,%rdx,8), %rcx
leaq (%rcx,%rcx,2), %rcx
addq %rdx, %rcx
addq %rcx, %rax
movq %rax, -0x58(%rbp)
leaq -0x58(%rbp), %rsi
callq 0x112c60
jmp 0xf0c6c
jmp 0xf0c6e
movq -0x50(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x50(%rbp)
jmp 0xf0c32
jmp 0xf0c7e
addq $0x100, %rsp            # imm = 0x100
popq %rbp
retq
movq -0xc8(%rbp), %rdi
callq 0x7708
movq -0x78(%rbp), %rdi
callq 0x7708
movq -0x80(%rbp), %rdi
callq 0x7708
movq -0x88(%rbp), %rdi
callq 0x112cd0
movq -0x90(%rbp), %rdi
callq 0x8430
movq -0x98(%rbp), %rdi
callq 0x112d30
movq -0xa0(%rbp), %rdi
callq 0x112d30
movq -0xa8(%rbp), %rdi
callq 0x112d50
movq -0xb0(%rbp), %rdi
callq 0x112d70
movq -0xb8(%rbp), %rdi
callq 0x112d90
movq -0x68(%rbp), %rdi
callq 0x112db0
movq -0x60(%rbp), %rdi
callq 0x14d30
movq -0x38(%rbp), %rdi
callq 0x7640
nopw %cs:(%rax,%rax)