// File: /workspace/github_cpp_makefile_star2_O1/MarkCBell[P]twister/./twister/kernel/parsing.cpp
// Function: format_command(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>> const&)
void format_command(std::string &command,
	const std::vector<std::string> &annulus_name,
	const std::vector<std::string> &annulus_name_inverse,
	const std::vector<std::string> &rectangle_name,
	const std::vector<std::string> &rectangle_name_inverse,
	const std::vector<std::string> &macro_name,
	const std::vector<std::string> &macro)
{
	// We now combine together all the curve names for formatting.
	std::set<std::string> valid_names;
	valid_names.insert(annulus_name.begin(), annulus_name.end());
	valid_names.insert(annulus_name_inverse.begin(), annulus_name_inverse.end());
	valid_names.insert(rectangle_name.begin(), rectangle_name.end());
	valid_names.insert(rectangle_name_inverse.begin(), rectangle_name_inverse.end());
	valid_names.insert(macro_name.begin(), macro_name.end());
	
	std::vector<std::string> names, inverse_names;
	names.insert(names.end(), annulus_name.begin(), annulus_name.end());
	names.insert(names.end(), annulus_name_inverse.begin(), annulus_name_inverse.end());
	names.insert(names.end(), rectangle_name.begin(), rectangle_name.end());
	names.insert(names.end(), rectangle_name_inverse.begin(), rectangle_name_inverse.end());
	inverse_names.insert(inverse_names.end(), annulus_name_inverse.begin(), annulus_name_inverse.end());
	inverse_names.insert(inverse_names.end(), annulus_name.begin(), annulus_name.end());
	inverse_names.insert(inverse_names.end(), rectangle_name_inverse.begin(), rectangle_name_inverse.end());
	inverse_names.insert(inverse_names.end(), rectangle_name.begin(), rectangle_name.end());
	
	nicen_command(command);
	tokenise_command(command, valid_names);
	replace_macros(command, macro_name, macro);
	expand_brackets(command, names, inverse_names);
	cleanup_command(command);
	
	return;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %r9, 0x58(%rsp)
movq %r8, 0x20(%rsp)
movq %rcx, 0x28(%rsp)
movq %rdx, %rbp
movq %rdi, 0x90(%rsp)
leaq 0x68(%rsp), %r14
movl $0x0, (%r14)
xorl %eax, %eax
movq %rax, 0x8(%r14)
movq %r14, 0x10(%r14)
movq %r14, 0x18(%r14)
movq %rax, 0x20(%r14)
movq (%rsi), %rbx
movq %rsi, 0x50(%rsp)
movq 0x8(%rsi), %r13
leaq 0x60(%rsp), %rax
movq %rax, (%rsp)
cmpq %r13, %rbx
je 0xd110
leaq 0x60(%rsp), %r15
movq %rsp, %r12
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movq %r12, %rcx
callq 0xd4ea
addq $0x20, %rbx
cmpq %r13, %rbx
jne 0xd0f6
movq (%rbp), %rbx
movq 0x8(%rbp), %r13
leaq 0x60(%rsp), %rax
movq %rax, (%rsp)
cmpq %r13, %rbx
je 0xd148
leaq 0x60(%rsp), %r15
movq %rsp, %r12
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movq %r12, %rcx
callq 0xd4ea
addq $0x20, %rbx
cmpq %r13, %rbx
jne 0xd12e
movq 0x28(%rsp), %rax
movq (%rax), %rbx
movq 0x8(%rax), %r13
leaq 0x60(%rsp), %rax
movq %rax, (%rsp)
cmpq %r13, %rbx
je 0xd184
leaq 0x60(%rsp), %r15
movq %rsp, %r12
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movq %r12, %rcx
callq 0xd4ea
addq $0x20, %rbx
cmpq %r13, %rbx
jne 0xd16a
movq 0x20(%rsp), %rax
movq (%rax), %rbx
movq 0x8(%rax), %r13
leaq 0x60(%rsp), %rax
movq %rax, (%rsp)
cmpq %r13, %rbx
je 0xd1c0
leaq 0x60(%rsp), %r15
movq %rsp, %r12
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movq %r12, %rcx
callq 0xd4ea
addq $0x20, %rbx
cmpq %r13, %rbx
jne 0xd1a6
movq 0x58(%rsp), %rax
movq (%rax), %rbx
movq 0x8(%rax), %r13
leaq 0x60(%rsp), %rax
movq %rax, (%rsp)
cmpq %r13, %rbx
je 0xd1fc
leaq 0x60(%rsp), %r15
movq %rsp, %r12
movq %r15, %rdi
movq %r14, %rsi
movq %rbx, %rdx
movq %r12, %rcx
callq 0xd4ea
addq $0x20, %rbx
cmpq %r13, %rbx
jne 0xd1e2
xorl %eax, %eax
movq %rsp, %rdi
movq %rax, 0x10(%rdi)
xorps %xmm0, %xmm0
movaps %xmm0, (%rdi)
movq %rax, 0x40(%rsp)
movaps %xmm0, 0x30(%rsp)
movq 0x8(%rdi), %rsi
movq 0x50(%rsp), %rax
movq (%rax), %rdx
movq 0x8(%rax), %rcx
callq 0xd79a
movq %rsp, %rdi
movq 0x8(%rdi), %rsi
movq (%rbp), %rdx
movq 0x8(%rbp), %rcx
callq 0xd79a
movq %rsp, %rdi
movq 0x8(%rdi), %rsi
movq 0x28(%rsp), %rax
movq (%rax), %rdx
movq 0x8(%rax), %rcx
callq 0xd79a
movq %rsp, %rdi
movq 0x8(%rdi), %rsi
movq 0x20(%rsp), %rax
movq (%rax), %rdx
movq 0x8(%rax), %rcx
callq 0xd79a
leaq 0x30(%rsp), %rdi
movq 0x8(%rdi), %rsi
movq (%rbp), %rdx
movq 0x8(%rbp), %rcx
callq 0xd79a
leaq 0x30(%rsp), %rdi
movq 0x8(%rdi), %rsi
movq 0x50(%rsp), %rax
movq (%rax), %rdx
movq 0x8(%rax), %rcx
callq 0xd79a
movq 0x90(%rsp), %rbx
leaq 0x30(%rsp), %rdi
movq 0x8(%rdi), %rsi
movq 0x20(%rsp), %rax
movq (%rax), %rdx
movq 0x8(%rax), %rcx
callq 0xd79a
leaq 0x30(%rsp), %rdi
movq 0x8(%rdi), %rsi
movq 0x28(%rsp), %rax
movq (%rax), %rdx
movq 0x8(%rax), %rcx
callq 0xd79a
movq %rbx, %rdi
callq 0xa765
leaq 0x60(%rsp), %rsi
movq %rbx, %rdi
callq 0xbb2e
movq 0xd0(%rsp), %rdx
movq %rbx, %rdi
movq 0x58(%rsp), %rsi
callq 0xc280
movq %rsp, %rsi
leaq 0x30(%rsp), %rdx
movq %rbx, %rdi
callq 0xc795
movq %rbx, %rdi
callq 0xd00e
leaq 0x30(%rsp), %rdi
callq 0x8550
movq %rsp, %rdi
callq 0x8550
leaq 0x60(%rsp), %rdi
callq 0xd3e8
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0xd35a
jmp 0xd35a
jmp 0xd35a
jmp 0xd35a
jmp 0xd35a
jmp 0xd35a
jmp 0xd35a
jmp 0xd35a
movq %rax, %rbx
leaq 0x30(%rsp), %rdi
callq 0x8550
movq %rsp, %rdi
callq 0x8550
jmp 0xd37c
jmp 0xd379
jmp 0xd379
jmp 0xd379
jmp 0xd379
movq %rax, %rbx
leaq 0x60(%rsp), %rdi
callq 0xd3e8
movq %rbx, %rdi
callq 0x33e0