// File: /workspace/github_c_makefile_star2_O0/zhou-yuxin[P]redis-aof-no-cow/deps/jemalloc/src/arena.c
// Function: arena_dalloc_bin_locked_impl
static void
arena_dalloc_bin_locked_impl(tsdn_t *tsdn, arena_t *arena, arena_chunk_t *chunk,
    void *ptr, arena_chunk_map_bits_t *bitselm, bool junked)
{
	size_t pageind, rpages_ind;
	arena_run_t *run;
	arena_bin_t *bin;
	arena_bin_info_t *bin_info;
	szind_t binind;

	pageind = ((uintptr_t)ptr - (uintptr_t)chunk) >> LG_PAGE;
	rpages_ind = pageind - arena_mapbits_small_runind_get(chunk, pageind);
	run = &arena_miscelm_get_mutable(chunk, rpages_ind)->run;
	binind = run->binind;
	bin = &arena->bins[binind];
	bin_info = &arena_bin_info[binind];

	if (!junked && config_fill && unlikely(opt_junk_free))
		arena_dalloc_junk_small(ptr, bin_info);

	arena_run_reg_dalloc(run, ptr);
	if (run->nfree == bin_info->nregs) {
		arena_dissociate_bin_run(chunk, run, bin);
		arena_dalloc_bin_run(tsdn, arena, chunk, run, bin);
	} else if (run->nfree == 1 && run != bin->runcur)
		arena_bin_lower_run(arena, run, bin);

	if (config_stats) {
		bin->stats.ndalloc++;
		bin->stats.curregs--;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xd0, %rsp
movb %r9b, %al
movq %rdi, -0x78(%rbp)
movq %rsi, -0x80(%rbp)
movq %rdx, -0x88(%rbp)
movq %rcx, -0x90(%rbp)
movq %r8, -0x98(%rbp)
andb $0x1, %al
movb %al, -0x99(%rbp)
movq -0x90(%rbp), %rax
movq -0x88(%rbp), %rcx
subq %rcx, %rax
shrq $0xc, %rax
movq %rax, -0xa8(%rbp)
movq -0xa8(%rbp), %rax
movq -0x88(%rbp), %rdx
movq -0xa8(%rbp), %rcx
movq %rdx, -0x60(%rbp)
movq %rcx, -0x68(%rbp)
movq -0x60(%rbp), %rdx
movq -0x68(%rbp), %rcx
movq %rdx, -0x40(%rbp)
movq %rcx, -0x48(%rbp)
movq -0x40(%rbp), %rdx
movq -0x48(%rbp), %rcx
movq %rdx, -0x28(%rbp)
movq %rcx, -0x30(%rbp)
movq -0x28(%rbp), %rdx
movq -0x30(%rbp), %rcx
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x18(%rbp), %rdx
movq -0x20(%rbp), %rcx
movq %rdx, -0x8(%rbp)
movq %rcx, -0x10(%rbp)
movq -0x8(%rbp), %rcx
addq $0x78, %rcx
movq -0x10(%rbp), %rdx
subq 0x64941(%rip), %rdx     # 0xa3fa0
shlq $0x3, %rdx
addq %rdx, %rcx
movq %rcx, -0x38(%rbp)
movq -0x38(%rbp), %rcx
movq (%rcx), %rcx
movq %rcx, -0x70(%rbp)
movq -0x70(%rbp), %rcx
shrq $0xd, %rcx
subq %rcx, %rax
movq %rax, -0xb0(%rbp)
movq -0x88(%rbp), %rcx
movq -0xb0(%rbp), %rax
movq %rcx, -0x50(%rbp)
movq %rax, -0x58(%rbp)
movq -0x50(%rbp), %rax
addq 0x64900(%rip), %rax     # 0xa3fa8
imulq $0x60, -0x58(%rbp), %rcx
addq %rcx, %rax
xorl %ecx, %ecx
subq 0x648e7(%rip), %rcx     # 0xa3fa0
imulq $0x60, %rcx, %rcx
addq %rcx, %rax
addq $0x18, %rax
movq %rax, -0xb8(%rbp)
movq -0xb8(%rbp), %rax
movl (%rax), %eax
movl %eax, -0xcc(%rbp)
movq -0x80(%rbp), %rax
addq $0x980, %rax            # imm = 0x980
movl -0xcc(%rbp), %ecx
imulq $0xa8, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0xc0(%rbp)
movl -0xcc(%rbp), %eax
movl %eax, %ecx
leaq 0x63eb6(%rip), %rax     # 0xa35c0
shlq $0x6, %rcx
addq %rcx, %rax
movq %rax, -0xc8(%rbp)
testb $0x1, -0x99(%rbp)
jne 0x3f74e
leaq 0x63dda(%rip), %rax     # 0xa3502
movb (%rax), %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x3f74e
movq -0x90(%rbp), %rdi
movq -0xc8(%rbp), %rsi
callq 0x3cbd0
movq -0xb8(%rbp), %rdi
movq -0x90(%rbp), %rsi
callq 0x4ebb0
movq -0xb8(%rbp), %rax
movl 0x4(%rax), %eax
movq -0xc8(%rbp), %rcx
cmpl 0x20(%rcx), %eax
jne 0x3f7b5
movq -0x88(%rbp), %rdi
movq -0xb8(%rbp), %rsi
movq -0xc0(%rbp), %rdx
callq 0x4ed10
movq -0x78(%rbp), %rdi
movq -0x80(%rbp), %rsi
movq -0x88(%rbp), %rdx
movq -0xb8(%rbp), %rcx
movq -0xc0(%rbp), %r8
callq 0x4b720
jmp 0x3f7ef
movq -0xb8(%rbp), %rax
cmpl $0x1, 0x4(%rax)
jne 0x3f7ed
movq -0xb8(%rbp), %rax
movq -0xc0(%rbp), %rcx
cmpq 0x50(%rcx), %rax
je 0x3f7ed
movq -0x80(%rbp), %rdi
movq -0xb8(%rbp), %rsi
movq -0xc0(%rbp), %rdx
callq 0x4b7c0
jmp 0x3f7ef
movq -0xc0(%rbp), %rax
movq 0x68(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x68(%rax)
movq -0xc0(%rbp), %rax
movq 0x78(%rax), %rcx
addq $-0x1, %rcx
movq %rcx, 0x78(%rax)
addq $0xd0, %rsp
popq %rbp
retq
nop