LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_store
int unqlite_kv_store(unqlite *pDb,const void *pKey,int nKeyLen,const void *pData,unqlite_int64 nDataLen)
{
	unqlite_kv_engine *pEngine;
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Point to the underlying storage engine */
	 pEngine = unqlitePagerGetKvEngine(pDb);
	 if( pEngine->pIo->pMethods->xReplace == 0 ){
		 /* Storage engine does not implement such method */
		 unqliteGenError(pDb,"xReplace() method not implemented in the underlying storage engine");
		 rc = UNQLITE_NOTIMPLEMENTED;
	 }else{
		 if( nKeyLen < 0 ){
			 /* Assume a null terminated string and compute it's length */
			 nKeyLen = SyStrlen((const char *)pKey);
		 }
		 if( !nKeyLen ){
			 unqliteGenError(pDb,"Empty key");
			 rc = UNQLITE_EMPTY;
		 }else{
			 /* Perform the requested operation */
			 rc = pEngine->pIo->pMethods->xReplace(pEngine,pKey,nKeyLen,pData,nDataLen);
		 }
	 }
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
pushq $-0x18
popq %r14
testq %rdi, %rdi
je 0x2a530
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2a530
movq %rcx, %r15
movl %edx, %r13d
movq %rsi, %r12
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2a488
movq 0x5d319(%rip), %rax     # 0x87798
movq %r8, %r14
callq *0x20(%rax)
movq %r14, %r8
cmpl $0x2, 0x5d319(%rip)     # 0x877a8
jb 0x2a49d
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2a501
movq 0xd8(%rbx), %rax
movq 0x10(%rax), %r14
movq (%r14), %rax
movq 0x8(%rax), %rax
movq 0x38(%rax), %rax
testq %rax, %rax
je 0x2a4ee
testl %r13d, %r13d
jns 0x2a4d6
movq %r12, %rdi
movq %r8, %r13
movq %rax, -0x30(%rbp)
callq 0x28e24
movq %r13, %r8
movl %eax, %r13d
movq -0x30(%rbp), %rax
testl %r13d, %r13d
je 0x2a507
movq %r14, %rdi
movq %r12, %rsi
movl %r13d, %edx
movq %r15, %rcx
callq *%rax
movl %eax, %r14d
jmp 0x2a51a
leaq 0x39206(%rip), %rsi     # 0x636fb
movq %rbx, %rdi
callq 0x2a542
pushq $-0x11
jmp 0x2a518
pushq $-0xa
popq %r14
jmp 0x2a530
leaq 0x39230(%rip), %rsi     # 0x6373e
movq %rbx, %rdi
callq 0x2a542
pushq $-0x3
popq %r14
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2a530
movq 0x5d26b(%rip), %rax     # 0x87798
callq *0x30(%rax)
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: SyBlobRelease
JX9_PRIVATE sxi32 SyBlobRelease(SyBlob *pBlob)
{
	if( (pBlob->nFlags & (SXBLOB_STATIC|SXBLOB_RDONLY)) == 0 && pBlob->mByte > 0 ){
		SyMemBackendFree(pBlob->pAllocator, pBlob->pBlob);
	}
	pBlob->pBlob = 0;
	pBlob->nByte = pBlob->mByte = 0;
	pBlob->nFlags = 0;
	return SXRET_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
testb $0x6, 0x18(%rdi)
jne 0x2a750
cmpl $0x0, 0x14(%rbx)
je 0x2a750
movq (%rbx), %rdi
movq 0x8(%rbx), %rsi
callq 0x2d420
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rbx)
andl $0x0, 0x18(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_append
int unqlite_kv_append(unqlite *pDb,const void *pKey,int nKeyLen,const void *pData,unqlite_int64 nDataLen)
{
	unqlite_kv_engine *pEngine;
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Point to the underlying storage engine */
	 pEngine = unqlitePagerGetKvEngine(pDb);
	 if( pEngine->pIo->pMethods->xAppend == 0 ){
		 /* Storage engine does not implement such method */
		 unqliteGenError(pDb,"xAppend() method not implemented in the underlying storage engine");
		 rc = UNQLITE_NOTIMPLEMENTED;
	 }else{
		 if( nKeyLen < 0 ){
			 /* Assume a null terminated string and compute it's length */
			 nKeyLen = SyStrlen((const char *)pKey);
		 }
		 if( !nKeyLen ){
			 unqliteGenError(pDb,"Empty key");
			 rc = UNQLITE_EMPTY;
		 }else{
			 /* Perform the requested operation */
			 rc = pEngine->pIo->pMethods->xAppend(pEngine,pKey,nKeyLen,pData,nDataLen);
		 }
	 }
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
pushq $-0x18
popq %r14
testq %rdi, %rdi
je 0x2a85d
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2a85d
movq %rcx, %r15
movl %edx, %r13d
movq %rsi, %r12
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2a7b5
movq 0x5cfec(%rip), %rax     # 0x87798
movq %r8, %r14
callq *0x20(%rax)
movq %r14, %r8
cmpl $0x2, 0x5cfec(%rip)     # 0x877a8
jb 0x2a7ca
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2a82e
movq 0xd8(%rbx), %rax
movq 0x10(%rax), %r14
movq (%r14), %rax
movq 0x8(%rax), %rax
movq 0x40(%rax), %rax
testq %rax, %rax
je 0x2a81b
testl %r13d, %r13d
jns 0x2a803
movq %r12, %rdi
movq %r8, %r13
movq %rax, -0x30(%rbp)
callq 0x28e24
movq %r13, %r8
movl %eax, %r13d
movq -0x30(%rbp), %rax
testl %r13d, %r13d
je 0x2a834
movq %r14, %rdi
movq %r12, %rsi
movl %r13d, %edx
movq %r15, %rcx
callq *%rax
movl %eax, %r14d
jmp 0x2a847
leaq 0x38f26(%rip), %rsi     # 0x63748
movq %rbx, %rdi
callq 0x2a542
pushq $-0x11
jmp 0x2a845
pushq $-0xa
popq %r14
jmp 0x2a85d
leaq 0x38f03(%rip), %rsi     # 0x6373e
movq %rbx, %rdi
callq 0x2a542
pushq $-0x3
popq %r14
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2a85d
movq 0x5cf3e(%rip), %rax     # 0x87798
callq *0x30(%rax)
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_fetch_callback
int unqlite_kv_fetch_callback(unqlite *pDb,const void *pKey,int nKeyLen,int (*xConsumer)(const void *,unsigned int,void *),void *pUserData)
{
	unqlite_kv_methods *pMethods;
	unqlite_kv_engine *pEngine;
	unqlite_kv_cursor *pCur;
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Point to the underlying storage engine */
	 pEngine = unqlitePagerGetKvEngine(pDb);
	 pMethods = pEngine->pIo->pMethods;
	 pCur = pDb->sDB.pCursor;
	 if( nKeyLen < 0 ){
		 /* Assume a null terminated string and compute it's length */
		 nKeyLen = SyStrlen((const char *)pKey);
	 }
	 if( !nKeyLen ){
		 unqliteGenError(pDb,"Empty key");
		 rc = UNQLITE_EMPTY;
	 }else{
		 /* Seek to the record position */
		 rc = pMethods->xSeek(pCur,pKey,nKeyLen,UNQLITE_CURSOR_MATCH_EXACT);
	 }
	 if( rc == UNQLITE_OK && xConsumer ){
		 /* Consume the data directly */
		 rc = pMethods->xData(pCur,xConsumer,pUserData);	 
	 }
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
pushq $-0x18
popq %r14
testq %rdi, %rdi
je 0x2acad
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2acad
movq %rcx, %r15
movl %edx, %r13d
movq %rsi, %r12
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2abf4
movq %r8, %r14
movq 0x5cbaa(%rip), %rax     # 0x87798
callq *0x20(%rax)
movq %r14, %r8
cmpl $0x2, 0x5cbad(%rip)     # 0x877a8
jb 0x2ac0d
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2aca9
movq %r8, -0x38(%rbp)
movq 0xd8(%rbx), %rax
movq 0xe8(%rbx), %rdi
movq 0x10(%rax), %rax
movq (%rax), %rax
movq 0x8(%rax), %r14
testl %r13d, %r13d
jns 0x2ac40
movq %rdi, %r13
movq %r12, %rdi
callq 0x28e24
movq %r13, %rdi
movl %eax, %r13d
testl %r13d, %r13d
je 0x2ac7e
pushq $0x1
popq %rcx
movq %rdi, -0x30(%rbp)
movq %r12, %rsi
movl %r13d, %edx
movq %r14, %r12
callq *0x50(%r14)
movl %eax, %r14d
testq %r15, %r15
je 0x2ac91
testl %r14d, %r14d
jne 0x2ac91
movq -0x30(%rbp), %rdi
movq %r15, %rsi
movq -0x38(%rbp), %rdx
callq *0xa0(%r12)
movl %eax, %r14d
jmp 0x2ac91
leaq 0x38ab9(%rip), %rsi     # 0x6373e
movq %rbx, %rdi
callq 0x2a542
pushq $-0x3
popq %r14
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2acad
movq 0x5caf4(%rip), %rax     # 0x87798
callq *0x30(%rax)
jmp 0x2acad
pushq $-0xa
popq %r14
movl %r14d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_delete
int unqlite_kv_delete(unqlite *pDb,const void *pKey,int nKeyLen)
{
	unqlite_kv_methods *pMethods;
	unqlite_kv_engine *pEngine;
	unqlite_kv_cursor *pCur;
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Point to the underlying storage engine */
	 pEngine = unqlitePagerGetKvEngine(pDb);
	 pMethods = pEngine->pIo->pMethods;
	 pCur = pDb->sDB.pCursor;
	 if( pMethods->xDelete == 0 ){
		 /* Storage engine does not implement such method */
		 unqliteGenError(pDb,"xDelete() method not implemented in the underlying storage engine");
		 rc = UNQLITE_NOTIMPLEMENTED;
	 }else{
		 if( nKeyLen < 0 ){
			 /* Assume a null terminated string and compute it's length */
			 nKeyLen = SyStrlen((const char *)pKey);
		 }
		 if( !nKeyLen ){
			 unqliteGenError(pDb,"Empty key");
			 rc = UNQLITE_EMPTY;
		 }else{
			 /* Seek to the record position */
			 rc = pMethods->xSeek(pCur,pKey,nKeyLen,UNQLITE_CURSOR_MATCH_EXACT);
		 }
		 if( rc == UNQLITE_OK ){
			 /* Exact match found, delete the entry */
			 rc = pMethods->xDelete(pCur);
		 }
	 }
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
pushq $-0x18
popq %r12
testq %rdi, %rdi
je 0x2adbe
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2adbe
movl %edx, %r15d
movq %rsi, %r14
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2ad09
movq 0x5ca92(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5ca98(%rip)     # 0x877a8
jb 0x2ad1e
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2ad8f
movq 0xd8(%rbx), %rax
movq 0x10(%rax), %rax
movq (%rax), %rax
movq 0x8(%rax), %r13
cmpq $0x0, 0x80(%r13)
je 0x2ad7c
movq 0xe8(%rbx), %r12
testl %r15d, %r15d
jns 0x2ad51
movq %r14, %rdi
callq 0x28e24
movl %eax, %r15d
testl %r15d, %r15d
je 0x2ad95
pushq $0x1
popq %rcx
movq %r12, %rdi
movq %r14, %rsi
movl %r15d, %edx
callq *0x50(%r13)
movq %r12, %rdi
movl %eax, %r12d
testl %eax, %eax
jne 0x2ada8
callq *0x80(%r13)
movl %eax, %r12d
jmp 0x2ada8
leaq 0x38a07(%rip), %rsi     # 0x6378a
movq %rbx, %rdi
callq 0x2a542
pushq $-0x11
jmp 0x2ada6
pushq $-0xa
popq %r12
jmp 0x2adbe
leaq 0x389a2(%rip), %rsi     # 0x6373e
movq %rbx, %rdi
callq 0x2a542
pushq $-0x3
popq %r12
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2adbe
movq 0x5c9dd(%rip), %rax     # 0x87798
callq *0x30(%rax)
movl %r12d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_config
int unqlite_kv_config(unqlite *pDb,int iOp,...)
{
	unqlite_kv_engine *pEngine;
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Point to the underlying storage engine */
	 pEngine = unqlitePagerGetKvEngine(pDb);
	 if( pEngine->pIo->pMethods->xConfig == 0 ){
		 /* Storage engine does not implements such method */
		 unqliteGenError(pDb,"xConfig() method not implemented in the underlying storage engine");
		 rc = UNQLITE_NOTIMPLEMENTED;
	 }else{
		 va_list ap;
		 /* Configure the storage engine */
		 va_start(ap,iOp);
		 rc = pEngine->pIo->pMethods->xConfig(pEngine,iOp,ap);
		 va_end(ap);
	 }
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0xc8, %rsp
movq %rdx, -0xd0(%rbp)
movq %rcx, -0xc8(%rbp)
movq %r8, -0xc0(%rbp)
movq %r9, -0xb8(%rbp)
testb %al, %al
je 0x2ae29
movaps %xmm0, -0xb0(%rbp)
movaps %xmm1, -0xa0(%rbp)
movaps %xmm2, -0x90(%rbp)
movaps %xmm3, -0x80(%rbp)
movaps %xmm4, -0x70(%rbp)
movaps %xmm5, -0x60(%rbp)
movaps %xmm6, -0x50(%rbp)
movaps %xmm7, -0x40(%rbp)
pushq $-0x18
popq %r15
testq %rdi, %rdi
je 0x2aef5
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2aef5
movl %esi, %r14d
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2ae62
movq 0x5c939(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5c93f(%rip)     # 0x877a8
jb 0x2ae77
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2aef1
movq 0xd8(%rbx), %rax
movq 0x10(%rax), %rdi
movq (%rdi), %rax
movq 0x8(%rax), %rax
cmpq $0x0, 0x28(%rax)
je 0x2aec6
leaq -0xe0(%rbp), %rax
leaq -0x30(%rbp), %rdx
movq %rax, 0x10(%rdx)
leaq 0x10(%rbp), %rax
movq %rax, 0x8(%rdx)
movabsq $0x3000000010, %rax     # imm = 0x3000000010
movq %rax, (%rdx)
movq (%rdi), %rax
movq 0x8(%rax), %rax
movl %r14d, %esi
callq *0x28(%rax)
movl %eax, %r15d
jmp 0x2aed9
leaq 0x388ff(%rip), %rsi     # 0x637cc
movq %rbx, %rdi
callq 0x2a542
pushq $-0x11
popq %r15
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2aef5
movq 0x5c8ac(%rip), %rax     # 0x87798
callq *0x30(%rax)
jmp 0x2aef5
pushq $-0xa
popq %r15
movl %r15d, %eax
addq $0xc8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_cursor_init
int unqlite_kv_cursor_init(unqlite *pDb,unqlite_kv_cursor **ppOut)
{
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) || ppOut == 0 /* Noop */){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Allocate a new cursor */
	 rc = unqliteInitCursor(pDb,ppOut);
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	 return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
pushq $-0x18
popq %r14
testq %rdi, %rdi
je 0x2af85
movq %rsi, %r15
testq %rsi, %rsi
je 0x2af85
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2af85
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2af46
movq 0x5c855(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5c85b(%rip)     # 0x877a8
jb 0x2af5b
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2af81
movq %rbx, %rdi
movq %r15, %rsi
callq 0x2af93
movl %eax, %r14d
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2af85
movq 0x5c81c(%rip), %rax     # 0x87798
callq *0x30(%rax)
jmp 0x2af85
pushq $-0xa
popq %r14
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqliteInitCursor
UNQLITE_PRIVATE int unqliteInitCursor(unqlite *pDb,unqlite_kv_cursor **ppOut)
{
	unqlite_kv_methods *pMethods;
	unqlite_kv_cursor *pCur;
	sxu32 nByte;
	/* Storage engine methods */
	pMethods = pDb->sDB.pPager->pEngine->pIo->pMethods;
	if( pMethods->szCursor < 1 ){
		/* Implementation does not supprt cursors */
		unqliteGenErrorFormat(pDb,"Storage engine '%s' does not support cursors",pMethods->zName);
		return UNQLITE_NOTIMPLEMENTED;
	}
	nByte = pMethods->szCursor;
	if( nByte < sizeof(unqlite_kv_cursor) ){
		nByte += sizeof(unqlite_kv_cursor);
	}
	pCur = (unqlite_kv_cursor *)SyMemBackendPoolAlloc(&pDb->sMem,nByte);
	if( pCur == 0 ){
		unqliteGenOutofMem(pDb);
		return UNQLITE_NOMEM;
	}
	/* Zero the structure */
	SyZero(pCur,nByte);
	/* Save the cursor */
	pCur->pStore = pDb->sDB.pPager->pEngine;
	/* Invoke the initialization callback if any */
	if( pMethods->xCursorInit ){
		pMethods->xCursorInit(pCur);
	}
	/* All done */
	*ppOut = pCur;
	return UNQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %r14
movq 0xd8(%rdi), %rax
movq 0x10(%rax), %rax
movq (%rax), %rax
movq 0x8(%rax), %r13
movl 0xc(%r13), %eax
testl %eax, %eax
jle 0x2b010
movq %rsi, %rbx
movl %eax, %r12d
orl $0x8, %r12d
cmpl $0x8, %eax
cmovael %eax, %r12d
movq %r14, %rdi
movl %r12d, %esi
callq 0x279f7
testq %rax, %rax
je 0x2b029
movq %rax, %r15
movq %rax, %rdi
movl %r12d, %esi
callq 0x27aea
movq 0xd8(%r14), %rax
movq 0x10(%rax), %rax
movq %rax, (%r15)
movq 0x48(%r13), %rax
testq %rax, %rax
je 0x2b009
movq %r15, %rdi
callq *%rax
movq %r15, (%rbx)
xorl %eax, %eax
jmp 0x2b034
movq (%r13), %rdx
leaq 0x3cdb8(%rip), %rsi     # 0x67dd3
movq %r14, %rdi
xorl %eax, %eax
callq 0x32836
pushq $-0x11
jmp 0x2b033
movq %r14, %rdi
callq 0x32825
pushq $-0x1
popq %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_cursor_release
int unqlite_kv_cursor_release(unqlite *pDb,unqlite_kv_cursor *pCur)
{
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) || pCur == 0 /* Noop */){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Release the cursor */
	 rc = unqliteReleaseCursor(pDb,pCur);
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	 return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
pushq $-0x18
popq %r14
testq %rdi, %rdi
je 0x2b0c2
movq %rsi, %r15
testq %rsi, %rsi
je 0x2b0c2
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2b0c2
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2b083
movq 0x5c718(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5c71e(%rip)     # 0x877a8
jb 0x2b098
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2b0be
movq %rbx, %rdi
movq %r15, %rsi
callq 0x2b0d0
movq 0xf8(%rbx), %rdi
xorl %r14d, %r14d
testq %rdi, %rdi
je 0x2b0c2
movq 0x5c6df(%rip), %rax     # 0x87798
callq *0x30(%rax)
jmp 0x2b0c2
pushq $-0xa
popq %r14
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqliteReleaseCursor
UNQLITE_PRIVATE int unqliteReleaseCursor(unqlite *pDb,unqlite_kv_cursor *pCur)
{
	unqlite_kv_methods *pMethods;
	/* Storage engine methods */
	pMethods = pDb->sDB.pPager->pEngine->pIo->pMethods;
	/* Invoke the release callback if available */
	if( pMethods->xCursorRelease ){
		pMethods->xCursorRelease(pCur);
	}
	/* Finally, free the whole instance */
	SyMemBackendPoolFree(&pDb->sMem,pCur);
	return UNQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %rbx
movq %rdi, %r14
movq 0xd8(%rdi), %rax
movq 0x10(%rax), %rax
movq (%rax), %rax
movq 0x8(%rax), %rax
movq 0xb0(%rax), %rax
testq %rax, %rax
je 0x2b100
movq %rbx, %rdi
callq *%rax
movq %r14, %rdi
movq %rbx, %rsi
popq %rbx
popq %r14
popq %rbp
jmp 0x27bf8
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_cursor_seek
int unqlite_kv_cursor_seek(unqlite_kv_cursor *pCursor,const void *pKey,int nKeyLen,int iPos)
{
	int rc = UNQLITE_OK;
#ifdef UNTRUST
	if( pCursor == 0 ){
		return UNQLITE_CORRUPT;
	}
#endif
	if( nKeyLen < 0 ){
		/* Assume a null terminated string and compute it's length */
		nKeyLen = SyStrlen((const char *)pKey);
	}
	if( !nKeyLen ){
		rc = UNQLITE_EMPTY;
	}else{
		/* Seek to the desired location */
		rc = pCursor->pStore->pIo->pMethods->xSeek(pCursor,pKey,nKeyLen,iPos);
	}
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %ecx, %ebx
movq %rsi, %r14
movq %rdi, %r15
testl %edx, %edx
jns 0x2b21c
movq %r14, %rdi
callq 0x28e24
movl %eax, %edx
testl %edx, %edx
je 0x2b242
movq (%r15), %rax
movq (%rax), %rax
movq 0x8(%rax), %rax
movq 0x50(%rax), %rax
movq %r15, %rdi
movq %r14, %rsi
movl %ebx, %ecx
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmpq *%rax
pushq $-0x3
popq %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_cursor_key
int unqlite_kv_cursor_key(unqlite_kv_cursor *pCursor,void *pBuf,int *pnByte)
{
	int rc;
#ifdef UNTRUST
	if( pCursor == 0 ){
		return UNQLITE_CORRUPT;
	}
#endif
	if( pBuf == 0 ){
		/* Key length only */
		rc = pCursor->pStore->pIo->pMethods->xKeyLength(pCursor,pnByte);
	}else{
		SyBlob sBlob;
		if( (*pnByte) < 0 ){
			return UNQLITE_CORRUPT;
		}
		/* Initialize the data consumer */
		SyBlobInitFromBuf(&sBlob,pBuf,(sxu32)(*pnByte));
		/* Consume the key */
		rc = pCursor->pStore->pIo->pMethods->xKey(pCursor,unqliteDataConsumer,&sBlob);
		 /* Key length */
		*pnByte = SyBlobLength(&sBlob);
		/* Cleanup */
		SyBlobRelease(&sBlob);
	}
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdx, %rbx
testq %rsi, %rsi
je 0x2b2cd
movl (%rbx), %eax
testl %eax, %eax
js 0x2b2ed
leaq -0x38(%rbp), %r15
movq %rsi, 0x8(%r15)
movl %eax, 0x14(%r15)
andl $0x0, 0x10(%r15)
andq $0x0, (%r15)
movl $0x3, 0x18(%r15)
movq (%rdi), %rax
movq (%rax), %rax
movq 0x8(%rax), %rax
leaq -0x728(%rip), %rsi      # 0x2ab89
movq %r15, %rdx
callq *0x90(%rax)
movl %eax, %r14d
movl 0x10(%r15), %eax
movl %eax, (%rbx)
movq %r15, %rdi
callq 0x2a72f
jmp 0x2b2f1
movq (%rdi), %rax
movq (%rax), %rax
movq 0x8(%rax), %rax
movq 0x88(%rax), %rax
movq %rbx, %rsi
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmpq *%rax
pushq $-0x18
popq %r14
movl %r14d, %eax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_kv_cursor_data
int unqlite_kv_cursor_data(unqlite_kv_cursor *pCursor,void *pBuf,unqlite_int64 *pnByte)
{
	int rc;
#ifdef UNTRUST
	if( pCursor == 0 ){
		return UNQLITE_CORRUPT;
	}
#endif
	if( pBuf == 0 ){
		/* Data length only */
		rc = pCursor->pStore->pIo->pMethods->xDataLength(pCursor,pnByte);
	}else{
		SyBlob sBlob;
		if( (*pnByte) < 0 ){
			return UNQLITE_CORRUPT;
		}
		/* Initialize the data consumer */
		SyBlobInitFromBuf(&sBlob,pBuf,(sxu32)(*pnByte));
		/* Consume the data */
		rc = pCursor->pStore->pIo->pMethods->xData(pCursor,unqliteDataConsumer,&sBlob);
		/* Data length */
		*pnByte = SyBlobLength(&sBlob);
		/* Cleanup */
		SyBlobRelease(&sBlob);
	}
	return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq %rdx, %rbx
testq %rsi, %rsi
je 0x2b37f
movq (%rbx), %rax
testq %rax, %rax
js 0x2b39f
leaq -0x38(%rbp), %r15
movq %rsi, 0x8(%r15)
movl %eax, 0x14(%r15)
andl $0x0, 0x10(%r15)
andq $0x0, (%r15)
movl $0x3, 0x18(%r15)
movq (%rdi), %rax
movq (%rax), %rax
movq 0x8(%rax), %rax
leaq -0x7d9(%rip), %rsi      # 0x2ab89
movq %r15, %rdx
callq *0xa0(%rax)
movl %eax, %r14d
movl 0x10(%r15), %eax
movq %rax, (%rbx)
movq %r15, %rdi
callq 0x2a72f
jmp 0x2b3a3
movq (%rdi), %rax
movq (%rax), %rax
movq 0x8(%rax), %rax
movq 0x98(%rax), %rax
movq %rbx, %rsi
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmpq *%rax
pushq $-0x18
popq %r14
movl %r14d, %eax
addq $0x28, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_begin
int unqlite_begin(unqlite *pDb)
{
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Begin the write transaction */
	 rc = unqlitePagerBegin(pDb->sDB.pPager);
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	 return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
pushq $-0x18
popq %r14
testq %rdi, %rdi
je 0x2b426
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2b426
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2b3e6
movq 0x5c3b5(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5c3bb(%rip)     # 0x877a8
jb 0x2b3fb
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2b422
movq 0xd8(%rbx), %rdi
callq 0x2b42e
movl %eax, %r14d
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2b426
movq 0x5c37b(%rip), %rax     # 0x87798
callq *0x30(%rax)
jmp 0x2b426
pushq $-0xa
popq %r14
movl %r14d, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_commit
int unqlite_commit(unqlite *pDb)
{
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Commit the transaction */
	 rc = unqlitePagerCommit(pDb->sDB.pPager);
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	 return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
pushq $-0x18
popq %r14
testq %rdi, %rdi
je 0x2b6db
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2b6db
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2b69b
movq 0x5c100(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5c106(%rip)     # 0x877a8
jb 0x2b6b0
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2b6d7
movq 0xd8(%rbx), %rdi
callq 0x2b6e3
movl %eax, %r14d
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2b6db
movq 0x5c0c6(%rip), %rax     # 0x87798
callq *0x30(%rax)
jmp 0x2b6db
pushq $-0xa
popq %r14
movl %r14d, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_rollback
int unqlite_rollback(unqlite *pDb)
{
	int rc;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Rollback the transaction */
	 rc = unqlitePagerRollback(pDb->sDB.pPager,TRUE);
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	 return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
pushq $-0x18
popq %r14
testq %rdi, %rdi
je 0x2ba29
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2ba29
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2b9e6
movq 0x5bdb5(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5bdbb(%rip)     # 0x877a8
jb 0x2b9fb
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2ba25
movq 0xd8(%rbx), %rdi
pushq $0x1
popq %rsi
callq 0x2ba31
movl %eax, %r14d
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2ba29
movq 0x5bd78(%rip), %rax     # 0x87798
callq *0x30(%rax)
jmp 0x2ba29
pushq $-0xa
popq %r14
movl %r14d, %eax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_util_random_string
UNQLITE_APIEXPORT int unqlite_util_random_string(unqlite *pDb,char *zBuf,unsigned int buf_size)
{
	if( UNQLITE_DB_MISUSE(pDb) ){
		return UNQLITE_CORRUPT;
	}
	if( zBuf == 0 || buf_size < 3 ){
		/* Buffer must be long enough to hold three bytes */
		return UNQLITE_INVALID;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return UNQLITE_ABORT; /* Another thread have released this instance */
	 }
#endif
	 /* Generate the random string */
	 unqlitePagerRandomString(pDb->sDB.pPager,zBuf,buf_size);
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	 return UNQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq $-0x18
popq %r12
testq %rdi, %rdi
je 0x2bd63
movq %rdi, %rbx
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2bd63
movl %edx, %r15d
movq %rsi, %r14
testq %rsi, %rsi
sete %al
cmpl $0x3, %edx
setb %cl
orb %al, %cl
je 0x2bcde
pushq $-0x9
popq %r12
jmp 0x2bd63
movq 0xf8(%rbx), %rdi
testq %rdi, %rdi
je 0x2bcf4
movq 0x5baa7(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5baad(%rip)     # 0x877a8
jb 0x2bd09
cmpl $0xdb7c2712, 0x120(%rbx) # imm = 0xDB7C2712
jne 0x2bd6f
movq 0xd8(%rbx), %rdi
addq $0x64, %rdi
movq %r14, %rsi
movl %r15d, %edx
callq 0x321c8
movl %r15d, %ecx
xorl %esi, %esi
pushq $0x24
popq %rdi
leaq 0x3c1a2(%rip), %r8      # 0x67ed0
cmpq %rsi, %rcx
je 0x2bd4a
movsbq (%r14,%rsi), %rax
xorl %edx, %edx
divq %rdi
movb (%rdx,%r8), %al
movb %al, (%r14,%rsi)
incq %rsi
jmp 0x2bd2e
movq 0xf8(%rbx), %rdi
xorl %r12d, %r12d
testq %rdi, %rdi
je 0x2bd63
movq 0x5ba38(%rip), %rax     # 0x87798
callq *0x30(%rax)
movl %r12d, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
pushq $-0xa
jmp 0x2bcd7
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unqlite_util_random_num
UNQLITE_APIEXPORT unsigned int unqlite_util_random_num(unqlite *pDb)
{
	sxu32 iNum;
	if( UNQLITE_DB_MISUSE(pDb) ){
		return 0;
	}
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Acquire DB mutex */
	 SyMutexEnter(sUnqlMPGlobal.pMutexMethods, pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
	 if( sUnqlMPGlobal.nThreadingLevel > UNQLITE_THREAD_LEVEL_SINGLE && 
		 UNQLITE_THRD_DB_RELEASE(pDb) ){
			 return 0; /* Another thread have released this instance */
	 }
#endif
	 /* Generate the random number */
	 iNum = unqlitePagerRandomNum(pDb->sDB.pPager);
#if defined(UNQLITE_ENABLE_THREADS)
	 /* Leave DB mutex */
	 SyMutexLeave(sUnqlMPGlobal.pMutexMethods,pDb->pMutex); /* NO-OP if sUnqlMPGlobal.nThreadingLevel != UNQLITE_THREAD_LEVEL_MULTI */
#endif
	 return iNum;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
xorl %ebx, %ebx
testq %rdi, %rdi
je 0x2bdf5
movq %rdi, %r14
cmpl $0xdb7c2712, 0x120(%rdi) # imm = 0xDB7C2712
jne 0x2bdf5
movq 0xf8(%r14), %rdi
testq %rdi, %rdi
je 0x2bdad
movq 0x5b9ee(%rip), %rax     # 0x87798
callq *0x20(%rax)
cmpl $0x2, 0x5b9f4(%rip)     # 0x877a8
jb 0x2bdc3
cmpl $0xdb7c2712, 0x120(%r14) # imm = 0xDB7C2712
jne 0x2bdf5
movq 0xd8(%r14), %rdi
addq $0x64, %rdi
leaq -0x14(%rbp), %rbx
pushq $0x4
popq %rdx
movq %rbx, %rsi
callq 0x321c8
movl (%rbx), %ebx
movq 0xf8(%r14), %rdi
testq %rdi, %rdi
je 0x2bdf5
movq 0x5b9a6(%rip), %rax     # 0x87798
callq *0x30(%rax)
movl %ebx, %eax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: SySetPut
JX9_PRIVATE sxi32 SySetPut(SySet *pSet, const void *pItem)
{
	unsigned char *zbase;
	if( pSet->nUsed >= pSet->nSize ){
		void *pNew;
		if( pSet->pAllocator == 0 ){
			return  SXERR_LOCKED;
		}
		if( pSet->nSize <= 0 ){
			pSet->nSize = 4;
		}
		pNew = SyMemBackendRealloc(pSet->pAllocator, pSet->pBase, pSet->eSize * pSet->nSize * 2);
		if( pNew == 0 ){
			return SXERR_MEM;
		}
		pSet->pBase = pNew;
		pSet->nSize <<= 1;
	}
	zbase = (unsigned char *)pSet->pBase;
	SX_MACRO_FAST_MEMCPY(pItem, &zbase[pSet->nUsed * pSet->eSize], pSet->eSize);
	pSet->nUsed++;	
	return SXRET_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
movl 0x10(%rdi), %ecx
movl 0x14(%rdi), %edx
cmpl %edx, %ecx
jae 0x2be1d
movq 0x8(%rbx), %rax
jmp 0x2be55
movq (%rbx), %rdi
testq %rdi, %rdi
je 0x2beb6
testl %edx, %edx
jne 0x2be37
movl $0x4, 0x14(%rbx)
pushq $0x4
popq %rdx
movq 0x8(%rbx), %rsi
imull 0x18(%rbx), %edx
addl %edx, %edx
callq 0x2c218
testq %rax, %rax
je 0x2beba
movq %rax, 0x8(%rbx)
shll 0x14(%rbx)
movl 0x10(%rbx), %ecx
movl 0x18(%rbx), %edx
imull %edx, %ecx
addq %rax, %rcx
leaq -0x3(%rdx), %rax
leaq -0x2(%rdx), %rsi
movq %rdx, %rdi
decq %rdi
xorl %r8d, %r8d
cmpl %r8d, %edx
je 0x2beaf
movb (%r14,%r8), %r9b
movb %r9b, (%rcx,%r8)
cmpl %r8d, %edi
je 0x2beaf
movb 0x1(%r14,%r8), %r9b
movb %r9b, 0x1(%rcx,%r8)
cmpl %r8d, %esi
je 0x2beaf
movb 0x2(%r14,%r8), %r9b
movb %r9b, 0x2(%rcx,%r8)
cmpl %r8d, %eax
je 0x2beaf
movb 0x3(%r14,%r8), %r9b
movb %r9b, 0x3(%rcx,%r8)
addq $0x4, %r8
jmp 0x2be6f
incl 0x10(%rbx)
xorl %eax, %eax
jmp 0x2bebd
pushq $-0x4
jmp 0x2bebc
pushq $-0x1
popq %rax
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: SyMemBackendInitFromOthers
JX9_PRIVATE sxi32 SyMemBackendInitFromOthers(SyMemBackend *pBackend, const SyMemMethods *pMethods, ProcMemError xMemErr, void * pUserData)
{
#if defined(UNTRUST)
	if( pBackend == 0 || pMethods == 0){
		return SXERR_EMPTY;
	}
#endif
	if( pMethods->xAlloc == 0 || pMethods->xRealloc == 0 || pMethods->xFree == 0 || pMethods->xChunkSize == 0 ){
		/* mandatory methods are missing */
		return SXERR_INVALID;
	}
	/* Zero the allocator first */
	SyZero(&(*pBackend), sizeof(SyMemBackend));
	pBackend->xMemError = xMemErr;
	pBackend->pUserData = pUserData;
	/* Switch to the host application memory allocator */
	pBackend->pMethods = pMethods;
	if( pBackend->pMethods->xInit ){
		/* Initialize the backend  */
		if( SXRET_OK != pBackend->pMethods->xInit(pBackend->pMethods->pUserData) ){
			return SXERR_ABORT;
		}
	}
#if defined(UNTRUST)
	pBackend->nMagic = SXMEM_BACKEND_MAGIC;
#endif
	return SXRET_OK;
}

// Assembly:
pushq $-0x9
popq %rax
cmpq $0x0, (%rsi)
je 0x2bf6a
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
cmpq $0x0, 0x8(%rsi)
je 0x2bf62
cmpq $0x0, 0x10(%rbx)
je 0x2bf62
cmpq $0x0, 0x18(%rbx)
je 0x2bf62
movq %rcx, %r14
movq %rdx, %r12
movq %rdi, %r15
movl $0xb8, %esi
callq 0x27aea
movq %r12, 0x20(%r15)
movq %r14, 0x28(%r15)
movq %rbx, 0x8(%r15)
movq 0x20(%rbx), %rax
testq %rax, %rax
je 0x2bf60
movq 0x30(%rbx), %rdi
callq *%rax
testl %eax, %eax
je 0x2bf60
pushq $-0xa
popq %rax
jmp 0x2bf62
xorl %eax, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: SyMemBackendRealloc
JX9_PRIVATE void * SyMemBackendRealloc(SyMemBackend *pBackend, void * pOld, sxu32 nByte)
{
	void *pChunk;
#if defined(UNTRUST)
	if( SXMEM_BACKEND_CORRUPT(pBackend)  ){
		return 0;
	}
#endif
	if( pBackend->pMutexMethods ){
		SyMutexEnter(pBackend->pMutexMethods, pBackend->pMutex);
	}
	pChunk = MemBackendRealloc(&(*pBackend), pOld, nByte);
	if( pBackend->pMutexMethods ){
		SyMutexLeave(pBackend->pMutexMethods, pBackend->pMutex);
	}
	return pChunk;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %edx, %r14d
movq %rsi, %r15
movq %rdi, %rbx
movq (%rdi), %rax
testq %rax, %rax
je 0x2c246
movq 0x30(%rbx), %rdi
testq %rdi, %rdi
je 0x2c246
callq *0x20(%rax)
testq %r15, %r15
je 0x2c29a
leaq -0x10(%r15), %r12
addl $0x10, %r14d
movq -0x10(%r15), %rax
movq %rax, -0x38(%rbp)
movq -0x8(%r15), %rax
movq %rax, -0x30(%rbp)
xorl %r15d, %r15d
xorl %r13d, %r13d
movq 0x8(%rbx), %rax
movq %r12, %rdi
movl %r14d, %esi
callq *0x8(%rax)
testq %rax, %rax
jne 0x2c2a7
movq 0x20(%rbx), %rax
testq %rax, %rax
je 0x2c2d2
cmpl $0x3, %r13d
ja 0x2c2d2
movq 0x28(%rbx), %rdi
callq *%rax
incl %r13d
cmpl $-0x21, %eax
je 0x2c269
jmp 0x2c2d2
movq %rbx, %rdi
movl %r14d, %esi
callq 0x2c2f8
jmp 0x2c2cf
cmpq %r12, %rax
movq -0x38(%rbp), %rdx
je 0x2c2cb
leaq 0x10(%rbx), %rcx
movq -0x30(%rbp), %rsi
testq %rsi, %rsi
cmovneq %rsi, %rcx
movq %rax, (%rcx)
testq %rdx, %rdx
je 0x2c2cb
movq %rax, 0x8(%rdx)
addq $0x10, %rax
movq %rax, %r15
movq (%rbx), %rax
testq %rax, %rax
je 0x2c2e6
movq 0x30(%rbx), %rdi
testq %rdi, %rdi
je 0x2c2e6
callq *0x30(%rax)
movq %r15, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: MemBackendAlloc
static void * MemBackendAlloc(SyMemBackend *pBackend, sxu32 nByte)
{
	SyMemBlock *pBlock;
	sxi32 nRetry = 0;

	/* Append an extra block so we can tracks allocated chunks and avoid memory
	 * leaks.
	 */
	nByte += sizeof(SyMemBlock);
	for(;;){
		pBlock = (SyMemBlock *)pBackend->pMethods->xAlloc(nByte);
		if( pBlock != 0 || pBackend->xMemError == 0 || nRetry > SXMEM_BACKEND_RETRY 
			|| SXERR_RETRY != pBackend->xMemError(pBackend->pUserData) ){
				break;
		}
		nRetry++;
	}
	if( pBlock  == 0 ){
		return 0;
	}
	pBlock->pNext = pBlock->pPrev = 0;
	/* Link to the list of already tracked blocks */
	MACRO_LD_PUSH(pBackend->pBlocks, pBlock);
#if defined(UNTRUST)
	pBlock->nGuard = SXMEM_BACKEND_MAGIC;
#endif
	pBackend->nBlock++;
	return (void *)&pBlock[1];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %esi, %r15d
movq %rdi, %rbx
addl $0x10, %r15d
xorl %r14d, %r14d
xorl %r12d, %r12d
movq 0x8(%rbx), %rax
movl %r15d, %edi
callq *(%rax)
testq %rax, %rax
jne 0x2c340
movq 0x20(%rbx), %rax
testq %rax, %rax
je 0x2c364
cmpl $0x3, %r12d
ja 0x2c364
movq 0x28(%rbx), %rdi
callq *%rax
incl %r12d
cmpl $-0x21, %eax
je 0x2c313
jmp 0x2c364
xorps %xmm0, %xmm0
movups %xmm0, (%rax)
movq 0x10(%rbx), %rcx
testq %rcx, %rcx
je 0x2c356
movq %rcx, (%rax)
movq %rax, 0x8(%rcx)
movq %rax, 0x10(%rbx)
incl 0x18(%rbx)
addq $0x10, %rax
movq %rax, %r14
movq %r14, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: MemOSAlloc
static void * MemOSAlloc(sxu32 nBytes)
{
	sxu32 *pChunk;
	pChunk = (sxu32 *)SyOSHeapAlloc(nBytes + sizeof(sxu32));
	if( pChunk == 0 ){
		return 0;
	}
	pChunk[0] = nBytes;
	return (void *)&pChunk[1];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %edi, %ebx
leal 0x4(%rbx), %edi
callq 0xca30
testq %rax, %rax
je 0x2c38d
movl %ebx, (%rax)
addq $0x4, %rax
jmp 0x2c38f
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: MemOSRealloc
static void * MemOSRealloc(void *pOld, sxu32 nBytes)
{
	sxu32 *pOldChunk;
	sxu32 *pChunk;
	pOldChunk = (sxu32 *)(((char *)pOld)-sizeof(sxu32));
	if( pOldChunk[0] >= nBytes ){
		return pOld;
	}
	pChunk = (sxu32 *)SyOSHeapRealloc(pOldChunk, nBytes + sizeof(sxu32));
	if( pChunk == 0 ){
		return 0;
	}
	pChunk[0] = nBytes;
	return (void *)&pChunk[1];
}

// Assembly:
movq %rdi, %rax
cmpl %esi, -0x4(%rdi)
jae 0x2c3ca
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movl %esi, %ebx
addq $-0x4, %rax
leal 0x4(%rbx), %esi
movq %rax, %rdi
callq 0xc130
testq %rax, %rax
je 0x2c3c2
movl %ebx, (%rax)
addq $0x4, %rax
jmp 0x2c3c4
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unixDelete
static int unixDelete(
  unqlite_vfs *NotUsed,     /* VFS containing this as the xDelete method */
  const char *zPath,        /* Name of file to be deleted */
  int dirSync               /* If true, fsync() directory after deleting file */
){
  int rc = UNQLITE_OK;
  SXUNUSED(NotUsed);
  
  if( unlink(zPath)==(-1) && errno!=ENOENT ){
	  return UNQLITE_IOERR;
  }
#ifndef UNQLITE_DISABLE_DIRSYNC
  if( dirSync ){
    int fd;
    rc = openDirectory(zPath, &fd);
    if( rc==UNQLITE_OK ){
      if( fsync(fd) )
      {
        rc = UNQLITE_IOERR;
      }
      if( close(fd) && !rc ){
        rc = UNQLITE_IOERR;
      }
    }
  }
#endif
  return rc;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movl %edx, %r14d
movq %rsi, %rbx
movq %rsi, %rdi
callq 0xc2c0
cmpl $-0x1, %eax
jne 0x2c73c
callq 0xcb50
cmpl $0x2, (%rax)
jne 0x2c77a
testl %r14d, %r14d
je 0x2c776
leaq -0x14(%rbp), %rsi
movq %rbx, %rdi
callq 0x2c925
testl %eax, %eax
jne 0x2c77d
movl -0x14(%rbp), %ebx
movl %ebx, %edi
callq 0xc960
movl %eax, %r14d
movl %ebx, %edi
callq 0xc2b0
xorl %ecx, %ecx
orl %r14d, %eax
sete %cl
leal -0x2(,%rcx,2), %eax
jmp 0x2c77d
xorl %eax, %eax
jmp 0x2c77d
pushq $-0x2
popq %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unixAccess
static int unixAccess(
  unqlite_vfs *NotUsed,   /* The VFS containing this xAccess method */
  const char *zPath,      /* Path of the file to examine */
  int flags,              /* What do we want to learn about the zPath file? */
  int *pResOut            /* Write result boolean here */
){
  int amode = 0;
  SXUNUSED(NotUsed);
  switch( flags ){
    case UNQLITE_ACCESS_EXISTS:
      amode = F_OK;
      break;
    case UNQLITE_ACCESS_READWRITE:
      amode = W_OK|R_OK;
      break;
    case UNQLITE_ACCESS_READ:
      amode = R_OK;
      break;
    default:
		/* Can't happen */
      break;
  }
  *pResOut = (access(zPath, amode)==0);
  if( flags==UNQLITE_ACCESS_EXISTS && *pResOut ){
    struct stat buf;
    if( 0==stat(zPath, &buf) && buf.st_size==0 ){
      *pResOut = 0;
    }
  }
  return UNQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x98, %rsp
movq %rcx, %rbx
movl %edx, %r15d
movq %rsi, %r14
xorl %eax, %eax
cmpl $0x1, %edx
pushq $0x6
popq %rcx
cmovnel %eax, %ecx
cmpl $0x2, %edx
pushq $0x4
popq %rsi
cmovnel %ecx, %esi
movq %r14, %rdi
callq 0xc170
xorl %ecx, %ecx
testl %eax, %eax
sete %cl
movl %ecx, (%rbx)
orl %r15d, %eax
jne 0x2c7e6
leaq -0xa8(%rbp), %rsi
movq %r14, %rdi
callq 0xc120
testl %eax, %eax
jne 0x2c7e6
cmpq $0x0, -0x78(%rbp)
jne 0x2c7e6
andl $0x0, (%rbx)
xorl %eax, %eax
addq $0x98, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: unixFullPathname
static int unixFullPathname(
  unqlite_vfs *pVfs,            /* Pointer to vfs object */
  const char *zPath,            /* Possibly relative input path */
  int nOut,                     /* Size of output buffer in bytes */
  char *zOut                    /* Output buffer */
){
  if( zPath[0]=='/' ){
	  Systrcpy(zOut,(sxu32)nOut,zPath,0);
	  SXUNUSED(pVfs);
  }else{
    sxu32 nCwd;
	zOut[nOut-1] = '\0';
    if( getcwd(zOut, nOut-1)==0 ){
		return UNQLITE_IOERR;
    }
    nCwd = SyStrlen(zOut);
    SyBufferFormat(&zOut[nCwd],(sxu32)nOut-nCwd,"/%s",zPath);
  }
  return UNQLITE_OK;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %r15
movl %edx, %r14d
movq %rsi, %rbx
cmpb $0x2f, (%rsi)
jne 0x2c824
xorl %r12d, %r12d
movq %r15, %rdi
movl %r14d, %esi
movq %rbx, %rdx
xorl %ecx, %ecx
callq 0x2ca64
jmp 0x2c86a
movslq %r14d, %rsi
movb $0x0, -0x1(%r15,%rsi)
decq %rsi
movq %r15, %rdi
callq 0xc410
testq %rax, %rax
je 0x2c866
movq %r15, %rdi
callq 0x28e24
movl %eax, %edi
addq %r15, %rdi
subl %eax, %r14d
leaq 0x3c64f(%rip), %rdx     # 0x68ea3
xorl %r12d, %r12d
movl %r14d, %esi
movq %rbx, %rcx
xorl %eax, %eax
callq 0x2d4b8
jmp 0x2c86a
pushq $-0x2
popq %r12
movl %r12d, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: openDirectory
static int openDirectory(const char *zFilename, int *pFd){
  sxu32 ii;
  int fd = -1;
  char zDirname[MAX_PATHNAME+1];
  sxu32 n;
  n = Systrcpy(zDirname,sizeof(zDirname),zFilename,0);
  for(ii=n; ii>1 && zDirname[ii]!='/'; ii--);
  if( ii>0 ){
    zDirname[ii] = '\0';
    fd = open(zDirname, O_RDONLY|O_BINARY, 0);
    if( fd>=0 ){
#ifdef FD_CLOEXEC
      fcntl(fd, F_SETFD, fcntl(fd, F_GETFD, 0) | FD_CLOEXEC);
#endif
    }
  }
  *pFd = fd;
  return (fd>=0?UNQLITE_OK: UNQLITE_IOERR );
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x208, %rsp            # imm = 0x208
movq %rsi, %rbx
movq %rdi, %rdx
leaq -0x220(%rbp), %rdi
movl $0x201, %esi            # imm = 0x201
xorl %ecx, %ecx
callq 0x2ca64
movl %eax, %ecx
pushq $-0x2
popq %r14
cmpl $0x2, %ecx
jb 0x2c969
movl %ecx, %edx
decl %ecx
cmpb $0x2f, -0x220(%rbp,%rdx)
jne 0x2c954
jmp 0x2c970
testl %eax, %eax
je 0x2c9b7
pushq $0x1
popq %rdx
movb $0x0, -0x220(%rbp,%rdx)
leaq -0x220(%rbp), %rdi
xorl %esi, %esi
xorl %edx, %edx
xorl %eax, %eax
callq 0xc510
movl %eax, %r15d
testl %eax, %eax
js 0x2c9bb
pushq $0x1
popq %rsi
movl %r15d, %edi
xorl %edx, %edx
xorl %eax, %eax
callq 0xc1d0
orl $0x1, %eax
pushq $0x2
popq %rsi
movl %r15d, %edi
movl %eax, %edx
xorl %eax, %eax
callq 0xc1d0
xorl %r14d, %r14d
jmp 0x2c9bb
pushq $-0x1
popq %r15
movl %r15d, (%rbx)
movl %r14d, %eax
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r14
popq %r15
popq %rbp
retq