// File: /workspace/github_c_makefile_star2_O3/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: lh_record_insert
static int lh_record_insert(
	  unqlite_kv_engine *pKv,         /* KV store */
	  const void *pKey,sxu32 nKeyLen, /* Payload: Key */
	  const void *pData,unqlite_int64 nDataLen, /* Payload: data */
	  int is_append /* True for an append operation */
	  )
{
	lhash_kv_engine *pEngine = (lhash_kv_engine *)pKv;
	lhash_bmap_rec *pRec;
	unqlite_page *pRaw;
	lhpage *pPage;
	lhcell *pCell;
	pgno iBucket;
	sxu32 nHash;
	int iCnt;
	int rc;

	/* Acquire the first page (DB hash Header) so that everything gets loaded autmatically */
	rc = pEngine->pIo->xGet(pEngine->pIo->pHandle,1,0);
	if( rc != UNQLITE_OK ){
		return rc;
	}
	iCnt = 0;
	/* Compute the hash of the key first */
	nHash = pEngine->xHash(pKey,(sxu32)nKeyLen);
retry:
	/* Extract the logical bucket number */
	iBucket = nHash & (pEngine->nmax_split_nucket - 1);
	if( iBucket >= pEngine->split_bucket + pEngine->max_split_bucket ){
		/* Low mask */
		iBucket = nHash & (pEngine->max_split_bucket - 1);
	}
	/* Map the logical bucket number to real page number */
	pRec = lhMapFindBucket(pEngine,iBucket);
	if( pRec == 0 ){
		/* Request a new page */
		rc = lhAcquirePage(pEngine,&pRaw);
		if( rc != UNQLITE_OK ){
			return rc;
		}
		/* Initialize the page */
		pPage = lhNewPage(pEngine,pRaw,0);
		if( pPage == 0 ){
			return UNQLITE_NOMEM;
		}
		/* Mark as an empty page */
		rc = lhSetEmptyPage(pPage);
		if( rc != UNQLITE_OK ){
			pEngine->pIo->xPageUnref(pRaw); /* pPage will be released during this call */
			return rc;
		}
		/* Store the cell */
		rc = lhStoreCell(pPage,pKey,nKeyLen,pData,nDataLen,nHash,1);
		if( rc == UNQLITE_OK ){
			/* Install and write the logical map record */
			rc = lhMapWriteRecord(pEngine,iBucket,pRaw->iPage);
		}
		pEngine->pIo->xPageUnref(pRaw);
		return rc;
	}else{
		/* Load the page */
		rc = lhLoadPage(pEngine,pRec->iReal,0,&pPage,0);
		if( rc != UNQLITE_OK ){
			/* IO error, unlikely scenario */
			return rc;
		}
		/* Do not add this page to the hot dirty list */
		pEngine->pIo->xDontMkHot(pPage->pRaw);
		/* Lookup for the cell */
		pCell = lhFindCell(pPage,pKey,(sxu32)nKeyLen,nHash);
		if( pCell == 0 ){
			/* Create the record */
			rc = lhRecordInstall(pPage,nHash,pKey,nKeyLen,pData,nDataLen);
			if( rc == SXERR_RETRY && iCnt++ < 2 ){
				rc = UNQLITE_OK;
				goto retry;
			}
		}else{
			if( is_append ){
				/* Append operation */
				rc = lhRecordAppend(pCell,pData,nDataLen);
			}else{
				/* Overwrite old value */
				rc = lhRecordOverwrite(pCell,pData,nDataLen);
			}
		}
		pEngine->pIo->xPageUnref(pPage->pRaw);
	}
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movl %r9d, -0x40(%rbp)
movq %r8, %r12
movq %rcx, %r13
movl %edx, %r14d
movq %rsi, %r15
movq %rdi, %rbx
movq (%rdi), %rax
movq (%rax), %rdi
movl $0x1, %esi
xorl %edx, %edx
callq *0x10(%rax)
testl %eax, %eax
jne 0x376b4
movq %r13, -0x58(%rbp)
movq %r12, -0x50(%rbp)
movl $0xffffffff, %r13d      # imm = 0xFFFFFFFF
movq %r15, -0x60(%rbp)
movq %r15, %rdi
movl %r14d, -0x48(%rbp)
movl %r14d, %esi
callq *0xc0(%rbx)
movl %eax, %r14d
movl 0x130(%rbx), %ecx
addl %r13d, %ecx
andl %eax, %ecx
movq 0x128(%rbx), %r12
movq 0x120(%rbx), %rdx
addq %r12, %rdx
addl %r13d, %r12d
andl %eax, %r12d
cmpq %rdx, %rcx
cmovbq %rcx, %r12
cmpl $0x0, 0xe0(%rbx)
je 0x3762f
xorl %r13d, %r13d
leaq -0x88(%rbp), %r15
movq 0xd8(%rbx), %rax
movl 0xe4(%rbx), %ecx
decl %ecx
andl %r12d, %ecx
movq (%rax,%rcx,8), %rax
testq %rax, %rax
je 0x3762f
cmpq %r12, (%rax)
je 0x372c8
movq 0x20(%rax), %rax
jmp 0x372b4
movq 0x8(%rax), %rsi
movq %rbx, %rdi
xorl %edx, %edx
movq %r15, %rcx
callq 0x3833b
testl %eax, %eax
jne 0x376b4
movq %rbx, -0x30(%rbp)
movq (%rbx), %rax
movq -0x88(%rbp), %rcx
movq 0x8(%rcx), %rdi
callq *0x40(%rax)
movq -0x88(%rbp), %rdi
movq -0x60(%rbp), %rbx
movq %rbx, %rsi
movq %r14, %r12
movl -0x48(%rbp), %r14d
movl %r14d, %edx
movl %r12d, %ecx
callq 0x385ca
testq %rax, %rax
jne 0x376c6
movq %r13, -0xa8(%rbp)
movq -0x88(%rbp), %r13
movl $0x0, (%rsp)
movq %r13, %rdi
movq %rbx, %rsi
movl %r14d, %edx
movq -0x58(%rbp), %rcx
movq -0x50(%rbp), %r8
movl %r12d, %r9d
callq 0x37f67
cmpl $-0x49, %eax
movq -0x30(%rbp), %rbx
movq %r12, %r14
jne 0x37496
movq (%r13), %r12
movl $0xffffffe8, %eax       # imm = 0xFFFFFFE8
cmpl $0x0, 0xe0(%r12)
je 0x37496
movq 0x120(%r12), %rsi
movq 0xd8(%r12), %rcx
movl 0xe4(%r12), %edx
decl %edx
andl %esi, %edx
movq (%rcx,%rdx,8), %rcx
testq %rcx, %rcx
je 0x37496
cmpq %rsi, (%rcx)
je 0x373a9
movq 0x20(%rcx), %rcx
jmp 0x37395
movq 0x8(%rcx), %rsi
movq %r12, %rdi
xorl %edx, %edx
leaq -0x80(%rbp), %rcx
callq 0x3833b
testl %eax, %eax
jne 0x37496
movq %r12, %rdi
leaq -0x38(%rbp), %rsi
callq 0x37ddc
testl %eax, %eax
jne 0x37496
movq %r13, -0x90(%rbp)
movq %r12, %rdi
movq -0x38(%rbp), %r12
movq %rdi, %r13
movq %r12, %rsi
xorl %edx, %edx
callq 0x37e75
testq %rax, %rax
je 0x37491
movq %rax, -0x98(%rbp)
movq %rax, %rdi
callq 0x37eed
testl %eax, %eax
jne 0x37477
movq %r13, %rdi
movq 0x128(%r13), %rsi
addq 0x120(%r13), %rsi
movq 0x10(%r12), %rdx
callq 0x3814c
testl %eax, %eax
jne 0x37477
movq -0x90(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x10(%rax), %rax
movq %rax, -0xa0(%rbp)
movq -0x80(%rbp), %rax
movq (%rax), %rdi
movq 0x8(%rax), %rcx
movq 0x10(%rcx), %r12
movq 0x120(%r13), %rcx
movq 0x130(%r13), %r8
decq %r8
movq 0x28(%rax), %rsi
movq -0x98(%rbp), %rdx
callq 0x392e7
testl %eax, %eax
je 0x374f3
movl %eax, %r12d
movq (%r13), %rax
movq -0x98(%rbp), %rcx
movq 0x8(%rcx), %rdi
callq *0x50(%rax)
movl %r12d, %eax
jmp 0x37496
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
cmpl $-0x21, %eax
jne 0x37d77
movq -0xa8(%rbp), %r13
cmpl $0x2, %r13d
je 0x37709
incl %r13d
movl 0x130(%rbx), %eax
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
addl %edx, %eax
andl %r14d, %eax
movq 0x128(%rbx), %r12
movq 0x120(%rbx), %rcx
addq %r12, %rcx
addl %edx, %r12d
andl %r14d, %r12d
cmpq %rcx, %rax
cmovbq %rax, %r12
cmpl $0x0, 0xe0(%rbx)
jne 0x3729e
jmp 0x3762f
incq 0x120(%r13)
movq (%r13), %rax
movq 0xd0(%r13), %rdi
callq *0x28(%rax)
testl %eax, %eax
jne 0x37496
movq 0x120(%r13), %rax
cmpq 0x128(%r13), %rax
jae 0x37554
movq 0xd0(%r13), %rcx
movq (%rcx), %rdx
leaq 0x10(%rdx), %rcx
movl %eax, %esi
bswapl %esi
movl %esi, 0x14(%rdx)
movq %rax, %rsi
shrq $0x20, %rsi
movb %sil, 0x13(%rdx)
movq %rax, %rsi
shrq $0x28, %rsi
movb %sil, 0x12(%rdx)
movq %rax, %rsi
shrq $0x30, %rsi
movb %sil, 0x11(%rdx)
jmp 0x375cc
movq $0x0, 0x120(%r13)
movq 0x130(%r13), %rax
movq %rax, 0x128(%r13)
addq %rax, %rax
movq %rax, 0x130(%r13)
je 0x3760d
movq 0xd0(%r13), %rax
movq (%rax), %rax
movq $0x0, 0x10(%rax)
movq 0xd0(%r13), %rcx
movq 0x128(%r13), %rax
movq (%rcx), %rdx
leaq 0x18(%rdx), %rcx
movl %eax, %esi
bswapl %esi
movl %esi, 0x1c(%rdx)
movq %rax, %rsi
shrq $0x20, %rsi
movb %sil, 0x1b(%rdx)
movq %rax, %rsi
shrq $0x28, %rsi
movb %sil, 0x1a(%rdx)
movq %rax, %rsi
shrq $0x30, %rsi
movb %sil, 0x19(%rdx)
shrq $0x38, %rax
movb %al, (%rcx)
cmpq %r12, -0xa0(%rbp)
movq -0x50(%rbp), %r8
movl -0x48(%rbp), %edx
movq -0x60(%rbp), %rsi
movq -0x30(%rbp), %rbx
je 0x3749f
movl $0x1, (%rsp)
movq -0x90(%rbp), %rdi
movq -0x58(%rbp), %rcx
movl %r14d, %r9d
callq 0x37f67
jmp 0x37496
movq (%r13), %rax
movq (%rax), %rdi
leaq 0x3c2dc(%rip), %rsi     # 0x738f7
callq *0x80(%rax)
movl $0xfffffff9, %eax       # imm = 0xFFFFFFF9
movq -0x30(%rbp), %rbx
jmp 0x37496
leaq -0x80(%rbp), %rsi
movq %rbx, %rdi
callq 0x37ddc
testl %eax, %eax
jne 0x376b4
movq -0x80(%rbp), %r13
movq %rbx, %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x37e75
movq %rax, -0x88(%rbp)
testq %rax, %rax
je 0x376af
movq %rax, %rdi
callq 0x37eed
testl %eax, %eax
jne 0x376a0
movq -0x88(%rbp), %rdi
movl $0x1, (%rsp)
movq -0x60(%rbp), %rsi
movl -0x48(%rbp), %edx
movq -0x58(%rbp), %rcx
movq -0x50(%rbp), %r8
movl %r14d, %r9d
callq 0x37f67
testl %eax, %eax
jne 0x376a0
movq 0x10(%r13), %rdx
movq %rbx, %rdi
movq %r12, %rsi
callq 0x3814c
movq (%rbx), %rcx
movq %r13, %rdi
movl %eax, %ebx
callq *0x50(%rcx)
movl %ebx, %eax
jmp 0x376b4
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x20(%rax), %r14
movq (%r14), %rbx
cmpl $0x0, -0x40(%rbp)
movq -0x50(%rbp), %r12
je 0x37713
movq 0x8(%rax), %rcx
movq %rbx, -0x40(%rbp)
movq (%rbx), %rdx
addq %r12, %rcx
movq -0x58(%rbp), %r13
jae 0x378d6
movq (%rdx), %rdi
leaq 0x3c18c(%rip), %rsi     # 0x73885
callq *0x80(%rdx)
movl $0xfffffff9, %eax       # imm = 0xFFFFFFF9
jmp 0x37d73
movl $0xffffffdf, %eax       # imm = 0xFFFFFFDF
jmp 0x37d77
movq %rax, -0x48(%rbp)
movq (%rbx), %rax
movq 0x8(%r14), %rdi
callq *0x28(%rax)
testl %eax, %eax
movq -0x58(%rbp), %r13
jne 0x37d73
movq %rbx, -0x40(%rbp)
movq -0x48(%rbp), %rbx
cmpq $0x0, 0x18(%rbx)
je 0x379c1
movq -0x40(%rbp), %r13
movq (%r13), %rax
movq (%rax), %rdi
movq 0x30(%rbx), %rsi
leaq -0x80(%rbp), %rdx
callq *0x10(%rax)
testl %eax, %eax
jne 0x37d73
movq -0x80(%rbp), %rdi
movq (%rdi), %rbx
movq (%rbx), %r12
bswapq %r12
movq %rdi, -0x38(%rbp)
testq %r12, %r12
je 0x377c1
leaq -0x38(%rbp), %rbx
movq (%r13), %rax
movq (%rax), %rdi
movq %r12, %rsi
movq %rbx, %rdx
callq *0x10(%rax)
movq -0x80(%rbp), %rdi
testl %eax, %eax
jne 0x377be
movq -0x38(%rbp), %rsi
movq (%rsi), %rax
movq (%rax), %r12
cmpq %rdi, %rsi
je 0x377b2
movq %r13, %rdi
callq 0x3981a
movq (%r13), %rax
movq -0x38(%rbp), %rdi
callq *0x50(%rax)
bswapq %r12
testq %r12, %r12
jne 0x37778
movq -0x80(%rbp), %rdi
movq (%rdi), %rbx
movq -0x48(%rbp), %rax
movzwl 0x38(%rax), %r12d
movq %r13, %rax
movslq 0x110(%r13), %r13
movq (%rax), %rax
callq *0x28(%rax)
testl %eax, %eax
jne 0x37d73
movq %r14, -0x60(%rbp)
movq -0x80(%rbp), %rax
movq (%rax), %rax
movq $0x0, (%rax)
cmpq $0x0, -0x50(%rbp)
jle 0x378bb
movq -0x50(%rbp), %rax
movq -0x58(%rbp), %rcx
leaq (%rcx,%rax), %r15
addq %rbx, %r12
addq %rbx, %r13
cmpq %r13, %r12
jb 0x37886
movq -0x40(%rbp), %rbx
movq %rbx, %rdi
leaq -0xb0(%rbp), %rsi
callq 0x37ddc
testl %eax, %eax
jne 0x37d73
movq (%rbx), %rax
movq -0xb0(%rbp), %r12
movq %r12, %rdi
callq *0x28(%rax)
testl %eax, %eax
jne 0x37d73
movq -0x80(%rbp), %rax
movq 0x10(%r12), %rcx
bswapq %rcx
movq (%rax), %rax
movq %rcx, (%rax)
movq (%rbx), %rax
movq -0x80(%rbp), %rdi
callq *0x50(%rax)
movq (%r12), %rax
movq $0x0, (%rax)
movq %r12, -0x80(%rbp)
movq (%r12), %rax
leaq 0x8(%rax), %r12
movslq 0x110(%rbx), %r13
addq %rax, %r13
movl %r13d, %eax
subl %r12d, %eax
movl %r15d, %ebx
movq -0x58(%rbp), %r14
subl %r14d, %ebx
cmpl %eax, %ebx
cmovael %eax, %ebx
movq %r14, %rdi
movq %r12, %rsi
movl %ebx, %edx
callq 0x34893
addq %rbx, %r14
addq %rbx, %r12
movq %r14, -0x58(%rbp)
cmpq %r15, %r14
jb 0x37811
movq -0x40(%rbp), %rax
movq (%rax), %rax
movq -0x80(%rbp), %rdi
callq *0x50(%rax)
movq -0x50(%rbp), %rdx
movq -0x48(%rbp), %rcx
jmp 0x37c70
movq %rax, -0x48(%rbp)
movq 0x8(%r14), %rdi
callq *0x28(%rdx)
testl %eax, %eax
jne 0x37d73
movq %r14, -0x60(%rbp)
movq -0x48(%rbp), %r14
cmpq $0x0, 0x18(%r14)
je 0x379f4
movq -0x40(%rbp), %rbx
movq (%rbx), %rax
movq (%rax), %rdi
movq 0x30(%r14), %rsi
leaq -0x80(%rbp), %rdx
callq *0x10(%rax)
testl %eax, %eax
jne 0x37d73
movq -0x80(%rbp), %rdi
movq %rbx, %rax
movq (%rdi), %r13
movq (%r13), %rbx
bswapq %rbx
movzwl 0x38(%r14), %ecx
leaq (%rcx,%r13), %r12
movslq 0x110(%rax), %rax
addq %rax, %r13
movq 0x8(%r14), %r15
subl %ecx, %eax
movq -0x40(%rbp), %r14
cmpq %r13, %r12
jb 0x379ab
movq (%r14), %rax
movq (%rax), %rdi
testq %rbx, %rbx
je 0x37d25
movq %rbx, %rsi
leaq -0x38(%rbp), %rdx
callq *0x10(%rax)
testl %eax, %eax
jne 0x37d73
movq -0x38(%rbp), %rax
movq (%rax), %rax
movq (%rax), %rbx
bswapq %rbx
movq (%r14), %rax
movq -0x80(%rbp), %rdi
callq *0x50(%rax)
movq -0x38(%rbp), %rdi
movq (%rdi), %r13
leaq 0x8(%r13), %r12
movq -0x48(%rbp), %rax
movq 0x20(%rax), %rax
movq (%rax), %rax
movslq 0x110(%rax), %rax
addq %rax, %r13
addl $-0x8, %eax
movq %rdi, -0x80(%rbp)
movl %eax, %edx
movq %r15, %rcx
subq %rdx, %rcx
jb 0x37b80
addq %rdx, %r12
movq %rcx, %r15
jmp 0x37947
movq 0x8(%r14), %rcx
movzwl 0x28(%rbx), %eax
movl 0x4(%rbx), %edx
leal (%rdx,%rax), %esi
addl $0x1a, %esi
movl %edx, %eax
addl $0x1a, %eax
addq (%rcx), %rsi
cmpq %r12, 0x8(%rbx)
jne 0x37aad
movq %r13, %rdi
movl %r12d, %edx
callq 0x34893
jmp 0x37d71
leaq -0x38(%rbp), %rdx
movw $0x0, (%rdx)
movl 0x4(%r14), %eax
addl $0x1a, %eax
movq 0x8(%r14), %rsi
addq %r12, %rsi
addq %rax, %rsi
movq -0x60(%rbp), %rbx
movq %rbx, %rdi
callq 0x38687
testl %eax, %eax
je 0x37b01
movq 0x8(%rbx), %rax
movq (%rax), %rax
movzwl 0x28(%r14), %ecx
leaq (%rax,%rcx), %rsi
addq $0x1a, %rsi
addq $0x1a, %rcx
movl 0x4(%r14), %edx
addl %edx, %ecx
addq %rax, %rcx
movq 0x8(%r14), %r8
movq %r12, (%rsp)
movq $0x0, 0x8(%rsp)
movq %r14, %rdi
movq %r13, %r9
xorl %eax, %eax
callq 0x38b94
testl %eax, %eax
jne 0x37d73
movq 0x8(%rbx), %rax
movq (%rax), %rax
movzwl 0x28(%r14), %ecx
movq 0x8(%r14), %rdx
addq %r12, %rdx
bswapq %rdx
movq %rdx, 0x8(%rax,%rcx)
movl 0x8(%r14), %edx
movl 0x28(%r14), %esi
addl 0x4(%r14), %edx
addl $0x1a, %esi
movl $0xffff, %eax           # imm = 0xFFFF
andl %eax, %esi
andl %eax, %edx
movq %rbx, %rdi
callq 0x396eb
addq %r12, 0x8(%r14)
jmp 0x37d71
jbe 0x37c90
movq %r13, %rdi
movl %r12d, %edx
callq 0x34893
movq 0x8(%r14), %rax
movq (%rax), %rax
movzwl 0x28(%rbx), %ecx
movq %r12, %rdx
bswapq %rdx
movq %rdx, 0x8(%rax,%rcx)
movl 0x8(%rbx), %edx
movl 0x28(%rbx), %eax
addl 0x4(%rbx), %eax
leal (%r12,%rax), %esi
addl $0x1a, %esi
subl %r12d, %edx
movl $0xffff, %eax           # imm = 0xFFFF
andl %eax, %esi
andl %eax, %edx
movq %r14, %rdi
callq 0x396eb
movq %r12, 0x8(%rbx)
jmp 0x37d71
movzwl 0x28(%r14), %r13d
movl 0x8(%r14), %r12d
movq -0x40(%rbp), %rax
addq $0x8, %rax
xorps %xmm0, %xmm0
leaq -0x80(%rbp), %rdi
movups %xmm0, 0x8(%rdi)
movq %rax, (%rdi)
movl $0x0, 0x18(%rdi)
movq 0x8(%rbx), %rax
movl 0x4(%r14), %ecx
leal (%rcx,%r13), %esi
addl $0x1a, %esi
addq (%rax), %rsi
movl %r12d, %edx
callq 0x359ad
testl %eax, %eax
jne 0x37b5e
leaq -0x80(%rbp), %rdi
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
callq 0x359ad
testl %eax, %eax
je 0x37d8f
movl %eax, %ebx
testb $0x6, -0x68(%rbp)
jne 0x37b79
cmpl $0x0, -0x6c(%rbp)
je 0x37b79
movq -0x80(%rbp), %rdi
movq -0x78(%rbp), %rsi
callq 0x3490d
movl %ebx, %eax
jmp 0x37d73
movq -0x40(%rbp), %rax
movq (%rax), %rax
callq *0x28(%rax)
testl %eax, %eax
jne 0x37d73
cmpq $0x0, -0x50(%rbp)
jle 0x37c56
addq %r15, %r12
movq -0x50(%rbp), %rax
movq -0x58(%rbp), %rcx
leaq (%rcx,%rax), %r15
cmpq %r13, %r12
jb 0x37c21
movq -0x40(%rbp), %rbx
movq %rbx, %rdi
leaq -0x38(%rbp), %rsi
callq 0x37ddc
testl %eax, %eax
jne 0x37d73
movq (%rbx), %rax
movq -0x38(%rbp), %rdi
callq *0x28(%rax)
testl %eax, %eax
jne 0x37d73
movq -0x80(%rbp), %rax
movq -0x38(%rbp), %rcx
movq 0x10(%rcx), %rcx
bswapq %rcx
movq (%rax), %rax
movq %rcx, (%rax)
movq (%rbx), %rax
movq -0x80(%rbp), %rdi
callq *0x50(%rax)
movq -0x38(%rbp), %rax
movq (%rax), %rax
movq $0x0, (%rax)
movq -0x38(%rbp), %rax
movq %rax, -0x80(%rbp)
movq (%rax), %rax
leaq 0x8(%rax), %r12
movslq 0x110(%rbx), %r13
addq %rax, %r13
movl %r13d, %eax
subl %r12d, %eax
movl %r15d, %ebx
movq -0x58(%rbp), %r14
subl %r14d, %ebx
cmpl %eax, %ebx
cmovael %eax, %ebx
movq %r14, %rdi
movq %r12, %rsi
movl %ebx, %edx
callq 0x34893
addq %rbx, %r14
addq %rbx, %r12
movq %r14, -0x58(%rbp)
cmpq %r15, %r14
jb 0x37bac
movq -0x40(%rbp), %rax
movq (%rax), %rax
movq -0x80(%rbp), %rdi
callq *0x50(%rax)
movq -0x50(%rbp), %rdx
movq -0x48(%rbp), %rcx
addq 0x8(%rcx), %rdx
movq %rdx, 0x8(%rcx)
movq -0x60(%rbp), %rax
movq 0x8(%rax), %rax
movq (%rax), %rax
movzwl 0x28(%rcx), %ecx
bswapq %rdx
movq %rdx, 0x8(%rax,%rcx)
jmp 0x37d71
leaq -0x80(%rbp), %rdx
movw $0x0, (%rdx)
movl %eax, %esi
addq %r12, %rsi
movq %r14, %rdi
callq 0x38687
testl %eax, %eax
je 0x37d39
movq %r14, -0x60(%rbp)
movq 0x8(%r14), %rax
movq (%rax), %rax
movzwl 0x28(%rbx), %ecx
leaq (%rax,%rcx), %rsi
addq $0x1a, %rsi
movl 0x4(%rbx), %edx
movq %rbx, %rdi
movq %r13, %rcx
movq %r12, %r8
xorl %r9d, %r9d
xorl %eax, %eax
callq 0x38b94
testl %eax, %eax
jne 0x37d73
movq -0x60(%rbp), %rdi
movq 0x8(%rdi), %rax
movq (%rax), %rax
movq -0x48(%rbp), %rbx
movzwl 0x28(%rbx), %ecx
movq -0x50(%rbp), %r14
movq %r14, %rdx
bswapq %rdx
movq %rdx, 0x8(%rax,%rcx)
movl 0x8(%rbx), %edx
movl 0x28(%rbx), %esi
addl 0x4(%rbx), %edx
addl $0x1a, %esi
movl $0xffff, %eax           # imm = 0xFFFF
andl %eax, %esi
andl %eax, %edx
callq 0x396eb
movq %r14, 0x8(%rbx)
jmp 0x37d71
leaq 0x3bbf8(%rip), %rsi     # 0x73924
callq *0x80(%rax)
movl $0xffffffe8, %eax       # imm = 0xFFFFFFE8
jmp 0x37d73
movzwl 0x28(%rbx), %r15d
movl 0x8(%rbx), %eax
movq %rax, -0x40(%rbp)
movzwl -0x80(%rbp), %esi
movq %rbx, %rdi
movq %r13, %rdx
movq %r12, %rcx
callq 0x3972f
movl 0x4(%rbx), %eax
movq -0x40(%rbp), %rcx
addl %ecx, %eax
addl $0x1a, %eax
movzwl %ax, %edx
movq %r14, %rdi
movl %r15d, %esi
callq 0x396eb
xorl %eax, %eax
movq -0x30(%rbp), %rbx
movq (%rbx), %rdx
movq -0x88(%rbp), %rcx
movq 0x8(%rcx), %rdi
movl %eax, %ebx
callq *0x50(%rdx)
jmp 0x376ab
movzwl -0x38(%rbp), %esi
movq -0x78(%rbp), %r14
movl -0x70(%rbp), %ecx
movq -0x48(%rbp), %rbx
movq %rbx, %rdi
movq %r14, %rdx
callq 0x3972f
movl 0x4(%rbx), %eax
addl %r12d, %eax
addl $0x1a, %eax
movzwl %ax, %edx
movzwl %r13w, %esi
movq -0x60(%rbp), %rdi
callq 0x396eb
testb $0x6, -0x68(%rbp)
jne 0x37d71
cmpl $0x0, -0x6c(%rbp)
je 0x37d71
movq -0x80(%rbp), %rdi
movq %r14, %rsi
callq 0x3490d
jmp 0x37d71