LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/misc.cpp
// Function: debugf64(double vector[2] const&)
void debugc8(const __m128i& vals)
{
	char inner[sizeof(__m128i)/sizeof(char)];
	memcpy(inner, &vals, sizeof(__m128i));
	for (size_t i : range(ARRAY_SIZE(inner)))
		printf("%c%c", inner[i], (i == ARRAY_SIZE(inner)-1 ? '\n' : ' '));
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x20, %rsp
movsd (%rdi), %xmm0
leaq 0x10(%rsp), %rax
movsd %xmm0, (%rax)
movsd 0x8(%rdi), %xmm0
leaq 0x18(%rsp), %r15
movsd %xmm0, (%r15)
movb $0x1, %r12b
movl $0x20, %ebp
movq %rsp, %rbx
leaq 0x197c6(%rip), %r14     # 0x2fb2c
movsd (%rax), %xmm0
movq %rbx, %rdi
callq 0x1ae5c
cmpb $0x0, 0xf(%rsp)
movq %rbx, %rsi
jns 0x16380
movq (%rsp), %rsi
movq %r14, %rdi
movl %ebp, %edx
xorl %eax, %eax
callq 0x3050
cmpb $0x0, 0xf(%rsp)
jns 0x1639c
movq (%rsp), %rdi
callq 0x3430
movl $0xa, %ebp
movq %r15, %rax
testb $0x1, %r12b
movl $0x0, %r12d
jne 0x16366
addq $0x20, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/opengl/helpers.cpp
// Function: aropengl_base::create(aropengl_base::context*, char const*, void (**)())
bool aropengl_base::create(context* core, const char * symNames, funcptr* symDest)
{
	destroy();
	
	this->core = core;
#ifdef ARLIB_GUI
	this->port = NULL;
#endif
	if (!core) return false;
	
	while (*symNames)
	{
		*symDest = core->getProcAddress(symNames);
		//nulls here are fine, don't worry about them
		symDest++;
		symNames += strlen(symNames)+1;
	}
	return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %rbx
movq %rdx, %r15
movq %rsi, %r14
movq %rdi, %r12
movq (%rdi), %rdi
testq %rdi, %rdi
je 0x167e2
movq (%rdi), %rax
callq *0x30(%rax)
movq %r14, (%r12)
testq %r14, %r14
je 0x16814
cmpb $0x0, (%r15)
je 0x16814
movq (%r14), %rax
movq %r14, %rdi
movq %r15, %rsi
callq *0x18(%rax)
movq %rax, (%rbx)
addq $0x8, %rbx
movq %r15, %rdi
callq 0x30f0
addq %rax, %r15
incq %r15
jmp 0x167eb
testq %r14, %r14
setne %al
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/random.cpp
// Function: random_base_t<true>::rand_mod(unsigned int)
uint32_t random_base_t<is_global>::rand_mod(uint32_t limit)
{
	// if RAND_MAX+1 is not a multiple of 'limit', rand() mod limit becomes biased towards lower values
	// to avoid that, find the highest multiple of limit <= RAND_MAX+1,
	// and if the returned value is higher than that, discard it and create a new one
	// alternatively and equivalently, that many values can be discarded from the lower end of the results
	// the size of the discarded section must be (RAND_MAX+1) mod limit, and discarding low ones is easier
	
	// unfortunately, RAND_MAX+1 is 2^32, which won't fit in a uint32
	// however, for a >= b, a%b equals (a-b)%b, and UINT32_MAX+1 is always greater than limit
	// the extra -1 +1 needed to avoid an overflow can also be avoided, by using how unsigned integer overflow is defined
	// so the calculation needed is simply
	uint32_t minvalid = -limit % limit;
	
	while (true)
	{
		uint32_t candidate = rand32();
		if (candidate < minvalid) continue;
		return candidate%limit;
	}
}

// Assembly:
movl %esi, %eax
negl %eax
xorl %edx, %edx
divl %esi
movabsq $0x5851f42d4c957f2d, %r8 # imm = 0x5851F42D4C957F2D
movabsq $0x14057b7ef767814f, %r9 # imm = 0x14057B7EF767814F
movq (%rdi), %rax
movq %rax, %rcx
movq %rax, %r10
imulq %r8, %r10
addq %r9, %r10
lock
cmpxchgq %r10, (%rdi)
cmpq %rax, %rcx
jne 0x16b8d
movq %rcx, %rax
shrq $0x2d, %rax
movq %rcx, %r10
shrq $0x1b, %r10
xorl %r10d, %eax
shrq $0x3b, %rcx
rorl %cl, %eax
cmpl %edx, %eax
jb 0x16b8a
xorl %edx, %edx
divl %esi
movl %edx, %eax
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/random.cpp
// Function: random_base_t<true>::rand_mod(unsigned long)
uint64_t random_base_t<is_global>::rand_mod(uint64_t limit)
{
	if (LIKELY(limit <= 0xFFFFFFFF)) return rand_mod((uint32_t)limit);
	uint64_t minvalid = -limit % limit;
	
	while (true)
	{
		uint64_t candidate = rand64();
		if (candidate < minvalid) continue;
		return candidate%limit;
	}
}

// Assembly:
movq %rdi, %r8
movq %rsi, %rax
shrq $0x20, %rax
jne 0x16c2a
movl %esi, %eax
negl %eax
xorl %edx, %edx
divl %esi
movabsq $0x5851f42d4c957f2d, %rdi # imm = 0x5851F42D4C957F2D
movabsq $0x14057b7ef767814f, %r9 # imm = 0x14057B7EF767814F
movq (%r8), %rax
movq %rax, %rcx
movq %rax, %r10
imulq %rdi, %r10
addq %r9, %r10
lock
cmpxchgq %r10, (%r8)
cmpq %rax, %rcx
jne 0x16bf1
movq %rcx, %rax
shrq $0x2d, %rax
movq %rcx, %r10
shrq $0x1b, %r10
xorl %r10d, %eax
shrq $0x3b, %rcx
rorl %cl, %eax
cmpl %edx, %eax
jb 0x16bee
xorl %edx, %edx
divl %esi
movl %edx, %eax
retq
pushq %rbx
subq $0x10, %rsp
leaq 0x8(%rsp), %rbx
movq %rsi, %rdi
movq %r8, %rsi
movq %rbx, %rdx
callq 0x3f1b
movq (%rbx), %rax
addq $0x10, %rsp
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/runloop-poll.cpp
// Function: runloop2::run(async<void>)
void run(async<void> event)
	{
		waiter<void, void> wait;
		event.then(&wait);
		auto& loop = get_loop();
		while (wait.is_waiting())
			loop.step(true);
	}

// Assembly:
pushq %rbx
subq $0x10, %rsp
movq %rsp, %rsi
movq $0x0, (%rsi)
leaq 0x8b1(%rip), %rax       # 0x178f6
movq %rax, 0x8(%rsi)
callq 0xa78a
cmpb $0x0, %fs:-0x8
je 0x1708a
cmpq $0x0, (%rsp)
je 0x17084
movq %fs:0x0, %rax
leaq -0x68(%rax), %rbx
movq %rbx, %rdi
movl $0x1, %esi
callq 0x16e1a
cmpq $0x0, (%rsp)
jne 0x17070
addq $0x10, %rsp
popq %rbx
retq
movb $0x1, %fs:-0x8
callq 0x4e8c
jmp 0x17059
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/runloop-poll.cpp
// Function: (anonymous namespace)::runloop2_poll::fds_t::reallocate(unsigned long)
void reallocate(size_t newsize)
		{
#ifdef EXTRA_POLLFDS
			size_t cursize = max_used;
#else
			size_t cursize = waiting.size();
#endif
			waiting.resize(newsize);
			wait_fd.resize(newsize);
			for (size_t i=0;i<cursize;i++)
				waiting[i].prod.moved();
#ifndef EXTRA_POLLFDS
			for (size_t i=cursize;i<newsize;i++)
				wait_fd[i].fd = ~(i+1);
#endif
		}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movq 0x8(%rdi), %r12
movq %rsi, %r15
subq %r12, %r15
jbe 0x17527
leaq -0x1(%r12), %rax
bsrq %rax, %rcx
movl $0x2, %eax
shlq %cl, %rax
cmpq $0x8, %r12
movl $0x8, %ecx
cmovaeq %rax, %rcx
cmpq %rbx, %rcx
setb %al
movq (%r14), %rdi
testq %rdi, %rdi
sete %cl
orb %al, %cl
cmpb $0x1, %cl
jne 0x174f6
leaq -0x1(%rbx), %rax
bsrq %rax, %rcx
movl $0x20, %eax
shlq %cl, %rax
cmpq $0x8, %rbx
movl $0x80, %esi
cmovaeq %rax, %rsi
callq 0x159f7
movq %rax, (%r14)
movq %rbx, 0x8(%r14)
movq %r12, %rax
shlq $0x4, %rax
orq $0x8, %rax
leaq 0x176(%rip), %rcx       # 0x17682
movq (%r14), %rdx
movq $0x0, -0x8(%rdx,%rax)
movq %rcx, (%rdx,%rax)
addq $0x10, %rax
decq %r15
jne 0x1750c
jmp 0x17599
jae 0x17599
movq %rbx, %r13
shlq $0x4, %r13
leaq 0x18759(%rip), %r15     # 0x2fc90
movq %r12, %rax
movq %rbx, %rbp
movq (%r14), %rcx
cmpq $0x0, (%rcx,%r13)
je 0x17553
movq %r15, %rdi
callq 0x8683
movq 0x8(%r14), %rax
incq %rbp
addq $0x10, %r13
cmpq %rax, %rbp
jb 0x1753d
cmpq %rbx, %rax
jbe 0x17599
leaq -0x1(%rbx), %rcx
bsrq %rcx, %rcx
movl $0x2, %edx
shlq %cl, %rdx
cmpq $0x8, %rbx
movl $0x8, %esi
cmovaeq %rdx, %rsi
cmpq %rsi, %rax
jbe 0x17595
movq (%r14), %rdi
shlq $0x4, %rsi
callq 0x159f7
movq %rax, (%r14)
movq %rbx, 0x8(%r14)
leaq 0x10(%r14), %r15
movq %r15, %rdi
movq %rbx, %rsi
callq 0x1774e
testq %r12, %r12
je 0x175c7
movq (%r14), %rax
movq %r12, %rcx
movq (%rax), %rdx
testq %rdx, %rdx
je 0x175be
movq %rax, (%rdx)
addq $0x10, %rax
decq %rcx
jne 0x175b3
subq %r12, %rbx
jbe 0x17673
movq (%r15), %rdx
leaq 0x1(%rbx), %rax
andq $-0x2, %rax
decq %rbx
movq %rbx, %xmm0
pshufd $0x44, %xmm0, %xmm0     # xmm0 = xmm0[0,1,0,1]
movl $0xfffffffd, %ecx       # imm = 0xFFFFFFFD
subl %r12d, %ecx
leaq (%rdx,%r12,8), %rdx
addq $0x8, %rdx
xorl %esi, %esi
movdqa 0x17d6e(%rip), %xmm1    # 0x2f370
movdqa 0x183b6(%rip), %xmm2    # 0x2f9c0
pxor %xmm2, %xmm0
pcmpeqd %xmm3, %xmm3
movq %rsi, %xmm4
pshufd $0x44, %xmm4, %xmm4     # xmm4 = xmm4[0,1,0,1]
por %xmm1, %xmm4
pxor %xmm2, %xmm4
movdqa %xmm4, %xmm5
pcmpgtd %xmm0, %xmm5
pcmpeqd %xmm0, %xmm4
pshufd $0xf5, %xmm4, %xmm6     # xmm6 = xmm4[1,1,3,3]
pand %xmm5, %xmm6
pshufd $0xf5, %xmm5, %xmm4     # xmm4 = xmm5[1,1,3,3]
por %xmm6, %xmm4
movd %xmm4, %edi
notl %edi
testb $0x1, %dil
je 0x17655
leal 0x1(%rcx), %edi
movl %edi, -0x8(%rdx,%rsi,8)
pxor %xmm3, %xmm4
pextrw $0x4, %xmm4, %edi
testb $0x1, %dil
je 0x17667
movl %ecx, (%rdx,%rsi,8)
addq $0x2, %rsi
addl $-0x2, %ecx
cmpq %rsi, %rax
jne 0x17612
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/runloop2.h
// Function: producer<void, (anonymous namespace)::runloop2_poll::fds_t::waiter_node::prod_t>::cancel_s(producer_base<void>*)
static void cancel_s(producer_base<T>* self)
	{
		if (self->wait)
			self->wait->prod = nullptr;
		self->wait = nullptr;
		if constexpr (!std::is_same_v<T2, void>)
		{
			static_assert(std::is_base_of_v<producer, T2>);
			((T2*)self)->cancel();
		}
	}

// Assembly:
pushq %rbx
movq %rdi, %rbx
movq (%rdi), %rax
testq %rax, %rax
je 0x17695
movq $0x0, (%rax)
movq $0x0, (%rbx)
cmpb $0x0, %fs:-0x8
je 0x176db
subq %fs:-0x68, %rbx
movq %rbx, %rax
sarq $0x4, %rax
movl %fs:-0x48, %ecx
notl %ecx
movq %fs:-0x58, %rdx
sarq %rbx
movl %ecx, (%rdx,%rbx)
movq %rax, %fs:-0x48
popq %rbx
retq
movb $0x1, %fs:-0x8
callq 0x4e8c
jmp 0x176a7
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/array.h
// Function: fifo<std::__n4861::coroutine_handle<void>>::push(std::__n4861::coroutine_handle<void>)
void push(T item)
	{
		if (wr == capacity)
		{
			if (rd <= capacity/2)
			{
				if (capacity == 0)
					capacity = 8;
				else
					capacity *= 2;
				items = xrealloc(items, sizeof(T)*capacity);
			}
			for (size_t n=0;n<rd;n++)
				items[n].~T();
			memmove(items, items+rd, sizeof(T)*(wr-rd));
			wr -= rd;
			rd = 0;
		}
		new(&items[wr]) T(std::move(item));
		wr++;
	}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq 0x18(%rdi), %rdx
cmpq 0x8(%rdi), %rdx
jne 0x178d5
movq (%rbx), %rdi
movq 0x10(%rbx), %rax
movq %rdx, %rcx
shrq %rcx
cmpq %rcx, %rax
ja 0x178b5
leaq (%rdx,%rdx), %rax
testq %rdx, %rdx
movl $0x8, %esi
cmovneq %rax, %rsi
movq %rsi, 0x8(%rbx)
shlq $0x3, %rsi
callq 0x159f7
movq %rax, %rdi
movq %rax, (%rbx)
movq 0x10(%rbx), %rax
movq 0x18(%rbx), %rdx
leaq (%rdi,%rax,8), %rsi
subq %rax, %rdx
shlq $0x3, %rdx
callq 0x3600
movq 0x18(%rbx), %rdx
subq 0x10(%rbx), %rdx
movq $0x0, 0x10(%rbx)
movq (%rbx), %rax
movq %r14, (%rax,%rdx,8)
incq %rdx
movq %rdx, 0x18(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::open(cstrnul, bool)
bool staticmap::open(cstrnul fn, bool map_writable)
{
	if (!f.open(fn, (file2::mode)(file2::m_write | file2::m_exclusive))) return false;
	this->map_writable = map_writable;
	this->sector_size = f.sector_size();
	
	mmap = f.mmapw(map_writable);
	if (mmap.size() == 0)
		create();
	else if (rd64(off_header) == t_meta+off_r_objsize && rd64(off_r_sig) == sig_passive)
		{} // do nothing
	else if (rd64(off_header) == t_meta+off_r_objsize && rd64(off_r_sig) == sig_active)
	{
		if (mmap.size() <= 1024 || rd64(off_r_entries) == 0)
			create();
		else
			recover();
	}
	else
		f.close();
	return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movl %ecx, %ebp
movq %rdi, %r14
leaq 0x4(%rdi), %r15
movq %r15, %rdi
movl $0x9, %ecx
callq 0x9968
movl %eax, %ebx
testb %al, %al
je 0x17a30
movb %bpl, 0x18(%r14)
movl 0x4(%r14), %edi
movq %rsp, %r12
movq %r12, %rsi
callq 0x3640
movl 0x38(%r12), %eax
movl %eax, 0x1c(%r14)
xorps %xmm0, %xmm0
movaps %xmm0, (%r12)
movzbl %bpl, %edx
movq %rsp, %r13
movq %r13, %rdi
movq %r15, %rsi
callq 0x9a0e
leaq 0x8(%r14), %r12
movq %r12, %rdi
callq 0x9a7c
movaps (%r13), %xmm0
movups %xmm0, 0x8(%r14)
xorps %xmm0, %xmm0
movaps %xmm0, (%r13)
movq %r13, %rdi
callq 0x9a7c
movq 0x10(%r14), %rax
testq %rax, %rax
je 0x17a12
movq (%r12), %rcx
cmpq $0x202, (%rcx)          # imm = 0x202
jne 0x17a1c
movq 0x8(%rcx), %rdx
movabsq $0x70616d736c7261, %rsi # imm = 0x70616D736C7261
cmpq %rsi, %rdx
je 0x17a30
movabsq $0x170616d736c7261, %rsi # imm = 0x170616D736C7261
cmpq %rsi, %rdx
jne 0x17a1c
cmpq $0x401, %rax            # imm = 0x401
jb 0x17a12
cmpq $0x0, 0x20(%rcx)
je 0x17a12
movq %r14, %rdi
callq 0x17b76
jmp 0x17a30
movq %r14, %rdi
callq 0x17a44
jmp 0x17a30
movl (%r15), %edi
cmpl $-0x1, %edi
je 0x17a29
callq 0x3700
movl $0xffffffff, (%r15)     # imm = 0xFFFFFFFF
movl %ebx, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::create()
void staticmap::create()
{
	mmap = nullptr;
	uint8_t buf[off_r_objsize + 512];
	
	writeu_le64(buf+off_header, off_r_objsize+t_meta);
	writeu_le64(buf+off_r_sig, sig_active);
	writeu_le64(buf+off_r_hm_ptr, 512); // hashmap pointer
	writeu_le64(buf+off_r_hm_load, 0); // number of used hashmap slots
	writeu_le64(buf+off_r_entries, 0); // number of object members
	for (int i=5;i<=9;i++) writeu_le64(buf+off_r_freespace(i), 0); // no freespaces of size 32 to 512
	for (int i=10;i<=15;i++) writeu_le64(buf+off_r_freespace(i), 1<<i); // have freespaces of size 1024 to 32768
	for (int i=16;i<=63;i++) writeu_le64(buf+off_r_freespace(i), 1); // no freespaces of size 65536 to 9223372036854775808
	
	writeu_le64(buf+512, 512+t_meta); // hashmap header
	for (int i=2;i<=63;i++) writeu_le64(buf+512+i*8, 0); // fill the hashmap
	f.pwrite(0, buf);
	
	f.resize(65536, mmap, map_writable);
	
	for (int i=10;i<=15;i++)
		wr64(1<<i, (1<<i)+t_free, 0, off_r_freespace(i)); // header, next_obj, prev_ptr
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x428, %rsp            # imm = 0x428
movq %rdi, %r14
leaq 0x8(%rdi), %rbx
movq %rbx, %rdi
callq 0x9a7c
movq $0x202, 0x20(%rsp)      # imm = 0x202
movabsq $0x170616d736c7261, %rax # imm = 0x170616D736C7261
movq %rax, 0x28(%rsp)
movq $0x200, 0x30(%rsp)      # imm = 0x200
xorps %xmm0, %xmm0
movups %xmm0, 0x38(%rsp)
movups %xmm0, 0x48(%rsp)
movups %xmm0, 0x58(%rsp)
movq $0x0, 0x68(%rsp)
movl $0xa, %ecx
movl $0x1, %eax
shll %cl, %eax
movq %rax, 0x20(%rsp,%rcx,8)
incq %rcx
cmpq $0x10, %rcx
jne 0x17aa2
movl $0x10, %eax
movaps 0x1826d(%rip), %xmm0    # 0x2fd30
movaps %xmm0, 0x20(%rsp,%rax,8)
addq $0x2, %rax
cmpq $0x40, %rax
jne 0x17ac3
leaq 0x230(%rsp), %rdi
movq $0x202, -0x10(%rdi)     # imm = 0x202
movl $0x1f0, %edx            # imm = 0x1F0
xorl %esi, %esi
callq 0x3170
leaq 0x4(%r14), %r15
movl 0x4(%r14), %edi
leaq 0x20(%rsp), %rsi
movl $0x400, %edx            # imm = 0x400
xorl %ecx, %ecx
callq 0x30d0
movzbl 0x18(%r14), %ecx
movl $0x10000, %esi          # imm = 0x10000
movq %r15, %rdi
movq %rbx, %rdx
callq 0xa318
movl $0xa, %ebx
movl $0x50, %r12d
movq %rsp, %r14
movl $0x1, %eax
movl %ebx, %ecx
shll %cl, %eax
movq %rax, (%rsp)
movq $0x0, 0x8(%rsp)
movq %r12, 0x10(%rsp)
movl (%r15), %edi
movl $0x18, %edx
movq %r14, %rsi
movq %rax, %rcx
callq 0x30d0
incl %ebx
addq $0x8, %r12
cmpq $0x80, %r12
jne 0x17b2a
addq $0x428, %rsp            # imm = 0x428
popq %rbx
popq %r12
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::free(unsigned long)
void staticmap::free(uint64_t addr)
{
//printf("free %lu\n", addr);
	uint64_t size = rd64(addr+off_header) & ~t_typemask;
again:
	uint64_t other = addr ^ size;
	if (rd64(other+off_header) == size + t_free)
	{
		uint64_t next_obj = rd64(other+off_f_nextobj);
		f.pwrite(rd64(other+off_f_prevptr), mmap.slice(other+off_f_nextobj, 8));  // *(other.prev_ptr) = other.next_obj;
		if (next_obj)                                                             // if (other.next_obj)
			f.pwrite(next_obj+off_f_prevptr, mmap.slice(other+off_f_prevptr, 8)); //   other.next_obj->prev_ptr = other.prev_ptr;
		
		addr &= ~size;
		size *= 2;
		goto again;
	}
	
	uint64_t bucket_pos = off_r_freespace(ilog2(size));
	// bucket_pos can be 1 if the freed space is combined with a sibling, such that the entire right half of the file is now free
	uint64_t prev_free = rd64(bucket_pos) & ~1;
	if (prev_free > 1)
		wr64(prev_free+off_f_prevptr, addr+off_f_nextobj);
	wr64(addr, size+t_free, prev_free, bucket_pos);
	wr64(bucket_pos, addr);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq 0x8(%rdi), %rax
movq (%rax,%rsi), %r13
andq $-0x10, %r13
movq %r13, %r15
xorq %rsi, %r15
cmpq %r13, (%rax,%r15)
jne 0x17ee6
leaq (%rax,%r15), %rsi
addq $0x8, %rsi
movq (%rsi), %r12
movq 0x8(%rsi), %rcx
movl 0x4(%rbx), %edi
movl $0x8, %edx
callq 0x30d0
testq %r12, %r12
je 0x17ece
addq $0x10, %r15
addq $0x10, %r12
addq 0x8(%rbx), %r15
movl 0x4(%rbx), %edi
movl $0x8, %edx
movq %r15, %rsi
movq %r12, %rcx
callq 0x30d0
movq %r13, %rax
notq %rax
andq %rax, %r14
addq %r13, %r13
movq %r14, %r15
xorq %r13, %r15
movq 0x8(%rbx), %rax
jmp 0x17e88
bsrq %r13, %r15
xorl $0x3f, %r15d
shll $0x3, %r15d
xorq $0x1f8, %r15            # imm = 0x1F8
movq (%rax,%r15), %rax
movq %rax, %rbp
andq $-0x2, %rbp
cmpq $0x2, %rax
jb 0x17f25
leaq 0x10(%rbp), %rcx
leaq 0x8(%r14), %rax
movq %rsp, %rsi
movq %rax, (%rsi)
movl 0x4(%rbx), %edi
movl $0x8, %edx
callq 0x30d0
movq %rsp, %r12
movq %r13, (%r12)
movq %rbp, 0x8(%r12)
movq %r15, 0x10(%r12)
movl 0x4(%rbx), %edi
movl $0x18, %edx
movq %r12, %rsi
movq %r14, %rcx
callq 0x30d0
movq %r14, (%r12)
movl 0x4(%rbx), %edi
movq %rsp, %rsi
movl $0x8, %edx
movq %r15, %rcx
callq 0x30d0
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::hashmap_locate(unsigned long, arrayview<unsigned char>)
uint64_t staticmap::hashmap_locate(uint64_t hash, bytesr key)
{
	uint64_t ret = 0;
	uint64_t hashmap_pos = rd64(off_r_hm_ptr);
	uint64_t hashmap_size = rd64(hashmap_pos+off_header) & ~t_typemask;
	
	// ignore bottom 4 bits of hash
	uint64_t off = hash & (hashmap_size-off_h_nodesize);
	while (true)
	{
		if (off == 0)
			off = off_h_nodesize;
		uint64_t node_addr = rd64(hashmap_pos+off+off_h_ptr);
		uint64_t node_hash = rd64(hashmap_pos+off+off_h_hash);
		if (node_addr <= 1)
		{
			if (ret == 0)
				ret = hashmap_pos+off;
			if (node_addr == 0)
				return ret;
		}
		if (node_addr > 1 && node_hash == hash)
		{
			bytesr node_key = mmap.slice(node_addr+off_d_keystart, rd64(node_addr+off_d_keysz));
			if (key == node_key)
				return hashmap_pos+off;
		}
		off = (off+off_h_nodesize) & (hashmap_size-off_h_nodesize);
	}
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, 0x18(%rsp)
movq %rsi, %rax
movq 0x8(%rdi), %r13
movq 0x10(%r13), %rbp
movq (%r13,%rbp), %rbx
andq $-0x10, %rbx
addq $-0x10, %rbx
movq %rbx, %r14
andq %rsi, %r14
leaq 0x18(%r13), %rdx
movq %rdx, 0x8(%rsp)
xorl %r15d, %r15d
movl $0x10, %edx
movq %rcx, 0x20(%rsp)
movq %rsi, 0x10(%rsp)
testq %r14, %r14
cmoveq %rdx, %r14
leaq (%r14,%rbp), %r12
movq (%r13,%r12), %rsi
cmpq $0x1, %rsi
ja 0x181e1
testq %r15, %r15
cmovneq %r15, %r12
movq %r12, %r15
testq %rsi, %rsi
jne 0x18214
jmp 0x1821d
cmpq %rax, 0x8(%r13,%r12)
jne 0x18214
cmpq %rcx, 0x8(%r13,%rsi)
jne 0x18214
addq 0x8(%rsp), %rsi
movq 0x18(%rsp), %rdi
movq %rcx, %rdx
callq 0x3380
movl $0x10, %edx
movq 0x20(%rsp), %rcx
testl %eax, %eax
movq 0x10(%rsp), %rax
je 0x1821d
addq $0x10, %r14
andq %rbx, %r14
jmp 0x181ba
movq %r12, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::get_or_empty(arrayview<unsigned char>, bool*)
bytesw staticmap::get_or_empty(bytesr key, bool* found)
{
//puts("GET "+tostringhex(key));
	uint64_t hash = sm_hash(key);
	uint64_t hashmap_pos = hashmap_locate(hash, key);
	
	uint64_t ptr = rd64(hashmap_pos+off_h_ptr);
	if (found)
		*found = (ptr > 1);
	if (ptr > 1)
		return mmap.slice(ptr+off_d_keystart+key.size(), rd64(ptr+off_d_valsz));
	return {};
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %r8, %r15
movq %rcx, %r14
movq %rdx, %r13
movq %rsi, %r12
movq %rdi, %rbx
movq %rdx, %rdi
movq %rcx, %rsi
callq 0x15ad7
movq %rax, %rcx
shrq $0x1e, %rcx
xorq %rax, %rcx
movabsq $-0x40a7b892e31b1a47, %rax # imm = 0xBF58476D1CE4E5B9
imulq %rcx, %rax
movq %rax, %rcx
shrq $0x1b, %rcx
xorq %rax, %rcx
movabsq $-0x6b2fb644ecceee15, %rax # imm = 0x94D049BB133111EB
imulq %rcx, %rax
movq %rax, %rsi
shrq $0x1f, %rsi
xorq %rax, %rsi
movq %r12, %rdi
movq %r13, %rdx
movq %r14, %rcx
callq 0x1816e
movq 0x8(%r12), %rcx
movq (%rcx,%rax), %rax
testq %r15, %r15
je 0x18419
cmpq $0x2, %rax
setae (%r15)
cmpq $0x2, %rax
jb 0x18439
leaq (%rcx,%rax), %rdx
movq 0x10(%rcx,%rax), %rax
leaq (%r14,%rdx), %rcx
addq $0x18, %rcx
movq %rcx, (%rbx)
movq %rax, 0x8(%rbx)
jmp 0x1843f
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::desync()
void staticmap::desync()
{
	if (!f) return;
	if (*synced)
		f.pwrite(off_r_sigactive, synced);
	*synced = false;
}

// Assembly:
movq %rdi, %rax
movl 0x4(%rdi), %edi
cmpl $-0x1, %edi
je 0x186f6
pushq %rbx
leaq 0x19(%rax), %rbx
cmpb $0x0, 0x19(%rax)
je 0x186f2
movl $0x1, %edx
movl $0xf, %ecx
movq %rbx, %rsi
callq 0x30d0
movb $0x0, (%rbx)
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::remove(arrayview<unsigned char>)
void staticmap::remove(bytesr key)
{
//puts("REMOVE "+tostringhex(key));
	desync();
	
	uint64_t hash = sm_hash(key);
	uint64_t hashmap_pos = hashmap_locate(hash, key);
	
	uint64_t ptr = rd64(hashmap_pos+off_h_ptr);
	if (ptr > 1)
	{
		free(ptr);
		wr64(hashmap_pos+off_h_ptr, 1);
		wr64(off_r_entries, rd64(off_r_entries)-1);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
callq 0x186ca
movq %r15, %rdi
movq %r14, %rsi
callq 0x15ad7
movq %rax, %rcx
shrq $0x1e, %rcx
xorq %rax, %rcx
movabsq $-0x40a7b892e31b1a47, %rax # imm = 0xBF58476D1CE4E5B9
imulq %rcx, %rax
movq %rax, %rcx
shrq $0x1b, %rcx
xorq %rax, %rcx
movabsq $-0x6b2fb644ecceee15, %rax # imm = 0x94D049BB133111EB
imulq %rcx, %rax
movq %rax, %rsi
shrq $0x1f, %rsi
xorq %rax, %rsi
movq %rbx, %rdi
movq %r15, %rdx
movq %r14, %rcx
callq 0x1816e
movq %rax, %r14
movq 0x8(%rbx), %rax
movq (%rax,%r14), %rsi
cmpq $0x2, %rsi
jb 0x187bf
movq %rbx, %rdi
callq 0x17e62
leaq 0x8(%rsp), %r15
movq $0x1, (%r15)
movl 0x4(%rbx), %edi
movl $0x8, %edx
movq %r15, %rsi
movq %r14, %rcx
callq 0x30d0
movq 0x8(%rbx), %rax
movq 0x20(%rax), %rax
decq %rax
movq %rax, (%r15)
movl 0x4(%rbx), %edi
leaq 0x8(%rsp), %rsi
movl $0x8, %edx
movl $0x20, %ecx
callq 0x30d0
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::iterator::operator*()
staticmap::node staticmap::iterator::operator*()
{
	it = next(it, nullptr);
	uint64_t keylen = readu_le64(it+off_d_keysz);
	uint64_t vallen = readu_le64(it+off_d_valsz);
	return { bytesr(it+off_d_keystart, keylen), bytesw(it+off_d_keystart+keylen, vallen) };
}

// Assembly:
movq %rdi, %rax
movq (%rsi), %rdi
testq %rdi, %rdi
je 0x18879
movq (%rdi), %rcx
movl %ecx, %edx
andl $0xf, %edx
cmpl $0x1, %edx
jne 0x1885b
movq %rdi, %rdx
jmp 0x1887b
andq $-0x10, %rcx
leaq (%rdi,%rcx), %rdx
movq (%rdi,%rcx), %rcx
movl %ecx, %r8d
andl $0xf, %r8d
movq %rdx, %rdi
cmpl $0x1, %r8d
jne 0x1885b
jmp 0x1887b
xorl %edx, %edx
movq %rdx, (%rsi)
movq 0x8(%rdx), %rcx
movq 0x10(%rdx), %rsi
leaq 0x18(%rdx), %rdi
movq %rdi, (%rax)
movq %rcx, 0x8(%rax)
addq %rdx, %rcx
addq $0x18, %rcx
movq %rcx, 0x10(%rax)
movq %rsi, 0x18(%rax)
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/staticmap.cpp
// Function: staticmap::iterator::operator!=(staticmap::iterator const&)
bool staticmap::iterator::operator!=(const iterator& other)
{
	uint8_t* a = it;
	uint8_t* b = other.it;
	if (it < other.it) a = next(a, b);
	else b = next(b, a);
	return (a != b);
}

// Assembly:
movq (%rdi), %rax
movq (%rsi), %rcx
cmpq %rcx, %rax
jae 0x18917
movq (%rax), %rdx
movl %edx, %esi
andl $0xf, %esi
cmpl $0x1, %esi
je 0x18935
andq $-0x10, %rdx
addq %rdx, %rax
cmpq %rcx, %rax
jne 0x188f9
movq %rcx, %rax
jmp 0x18935
je 0x18932
movq (%rcx), %rdx
movl %edx, %esi
andl $0xf, %esi
cmpl $0x1, %esi
je 0x18935
andq $-0x10, %rdx
addq %rdx, %rcx
cmpq %rax, %rcx
jne 0x18919
movq %rax, %rcx
cmpq %rcx, %rax
setne %al
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: string::resize(unsigned long)
void string::resize(size_t newlen)
{
	switch (!inlined()<<1 | (newlen>max_inline()))
	{
	case 0: // small->small
		{
			m_inline[newlen] = '\0';
			m_inline_len_w() = max_inline()-newlen;
		}
		break;
	case 1: // small->big
		{
			uint8_t* newptr = xmalloc(bytes_for(newlen));
			memcpy(newptr, m_inline, max_inline());
			newptr[newlen] = '\0';
			m_data = newptr;
			m_len = newlen;
			m_nul = true;
			
			m_inline_len_w() = -1;
		}
		break;
	case 2: // big->small
		{
			uint8_t* oldptr = m_data;
			memcpy(m_inline, oldptr, newlen);
			free(oldptr);
			m_inline[newlen] = '\0';
			m_inline_len_w() = max_inline()-newlen;
		}
		break;
	case 3: // big->big
		{
			if (bytes_for(newlen) != bytes_for(m_len))
				m_data = xrealloc(m_data, bytes_for(newlen));
			m_data[newlen] = '\0';
			m_len = newlen;
		}
		break;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movzbl 0xf(%rdi), %eax
shrl $0x6, %eax
andl $0x2, %eax
xorl %ecx, %ecx
cmpq $0x10, %rsi
setae %cl
orl %eax, %ecx
leaq 0x16955(%rip), %rax     # 0x2fd40
movslq (%rax,%rcx,4), %rcx
addq %rax, %rcx
jmpq *%rcx
bsrq %r14, %rcx
movl $0x2, %eax
shlq %cl, %rax
leaq -0x1(%r14), %rcx
cmpq $-0x2, %rcx
movl $0x1, %edi
cmovbq %rax, %rdi
callq 0x1597c
movq (%rbx), %rcx
movq 0x7(%rbx), %rdx
movq %rcx, (%rax)
movq %rdx, 0x7(%rax)
movb $0x0, (%rax,%r14)
movq %rax, (%rbx)
movl %r14d, 0x8(%rbx)
movb $0x1, 0xc(%rbx)
movb $-0x1, 0xf(%rbx)
jmp 0x194b5
movq (%rbx), %r15
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x3280
movq %r15, %rdi
callq 0x3430
movb $0x0, (%rbx,%r14)
movb $0xf, %al
subb %r14b, %al
movb %al, 0xf(%rbx)
jmp 0x194b5
bsrq %r14, %rcx
movl $0x2, %esi
shlq %cl, %rsi
movl $0x2, %edx
leaq -0x1(%r14), %rax
cmpq $-0x2, %rax
movl $0x1, %eax
cmovaeq %rax, %rsi
movl 0x8(%rbx), %edi
bsrq %rdi, %rcx
shlq %cl, %rdx
decq %rdi
cmpq $-0x2, %rdi
cmovaeq %rax, %rdx
movq (%rbx), %rax
cmpq %rdx, %rsi
je 0x194ac
movq %rax, %rdi
callq 0x159f7
movq %rax, (%rbx)
movb $0x0, (%rax,%r14)
movl %r14d, 0x8(%rbx)
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: string::init_from_outline(unsigned char const*, unsigned long)
void string::init_from_outline(const uint8_t * str, size_t len)
{
	if (len <= max_inline())
	{
		memcpy(m_inline, str, len);
		m_inline[len] = '\0';
		m_inline_len_w() = max_inline()-len;
	}
	else
	{
		init_from_large(str, len);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
cmpq $0xf, %rdx
jbe 0x19515
movb $-0x1, 0xf(%rbx)
bsrq %r14, %rcx
movl $0x2, %eax
shlq %cl, %rax
cmpq $-0x1, %r14
movl $0x1, %edi
cmovneq %rax, %rdi
callq 0x1597c
movq %rax, (%rbx)
movq %rax, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x3280
movq (%rbx), %rax
movb $0x0, (%rax,%r14)
movl %r14d, 0x8(%rbx)
movb $0x1, 0xc(%rbx)
jmp 0x19530
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
callq 0x3280
movb $0x0, (%rbx,%r14)
movb $0xf, %al
subb %r14b, %al
movb %al, 0xf(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: string::init_from(cstring const&)
void string::init_from(const cstring& other)
{
	if (other.inlined())
		memcpy((void*)this, (void*)&other, sizeof(*this));
	else
		init_from_large(other.m_data, other.m_len);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpb $0x0, 0xf(%rsi)
js 0x195a8
movups (%rsi), %xmm0
movups %xmm0, (%rbx)
jmp 0x195f6
movq (%rsi), %r14
movl 0x8(%rsi), %r15d
movb $-0x1, 0xf(%rbx)
bsrq %r15, %rcx
movl $0x2, %eax
shlq %cl, %rax
leaq -0x1(%r15), %rcx
cmpq $-0x2, %rcx
movl $0x1, %edi
cmovbq %rax, %rdi
callq 0x1597c
movq %rax, (%rbx)
movq %rax, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x3280
movq (%rbx), %rax
movb $0x0, (%rax,%r15)
movl %r15d, 0x8(%rbx)
movb $0x1, 0xc(%rbx)
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: string::reinit_from(arrayview<unsigned char>)
void string::reinit_from(arrayview<uint8_t> data)
{
	const uint8_t * str = data.ptr();
	size_t len = data.size();
	
	if (str >= this->ptr() && str <= this->ptr()+this->length())
	{
		if (str == this->ptr() && len == this->length()) return;
		
		memmove(this->ptr(), str, len);
		resize(len);
	}
	else
	{
		deinit();
		init_from(data);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, %r14
movzbl 0xf(%rdi), %ecx
testb %cl, %cl
movq (%rdi), %rax
movq %rax, %rdi
cmovnsq %r14, %rdi
cmpq %rsi, %rdi
ja 0x19634
movl %ecx, %edx
xorl $0xf, %edx
testb %cl, %cl
cmovsl 0x8(%r14), %edx
leaq (%rdi,%rdx), %rsi
cmpq %r15, %rsi
jae 0x19653
testb %cl, %cl
jns 0x19640
movq %rax, %rdi
callq 0x3430
movq %r14, %rdi
movq %r15, %rsi
movq %rbx, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x194bc
cmpq %r15, %rdi
jne 0x19663
cmpq %rbx, %rdx
jne 0x19663
popq %rbx
popq %r14
popq %r15
retq
movq %r15, %rsi
movq %rbx, %rdx
callq 0x3600
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x193c4
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: string::append(arrayview<unsigned char>)
void string::append(arrayview<uint8_t> newdat)
{
	// cache these four, for performance
	uint8_t* p1 = ptr();
	const uint8_t* p2 = newdat.ptr();
	uint32_t l1 = length();
	uint32_t l2 = newdat.size();
	
	if (UNLIKELY(p2 >= p1 && p2 < p1+l1))
	{
		uint32_t offset = p2-p1;
		resize(l1+l2);
		p1 = ptr();
		memcpy(p1+l1, p1+offset, l2);
	}
	else
	{
		resize(l1+l2);
		memcpy(ptr()+l1, p2, l2);
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %rbx
movq %rdi, %r15
movzbl 0xf(%rdi), %eax
movl %eax, %r12d
xorl $0xf, %r12d
testb %al, %al
movq (%rdi), %rax
cmovnsq %rdi, %rax
cmovsl 0x8(%rdi), %r12d
cmpq %rsi, %rax
ja 0x196b6
leaq (%rax,%r12), %rcx
cmpq %rbx, %rcx
ja 0x196e8
leal (%r12,%r14), %esi
movq %r15, %rdi
callq 0x193c4
cmpb $0x0, 0xf(%r15)
jns 0x196cc
movq (%r15), %r15
addq %r12, %r15
movl %r14d, %edx
movq %r15, %rdi
movq %rbx, %rsi
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x3280
subl %eax, %ebx
leal (%r12,%r14), %esi
movq %r15, %rdi
callq 0x193c4
cmpb $0x0, 0xf(%r15)
jns 0x19700
movq (%r15), %r15
addq %r15, %r12
addq %r15, %rbx
movl %r14d, %edx
movq %r12, %rdi
jmp 0x196d5
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: string::create_usurp(char*)
string string::create_usurp(char * str)
{
	cstring tmp(str);
	string ret;
	memcpy((void*)&ret, (void*)&tmp, sizeof(string));
	if (tmp.inlined()) free(str);
	else ret.m_data = xrealloc(ret.m_data, bytes_for(ret.m_len));
	return ret;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x30f0
movq %rsp, %r15
movq %r15, %rdi
movq %r14, %rsi
movq %rax, %rdx
movl $0x1, %ecx
callq 0x5990
movups (%r15), %xmm0
movups %xmm0, (%rbx)
cmpb $0x0, 0xf(%r15)
js 0x19753
movq %r14, %rdi
callq 0x3430
jmp 0x1977d
movq (%rbx), %rdi
movl 0x8(%rbx), %eax
bsrq %rax, %rcx
movl $0x2, %edx
shlq %cl, %rdx
decq %rax
cmpq $-0x2, %rax
movl $0x1, %esi
cmovbq %rdx, %rsi
callq 0x159f7
movq %rax, (%rbx)
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: string::string(array<unsigned char>&&)
string::string(array<uint8_t>&& bytes) : cstrnul(noinit())
{
	cstring tmp(bytes);
	memcpy((void*)this, (void*)&tmp, sizeof(string));
	
	uint8_t* ptr = bytes.release().ptr();
	if (tmp.inlined()) free(ptr);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
movq (%rsi), %rsi
movq 0x8(%rbx), %rdx
movq %rsp, %r15
movq %r15, %rdi
xorl %ecx, %ecx
callq 0x5990
movups (%r15), %xmm0
movups %xmm0, (%r14)
movq (%rbx), %rdi
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
cmpb $0x0, 0xf(%r15)
js 0x197ca
callq 0x3430
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::lastindexof(cstring) const
size_t cstring::lastindexof(cstring other) const
{
	size_t ret = -1;
	const uint8_t* start = this->ptr();
	const uint8_t* find = start;
	const uint8_t* find_end = find + this->length();
	if (!other) return this->length();
	
	while (true)
	{
		find = (uint8_t*)memmem(find, find_end-find, other.ptr(), other.length());
		if (!find) return ret;
		ret = find-start;
		find += 1;
	}
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rsi, (%rsp)
movq %rdx, 0x8(%rsp)
movzbl 0xf(%rdi), %eax
movq %rdx, %r14
shrq $0x38, %r14
xorl $0xf, %r14d
testq %rdx, %rdx
movl %r14d, %ecx
cmovsl %edx, %ecx
movl %eax, %r15d
xorl $0xf, %r15d
testb %al, %al
movq (%rdi), %r12
cmovnsq %rdi, %r12
cmovsl 0x8(%rdi), %r15d
testl %ecx, %ecx
je 0x198e1
movq %rsi, %rbx
testq %rdx, %rdx
movq %rsp, %rax
cmovnsq %rax, %rbx
cmovsl %edx, %r14d
movq %r12, %rdi
movq %r15, %rsi
movq %rbx, %rdx
movq %r14, %rcx
callq 0x3e3d
testq %rax, %rax
je 0x198da
addq %r12, %r15
movq %rax, %r13
leaq 0x1(%rax), %rdi
movq %r15, %rsi
subq %rdi, %rsi
movq %rbx, %rdx
movq %r14, %rcx
callq 0x3e3d
testq %rax, %rax
jne 0x198b5
subq %r12, %r13
movq %r13, %r15
jmp 0x198e1
movq $-0x1, %r15
movq %r15, %rax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::iindexof(cstring, unsigned long) const
size_t cstring::iindexof(cstring other, size_t start) const
{
	if (start+other.length() > this->length()) return -1;
	const char* a = (char*)this->ptr();
	const char* b = (char*)other.ptr();
	while (start <= this->length()-other.length())
	{
		size_t i;
		for (i=0;i<other.length();i++)
		{
			if (tolower(a[start+i]) != tolower(b[i])) break;
		}
		if (i==other.length()) return start;
		start++;
	}
	return -1;
}

// Assembly:
pushq %rbx
movq %rsi, -0x10(%rsp)
movq %rdx, -0x8(%rsp)
movq %rdx, %r8
shrq $0x38, %r8
xorl $0xf, %r8d
testq %rdx, %rdx
cmovsl %edx, %r8d
leaq (%r8,%rcx), %r10
movzbl 0xf(%rdi), %eax
movl %eax, %r9d
xorl $0xf, %r9d
testb %al, %al
cmovsl 0x8(%rdi), %r9d
cmpq %r9, %r10
jbe 0x19a05
movq $-0x1, %rax
popq %rbx
retq
testb %al, %al
jns 0x19a0c
movq (%rdi), %rdi
testq %rdx, %rdx
leaq -0x10(%rsp), %rax
cmovnsq %rax, %rsi
subl %r8d, %r9d
addq %rcx, %rdi
leaq 0x1632b(%rip), %rdx     # 0x2fd50
cmpq %r9, %rcx
ja 0x199fc
movq %rcx, %rax
xorl %r10d, %r10d
testl %r8d, %r8d
je 0x19a61
movzbl (%rdi,%r10), %ecx
movb (%rcx,%rdx), %r11b
andb $0x20, %r11b
orb %cl, %r11b
movzbl (%rsi,%r10), %ecx
movb (%rcx,%rdx), %bl
andb $0x20, %bl
orb %cl, %bl
cmpb %bl, %r11b
jne 0x19a61
incq %r10
cmpq %r10, %r8
jne 0x19a35
jmp 0x19a03
leaq 0x1(%rax), %rcx
incq %rdi
cmpq %r8, %r10
jne 0x19a25
jmp 0x19a03
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::ilastindexof(cstring) const
size_t cstring::ilastindexof(cstring other) const
{
	if (other.length() > this->length()) return -1;
	const char* a = (char*)this->ptr();
	const char* b = (char*)other.ptr();
	
	size_t start=this->length()-other.length();
	while (true)
	{
		size_t i;
		for (i=0;i<other.length();i++)
		{
			if (tolower(a[start+i]) != tolower(b[i])) break;
		}
		if (i==other.length()) return start;
		
		if (start == 0) return -1;
		start--;
	}
}

// Assembly:
pushq %rbx
movq %rsi, -0x10(%rsp)
movq %rdx, -0x8(%rsp)
movq %rdx, %rcx
shrq $0x38, %rcx
xorl $0xf, %ecx
testq %rdx, %rdx
cmovsl %edx, %ecx
movzbl 0xf(%rdi), %r9d
testb %r9b, %r9b
js 0x19aa7
xorl $0xf, %r9d
movq $-0x1, %rax
cmpl %r9d, %ecx
ja 0x19ab7
jmp 0x19abc
movl 0x8(%rdi), %r9d
movq $-0x1, %rax
cmpl %r9d, %ecx
jbe 0x19ab9
popq %rbx
retq
movq (%rdi), %rdi
testq %rdx, %rdx
leaq -0x10(%rsp), %rax
cmovnsq %rax, %rsi
subl %ecx, %r9d
movl %ecx, %edx
addq %r9, %rdi
leaq 0x16279(%rip), %r8      # 0x2fd50
movq %r9, %rax
xorl %r9d, %r9d
testl %ecx, %ecx
je 0x19b0f
movzbl (%rdi,%r9), %r10d
movb (%r10,%r8), %r11b
andb $0x20, %r11b
orb %r10b, %r11b
movzbl (%rsi,%r9), %r10d
movb (%r10,%r8), %bl
andb $0x20, %bl
orb %r10b, %bl
cmpb %bl, %r11b
jne 0x19b0f
incq %r9
cmpq %r9, %rdx
jne 0x19ae1
jmp 0x19ab7
cmpq %rdx, %r9
je 0x19ab7
subq $0x1, %rax
jb 0x19b1f
decq %rdi
jmp 0x19ada
movq $-0x1, %rax
jmp 0x19ab7
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::istartswith(cstring) const
bool cstring::istartswith(cstring other) const
{
	if (other.length() > this->length()) return false;
	const char* a = (char*)this->ptr();
	const char* b = (char*)other.ptr();
	for (size_t i=0;i<other.length();i++)
	{
		if (tolower(a[i]) != tolower(b[i])) return false;
	}
	return true;
}

// Assembly:
movq %rsi, -0x10(%rsp)
movq %rdx, -0x8(%rsp)
movq %rdx, %rax
shrq $0x38, %rax
xorl $0xf, %eax
testq %rdx, %rdx
cmovsl %edx, %eax
movzbl 0xf(%rdi), %ecx
testb %cl, %cl
jns 0x19b62
movl 0x8(%rdi), %r8d
jmp 0x19b69
movl %ecx, %r8d
xorl $0xf, %r8d
cmpl %r8d, %eax
jbe 0x19b71
xorl %eax, %eax
retq
testb %cl, %cl
jns 0x19b78
movq (%rdi), %rdi
testq %rdx, %rdx
leaq -0x10(%rsp), %rcx
cmovnsq %rcx, %rsi
testl %eax, %eax
je 0x19bca
movl %eax, %ecx
decq %rcx
xorl %edx, %edx
leaq 0x161ba(%rip), %r8      # 0x2fd50
movzbl (%rdi,%rdx), %eax
movb (%rax,%r8), %r9b
andb $0x20, %r9b
orb %al, %r9b
movzbl (%rsi,%rdx), %eax
movb (%rax,%r8), %r10b
andb $0x20, %r10b
orb %al, %r10b
cmpb %r10b, %r9b
sete %al
jne 0x19b70
leaq 0x1(%rdx), %r9
cmpq %rdx, %rcx
movq %r9, %rdx
jne 0x19b96
jmp 0x19b70
movb $0x1, %al
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::iendswith(cstring) const
bool cstring::iendswith(cstring other) const
{
	if (other.length() > this->length()) return false;
	const char* a = (char*)this->ptr()+this->length()-other.length();
	const char* b = (char*)other.ptr();
	for (size_t i=0;i<other.length();i++)
	{
		if (tolower(a[i]) != tolower(b[i])) return false;
	}
	return true;
}

// Assembly:
movq %rsi, -0x10(%rsp)
movq %rdx, -0x8(%rsp)
movq %rdx, %rax
shrq $0x38, %rax
xorl $0xf, %eax
testq %rdx, %rdx
cmovsl %edx, %eax
movzbl 0xf(%rdi), %ecx
testb %cl, %cl
js 0x19bf9
xorl $0xf, %ecx
cmpl %ecx, %eax
ja 0x19c00
jmp 0x19c06
movl 0x8(%rdi), %ecx
cmpl %ecx, %eax
jbe 0x19c03
xorl %eax, %eax
retq
movq (%rdi), %rdi
testq %rdx, %rdx
leaq -0x10(%rsp), %rdx
cmovnsq %rdx, %rsi
testl %eax, %eax
je 0x19c60
movl %ecx, %ecx
addq %rcx, %rdi
movl %eax, %ecx
subq %rcx, %rdi
decq %rcx
xorl %edx, %edx
leaq 0x16124(%rip), %r8      # 0x2fd50
movzbl (%rdi,%rdx), %eax
movb (%rax,%r8), %r9b
andb $0x20, %r9b
orb %al, %r9b
movzbl (%rsi,%rdx), %eax
movb (%rax,%r8), %r10b
andb $0x20, %r10b
orb %al, %r10b
cmpb %r10b, %r9b
sete %al
jne 0x19c02
leaq 0x1(%rdx), %r9
cmpq %rdx, %rcx
movq %r9, %rdx
jne 0x19c2c
jmp 0x19c02
movb $0x1, %al
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::csplit(cstring, unsigned long) const
array<cstring> cstring::csplit(cstring sep, size_t limit) const
{
	array<cstring> ret;
	const uint8_t * data = ptr();
	const uint8_t * dataend = ptr()+length();
	
	while (ret.size() < limit)
	{
		const uint8_t * next = (uint8_t*)memmem(data, dataend-data, sep.ptr(), sep.length());
		if (!next) break;
		ret.append(arrayview<uint8_t>(data, next-data));
		data = next+sep.length();
	}
	ret.append(arrayview<uint8_t>(data, dataend-data));
	return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
movq %rdx, 0x8(%rsp)
movq %rcx, 0x10(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movzbl 0xf(%rsi), %eax
movl %eax, %r14d
xorl $0xf, %r14d
testb %al, %al
movq (%rsi), %r12
cmovsl 0x8(%rsi), %r14d
cmovnsq %rsi, %r12
addq %r12, %r14
testq %r8, %r8
je 0x19f88
movq %r8, %r15
movq %rcx, %rax
shrq $0x38, %rax
leaq 0x18(%rsp), %r13
movq %r14, %rsi
subq %r12, %rsi
movl %eax, %edi
xorb $0xf, %dil
testb %al, %al
movq 0x8(%rsp), %rdx
leaq 0x8(%rsp), %rax
cmovnsq %rax, %rdx
movzbl %dil, %eax
cmovsl %ecx, %eax
movq %r12, %rdi
movq %rax, %rcx
callq 0x3e3d
testq %rax, %rax
je 0x19f88
movq %rax, %rbp
movq %rax, %rdx
subq %r12, %rdx
movq %r13, %rdi
movq %r12, %rsi
xorl %ecx, %ecx
callq 0x5990
movq 0x8(%rbx), %rsi
movq %rbx, %rdi
movq %r13, %rdx
callq 0x129a6
movzbl 0x17(%rsp), %eax
movl %eax, %r12d
xorl $0xf, %r12d
movl 0x10(%rsp), %ecx
testb %al, %al
cmovsl %ecx, %r12d
addq %rbp, %r12
cmpq %r15, 0x8(%rbx)
jb 0x19f11
subq %r12, %r14
leaq 0x18(%rsp), %r15
movq %r15, %rdi
movq %r12, %rsi
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x5990
movq 0x8(%rbx), %rsi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x129a6
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::crsplit(cstring, unsigned long) const
array<cstring> cstring::crsplit(cstring sep, size_t limit) const
{
	array<cstring> ret;
	const uint8_t * datastart = ptr();
	const uint8_t * data = ptr()+length();
	
	const uint8_t * sepp = sep.ptr();
	size_t sepl = sep.length();
	
	while (ret.size() < limit)
	{
		if (datastart+sepl > data) break;
		const uint8_t * next = data-sepl;
		while (memcmp(next, sepp, sepl) != 0)
		{
			if (datastart==next) goto done;
			next--;
		}
		ret.insert(0, arrayview<uint8_t>(next+sepl, data-(next+sepl)));
		data = next;
	}
done:
	ret.insert(0, arrayview<uint8_t>(datastart, data-datastart));
	return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rcx, %r12
movq %rdx, %r13
movq %rdi, %rbx
leaq 0x38(%rsp), %rcx
movq %rdx, (%rcx)
movq %r12, 0x8(%rcx)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movzbl 0xf(%rsi), %edx
movl %edx, %eax
xorl $0xf, %eax
testb %dl, %dl
movq (%rsi), %r14
cmovsl 0x8(%rsi), %eax
cmovnsq %rsi, %r14
movq %r12, %rdx
shrq $0x38, %rdx
xorl $0xf, %edx
testq %r12, %r12
cmovnsq %rcx, %r13
leaq (%rax,%r14), %r15
cmovnsl %edx, %r12d
movq %r8, 0x20(%rsp)
testq %r8, %r8
je 0x1a0d5
cmpl %eax, %r12d
ja 0x1a0d5
leaq (%r14,%r12), %rax
movq %rax, 0x10(%rsp)
movq %r12, %rax
negq %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rax
leaq (%r15,%rax), %rbp
movq %rbp, %rdi
movq %r13, %rsi
movq %r12, %rdx
callq 0x3380
testl %eax, %eax
je 0x1a06a
cmpq %r14, %rbp
je 0x1a0d5
decq %rbp
jmp 0x1a04e
leaq (%r12,%rbp), %rsi
subq %rsi, %r15
leaq 0x28(%rsp), %rdi
movq %r15, %rdx
xorl %ecx, %ecx
callq 0x5990
movups 0x28(%rsp), %xmm0
movaps %xmm0, (%rsp)
movq 0x8(%rbx), %rsi
incq %rsi
movq %rbx, %rdi
callq 0x1285c
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
leaq 0x10(%rsi), %rdi
shlq $0x4, %rdx
addq $-0x10, %rdx
callq 0x3600
movq (%rbx), %rax
movaps (%rsp), %xmm0
movups %xmm0, (%rax)
movq 0x20(%rsp), %rax
cmpq %rax, 0x8(%rbx)
jae 0x1a0d8
movq %rbp, %r15
cmpq %rbp, 0x10(%rsp)
jbe 0x1a045
jmp 0x1a0d8
movq %r15, %rbp
subq %r14, %rbp
leaq 0x28(%rsp), %r15
movq %r15, %rdi
movq %r14, %rsi
movq %rbp, %rdx
xorl %ecx, %ecx
callq 0x5990
movups (%r15), %xmm0
movaps %xmm0, (%rsp)
movq 0x8(%rbx), %rsi
incq %rsi
movq %rbx, %rdi
callq 0x1285c
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
leaq 0x10(%rsi), %rdi
shlq $0x4, %rdx
addq $-0x10, %rdx
callq 0x3600
movq (%rbx), %rax
movaps (%rsp), %xmm0
movups %xmm0, (%rax)
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::cspliti(cstring, unsigned long) const
array<cstring> cstring::cspliti(cstring sep, size_t limit) const
{
	array<cstring> ret;
	const uint8_t * data = ptr();
	const uint8_t * dataend = ptr()+length();
	
	while (ret.size() < limit)
	{
		const uint8_t * next = (uint8_t*)memmem(data, dataend-data, sep.ptr(), sep.length());
		if (!next) break;
		ret.append(arrayview<uint8_t>(data, next-data+sep.length()));
		data = next+sep.length();
	}
	if (dataend != data)
		ret.append(arrayview<uint8_t>(data, dataend-data));
	return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, %rbx
movq %rdx, (%rsp)
movq %rcx, 0x8(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movzbl 0xf(%rsi), %eax
movl %eax, %r14d
xorl $0xf, %r14d
testb %al, %al
movq (%rsi), %r12
cmovsl 0x8(%rsi), %r14d
cmovnsq %rsi, %r12
addq %r12, %r14
movq %r8, 0x10(%rsp)
testq %r8, %r8
je 0x1a20d
movq %rcx, %rax
shrq $0x38, %rax
leaq 0x18(%rsp), %rbp
movq %r14, %rsi
subq %r12, %rsi
testb %al, %al
js 0x1a1aa
xorb $0xf, %al
movzbl %al, %r15d
movq %r12, %rdi
movq %rsp, %rdx
jmp 0x1a1b4
movq (%rsp), %rdx
movl %ecx, %r15d
movq %r12, %rdi
movq %r15, %rcx
callq 0x3e3d
testq %rax, %rax
je 0x1a20d
movq %rax, %r13
movq %rax, %rdx
subq %r12, %rdx
addq %r15, %rdx
movq %rbp, %rdi
movq %r12, %rsi
xorl %ecx, %ecx
callq 0x5990
movq 0x8(%rbx), %rsi
movq %rbx, %rdi
movq %rbp, %rdx
callq 0x129a6
movzbl 0xf(%rsp), %eax
movl %eax, %r12d
xorl $0xf, %r12d
movl 0x8(%rsp), %ecx
testb %al, %al
cmovsl %ecx, %r12d
addq %r13, %r12
movq 0x10(%rsp), %rdx
cmpq %rdx, 0x8(%rbx)
jb 0x1a192
subq %r12, %r14
je 0x1a236
leaq 0x18(%rsp), %r15
movq %r15, %rdi
movq %r12, %rsi
movq %r14, %rdx
xorl %ecx, %ecx
callq 0x5990
movq 0x8(%rbx), %rsi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x129a6
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O3/Alcaro[P]bridges/arlib/string.cpp
// Function: cstring::csplit(bool (*)(unsigned char const*, unsigned char const*&, unsigned char const*&), unsigned long) const
array<cstring> cstring::csplit(bool(*find)(const uint8_t * start, const uint8_t * & at, const uint8_t * & end), size_t limit) const
{
	array<cstring> ret;
	
	const uint8_t * data = ptr();
	const uint8_t * dataend = ptr()+length();
	
	const uint8_t * gstart = data;
	const uint8_t * at = gstart;
	
	while (ret.size() < limit && at < dataend)
	{
		const uint8_t * mat = at;
		const uint8_t * mend = dataend;
		if (!find(data, mat, mend) || (gstart == mat && mat == mend))
		{
			at++;
			continue;
		}
		
		ret.append(arrayview<uint8_t>(gstart, mat-gstart));
		gstart = mend;
		at = gstart;
	}
	ret.append(arrayview<uint8_t>(gstart, dataend-gstart));
	return ret;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %r14
movq %rdx, 0x10(%rsp)
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movzbl 0xf(%rsi), %ecx
movl %ecx, %eax
xorl $0xf, %eax
testb %cl, %cl
movq (%rsi), %r15
cmovsl 0x8(%rsi), %eax
cmovnsq %rsi, %r15
leaq (%rax,%r15), %r12
testq %r14, %r14
je 0x1a4ef
testl %eax, %eax
je 0x1a4ef
movq %r15, %r13
movq %r15, %rbp
movq %r13, 0x8(%rsp)
movq %r12, (%rsp)
movq %r15, %rdi
leaq 0x8(%rsp), %rsi
movq %rsp, %rdx
callq *0x10(%rsp)
testb %al, %al
je 0x1a4b2
movq 0x8(%rsp), %rdx
cmpq %rdx, %rbp
jne 0x1a4b7
cmpq (%rsp), %rdx
jne 0x1a4b7
incq %r13
jmp 0x1a4e2
subq %rbp, %rdx
leaq 0x18(%rsp), %r13
movq %r13, %rdi
movq %rbp, %rsi
xorl %ecx, %ecx
callq 0x5990
movq 0x8(%rbx), %rsi
movq %rbx, %rdi
movq %r13, %rdx
callq 0x129a6
movq (%rsp), %rbp
movq %rbp, %r13
cmpq %r14, 0x8(%rbx)
jae 0x1a4f2
cmpq %r12, %r13
jb 0x1a486
jmp 0x1a4f2
movq %r15, %rbp
subq %rbp, %r12
leaq 0x18(%rsp), %r14
movq %r14, %rdi
movq %rbp, %rsi
movq %r12, %rdx
xorl %ecx, %ecx
callq 0x5990
movq 0x8(%rbx), %rsi
movq %rbx, %rdi
movq %r14, %rdx
callq 0x129a6
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq