// File: /workspace/github_cpp_makefile_star2_O3/rossy[P]crossc/SPIRV-Cross/spirv_glsl.cpp
// Function: spirv_cross::CompilerGLSL::variable_decl[abi:cxx11](spirv_cross::SPIRVariable const&)
string CompilerGLSL::variable_decl(const SPIRVariable &variable)
{
	// Ignore the pointer type since GLSL doesn't have pointers.
	auto &type = get<SPIRType>(variable.basetype);

	auto res = join(to_qualifiers_glsl(variable.self), variable_decl(type, to_name(variable.self), variable.self));

	if (variable.loop_variable && variable.static_expression)
	{
		uint32_t expr = variable.static_expression;
		if (ir.ids[expr].get_type() != TypeUndef)
			res += join(" = ", to_expression(variable.static_expression));
	}
	else if (variable.initializer)
	{
		uint32_t expr = variable.initializer;
		if (ir.ids[expr].get_type() != TypeUndef)
			res += join(" = ", to_initializer_expression(variable));
	}
	return res;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %rbx
movl 0xc(%rdx), %esi
movq %r14, %rdi
callq 0xa3ea
movq %rax, %r12
movl 0x8(%r15), %edx
movq (%r14), %rax
movq %rsp, %rdi
movq %r14, %rsi
callq *0x128(%rax)
movl 0x8(%r15), %edx
movq (%r14), %rax
leaq 0x40(%rsp), %rdi
movq %r14, %rsi
movl $0x1, %ecx
callq *0x38(%rax)
movl 0x8(%r15), %r8d
movq (%r14), %rax
leaq 0x20(%rsp), %rdi
leaq 0x40(%rsp), %rcx
movq %r14, %rsi
movq %r12, %rdx
callq *0xc8(%rax)
movq %rsp, %rsi
leaq 0x20(%rsp), %rdx
movq %rbx, %rdi
callq 0x52133
leaq 0x30(%rsp), %r12
movq -0x10(%r12), %rdi
cmpq %r12, %rdi
je 0x2c843
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6260
leaq 0x50(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2c85e
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x6260
leaq 0x10(%rsp), %r13
movq -0x10(%r13), %rdi
cmpq %r13, %rdi
je 0x2c879
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6260
cmpb $0x1, 0x64(%r15)
jne 0x2c8d3
movl 0x3c(%r15), %edx
testq %rdx, %rdx
je 0x2c8d3
movq 0x20(%r14), %rax
movq %rdx, %rcx
shlq $0x4, %rcx
cmpl $0xd, 0x8(%rax,%rcx)
je 0x2c951
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
callq 0x33f8a
leaq 0x921a7(%rip), %rsi     # 0xbea5a
movq %rsp, %rdi
leaq 0x20(%rsp), %rdx
callq 0x5819d
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x60b0
jmp 0x2c924
movl 0x18(%r15), %eax
testq %rax, %rax
je 0x2c951
movq 0x20(%r14), %rcx
shlq $0x4, %rax
cmpl $0xd, 0x8(%rcx,%rax)
je 0x2c951
movq (%r14), %rax
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
movq %r15, %rdx
callq *0x160(%rax)
leaq 0x92154(%rip), %rsi     # 0xbea5a
movq %rsp, %rdi
leaq 0x20(%rsp), %rdx
callq 0x5819d
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x60b0
movq (%rsp), %rdi
cmpq %r13, %rdi
je 0x2c93a
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6260
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x2c951
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6260
movq %rbx, %rax
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
jmp 0x2c968
jmp 0x2c983
jmp 0x2c99f
movq %rax, %r14
movq (%rsp), %rdi
cmpq %r13, %rdi
je 0x2c986
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6260
jmp 0x2c986
movq %rax, %r14
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x2c9a2
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6260
jmp 0x2c9a2
movq %rax, %r14
movq (%rbx), %rdi
addq $0x10, %rbx
cmpq %rbx, %rdi
je 0x2ca11
movq (%rbx), %rsi
jmp 0x2ca09
movq %rax, %r14
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2c9d6
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6260
jmp 0x2c9d6
movq %rax, %r14
leaq 0x50(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2c9f6
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x6260
jmp 0x2c9f6
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2ca11
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6260
movq %r14, %rdi
callq 0x64a0
nop