// File: /workspace/github_c_makefile_star2_O1/coyove[P]chann/./lib/unqlite/unqlite.c
// Function: jx9VmThrowError
JX9_PRIVATE sxi32 jx9VmThrowError(
	jx9_vm *pVm,         /* Target VM */
	SyString *pFuncName, /* Function name. NULL otherwise */
	sxi32 iErr,          /* Severity level: [i.e: Error, Warning or Notice]*/
	const char *zMessage /* Null terminated error message */
	)
{
	SyBlob *pWorker = &pVm->sWorker;
	SyString *pFile;
	char *zErr;
	sxi32 rc;
	if( !pVm->bErrReport ){
		/* Don't bother reporting errors */
		return SXRET_OK;
	}
	/* Reset the working buffer */
	SyBlobReset(pWorker);
	/* Peek the processed file if available */
	pFile = (SyString *)SySetPeek(&pVm->aFiles);
	if( pFile ){
		/* Append file name */
		SyBlobAppend(pWorker, pFile->zString, pFile->nByte);
		SyBlobAppend(pWorker, (const void *)" ", sizeof(char));
	}
	zErr = "Error: ";
	switch(iErr){
	case JX9_CTX_WARNING: zErr = "Warning: "; break;
	case JX9_CTX_NOTICE:  zErr = "Notice: ";  break;
	default:
		iErr = JX9_CTX_ERR;
		break;
	}
	SyBlobAppend(pWorker, zErr, SyStrlen(zErr));
	if( pFuncName ){
		/* Append function name first */
		SyBlobAppend(pWorker, pFuncName->zString, pFuncName->nByte);
		SyBlobAppend(pWorker, "(): ", sizeof("(): ")-1);
	}
	SyBlobAppend(pWorker, zMessage, SyStrlen(zMessage));
	/* Consume the error message */
	rc = VmCallErrorHandler(&(*pVm), pWorker);
	return rc;
}

// Assembly:
cmpl $0x0, 0x4e8(%rdi)
je 0x415ad
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rcx, %r14
movl %edx, %r13d
movq %rsi, %r12
movq %rdi, %rbx
movl $0x0, 0x3b8(%rdi)
movl 0x3c0(%rdi), %eax
testb $0x4, %al
je 0x41591
movq $0x0, 0x3b0(%rbx)
movl $0x0, 0x3bc(%rbx)
andl $-0x5, %eax
movl %eax, 0x3c0(%rbx)
movl 0x3f8(%rbx), %eax
testl %eax, %eax
je 0x415b0
decl %eax
imull 0x400(%rbx), %eax
addq 0x3f0(%rbx), %rax
jmp 0x415b2
xorl %eax, %eax
retq
xorl %eax, %eax
leaq 0x3a8(%rbx), %r15
testq %rax, %rax
je 0x415e0
movq (%rax), %rsi
movl 0x8(%rax), %edx
movq %r15, %rdi
callq 0x360ae
leaq 0x38543(%rip), %rsi     # 0x79b16
movq %r15, %rdi
movl $0x1, %edx
callq 0x360ae
cmpl $0x3, %r13d
leaq 0x34b74(%rip), %rax     # 0x7615f
leaq 0x34b5b(%rip), %rcx     # 0x7614d
cmoveq %rax, %rcx
cmpl $0x2, %r13d
leaq 0x34b54(%rip), %rsi     # 0x76155
cmovneq %rcx, %rsi
cmpb $0x0, (%rsi)
movq %rsi, %rdx
je 0x41640
leaq 0x2(%rsi), %rdx
cmpb $0x0, -0x1(%rdx)
je 0x41638
cmpb $0x0, (%rdx)
je 0x41640
cmpb $0x0, 0x1(%rdx)
je 0x4163d
leaq 0x4(%rdx), %rax
cmpb $0x0, 0x2(%rdx)
movq %rax, %rdx
jne 0x41611
addq $-0x2, %rax
movq %rax, %rdx
jmp 0x41640
decq %rdx
jmp 0x41640
incq %rdx
subl %esi, %edx
movq %r15, %rdi
callq 0x360ae
testq %r12, %r12
je 0x41674
movq (%r12), %rsi
movl 0x8(%r12), %edx
movq %r15, %rdi
callq 0x360ae
leaq 0x34b01(%rip), %rsi     # 0x76168
movq %r15, %rdi
movl $0x4, %edx
callq 0x360ae
cmpb $0x0, (%r14)
movq %r14, %rdx
je 0x416b0
leaq 0x2(%r14), %rdx
cmpb $0x0, -0x1(%rdx)
je 0x416a8
cmpb $0x0, (%rdx)
je 0x416b0
cmpb $0x0, 0x1(%rdx)
je 0x416ad
leaq 0x4(%rdx), %rax
cmpb $0x0, 0x2(%rdx)
movq %rax, %rdx
jne 0x41681
addq $-0x2, %rax
movq %rax, %rdx
jmp 0x416b0
decq %rdx
jmp 0x416b0
incq %rdx
subl %r14d, %edx
movq %r15, %rdi
movq %r14, %rsi
callq 0x360ae
leaq 0x38c1c(%rip), %rsi     # 0x7a2e1
movq %r15, %rdi
movl $0x1, %edx
callq 0x360ae
movq 0x3b0(%rbx), %rdi
movl 0x3b8(%rbx), %esi
movq 0x500(%rbx), %rdx
callq *0x4f8(%rbx)
movl 0x3b8(%rbx), %ecx
addl %ecx, 0x4f4(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq