// File: /workspace/github_c_makefile_star2_O3/mmcco[P]sljit/sljit_src/sljitNativeX86_common.c
// Function: sljit_emit_const
struct sljit_const* sljit_emit_const(struct sljit_compiler *compiler, int dst, long dstw, long init_value)
{
	u_char *inst;
	struct sljit_const *const_;
#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
	int reg;
#endif

	CHECK_ERROR_PTR();
	CHECK_PTR(check_sljit_emit_const(compiler, dst, dstw, init_value));
	ADJUST_LOCAL_OFFSET(dst, dstw);

	CHECK_EXTRA_REGS(dst, dstw, (void)0);

	const_ = ensure_abuf(compiler, sizeof(struct sljit_const));
	if (!const_)
		return NULL;
	set_const(const_, compiler);

#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
	compiler->mode32 = 0;
	reg = SLOW_IS_REG(dst) ? dst : TMP_REG1;

	if (emit_load_imm64(compiler, reg, init_value))
		return NULL;
#else
	if (dst == SLJIT_UNUSED)
		dst = TMP_REG1;

	if (emit_mov(compiler, dst, dstw, SLJIT_IMM, init_value))
		return NULL;
#endif

	inst = ensure_buf(compiler, 2);
	if (!inst)
		return NULL;

	*inst++ = 0;
	*inst++ = 1;

#if (defined SLJIT_CONFIG_X86_64 && SLJIT_CONFIG_X86_64)
	if (dst & SLJIT_MEM)
		if (emit_mov(compiler, dst, dstw, TMP_REG1, 0))
			return NULL;
#endif

	return const_;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
cmpl $0x0, (%rdi)
je 0x1e43d
xorl %r12d, %r12d
movq %r12, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rdi, %rbx
movl 0x48(%rdi), %eax
cmpl $-0x1, %eax
je 0x1e7c4
movq %rdx, %r12
movl 0x4c(%rbx), %edx
cmpl $-0x1, %edx
je 0x1e7c4
movq %rcx, %r15
movl %esi, %r14d
testl %esi, %esi
je 0x1e48e
setg %cl
cmpl %r14d, %eax
setge %sil
testb %sil, %cl
jne 0x1e48e
movl $0xc, %ecx
subl %edx, %ecx
cmpl %r14d, %ecx
setge %dl
cmpl $0xd, %r14d
setge %sil
orb %dl, %sil
jne 0x1e50a
testq %r12, %r12
jne 0x1e7c4
movq 0x78(%rbx), %rcx
testq %rcx, %rcx
je 0x1e6ea
leaq 0x521d(%rip), %rdi      # 0x236c8
movl $0x8, %esi
movl $0x1, %edx
callq 0x2130
testb $0x40, %r14b
jne 0x1e4f0
testb %r14b, %r14b
js 0x1e531
testl %r14d, %r14d
je 0x1e5d9
movq 0x78(%rbx), %rdi
cmpl %r14d, 0x48(%rbx)
jge 0x1e60a
movl $0xc, %edx
subl %r14d, %edx
leaq 0x50b7(%rip), %rsi      # 0x235a2
jmp 0x1e615
movq 0x78(%rbx), %rdi
leaq 0x4f46(%rip), %rsi      # 0x23441
movq %r12, %rdx
xorl %eax, %eax
callq 0x20c0
jmp 0x1e6d5
cmpl $0x8d, %r14d
jne 0x1e56b
testq %r12, %r12
js 0x1e7c4
movslq 0x80(%rbx), %rax
cmpq %r12, %rax
jg 0x1e497
jmp 0x1e7c4
movl %r14d, %ebp
movq 0x78(%rbx), %rsi
andl $0x3f, %ebp
je 0x1e5f8
movl $0x5b, %edi
callq 0x20a0
movq 0x78(%rbx), %rdi
cmpl 0x48(%rbx), %ebp
jle 0x1e621
movl $0xc, %edx
subl %ebp, %edx
leaq 0x503c(%rip), %rsi      # 0x235a2
jmp 0x1e62c
testb %r14b, %r14b
jns 0x1e7c4
movl %r14d, %edx
andl $0x3f, %edx
je 0x1e7ae
cmpl %eax, %edx
jle 0x1e595
cmpl $0xc, %edx
ja 0x1e7c4
cmpl %ecx, %edx
jle 0x1e7c4
testl $0x3f00, %r14d          # imm = 0x3F00
je 0x1e7b7
movl %r14d, %edx
shrl $0x8, %edx
andl $0x3f, %edx
setne %sil
cmpl %eax, %edx
setle %al
testb %al, %sil
jne 0x1e5ca
cmpl $0xc, %edx
ja 0x1e7c4
cmpl %ecx, %edx
jle 0x1e7c4
cmpq $0x4, %r12
jb 0x1e7b7
jmp 0x1e7c4
movq 0x78(%rbx), %rcx
leaq 0x4e7a(%rip), %rdi      # 0x2345e
movl $0x6, %esi
movl $0x1, %edx
callq 0x2130
jmp 0x1e6d5
leaq 0x4e58(%rip), %rax      # 0x23457
movq %rsi, %rdi
movq %rax, %rsi
jmp 0x1e4fb
leal -0x1(%r14), %edx
leaq 0x4f88(%rip), %rsi      # 0x2359d
xorl %eax, %eax
callq 0x20c0
jmp 0x1e6d5
decl %ebp
leaq 0x4f73(%rip), %rsi      # 0x2359d
movl %ebp, %edx
xorl %eax, %eax
callq 0x20c0
testl $0x3f00, %r14d          # imm = 0x3F00
je 0x1e67a
movq 0x78(%rbx), %rcx
leaq 0x4dff(%rip), %rdi      # 0x23446
movl $0x3, %esi
movl $0x1, %edx
callq 0x2130
movl %r14d, %edx
shrl $0x8, %edx
andl $0x3f, %edx
movq 0x78(%rbx), %rdi
cmpl 0x48(%rbx), %edx
jle 0x1e696
movl $0xc, %eax
subl %edx, %eax
leaq 0x4f2c(%rip), %rsi      # 0x235a2
movl %eax, %edx
jmp 0x1e69f
testq %r12, %r12
je 0x1e6c7
movq 0x78(%rbx), %rdi
leaq 0x4dc6(%rip), %rsi      # 0x23450
movq %r12, %rdx
xorl %eax, %eax
callq 0x20c0
jmp 0x1e6c7
decl %edx
leaq 0x4efe(%rip), %rsi      # 0x2359d
xorl %eax, %eax
callq 0x20c0
testq %r12, %r12
je 0x1e6c7
movq 0x78(%rbx), %rdi
movl $0x1, %edx
movl %r12d, %ecx
shll %cl, %edx
leaq 0x4d8a(%rip), %rsi      # 0x2344a
xorl %eax, %eax
callq 0x20c0
movq 0x78(%rbx), %rsi
movl $0x5d, %edi
callq 0x20a0
movq 0x78(%rbx), %rdi
leaq 0x4fe0(%rip), %rsi      # 0x236c0
movq %r15, %rdx
xorl %eax, %eax
callq 0x20c0
leaq 0x8(%r12), %r13
cmpl $0x8d, %r14d
cmovneq %r12, %r13
movl $0x10, %esi
movq %rbx, %rdi
callq 0x14955
testq %rax, %rax
je 0x1e428
movq %rax, %r12
movq $0x0, (%rax)
movq 0x60(%rbx), %rax
movq %rax, 0x8(%r12)
movq 0x30(%rbx), %rax
leaq 0x18(%rbx), %rcx
testq %rax, %rax
cmovneq %rax, %rcx
movq %r12, (%rcx)
movq %r12, 0x30(%rbx)
movl $0x0, 0x70(%rbx)
leal -0x1(%r14), %eax
cmpl $0x3f, %eax
movl $0xe, %esi
cmovbl %r14d, %esi
movq %rbx, %rdi
movq %r15, %rdx
callq 0x1683c
testl %eax, %eax
jne 0x1e428
movl $0x2, %esi
movq %rbx, %rdi
callq 0x15218
testq %rax, %rax
je 0x1e428
movw $0x100, (%rax)          # imm = 0x100
testb %r14b, %r14b
jns 0x1e42b
movq %rbx, %rdi
movl $0x1, %esi
movl $0xe, %edx
xorl %ecx, %ecx
movl %r14d, %r8d
movq %r13, %r9
callq 0x15da2
testq %rax, %rax
je 0x1e7dc
movb $-0x77, (%rax)
jmp 0x1e42b
testl $0x3f00, %r14d          # imm = 0x3F00
jne 0x1e7c4
cmpl $0x4000, %r14d          # imm = 0x4000
jb 0x1e497
leaq 0x4b74(%rip), %rdi      # 0x2333f
movl $0x5a2, %esi            # imm = 0x5A2
xorl %eax, %eax
callq 0x2080
callq 0x2040
cmpl $0x0, (%rbx)
jne 0x1e428
jmp 0x1e42b