LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_remapped_declared_block_name[abi:cxx11](unsigned int) const
std::string Compiler::get_remapped_declared_block_name(uint32_t id) const
{
	auto itr = declared_block_names.find(id);
	if (itr != end(declared_block_names))
		return itr->second;
	else
	{
		auto &var = get<SPIRVariable>(id);
		auto &type = get<SPIRType>(var.basetype);
		auto &block_name = ir.meta[type.self].decoration.alias;
		return block_name.empty() ? get_block_fallback_name(id) : block_name;
	}
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
movl %edx, %eax
movq 0x3d8(%rsi), %rsi
movq 0x3e0(%r14), %rdi
xorl %r9d, %r9d
xorl %edx, %edx
divq %rdi
movq (%rsi,%rdx,8), %rax
testq %rax, %rax
je 0x140ec
movq (%rax), %r8
movq %rax, %r9
cmpl %ebp, 0x8(%r8)
je 0x140ec
movq %rdx, %rcx
movq %r8, %r10
movq (%r8), %r8
testq %r8, %r8
je 0x140e9
movl 0x8(%r8), %esi
movq %rsi, %rax
xorl %edx, %edx
divq %rdi
movl $0x0, %r9d
cmpq %rcx, %rdx
jne 0x140ec
movq %r10, %r9
cmpl %ebp, %esi
jne 0x140be
jmp 0x140ec
xorl %r9d, %r9d
testq %r9, %r9
je 0x140f6
movq (%r9), %rax
jmp 0x140f8
xorl %eax, %eax
testq %rax, %rax
je 0x1410e
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq 0x10(%rax), %rsi
movq 0x18(%rax), %rdx
jmp 0x14148
movq %r14, %rdi
movl %ebp, %esi
callq 0x1baba
movl 0xc(%rax), %esi
movq %r14, %rdi
callq 0x1b9de
movl 0x8(%rax), %ecx
movq 0x38(%r14), %rax
imulq $0x148, %rcx, %rcx      # imm = 0x148
movq 0x8(%rax,%rcx), %rdx
testq %rdx, %rdx
je 0x1415b
addq %rcx, %rax
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
movq (%rax), %rsi
addq %rsi, %rdx
movq %rbx, %rdi
callq 0xe480
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
movq (%r14), %rax
movq %rbx, %rdi
movq %r14, %rsi
movl %ebp, %edx
callq *0x20(%rax)
jmp 0x14153
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::type_is_block_like(spirv_cross::SPIRType const&) const
bool Compiler::type_is_block_like(const SPIRType &type) const
{
	if (type.basetype != SPIRType::Struct)
		return false;

	if (has_decoration(type.self, DecorationBlock) || has_decoration(type.self, DecorationBufferBlock))
	{
		return true;
	}

	// Block-like types may have Offset decorations.
	for (uint32_t i = 0; i < uint32_t(type.member_types.size()); i++)
		if (has_member_decoration(type.self, i, DecorationOffset))
			return true;

	return false;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
cmpl $0xc, 0xc(%rsi)
jne 0x14213
movq %rsi, %rbx
movq %rdi, %r14
movl 0x8(%rsi), %esi
addq $0x8, %r14
movq %r14, %rdi
movl $0x2, %edx
callq 0x24fbc
movb $0x1, %bpl
testb %al, %al
jne 0x14215
movl 0x8(%rbx), %esi
movq %r14, %rdi
movl $0x3, %edx
callq 0x24fbc
testb %al, %al
jne 0x14215
movq 0x70(%rbx), %rax
subq 0x68(%rbx), %rax
shrq $0x2, %rax
testl %eax, %eax
setne %bpl
je 0x14215
movl 0x8(%rbx), %esi
movq %r14, %rdi
xorl %edx, %edx
movl $0x23, %ecx
callq 0x252a8
testb %al, %al
jne 0x14215
movl $0x1, %r15d
movq 0x70(%rbx), %rax
subq 0x68(%rbx), %rax
shrq $0x2, %rax
cmpl %eax, %r15d
setb %bpl
jae 0x14215
movl 0x8(%rbx), %esi
movq %r14, %rdi
movl %r15d, %edx
movl $0x23, %ecx
callq 0x252a8
incl %r15d
testb %al, %al
je 0x141e2
jmp 0x14215
xorl %ebp, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::fixup_type_alias()
void Compiler::fixup_type_alias()
{
	// Due to how some backends work, the "master" type of type_alias must be a block-like type if it exists.
	// FIXME: Multiple alias types which are both block-like will be awkward, for now, it's best to just drop the type
	// alias if the slave type is a block type.
	for (auto &id : ir.ids)
	{
		if (id.get_type() != TypeType)
			continue;

		auto &type = id.get<SPIRType>();

		if (type.type_alias && type_is_block_like(type))
		{
			// Become the master.
			for (auto &other_id : ir.ids)
			{
				if (other_id.get_type() != TypeType)
					continue;
				if (other_id.get_id() == type.self)
					continue;

				auto &other_type = other_id.get<SPIRType>();
				if (other_type.type_alias == type.type_alias)
					other_type.type_alias = type.self;
			}

			get<SPIRType>(type.type_alias).type_alias = id.get_id();
			type.type_alias = 0;
		}
	}

	for (auto &id : ir.ids)
	{
		if (id.get_type() != TypeType)
			continue;

		auto &type = id.get<SPIRType>();
		if (type.type_alias && type_is_block_like(type))
		{
			// This is not allowed, drop the type_alias.
			type.type_alias = 0;
		}
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x20(%rdi), %r14
movq 0x28(%rdi), %r13
cmpq %r13, %r14
je 0x1430b
cmpl $0x1, 0x8(%r14)
jne 0x14302
movq %r14, %rdi
callq 0xb08e
cmpl $0x0, 0x98(%rax)
je 0x14302
movq %rax, %r15
movq %rbx, %rdi
movq %rax, %rsi
callq 0x1416c
testb %al, %al
je 0x14302
movq 0x20(%rbx), %r12
movq 0x28(%rbx), %rbp
cmpq %rbp, %r12
je 0x142d3
cmpl $0x1, 0x8(%r12)
jne 0x142cd
movq (%r12), %rax
testq %rax, %rax
je 0x142a4
movl 0x8(%rax), %eax
jmp 0x142a6
xorl %eax, %eax
cmpl 0x8(%r15), %eax
je 0x142cd
movq %r12, %rdi
callq 0xb08e
movl 0x98(%rax), %ecx
cmpl 0x98(%r15), %ecx
jne 0x142cd
movl 0x8(%r15), %ecx
movl %ecx, 0x98(%rax)
addq $0x10, %r12
jmp 0x14289
movq (%r14), %rax
testq %rax, %rax
je 0x142e0
movl 0x8(%rax), %ebp
jmp 0x142e2
xorl %ebp, %ebp
movl 0x98(%r15), %esi
movq %rbx, %rdi
callq 0xa426
movl %ebp, 0x98(%rax)
movl $0x0, 0x98(%r15)
addq $0x10, %r14
jmp 0x14242
movq 0x20(%rbx), %r14
movq 0x28(%rbx), %r12
cmpq %r12, %r14
je 0x14353
cmpl $0x1, 0x8(%r14)
jne 0x1434d
movq %r14, %rdi
callq 0xb08e
cmpl $0x0, 0x98(%rax)
je 0x1434d
movq %rax, %r15
movq %rbx, %rdi
movq %rax, %rsi
callq 0x1416c
testb %al, %al
je 0x1434d
movl $0x0, 0x98(%r15)
addq $0x10, %r14
jmp 0x14313
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_non_pointer_type_id(unsigned int) const
uint32_t Compiler::get_non_pointer_type_id(uint32_t type_id) const
{
	auto *p_type = &get<SPIRType>(type_id);
	while (p_type->pointer)
	{
		assert(p_type->parent_type);
		type_id = p_type->parent_type;
		p_type = &get<SPIRType>(type_id);
	}
	return type_id;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x1b9de
cmpb $0x1, 0x60(%rax)
jne 0x14c25
movl 0x9c(%rax), %ebp
testl %ebp, %ebp
je 0x14c2e
movq %rbx, %rdi
movl %ebp, %esi
callq 0x1b9de
cmpb $0x0, 0x60(%rax)
jne 0x14c0b
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
leaq 0xa10c0(%rip), %rdi     # 0xb5cf5
leaq 0xa10cd(%rip), %rsi     # 0xb5d09
leaq 0xa10e2(%rip), %rcx     # 0xb5d25
movl $0x3c3, %edx            # imm = 0x3C3
callq 0x61b0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_non_pointer_type(spirv_cross::SPIRType const&) const
const SPIRType &Compiler::get_non_pointer_type(const SPIRType &type) const
{
	auto *p_type = &type;
	while (p_type->pointer)
	{
		assert(p_type->parent_type);
		p_type = &get<SPIRType>(p_type->parent_type);
	}
	return *p_type;
}

// Assembly:
pushq %rbx
movq %rsi, %rax
cmpb $0x1, 0x60(%rsi)
jne 0x14c73
movq %rdi, %rbx
movl 0x9c(%rax), %esi
testl %esi, %esi
je 0x14c75
movq %rbx, %rdi
callq 0x1b9de
cmpb $0x0, 0x60(%rax)
jne 0x14c5b
popq %rbx
retq
leaq 0xa1079(%rip), %rdi     # 0xb5cf5
leaq 0xa1086(%rip), %rsi     # 0xb5d09
leaq 0xa10e3(%rip), %rcx     # 0xb5d6d
movl $0x3cf, %edx            # imm = 0x3CF
callq 0x61b0
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_member_qualified_name[abi:cxx11](unsigned int, unsigned int) const
const std::string &Compiler::get_member_qualified_name(uint32_t type_id, uint32_t index) const
{
	const static string empty;

	auto &m = ir.meta.at(type_id);
	if (index < m.members.size())
		return m.members[index].qualified_alias;
	else
		return empty;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebx
movl %esi, %ebp
movq %rdi, %r14
movb 0xe96ff(%rip), %al      # 0xfe4e0
testb %al, %al
je 0x14e56
movl %ebp, %esi
movq 0x38(%r14), %rax
movq 0x40(%r14), %rcx
subq %rax, %rcx
sarq $0x3, %rcx
movabsq $-0x7063e7063e7063e7, %rdx # imm = 0x8F9C18F9C18F9C19
imulq %rcx, %rdx
cmpq %rsi, %rdx
jbe 0x14e5d
movl %ebx, %ecx
imulq $0x148, %rsi, %rdx      # imm = 0x148
movq 0xd0(%rax,%rdx), %rsi
movq 0xd8(%rax,%rdx), %rax
subq %rsi, %rax
sarq $0x4, %rax
movabsq $0x4ec4ec4ec4ec4ec5, %rdx # imm = 0x4EC4EC4EC4EC4EC5
imulq %rax, %rdx
imulq $0xd0, %rcx, %rax
cmpq %rcx, %rdx
leaq 0x20(%rsi,%rax), %rcx
leaq 0xe9673(%rip), %rax     # 0xfe4c0
cmovaq %rcx, %rax
popq %rbx
popq %r14
popq %rbp
retq
callq 0x68bc
jmp 0x14de5
leaq 0xa02b5(%rip), %rdi     # 0xb5119
xorl %eax, %eax
callq 0x63d0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_block_fallback_name[abi:cxx11](unsigned int) const
const std::string Compiler::get_block_fallback_name(uint32_t id) const
{
	auto &var = get<SPIRVariable>(id);
	if (get_name(id).empty())
		return join("_", get<SPIRType>(var.basetype).self, "_", id);
	else
		return get_name(id);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movl %edx, 0x4(%rsp)
movq %rsi, %rdi
movl %edx, %esi
callq 0x1baba
movl 0x4(%rsp), %esi
movq 0x38(%r14), %rcx
movq 0x40(%r14), %rdi
subq %rcx, %rdi
sarq $0x3, %rdi
movabsq $-0x7063e7063e7063e7, %rdx # imm = 0x8F9C18F9C18F9C19
imulq %rdi, %rdx
cmpq %rsi, %rdx
jbe 0x14fba
imulq $0x148, %rsi, %rsi      # imm = 0x148
movq 0x8(%rcx,%rsi), %rdx
testq %rdx, %rdx
je 0x14f89
addq %rsi, %rcx
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movq (%rcx), %rsi
addq %rsi, %rdx
movq %rbx, %rdi
callq 0xe480
jmp 0x14faf
movl 0xc(%rax), %esi
movq %r14, %rdi
callq 0x1b9de
leaq 0x8(%rax), %rdx
leaq 0xaa010(%rip), %rcx     # 0xbefaf
leaq 0x4(%rsp), %r8
movq %rbx, %rdi
movq %rcx, %rsi
callq 0x1bfcf
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0xa0158(%rip), %rdi     # 0xb5119
xorl %eax, %eax
callq 0x63d0
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_binary_offset_for_decoration(unsigned int, spv::Decoration, unsigned int&) const
bool Compiler::get_binary_offset_for_decoration(uint32_t id, spv::Decoration decoration, uint32_t &word_offset) const
{
	auto &word_offsets = ir.meta.at(id).decoration_word_offset;
	auto itr = word_offsets.find(decoration);
	if (itr == end(word_offsets))
		return false;

	word_offset = itr->second;
	return true;
}

// Assembly:
pushq %rbx
movl %edx, %r8d
movl %esi, %esi
movq 0x38(%rdi), %r9
movq 0x40(%rdi), %rax
subq %r9, %rax
sarq $0x3, %rax
movabsq $-0x7063e7063e7063e7, %rdx # imm = 0x8F9C18F9C18F9C19
imulq %rax, %rdx
cmpq %rsi, %rdx
jbe 0x150bd
imulq $0x148, %rsi, %rdx      # imm = 0x148
movl %r8d, %eax
movq 0xe8(%r9,%rdx), %rdi
movq 0xf0(%r9,%rdx), %r9
xorl %r11d, %r11d
xorl %edx, %edx
divq %r9
movq (%rdi,%rdx,8), %rax
testq %rax, %rax
je 0x1509f
movq (%rax), %r10
movq %rax, %r11
cmpl %r8d, 0x8(%r10)
je 0x1509f
movq %rdx, %rsi
movq %r10, %rbx
movq (%r10), %r10
testq %r10, %r10
je 0x1509c
movl 0x8(%r10), %edi
movq %rdi, %rax
xorl %edx, %edx
divq %r9
movl $0x0, %r11d
cmpq %rsi, %rdx
jne 0x1509f
movq %rbx, %r11
cmpl %r8d, %edi
jne 0x15070
jmp 0x1509f
xorl %r11d, %r11d
testq %r11, %r11
je 0x150a9
movq (%r11), %rax
jmp 0x150ab
xorl %eax, %eax
testq %rax, %rax
je 0x150b5
movl 0xc(%rax), %edx
movl %edx, (%rcx)
testq %rax, %rax
setne %al
popq %rbx
retq
leaq 0xa0055(%rip), %rdi     # 0xb5119
xorl %eax, %eax
callq 0x63d0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::block_is_outside_flow_control_from_block(spirv_cross::SPIRBlock const&, spirv_cross::SPIRBlock const&)
bool Compiler::block_is_outside_flow_control_from_block(const SPIRBlock &from, const SPIRBlock &to)
{
	auto *start = &from;

	if (start->self == to.self)
		return true;

	// Break cycles.
	if (is_continue(start->self))
		return false;

	// If our select block doesn't merge, we must break or continue in these blocks,
	// so if continues occur branchless within these blocks, consider them branchless as well.
	// This is typically used for loop control.
	if (start->terminator == SPIRBlock::Select && start->merge == SPIRBlock::MergeNone &&
	    (block_is_outside_flow_control_from_block(get<SPIRBlock>(start->true_block), to) ||
	     block_is_outside_flow_control_from_block(get<SPIRBlock>(start->false_block), to)))
	{
		return true;
	}
	else if (start->merge_block && block_is_outside_flow_control_from_block(get<SPIRBlock>(start->merge_block), to))
	{
		return true;
	}
	else if (start->next_block && block_is_outside_flow_control_from_block(get<SPIRBlock>(start->next_block), to))
	{
		return true;
	}
	else
		return false;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movl 0x8(%rsi), %eax
movb $0x1, %bl
cmpl 0x8(%rdx), %eax
je 0x15376
movq %rdi, %r15
movq 0x80(%rdi), %rcx
testb $0x2, (%rcx,%rax)
jne 0x15374
movq %rdx, %r14
movq %rsi, %r12
cmpl $0x2, 0xc(%rsi)
jne 0x1532e
cmpl $0x0, 0x10(%r12)
jne 0x1532e
movl 0x2c(%r12), %esi
movq %r15, %rdi
callq 0x78fe
movq %r15, %rdi
movq %rax, %rsi
movq %r14, %rdx
callq 0x152b2
testb %al, %al
jne 0x15376
movl 0x30(%r12), %esi
movq %r15, %rdi
callq 0x78fe
movq %r15, %rdi
movq %rax, %rsi
movq %r14, %rdx
callq 0x152b2
testb %al, %al
jne 0x15376
movl 0x1c(%r12), %esi
testl %esi, %esi
je 0x15351
movq %r15, %rdi
callq 0x78fe
movq %r15, %rdi
movq %rax, %rsi
movq %r14, %rdx
callq 0x152b2
testb %al, %al
jne 0x15376
movl 0x18(%r12), %esi
testl %esi, %esi
je 0x15374
movq %r15, %rdi
callq 0x78fe
movq %r15, %rdi
movq %rax, %rsi
movq %r14, %rdx
callq 0x152b2
testb %al, %al
jne 0x15376
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::execution_is_noop(spirv_cross::SPIRBlock const&, spirv_cross::SPIRBlock const&) const
bool Compiler::execution_is_noop(const SPIRBlock &from, const SPIRBlock &to) const
{
	if (!execution_is_branchless(from, to))
		return false;

	auto *start = &from;
	for (;;)
	{
		if (start->self == to.self)
			return true;

		if (!start->ops.empty())
			return false;

		auto &next = get<SPIRBlock>(start->next_block);
		// Flushing phi variables does not count as noop.
		for (auto &phi : next.phi_variables)
			if (phi.parent == start->self)
				return false;

		start = &next;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
callq 0x15400
testb %al, %al
je 0x153f8
movl 0x8(%r15), %eax
cmpl 0x8(%rbx), %eax
sete %al
je 0x153fa
movq 0x38(%r15), %rax
cmpq 0x40(%r15), %rax
jne 0x153f8
movl 0x18(%r15), %esi
movq %r14, %rdi
callq 0x7932
movq 0x50(%rax), %rsi
movq 0x58(%rax), %rdx
cmpq %rdx, %rsi
sete %cl
je 0x153f1
movl 0x8(%r15), %edi
cmpl %edi, 0x4(%rsi)
je 0x153ee
addq $0xc, %rsi
cmpq %rdx, %rsi
sete %cl
je 0x153f1
leaq 0xc(%rsi), %r8
cmpl %edi, 0x4(%rsi)
movq %r8, %rsi
jne 0x153da
movq %r15, %rax
movq %rax, %r15
testb %cl, %cl
jne 0x1539b
xorl %eax, %eax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::execution_is_branchless(spirv_cross::SPIRBlock const&, spirv_cross::SPIRBlock const&) const
bool Compiler::execution_is_branchless(const SPIRBlock &from, const SPIRBlock &to) const
{
	auto *start = &from;
	for (;;)
	{
		if (start->self == to.self)
			return true;

		if (start->terminator == SPIRBlock::Direct && start->merge == SPIRBlock::MergeNone)
			start = &get<SPIRBlock>(start->next_block);
		else
			return false;
	}
}

// Assembly:
movl 0x8(%rsi), %eax
cmpl 0x8(%rdx), %eax
sete %al
je 0x15447
cmpl $0x1, 0xc(%rsi)
jne 0x15447
pushq %r14
pushq %rbx
pushq %rax
movq %rdx, %rbx
movq %rdi, %r14
cmpl $0x0, 0x10(%rsi)
jne 0x15440
movl 0x18(%rsi), %esi
movq %r14, %rdi
callq 0x7932
movq %rax, %rsi
movl 0x8(%rax), %eax
cmpl 0x8(%rbx), %eax
sete %al
je 0x15440
cmpl $0x1, 0xc(%rsi)
je 0x1541b
addq $0x8, %rsp
popq %rbx
popq %r14
andb $0x1, %al
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::continue_block_type(spirv_cross::SPIRBlock const&) const
SPIRBlock::ContinueBlockType Compiler::continue_block_type(const SPIRBlock &block) const
{
	// The block was deemed too complex during code emit, pick conservative fallback paths.
	if (block.complex_continue)
		return SPIRBlock::ComplexLoop;

	// In older glslang output continue block can be equal to the loop header.
	// In this case, execution is clearly branchless, so just assume a while loop header here.
	if (block.merge == SPIRBlock::MergeLoop)
		return SPIRBlock::WhileLoop;

	auto &dominator = get<SPIRBlock>(block.loop_dominator);

	if (execution_is_noop(block, dominator))
		return SPIRBlock::WhileLoop;
	else if (execution_is_branchless(block, dominator))
		return SPIRBlock::ForLoop;
	else
	{
		if (block.merge == SPIRBlock::MergeNone && block.terminator == SPIRBlock::Select &&
		    block.true_block == dominator.self && block.false_block == dominator.merge_block)
		{
			return SPIRBlock::DoWhileLoop;
		}
		else
			return SPIRBlock::ComplexLoop;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl $0x4, %ebp
cmpb $0x0, 0xb1(%rsi)
jne 0x154cf
movq %rsi, %rbx
movl $0x2, %ebp
cmpl $0x1, 0x10(%rsi)
je 0x154cf
movq %rdi, %r15
movl 0xb4(%rbx), %esi
callq 0x7932
movq %rax, %r14
movq %r15, %rdi
movq %rbx, %rsi
movq %rax, %rdx
callq 0x15384
testb %al, %al
jne 0x154cf
movq %r15, %rdi
movq %rbx, %rsi
movq %r14, %rdx
callq 0x15400
movl $0x1, %ebp
testb %al, %al
jne 0x154cf
cmpl $0x0, 0x10(%rbx)
jne 0x154ca
cmpl $0x2, 0xc(%rbx)
jne 0x154ca
movl 0x2c(%rbx), %eax
cmpl 0x8(%r14), %eax
jne 0x154ca
movl 0x30(%rbx), %eax
movl $0x3, %ebp
cmpl 0x1c(%r14), %eax
je 0x154cf
movl $0x4, %ebp
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::traverse_all_reachable_opcodes(spirv_cross::SPIRBlock const&, spirv_cross::Compiler::OpcodeHandler&) const
bool Compiler::traverse_all_reachable_opcodes(const SPIRBlock &block, OpcodeHandler &handler) const
{
	handler.set_current_block(block);

	// Ideally, perhaps traverse the CFG instead of all blocks in order to eliminate dead blocks,
	// but this shouldn't be a problem in practice unless the SPIR-V is doing insane things like recursing
	// inside dead blocks ...
	for (auto &i : block.ops)
	{
		auto ops = stream(i);
		auto op = static_cast<Op>(i.op);

		if (!handler.handle(op, ops, i.length))
			return false;

		if (op == OpFunctionCall)
		{
			auto &func = get<SPIRFunction>(ops[2]);
			if (handler.follow_function_call(func))
			{
				if (!handler.begin_function_scope(ops, i.length))
					return false;
				if (!traverse_all_reachable_opcodes(get<SPIRFunction>(ops[2]), handler))
					return false;
				if (!handler.end_function_scope(ops, i.length))
					return false;
			}
		}
	}

	return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %rbx
movq %rdi, %r15
movq (%rdx), %rax
movq %rdx, %rdi
callq *0x20(%rax)
movq 0x38(%rbx), %r12
movq 0x40(%rbx), %rax
movq %rax, (%rsp)
cmpq %rax, %r12
sete %bl
je 0x155ea
movq %r15, %rdi
movq %r12, %rsi
callq 0x1b906
movq %rax, %r13
movzwl (%r12), %ebp
movzwl %bp, %esi
movl 0x8(%r12), %ecx
movq (%r14), %rax
movq %r14, %rdi
movq %r13, %rdx
callq *0x10(%rax)
testb %al, %al
je 0x155ea
addq $0xc, %r12
cmpw $0x39, %bp
jne 0x155ae
movl 0x8(%r13), %esi
movq %r15, %rdi
callq 0x1bc94
movq (%r14), %rcx
movq %r14, %rdi
movq %rax, %rsi
callq *0x18(%rcx)
testb %al, %al
je 0x155ae
movl -0x4(%r12), %edx
movq (%r14), %rax
movq %r14, %rdi
movq %r13, %rsi
callq *0x28(%rax)
testb %al, %al
je 0x155ea
movl 0x8(%r13), %esi
movq %r15, %rdi
callq 0x1bc94
movq %r15, %rdi
movq %rax, %rsi
movq %r14, %rdx
callq 0x13ece
testb %al, %al
je 0x155ea
movl -0x4(%r12), %edx
movq (%r14), %rax
movq %r14, %rdi
movq %r13, %rsi
callq *0x30(%rax)
testb %al, %al
je 0x155ea
cmpq (%rsp), %r12
sete %bl
je 0x155ea
movq %r15, %rdi
movq %r12, %rsi
callq 0x1b906
movq %rax, %r13
movzwl (%r12), %ebp
movzwl %bp, %esi
movl 0x8(%r12), %ecx
movq (%r14), %rax
movq %r14, %rdi
movq %r13, %rdx
callq *0x10(%rax)
addq $0xc, %r12
testb %al, %al
jne 0x15544
andb $0x1, %bl
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::type_struct_member_offset(spirv_cross::SPIRType const&, unsigned int) const
uint32_t Compiler::type_struct_member_offset(const SPIRType &type, uint32_t index) const
{
	// Decoration must be set in valid SPIR-V, otherwise throw.
	auto &dec = ir.meta[type.self].members.at(index);
	if (dec.decoration_flags.get(DecorationOffset))
		return dec.offset;
	else
		SPIRV_CROSS_THROW("Struct member does not have Offset set.");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movl 0x8(%rsi), %eax
movq 0x38(%rdi), %rcx
imulq $0x148, %rax, %rdi      # imm = 0x148
movl %edx, %esi
movq 0xd0(%rcx,%rdi), %rax
movq 0xd8(%rcx,%rdi), %rcx
subq %rax, %rcx
sarq $0x4, %rcx
movabsq $0x4ec4ec4ec4ec4ec5, %rdx # imm = 0x4EC4EC4EC4EC4EC5
imulq %rcx, %rdx
cmpq %rsi, %rdx
jbe 0x15664
imulq $0xd0, %rsi, %rcx
testb $0x8, 0x64(%rax,%rcx)
je 0x15672
addq %rcx, %rax
movl 0xb4(%rax), %eax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
leaq 0x9faae(%rip), %rdi     # 0xb5119
xorl %eax, %eax
callq 0x63d0
movl $0x10, %edi
callq 0x6140
movq %rax, %rbx
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0xa0732(%rip), %rsi     # 0xb5dc1
leaq 0xa0752(%rip), %rdx     # 0xb5de8
leaq 0x8(%rsp), %rdi
callq 0x7c64
movb $0x1, %bpl
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x6320
leaq 0xe76e1(%rip), %rax     # 0xfcd98
addq $0x10, %rax
movq %rax, (%rbx)
xorl %ebp, %ebp
leaq 0xe76b9(%rip), %rsi     # 0xfcd80
movq 0xe890a(%rip), %rdx     # 0xfdfd8
movq %rbx, %rdi
callq 0x6470
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x156f8
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x6260
jmp 0x156f8
movq %rax, %r14
movb $0x1, %bpl
testb %bpl, %bpl
je 0x15705
movq %rbx, %rdi
callq 0x6200
movq %r14, %rdi
callq 0x64a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::type_struct_member_array_stride(spirv_cross::SPIRType const&, unsigned int) const
uint32_t Compiler::type_struct_member_array_stride(const SPIRType &type, uint32_t index) const
{
	// Decoration must be set in valid SPIR-V, otherwise throw.
	// ArrayStride is part of the array type not OpMemberDecorate.
	auto &dec = ir.meta[type.member_types[index]].decoration;
	if (dec.decoration_flags.get(DecorationArrayStride))
		return dec.array_stride;
	else
		SPIRV_CROSS_THROW("Struct member does not have ArrayStride set.");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movl %edx, %eax
movq 0x68(%rsi), %rcx
movl (%rcx,%rax,4), %ecx
movq 0x38(%rdi), %rax
imulq $0x148, %rcx, %rcx      # imm = 0x148
testb $0x40, 0x60(%rax,%rcx)
je 0x15747
addq %rcx, %rax
movl 0xb8(%rax), %eax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x6140
movq %rax, %rbx
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0xa0685(%rip), %rsi     # 0xb5de9
leaq 0xa06aa(%rip), %rdx     # 0xb5e15
leaq 0x8(%rsp), %rdi
callq 0x7c64
movb $0x1, %bpl
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x6320
leaq 0xe760c(%rip), %rax     # 0xfcd98
addq $0x10, %rax
movq %rax, (%rbx)
xorl %ebp, %ebp
leaq 0xe75e4(%rip), %rsi     # 0xfcd80
movq 0xe8835(%rip), %rdx     # 0xfdfd8
movq %rbx, %rdi
callq 0x6470
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x157cd
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x6260
jmp 0x157cd
movq %rax, %r14
movb $0x1, %bpl
testb %bpl, %bpl
je 0x157da
movq %rbx, %rdi
callq 0x6200
movq %r14, %rdi
callq 0x64a0
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::type_struct_member_matrix_stride(spirv_cross::SPIRType const&, unsigned int) const
uint32_t Compiler::type_struct_member_matrix_stride(const SPIRType &type, uint32_t index) const
{
	// Decoration must be set in valid SPIR-V, otherwise throw.
	// MatrixStride is part of OpMemberDecorate.
	auto &dec = ir.meta[type.self].members[index];
	if (dec.decoration_flags.get(DecorationMatrixStride))
		return dec.matrix_stride;
	else
		SPIRV_CROSS_THROW("Struct member does not have MatrixStride set.");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movl 0x8(%rsi), %eax
movq 0x38(%rdi), %rcx
imulq $0x148, %rax, %rax      # imm = 0x148
movl %edx, %edx
movq 0xd0(%rcx,%rax), %rax
imulq $0xd0, %rdx, %rcx
testb $-0x80, 0x60(%rax,%rcx)
je 0x15826
addq %rcx, %rax
movl 0xbc(%rax), %eax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x6140
movq %rax, %rbx
leaq 0x18(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0xa05d3(%rip), %rsi     # 0xb5e16
leaq 0xa05f9(%rip), %rdx     # 0xb5e43
leaq 0x8(%rsp), %rdi
callq 0x7c64
movb $0x1, %bpl
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x6320
leaq 0xe752d(%rip), %rax     # 0xfcd98
addq $0x10, %rax
movq %rax, (%rbx)
xorl %ebp, %ebp
leaq 0xe7505(%rip), %rsi     # 0xfcd80
movq 0xe8756(%rip), %rdx     # 0xfdfd8
movq %rbx, %rdi
callq 0x6470
movq %rax, %r14
movq 0x8(%rsp), %rdi
cmpq %r15, %rdi
je 0x158ac
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x6260
jmp 0x158ac
movq %rax, %r14
movb $0x1, %bpl
testb %bpl, %bpl
je 0x158b9
movq %rbx, %rdi
callq 0x6200
movq %r14, %rdi
callq 0x64a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_active_buffer_ranges(unsigned int) const
std::vector<BufferRange> Compiler::get_active_buffer_ranges(uint32_t id) const
{
	std::vector<BufferRange> ranges;
	BufferAccessHandler handler(*this, ranges, id);
	traverse_all_reachable_opcodes(get<SPIRFunction>(ir.default_entry_point), handler);
	return ranges;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rsi, %r15
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
leaq 0xe7190(%rip), %r12     # 0xfd0a8
addq $0x10, %r12
leaq 0x20(%rsp), %r14
movq %r12, -0x20(%r14)
movq %rsi, -0x18(%r14)
movq %rdi, -0x10(%r14)
movl %edx, -0x8(%r14)
leaq 0x50(%rsp), %rax
movq %rax, -0x30(%rax)
movq $0x1, -0x28(%rax)
movups %xmm0, -0x20(%rax)
movl $0x3f800000, -0x10(%rax) # imm = 0x3F800000
movups %xmm0, -0x8(%rax)
movl 0x108(%rsi), %esi
movq %r15, %rdi
callq 0x1bc94
movq %rsp, %rdx
movq %r15, %rdi
movq %rax, %rsi
callq 0x13ece
movq %r12, (%rsp)
movq %r14, %rdi
callq 0xd5b0
movq %rbx, %rax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %r15
movq %r12, (%rsp)
movq %r14, %rdi
callq 0xd5b0
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x15fab
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x6260
movq %r15, %rdi
callq 0x64a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::types_are_logically_equivalent(spirv_cross::SPIRType const&, spirv_cross::SPIRType const&) const
bool Compiler::types_are_logically_equivalent(const SPIRType &a, const SPIRType &b) const
{
	if (a.basetype != b.basetype)
		return false;
	if (a.width != b.width)
		return false;
	if (a.vecsize != b.vecsize)
		return false;
	if (a.columns != b.columns)
		return false;
	if (a.array.size() != b.array.size())
		return false;

	size_t array_count = a.array.size();
	if (array_count && memcmp(a.array.data(), b.array.data(), array_count * sizeof(uint32_t)) != 0)
		return false;

	if (a.basetype == SPIRType::Image || a.basetype == SPIRType::SampledImage)
	{
		if (memcmp(&a.image, &b.image, sizeof(SPIRType::Image)) != 0)
			return false;
	}

	if (a.member_types.size() != b.member_types.size())
		return false;

	size_t member_types = a.member_types.size();
	for (size_t i = 0; i < member_types; i++)
	{
		if (!types_are_logically_equivalent(get<SPIRType>(a.member_types[i]), get<SPIRType>(b.member_types[i])))
			return false;
	}

	return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl 0xc(%rsi), %ebp
cmpl 0xc(%rdx), %ebp
jne 0x160c4
movq %rdx, %rbx
movq %rsi, %r14
movl 0x10(%rsi), %eax
cmpl 0x10(%rdx), %eax
jne 0x160c4
movl 0x14(%r14), %eax
cmpl 0x14(%rbx), %eax
jne 0x160c4
movl 0x18(%r14), %eax
cmpl 0x18(%rbx), %eax
jne 0x160c4
movq %rdi, %r15
movq 0x20(%r14), %rdi
movq 0x28(%r14), %rax
movq %rax, %rdx
subq %rdi, %rdx
movq 0x20(%rbx), %rsi
movq 0x28(%rbx), %rcx
subq %rsi, %rcx
cmpq %rcx, %rdx
jne 0x160c4
cmpq %rdi, %rax
je 0x1602e
callq 0x6280
testl %eax, %eax
jne 0x160c4
addl $-0xd, %ebp
cmpl $0x1, %ebp
ja 0x16045
movl 0x80(%r14), %eax
cmpl 0x80(%rbx), %eax
jne 0x160c4
movq 0x68(%r14), %rax
movq 0x70(%r14), %rcx
movq %rcx, %rsi
subq %rax, %rsi
movq 0x70(%rbx), %rdx
subq 0x68(%rbx), %rdx
cmpq %rdx, %rsi
jne 0x160c4
cmpq %rax, %rcx
sete %al
je 0x160c6
sarq $0x2, %rsi
cmpq $0x1, %rsi
movq %rsi, (%rsp)
movq %rsi, %rbp
adcq $0x0, %rbp
xorl %r13d, %r13d
movq 0x68(%r14), %rax
movl (%rax,%r13,4), %esi
movq %r15, %rdi
callq 0x1b9de
movq %rax, %r12
movq 0x68(%rbx), %rax
movl (%rax,%r13,4), %esi
movq %r15, %rdi
callq 0x1b9de
movq %r15, %rdi
movq %r12, %rsi
movq %rax, %rdx
callq 0x15fb4
testb %al, %al
je 0x160c4
incq %r13
cmpq %r13, %rbp
jne 0x1607e
cmpq (%rsp), %r13
setae %al
jmp 0x160c6
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::set_execution_mode(spv::ExecutionMode, unsigned int, unsigned int, unsigned int)
void Compiler::set_execution_mode(ExecutionMode mode, uint32_t arg0, uint32_t arg1, uint32_t arg2)
{
	auto &execution = get_entry_point();

	execution.flags.set(mode);
	switch (mode)
	{
	case ExecutionModeLocalSize:
		execution.workgroup_size.x = arg0;
		execution.workgroup_size.y = arg1;
		execution.workgroup_size.z = arg2;
		break;

	case ExecutionModeInvocations:
		execution.invocations = arg0;
		break;

	case ExecutionModeOutputVertices:
		execution.output_vertices = arg0;
		break;

	default:
		break;
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movl %r8d, %ebx
movl %ecx, %r14d
movl %edx, %ebp
movl %esi, %r15d
leaq 0xd0(%rdi), %rcx
leaq 0x108(%rdi), %r8
movl 0x108(%rdi), %r9d
movq %r9, %rax
xorl %edx, %edx
divq 0xd8(%rdi)
movq %rcx, %rdi
movq %rdx, %rsi
movq %r8, %rdx
movq %r9, %rcx
callq 0x22394
movq (%rax), %r12
movl %r15d, 0x4(%rsp)
cmpl $0x3f, %r15d
ja 0x161f3
movl $0x1, %eax
movl %r15d, %ecx
shlq %cl, %rax
orq %rax, 0x70(%r12)
jmp 0x1620a
leaq 0x78(%r12), %rdi
leaq 0x8(%rsp), %rdx
movq %rdi, (%rdx)
leaq 0x4(%rsp), %rsi
callq 0x1fc02
testl %r15d, %r15d
je 0x1623f
cmpl $0x1a, %r15d
je 0x16235
cmpl $0x11, %r15d
jne 0x16247
movl %ebp, 0xb0(%r12)
movl %r14d, 0xb4(%r12)
movl %ebx, 0xb8(%r12)
jmp 0x16247
movl %ebp, 0xc4(%r12)
jmp 0x16247
movl %ebp, 0xc0(%r12)
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_work_group_size_specialization_constants(spirv_cross::SpecializationConstant&, spirv_cross::SpecializationConstant&, spirv_cross::SpecializationConstant&) const
uint32_t Compiler::get_work_group_size_specialization_constants(SpecializationConstant &x, SpecializationConstant &y,
                                                                SpecializationConstant &z) const
{
	auto &execution = get_entry_point();
	x = { 0, 0 };
	y = { 0, 0 };
	z = { 0, 0 };

	if (execution.workgroup_size.constant != 0)
	{
		auto &c = get<SPIRConstant>(execution.workgroup_size.constant);

		if (c.m.c[0].id[0] != 0)
		{
			x.id = c.m.c[0].id[0];
			x.constant_id = get_decoration(c.m.c[0].id[0], DecorationSpecId);
		}

		if (c.m.c[0].id[1] != 0)
		{
			y.id = c.m.c[0].id[1];
			y.constant_id = get_decoration(c.m.c[0].id[1], DecorationSpecId);
		}

		if (c.m.c[0].id[2] != 0)
		{
			z.id = c.m.c[0].id[2];
			z.constant_id = get_decoration(c.m.c[0].id[2], DecorationSpecId);
		}
	}

	return execution.workgroup_size.constant;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r14
addq $0xd0, %rdi
leaq 0x108(%r14), %rcx
movl 0x108(%r14), %r8d
xorl %r13d, %r13d
movq %r8, %rax
xorl %edx, %edx
divq 0xd8(%r14)
movq %rdx, %rsi
movq %rcx, %rdx
movq %r8, %rcx
callq 0x22394
movq (%rax), %rbp
movq %r13, (%r12)
movq %r13, (%r15)
movq %r13, (%rbx)
movl 0xbc(%rbp), %esi
testl %esi, %esi
je 0x163cc
movq %r14, %rdi
callq 0x1bb22
movq %rax, %r13
movl 0x30(%rax), %eax
testl %eax, %eax
je 0x16389
movl %eax, (%r12)
movl 0x30(%r13), %esi
leaq 0x8(%r14), %rdi
movl $0x1, %edx
callq 0x25016
movl %eax, 0x4(%r12)
movl 0x34(%r13), %eax
testl %eax, %eax
je 0x163aa
movl %eax, (%r15)
movl 0x34(%r13), %esi
leaq 0x8(%r14), %rdi
movl $0x1, %edx
callq 0x25016
movl %eax, 0x4(%r15)
movl 0x38(%r13), %eax
testl %eax, %eax
je 0x163cc
movl %eax, (%rbx)
movl 0x38(%r13), %esi
addq $0x8, %r14
movq %r14, %rdi
movl $0x1, %edx
callq 0x25016
movl %eax, 0x4(%rbx)
movl 0xbc(%rbp), %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_execution_mode_argument(spv::ExecutionMode, unsigned int) const
uint32_t Compiler::get_execution_mode_argument(spv::ExecutionMode mode, uint32_t index) const
{
	auto &execution = get_entry_point();
	switch (mode)
	{
	case ExecutionModeLocalSize:
		switch (index)
		{
		case 0:
			return execution.workgroup_size.x;
		case 1:
			return execution.workgroup_size.y;
		case 2:
			return execution.workgroup_size.z;
		default:
			return 0;
		}

	case ExecutionModeInvocations:
		return execution.invocations;

	case ExecutionModeOutputVertices:
		return execution.output_vertices;

	default:
		return 0;
	}
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movl %esi, %r14d
leaq 0xd0(%rdi), %rcx
leaq 0x108(%rdi), %r8
movl 0x108(%rdi), %r9d
xorl %ebx, %ebx
movq %r9, %rax
xorl %edx, %edx
divq 0xd8(%rdi)
movq %rcx, %rdi
movq %rdx, %rsi
movq %r8, %rdx
movq %r9, %rcx
callq 0x22394
movq (%rax), %rax
testl %r14d, %r14d
je 0x16451
cmpl $0x1a, %r14d
je 0x16449
cmpl $0x11, %r14d
jne 0x16457
cmpl $0x2, %ebp
je 0x16466
cmpl $0x1, %ebp
je 0x1645e
testl %ebp, %ebp
jne 0x16457
movl 0xb0(%rax), %ebx
jmp 0x16457
movl 0xc4(%rax), %ebx
jmp 0x16457
movl 0xc0(%rax), %ebx
movl %ebx, %eax
popq %rbx
popq %r14
popq %rbp
retq
movl 0xb4(%rax), %ebx
jmp 0x16457
movl 0xb8(%rax), %ebx
jmp 0x16457
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_entry_points[abi:cxx11]() const
vector<string> Compiler::get_entry_points() const
{
	vector<string> entries;
	for (auto &entry : ir.entry_points)
		entries.push_back(entry.second.orig_name);
	return entries;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
addq $0xe0, %r14
movq (%r14), %r14
testq %r14, %r14
je 0x16723
leaq 0x38(%r14), %rsi
movq %rbx, %rdi
callq 0x1c0c0
jmp 0x1670d
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0xda64
movq %r14, %rdi
callq 0x64a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_entry_points_and_stages() const
vector<EntryPoint> Compiler::get_entry_points_and_stages() const
{
	vector<EntryPoint> entries;
	for (auto &entry : ir.entry_points)
		entries.push_back({ entry.second.orig_name, entry.second.model });
	return entries;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq 0xe0(%rsi), %r12
testq %r12, %r12
je 0x167c1
leaq 0x10(%rsp), %r15
movq %rsp, %r14
movq %r15, (%rsp)
movq 0x38(%r12), %rsi
movq 0x40(%r12), %rdx
addq %rsi, %rdx
movq %r14, %rdi
callq 0xe480
movl 0xc8(%r12), %eax
movl %eax, 0x20(%rsp)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x220de
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x167b8
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6260
movq (%r12), %r12
testq %r12, %r12
jne 0x16772
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %r14
jmp 0x167ee
movq %rax, %r14
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x167ee
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6260
movq %rbx, %rdi
callq 0x1c0fe
movq %r14, %rdi
callq 0x64a0
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_entry_point(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, spv::ExecutionModel)
SPIREntryPoint &Compiler::get_entry_point(const std::string &name, ExecutionModel model)
{
	auto itr = find_if(begin(ir.entry_points), end(ir.entry_points),
	                   [&](const std::pair<uint32_t, SPIREntryPoint> &entry) -> bool {
		                   return entry.second.orig_name == name && entry.second.model == model;
	                   });

	if (itr == end(ir.entry_points))
		SPIRV_CROSS_THROW("Entry point does not exist.");

	return itr->second;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xd8, %rsp
movl %edx, 0xc(%rsp)
movq 0xe0(%rdi), %rbx
testq %rbx, %rbx
je 0x16acc
movq %rsi, %r14
leaq 0x80(%rsp), %r12
leaq 0x50(%rsp), %r13
leaq 0x30(%rsp), %rbp
movl 0x8(%rbx), %eax
movl %eax, 0x10(%rsp)
leaq 0x10(%rbx), %rsi
leaq 0x18(%rsp), %rdi
callq 0x1ee0a
movq 0x48(%rsp), %rdx
cmpq 0x8(%r14), %rdx
jne 0x16a5a
testq %rdx, %rdx
je 0x16a5f
movq (%r14), %rsi
movq 0x40(%rsp), %rdi
callq 0x6280
testl %eax, %eax
je 0x16a5f
xorl %r15d, %r15d
jmp 0x16a6e
movl 0xc(%rsp), %eax
cmpl %eax, 0xd0(%rsp)
sete %r15b
movq %r12, %rdi
callq 0xd5b0
movq 0x60(%rsp), %rdi
testq %rdi, %rdi
je 0x16a8d
movq 0x70(%rsp), %rsi
subq %rdi, %rsi
callq 0x6260
movq 0x40(%rsp), %rdi
cmpq %r13, %rdi
je 0x16aa4
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x6260
movq 0x20(%rsp), %rdi
cmpq %rbp, %rdi
je 0x16abb
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6260
testb %r15b, %r15b
jne 0x16acc
movq (%rbx), %rbx
testq %rbx, %rbx
jne 0x16a24
testq %rbx, %rbx
je 0x16aea
addq $0x10, %rbx
movq %rbx, %rax
addq $0xd8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x6140
movq %rax, %rbx
leaq 0x20(%rsp), %r15
movq %r15, -0x10(%r15)
leaq 0x9f3d2(%rip), %rsi     # 0xb5ed9
leaq 0x9f3e6(%rip), %rdx     # 0xb5ef4
leaq 0x10(%rsp), %rdi
callq 0x7c64
movb $0x1, %bpl
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x6320
leaq 0xe6269(%rip), %rax     # 0xfcd98
addq $0x10, %rax
movq %rax, (%rbx)
xorl %ebp, %ebp
leaq 0xe6241(%rip), %rsi     # 0xfcd80
movq 0xe7492(%rip), %rdx     # 0xfdfd8
movq %rbx, %rdi
callq 0x6470
movq %rax, %r14
movq 0x10(%rsp), %rdi
cmpq %r15, %rdi
je 0x16b70
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x6260
jmp 0x16b70
movq %rax, %r14
movb $0x1, %bpl
testb %bpl, %bpl
je 0x16b7d
movq %rbx, %rdi
callq 0x6200
movq %r14, %rdi
callq 0x64a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::CombinedImageSamplerHandler::push_remap_parameters(spirv_cross::SPIRFunction const&, unsigned int const*, unsigned int)
void Compiler::CombinedImageSamplerHandler::push_remap_parameters(const SPIRFunction &func, const uint32_t *args,
                                                                  uint32_t length)
{
	// If possible, pipe through a remapping table so that parameters know
	// which variables they actually bind to in this scope.
	unordered_map<uint32_t, uint32_t> remapping;
	for (uint32_t i = 0; i < length; i++)
		remapping[func.arguments[i].id] = remap_parameter(args[i]);
	parameter_remapping.push(move(remapping));
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rdx, 0x8(%rsp)
movq %rdi, %rbx
leaq 0x40(%rsp), %rax
movq %rax, -0x30(%rax)
movq $0x1, -0x28(%rax)
xorps %xmm0, %xmm0
movups %xmm0, -0x20(%rax)
movl $0x3f800000, -0x10(%rax) # imm = 0x3F800000
movups %xmm0, -0x8(%rax)
testl %ecx, %ecx
je 0x16f72
movq %rsi, %r15
movl %ecx, %r13d
movl $0x4, %r12d
xorl %r14d, %r14d
movq 0x8(%rsp), %rax
movl (%rax,%r14,4), %esi
movq %rbx, %rdi
callq 0x16fb4
movl %eax, %ebp
movq 0x18(%r15), %rsi
addq %r12, %rsi
leaq 0x10(%rsp), %rdi
callq 0x22474
movl %ebp, (%rax)
incq %r14
addq $0x14, %r12
cmpq %r14, %r13
jne 0x16f40
addq $0x10, %rbx
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
callq 0x226f4
leaq 0x10(%rsp), %rdi
callq 0xdd10
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x16f9e
movq %rax, %rbx
leaq 0x10(%rsp), %rdi
callq 0xdd10
movq %rbx, %rdi
callq 0x64a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::CombinedImageSamplerHandler::remap_parameter(unsigned int)
uint32_t Compiler::CombinedImageSamplerHandler::remap_parameter(uint32_t id)
{
	auto *var = compiler.maybe_get_backing_variable(id);
	if (var)
		id = var->self;

	if (parameter_remapping.empty())
		return id;

	auto &remapping = parameter_remapping.top();
	auto itr = remapping.find(id);
	if (itr != end(remapping))
		return itr->second;
	else
		return id;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
movq 0x8(%rdi), %rdi
callq 0x12cda
testq %rax, %rax
je 0x16fce
movl 0x8(%rax), %ebx
movq 0x40(%r14), %rcx
cmpq 0x20(%r14), %rcx
je 0x17057
cmpq 0x48(%r14), %rcx
jne 0x16feb
movq 0x58(%r14), %rax
movl $0x1f8, %ecx            # imm = 0x1F8
addq -0x8(%rax), %rcx
movl %ebx, %eax
movq -0x38(%rcx), %rsi
movq -0x30(%rcx), %rdi
xorl %r9d, %r9d
xorl %edx, %edx
divq %rdi
movq (%rsi,%rdx,8), %rax
testq %rax, %rax
je 0x17043
movq (%rax), %r8
movq %rax, %r9
cmpl 0x8(%r8), %ebx
je 0x17043
movq %rdx, %rcx
movq %r8, %r10
movq (%r8), %r8
testq %r8, %r8
je 0x17040
movl 0x8(%r8), %esi
movq %rsi, %rax
xorl %edx, %edx
divq %rdi
movl $0x0, %r9d
cmpq %rcx, %rdx
jne 0x17043
movq %r10, %r9
cmpl %esi, %ebx
jne 0x17015
jmp 0x17043
xorl %r9d, %r9d
testq %r9, %r9
je 0x1704d
movq (%r9), %rax
jmp 0x1704f
xorl %eax, %eax
testq %rax, %rax
je 0x17057
movl 0xc(%rax), %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::CombinedImageSamplerHandler::begin_function_scope(unsigned int const*, unsigned int)
bool Compiler::CombinedImageSamplerHandler::begin_function_scope(const uint32_t *args, uint32_t length)
{
	if (length < 3)
		return false;

	auto &callee = compiler.get<SPIRFunction>(args[2]);
	args += 3;
	length -= 3;
	push_remap_parameters(callee, args, length);
	functions.push(&callee);
	return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %ebx
cmpl $0x3, %edx
jb 0x170dc
movq %rsi, %r12
movq %rdi, %r14
movq 0x8(%rdi), %rdi
movl 0x8(%rsi), %esi
callq 0xb9ca
movq %rax, %r15
addq $0xc, %r12
leal -0x3(%rbx), %ecx
movq %r14, %rdi
movq %rax, %rsi
movq %r12, %rdx
callq 0x16ef4
movq %r15, (%rsp)
movq 0x90(%r14), %rax
movq 0xa0(%r14), %rcx
addq $-0x8, %rcx
cmpq %rcx, %rax
je 0x170cd
movq %r15, (%rax)
addq $0x8, 0x90(%r14)
jmp 0x170dc
addq $0x60, %r14
movq %rsp, %rsi
movq %r14, %rdi
callq 0x22a26
cmpl $0x3, %ebx
setae %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::build_combined_image_samplers()
void Compiler::build_combined_image_samplers()
{
	for (auto &id : ir.ids)
	{
		if (id.get_type() == TypeFunction)
		{
			auto &func = id.get<SPIRFunction>();
			func.combined_parameters.clear();
			func.shadow_arguments.clear();
			func.do_combined_parameters = true;
		}
	}

	combined_image_samplers.clear();
	CombinedImageSamplerHandler handler(*this);
	traverse_all_reachable_opcodes(get<SPIRFunction>(ir.default_entry_point), handler);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0xb0, %rsp
movq %rdi, %rbx
movq 0x20(%rdi), %r14
movq 0x28(%rdi), %r15
cmpq %r15, %r14
je 0x185e1
cmpl $0x4, 0x8(%r14)
jne 0x185db
movq %r14, %rdi
callq 0x10298
movq 0x80(%rax), %rcx
cmpq %rcx, 0x88(%rax)
je 0x185c6
movq %rcx, 0x88(%rax)
movq 0x30(%rax), %rcx
cmpq %rcx, 0x38(%rax)
je 0x185d4
movq %rcx, 0x38(%rax)
movb $0x1, 0xca(%rax)
addq $0x10, %r14
jmp 0x1859b
movq 0x1d8(%rbx), %rax
cmpq %rax, 0x1e0(%rbx)
je 0x185f8
movq %rax, 0x1e0(%rbx)
movq %rsp, %rdi
movq %rbx, %rsi
callq 0x1c494
movl 0x108(%rbx), %esi
movq %rbx, %rdi
callq 0xb9ca
movq %rsp, %rdx
movq %rbx, %rdi
movq %rax, %rsi
callq 0x13ece
leaq 0xe4b42(%rip), %rax     # 0xfd168
addq $0x10, %rax
leaq 0x60(%rsp), %rdi
movq %rax, -0x60(%rdi)
callq 0x1fae4
leaq 0x10(%rsp), %rdi
callq 0x1f9aa
addq $0xb0, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
leaq 0xe4b0f(%rip), %rax     # 0xfd168
addq $0x10, %rax
leaq 0x60(%rsp), %rdi
movq %rax, -0x60(%rdi)
callq 0x1fae4
leaq 0x10(%rsp), %rdi
callq 0x1f9aa
movq %rbx, %rdi
callq 0x64a0
nop
// File: /workspace/github_cpp_makefile_star2_O1/rossy[P]crossc/SPIRV-Cross/spirv_cross.cpp
// Function: spirv_cross::Compiler::get_specialization_constants() const
vector<SpecializationConstant> Compiler::get_specialization_constants() const
{
	vector<SpecializationConstant> spec_consts;
	for (auto &id : ir.ids)
	{
		if (id.get_type() == TypeConstant)
		{
			auto &c = id.get<SPIRConstant>();
			if (c.specialization && has_decoration(c.self, DecorationSpecId))
				spec_consts.push_back({ c.self, get_decoration(c.self, DecorationSpecId) });
		}
	}
	return spec_consts;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq $0x0, 0x10(%rdi)
movq 0x20(%rsi), %r15
movq 0x28(%rsi), %rbp
cmpq %rbp, %r15
je 0x18725
movq %rsi, %r14
addq $0x8, %r14
movq %rsp, %r12
cmpl $0x3, 0x8(%r15)
jne 0x1871c
movq %r15, %rdi
callq 0x1c546
movq %rax, %r13
cmpb $0x1, 0x108(%rax)
jne 0x1871c
movl 0x8(%r13), %esi
movq %r14, %rdi
movl $0x1, %edx
callq 0x24fbc
testb %al, %al
je 0x1871c
movl 0x8(%r13), %esi
movl %esi, (%rsp)
movq %r14, %rdi
movl $0x1, %edx
callq 0x25016
movl %eax, 0x4(%rsp)
movq 0x8(%rbx), %rsi
cmpq 0x10(%rbx), %rsi
je 0x18711
movq (%rsp), %rax
movq %rax, (%rsi)
addq $0x8, 0x8(%rbx)
jmp 0x1871c
movq %rbx, %rdi
movq %r12, %rdx
callq 0x23656
addq $0x10, %r15
cmpq %rbp, %r15
jne 0x186b1
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x18739
movq %rax, %r14
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x18750
movq 0x10(%rbx), %rsi
subq %rdi, %rsi
callq 0x6260
movq %r14, %rdi
callq 0x64a0