// File: /workspace/github_c_makefile_star2_O2/gplessis[P]dotdeb-redis/deps/jemalloc/src/huge.c
// Function: je_huge_dalloc
void
huge_dalloc(tsd_t *tsd, void *ptr, tcache_t *tcache)
{
	extent_node_t *node;
	arena_t *arena;

	node = huge_node_get(ptr);
	arena = extent_node_arena_get(node);
	huge_node_unset(ptr, node);
	malloc_mutex_lock(&arena->huge_mtx);
	ql_remove(&arena->huge, node, ql_link);
	malloc_mutex_unlock(&arena->huge_mtx);

	huge_dalloc_junk(extent_node_addr_get(node),
	    extent_node_size_get(node));
	arena_chunk_dalloc_huge(extent_node_arena_get(node),
	    extent_node_addr_get(node), extent_node_size_get(node));
	idalloctm(tsd, node, tcache, true);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdx, 0x10(%rsp)
movq %rsi, %r15
movq %rdi, 0x8(%rsp)
leaq 0x25844(%rip), %rbp     # 0x56622
leaq 0x26773(%rip), %rbx     # 0x57558
movq %rbp, %r14
movq %r15, %rdi
callq 0x3110a
movq %rax, %r12
movq (%rax), %rbp
movq %r15, %rdi
movq %rax, %rsi
callq 0x28f90
leaq 0x1d8(%rbp), %r13
movq %r13, %rdi
callq 0x106d0
movq 0x1d0(%rbp), %rax
cmpq %r12, %rax
jne 0x30e27
movq 0x48(%rax), %rax
movq %rax, 0x1d0(%rbp)
movq %r12, %r15
cmpq %r12, %rax
je 0x30e4d
movq 0x48(%r15), %rax
movq 0x50(%r15), %rcx
movq %rax, 0x48(%rcx)
movq 0x50(%r15), %rcx
movq %rcx, 0x50(%rax)
movq %r15, 0x48(%r15)
movq %r15, 0x50(%r15)
jmp 0x30e55
andq $0x0, 0x1d0(%rbp)
movq %r13, %rdi
callq 0x10440
movq %r14, %rbp
cmpb $0x1, (%r14)
je 0x30ee2
movq (%r15), %rdi
movq 0x8(%r15), %rsi
movq 0x10(%r15), %rdx
callq 0x22433
leaq 0x26833(%rip), %rdx     # 0x576b0
movq (%rdx), %rax
notq %rax
andq %r12, %rax
cmpq %rax, %r12
je 0x30ef7
movq (%rax), %r13
cmpq %rax, %r12
je 0x30f17
movq %r12, %rcx
subq %rax, %rcx
shrq $0xc, %rcx
subq (%rbx), %rcx
movq 0x68(%rax,%rcx,8), %rax
movl %eax, %ecx
shrl $0x5, %ecx
movl $0xff, %esi
andl %esi, %ecx
cmpl %esi, %ecx
je 0x30f28
movl %ecx, %eax
leaq 0x114be(%rip), %rcx     # 0x42380
movq (%rcx,%rax,8), %rax
negq %rax
lock
xaddq %rax, 0x58(%r13)
movq (%rdx), %rsi
notq %rsi
andq %r12, %rsi
subq %rsi, %r12
jne 0x30f39
jmp 0x30de5
movq 0x8(%r15), %rdi
movq 0x10(%r15), %rdx
pushq $0x5a
popq %rsi
callq 0x10270
jmp 0x30e66
movq %r15, %rdi
callq 0x311b6
leaq 0x267aa(%rip), %rdx     # 0x576b0
movq %rax, %r13
movq (%rdx), %rax
notq %rax
andq %r12, %rax
jmp 0x30e8e
movq %r15, %rdi
callq 0x311c1
leaq 0x2678a(%rip), %rdx     # 0x576b0
jmp 0x30ec6
shrq %rax
andq $-0x1000, %rax          # imm = 0xF000
addq $-0x1000, %rax          # imm = 0xF000
jmp 0x30ec6
shrq $0xc, %r12
movq %r12, %rax
subq (%rbx), %rax
movq 0x68(%rsi,%rax,8), %rax
testb $0x2, %al
jne 0x30fc1
movq 0x10(%rsp), %rbx
testq %rbx, %rbx
je 0x31004
shrl $0x5, %eax
movzbl %al, %r12d
cmpb $0x1, (%rbp)
je 0x3103b
movl %r12d, %eax
shll $0x5, %eax
leaq (%rbx,%rax), %r13
addq $0x20, %r13
leaq 0x26e30(%rip), %rax     # 0x57db0
movq (%rax), %rax
movl 0x10(%r13), %r8d
cmpl (%rax,%r12,4), %r8d
je 0x31053
movq 0x18(%r13), %rax
movl %r8d, %ecx
movq %r15, (%rax,%rcx,8)
incl %r8d
movl %r8d, 0x10(%r13)
movl 0x18(%rbx), %eax
incl %eax
movl %eax, 0x18(%rbx)
cmpl $0xd3, %eax
je 0x31020
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x10(%rsp), %rbx
testq %rbx, %rbx
je 0x30feb
shrq %rax
andq $-0x1000, %rax          # imm = 0xF000
leaq -0x1000(%rax), %r12
leaq 0x26dfe(%rip), %rcx     # 0x57de0
cmpq (%rcx), %r12
jbe 0x31072
movq (%rsi), %rdi
movq %r15, %rdx
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x24608
movq (%rsi), %rdi
movq %r15, %rdx
movq %r12, %rcx
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x244f0
movq 0x8(%rsp), %rdi
movq %rbx, %rsi
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x36f85
imulq $0x60, %r12, %rsi
addq 0x22f92(%rip), %rsi     # 0x53fd8
movq %r15, %rdi
callq 0x233ee
jmp 0x30f6b
shrl %r8d
movq 0x8(%rsp), %rdi
movq %rbx, %rsi
movq %r13, %rdx
movl %r12d, %ecx
callq 0x37034
movl 0x10(%r13), %r8d
jmp 0x30f91
cmpq $0x1000, %r12           # imm = 0x1000
ja 0x310d4
addq $-0x1001, %rax          # imm = 0xEFFF
shrq $0x3, %rax
leaq 0x11a74(%rip), %rcx     # 0x42b00
movzbl (%rcx,%rax), %r13d
cmpb $0x1, (%rbp)
je 0x310e1
movl %r13d, %eax
movq %rax, %rcx
shlq $0x5, %rcx
leaq (%rbx,%rcx), %r12
addq $0x20, %r12
leaq 0x26d00(%rip), %rcx     # 0x57db0
movq (%rcx), %rdx
movl 0x10(%r12), %ecx
cmpl (%rdx,%rax,4), %ecx
je 0x310ee
movq 0x18(%r12), %rax
movl %ecx, %edx
movq %r15, (%rax,%rdx,8)
incl %ecx
movl %ecx, 0x10(%r12)
jmp 0x30fa3
movq %r12, %rdi
callq 0x31263
movl %eax, %r13d
jmp 0x31091
movq %r15, %rdi
movq %r12, %rsi
callq 0x244f5
jmp 0x31097
shrl %ecx
movq 0x8(%rsp), %rdi
movq %r12, %rsi
movl %r13d, %edx
movq %rbx, %r8
callq 0x371b7
movl 0x10(%r12), %ecx
jmp 0x310bd