// File: /workspace/github_c_makefile_star2_O3/nilyang[P]redis-tdd-annotation/deps/jemalloc/src/jemalloc.c
// Function: je_dallocm
int
je_dallocm(void *ptr, int flags)
{
	size_t usize;
	size_t rzsize JEMALLOC_CC_SILENCE_INIT(0);
	unsigned arena_ind = ((unsigned)(flags >> 8)) - 1;
	bool try_tcache;

	assert(ptr != NULL);
	assert(malloc_initialized || IS_INITIALIZER);

	if (arena_ind != UINT_MAX) {
		arena_chunk_t *chunk = (arena_chunk_t *)CHUNK_ADDR2BASE(ptr);
		try_tcache = (chunk == ptr || chunk->arena !=
		    arenas[arena_ind]);
	} else
		try_tcache = true;

	UTRACE(ptr, 0, 0);
	if (config_stats || config_valgrind)
		usize = isalloc(ptr, config_prof);
	if (config_prof && opt_prof) {
		if (config_stats == false && config_valgrind == false)
			usize = isalloc(ptr, config_prof);
		prof_free(ptr, usize);
	}
	if (config_stats)
		thread_allocated_tsd_get()->deallocated += usize;
	if (config_valgrind && opt_valgrind)
		rzsize = p2rz(ptr);
	iqallocx(ptr, try_tcache);
	JEMALLOC_VALGRIND_FREE(ptr, rzsize);

	return (ALLOCM_SUCCESS);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x48, %rsp
movq %rdi, %rbx
cmpl $0x100, %esi            # imm = 0x100
setb %cl
leaq 0x6055e(%rip), %r14     # 0xdf880
movq (%r14), %rax
notq %rax
andq %rdi, %rax
cmpq %rdi, %rax
sete %dl
orb %cl, %dl
movb $0x1, %bpl
jne 0x7f34f
sarl $0x8, %esi
decl %esi
movq (%rax), %rcx
movq 0x5f831(%rip), %rdx     # 0xdeb78
cmpq (%rdx,%rsi,8), %rcx
setne %bpl
cmpq %rbx, %rax
je 0x7f389
movq %rbx, %rcx
subq %rax, %rcx
shrq $0xc, %rcx
leaq 0x605c3(%rip), %rdx     # 0xdf928
subq (%rdx), %rcx
leaq (%rcx,%rcx,2), %rcx
movq 0x40(%rax,%rcx,8), %rax
movl %eax, %ecx
shrl $0x4, %ecx
movl $0xff, %edx
andl %edx, %ecx
cmpl %edx, %ecx
jne 0x7f393
andq $-0x1000, %rax          # imm = 0xF000
jmp 0x7f3a2
movq %rbx, %rdi
callq 0x8be94
jmp 0x7f3a2
imulq $0x68, %rcx, %rax
leaq 0x5f862(%rip), %rcx     # 0xdec00
movq (%rcx,%rax), %rax
addq %rax, %fs:-0x20
cmpb $0x1, 0x5f7b8(%rip)     # 0xdeb6a
jne 0x7f440
movq (%r14), %rax
notq %rax
andq %rbx, %rax
cmpq %rbx, %rax
je 0x7f3fb
movq %rbx, %rcx
subq %rax, %rcx
shrq $0xc, %rcx
leaq 0x60551(%rip), %rdx     # 0xdf928
subq (%rdx), %rcx
leaq (%rcx,%rcx,2), %rcx
movq 0x40(%rax,%rcx,8), %rax
movl %eax, %ecx
shrl $0x4, %ecx
movl $0xff, %edx
andl %edx, %ecx
cmpl %edx, %ecx
jne 0x7f405
andq $-0x1000, %rax          # imm = 0xF000
jmp 0x7f414
movq %rbx, %rdi
callq 0x8be94
jmp 0x7f414
imulq $0x68, %rcx, %rax
leaq 0x5f7f0(%rip), %rcx     # 0xdec00
movq (%rcx,%rax), %rax
cmpq $0xe00, %rax            # imm = 0xE00
ja 0x7f440
decq %rax
shrq $0x3, %rax
leaq 0x23d96(%rip), %rcx     # 0xa31c0
movzbl (%rcx,%rax), %eax
imulq $0x68, %rax, %rax
leaq 0x5f7c7(%rip), %rcx     # 0xdec00
movq 0x8(%rcx,%rax), %r15
jmp 0x7f443
xorl %r15d, %r15d
cmpq $0x0, 0x5f715(%rip)     # 0xdeb60
je 0x7f457
movq %rbx, %rdi
callq 0x8da50
jmp 0x7f483
movq (%r14), %rsi
notq %rsi
andq %rbx, %rsi
cmpq %rbx, %rsi
je 0x7f476
movq (%rsi), %rdi
movzbl %bpl, %ecx
movq %rbx, %rdx
callq 0x7f86f
jmp 0x7f483
movq %rbx, %rdi
movl $0x1, %esi
callq 0x8bdfd
cmpb $0x1, 0x5f6e0(%rip)     # 0xdeb6a
jne 0x7f4cd
leaq 0x10(%rsp), %rax
movq $0x1302, (%rax)         # imm = 0x1302
movq %rbx, 0x8(%rax)
movq %r15, 0x10(%rax)
xorl %ecx, %ecx
movq %rcx, 0x18(%rax)
movq %rcx, 0x20(%rax)
movq %rcx, 0x28(%rax)
xorl %edx, %edx
rolq $0x3, %rdi
rolq $0xd, %rdi
rolq $0x3d, %rdi
rolq $0x33, %rdi
xchgq %rbx, %rbx
movq %rdx, 0x8(%rsp)
movq 0x8(%rsp), %rax
xorl %eax, %eax
addq $0x48, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq