// File: /workspace/github_cpp_makefile_star2_O2/rossy[P]crossc/SPIRV-Cross/spirv_cpp.cpp
// Function: spirv_cross::CompilerCPP::emit_c_linkage()
void CompilerCPP::emit_c_linkage()
{
	statement("");

	statement("spirv_cross_shader_t *spirv_cross_construct(void)");
	begin_scope();
	statement("return new ", impl_type, "();");
	end_scope();

	statement("");
	statement("void spirv_cross_destruct(spirv_cross_shader_t *shader)");
	begin_scope();
	statement("delete static_cast<", impl_type, "*>(shader);");
	end_scope();

	statement("");
	statement("void spirv_cross_invoke(spirv_cross_shader_t *shader)");
	begin_scope();
	statement("static_cast<", impl_type, "*>(shader)->invoke();");
	end_scope();

	statement("");
	statement("static const struct spirv_cross_interface vtable =");
	begin_scope();
	statement("spirv_cross_construct,");
	statement("spirv_cross_destruct,");
	statement("spirv_cross_invoke,");
	end_scope_decl();

	statement("");
	statement("const struct spirv_cross_interface *",
	          interface_name.empty() ? string("spirv_cross_get_interface") : interface_name, "(void)");
	begin_scope();
	statement("return &vtable;");
	end_scope();
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %rbx
leaq 0x871da(%rip), %r14     # 0x8f887
movq %r14, %rsi
callq 0x928e
leaq 0x86d2e(%rip), %rsi     # 0x8f3ea
movq %rbx, %rdi
callq 0xa09c
movq %rbx, %rdi
callq 0x22d28
leaq 0x7a0(%rbx), %r15
leaq 0x86d42(%rip), %rsi     # 0x8f41c
leaq 0x9139e(%rip), %rcx     # 0x99a7f
movq %rbx, %rdi
movq %r15, %rdx
callq 0xa158
movq %rbx, %rdi
callq 0x3650a
movq %rbx, %rdi
movq %r14, %rsi
callq 0x928e
leaq 0x86d22(%rip), %rsi     # 0x8f428
movq %rbx, %rdi
callq 0xa232
movq %rbx, %rdi
callq 0x22d28
leaq 0x86d43(%rip), %rsi     # 0x8f460
leaq 0x86d50(%rip), %rcx     # 0x8f474
movq %rbx, %rdi
movq %r15, %rdx
callq 0xa2ee
movq %rbx, %rdi
callq 0x3650a
movq %rbx, %rdi
movq %r14, %rsi
callq 0x928e
leaq 0x86d37(%rip), %rsi     # 0x8f480
movq %rbx, %rdi
callq 0xa3c8
movq %rbx, %rdi
callq 0x22d28
leaq 0x86d07(%rip), %rsi     # 0x8f467
leaq 0x86d4f(%rip), %rcx     # 0x8f4b6
movq %rbx, %rdi
movq %r15, %rdx
callq 0xa484
movq %rbx, %rdi
callq 0x3650a
movq %rbx, %rdi
movq %r14, %rsi
callq 0x928e
leaq 0x86d40(%rip), %rsi     # 0x8f4cc
movq %rbx, %rdi
callq 0xa55e
movq %rbx, %rdi
callq 0x22d28
leaq 0x86d5c(%rip), %rsi     # 0x8f4ff
movq %rbx, %rdi
callq 0xa61a
leaq 0x86d64(%rip), %rsi     # 0x8f516
movq %rbx, %rdi
callq 0xa6d6
leaq 0x86d6b(%rip), %rsi     # 0x8f52c
movq %rbx, %rdi
callq 0xa792
movq %rbx, %rdi
callq 0x22dba
movq %rbx, %rdi
movq %r14, %rsi
callq 0x928e
movq 0x7f0(%rbx), %r14
testq %r14, %r14
je 0x87fb
leaq 0x7e8(%rbx), %rsi
leaq 0x10(%rsp), %rdi
callq 0x63c0
jmp 0x8811
leaq 0x86d63(%rip), %rsi     # 0x8f565
leaq 0x10(%rsp), %rdi
leaq 0xf(%rsp), %rdx
callq 0x6100
leaq 0x86d28(%rip), %rsi     # 0x8f540
leaq 0x86bf6(%rip), %rcx     # 0x8f415
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
callq 0xa84e
leaq 0x10(%rsp), %rdi
callq 0x6548
testq %r14, %r14
movq %rbx, %rdi
callq 0x22d28
leaq 0x86d37(%rip), %rsi     # 0x8f57f
movq %rbx, %rdi
callq 0xa928
movq %rbx, %rdi
callq 0x3650a
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0x6548
jmp 0x8874
movq %rax, %rbx
testq %r14, %r14
movq %rbx, %rdi
callq 0x64b0
nop