// File: /workspace/github_c_makefile_star2_O3/gplessis[P]dotdeb-redis/deps/jemalloc/src/arena.c
// Function: je_arena_palloc
void *
arena_palloc(tsd_t *tsd, arena_t *arena, size_t usize, size_t alignment,
    bool zero, tcache_t *tcache)
{
	void *ret;

	if (usize <= SMALL_MAXCLASS && (alignment < PAGE || (alignment == PAGE
	    && (usize & PAGE_MASK) == 0))) {
		/* Small; alignment doesn't require special run placement. */
		ret = arena_malloc(tsd, arena, usize, zero, tcache);
	} else if (usize <= large_maxclass && alignment <= PAGE) {
		/*
		 * Large; alignment doesn't require special run placement.
		 * However, the cached pointer may be at a random offset from
		 * the base of the run, so do some bit manipulation to retrieve
		 * the base.
		 */
		ret = arena_malloc(tsd, arena, usize, zero, tcache);
		if (config_cache_oblivious)
			ret = (void *)((uintptr_t)ret & ~PAGE_MASK);
	} else {
		if (likely(usize <= large_maxclass)) {
			ret = arena_palloc_large(tsd, arena, usize, alignment,
			    zero);
		} else if (likely(alignment <= chunksize))
			ret = huge_malloc(tsd, arena, usize, zero, tcache);
		else {
			ret = huge_palloc(tsd, arena, usize, alignment, zero,
			    tcache);
		}
	}
	return (ret);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %r9, %r15
movq %rcx, %rbp
movq %rdx, %r13
movq %rsi, %r14
cmpq $0x3800, %rdx           # imm = 0x3800
ja 0x28d5b
cmpq $0x1000, %rbp           # imm = 0x1000
jb 0x28c88
movq %rbp, %rax
xorq $0x1000, %rax           # imm = 0x1000
movl %r13d, %ecx
andl $0xfff, %ecx            # imm = 0xFFF
orq %rax, %rcx
jne 0x28d5b
testq %r14, %r14
jne 0x28c9a
movq 0x28(%rdi), %r14
testq %r14, %r14
je 0x2943c
testq %r15, %r15
je 0x291a8
cmpq $0x1000, %r13           # imm = 0x1000
ja 0x291c5
decq %r13
shrq $0x3, %r13
leaq 0x1f302(%rip), %rax     # 0x47fc0
movzbl (%rax,%r13), %eax
movl %eax, %r12d
movq %r12, %rax
shlq $0x5, %rax
leaq (%r15,%rax), %rbx
addq $0x20, %rbx
leaq 0x1eb64(%rip), %rax     # 0x47840
movq (%rax,%r12,8), %r13
movl 0x10(%rbx), %eax
testl %eax, %eax
je 0x291de
decl %eax
movl %eax, 0x10(%rbx)
cmpl 0x8(%rbx), %eax
jl 0x29227
movq 0x18(%rbx), %rcx
movl %eax, %eax
movq (%rcx,%rax,8), %rbp
testq %rbp, %rbp
je 0x291e5
leaq 0x3190e(%rip), %rax     # 0x5a621
movb (%rax), %al
testb %r8b, %r8b
jne 0x29213
testb %al, %al
jne 0x2922f
leaq 0x31906(%rip), %rax     # 0x5a633
cmpb $0x1, (%rax)
je 0x29255
incq (%rbx)
movl 0x18(%r15), %eax
incl %eax
movl %eax, 0x18(%r15)
cmpl $0xd3, %eax
jne 0x29196
movq %r15, %rsi
callq 0x3c7e1
jmp 0x29196
movq 0x327de(%rip), %rax     # 0x5b540
cmpq %r13, %rax
setb %cl
cmpq $0x1001, %rbp           # imm = 0x1001
setae %dl
orb %cl, %dl
jne 0x28e59
testq %r14, %r14
jne 0x28d8c
movq 0x28(%rdi), %r14
testq %r14, %r14
je 0x2945e
cmpq $0x3800, %r13           # imm = 0x3800
ja 0x2929d
testq %r15, %r15
je 0x29369
cmpq $0x1000, %r13           # imm = 0x1000
ja 0x2937d
decq %r13
shrq $0x3, %r13
leaq 0x1f203(%rip), %rax     # 0x47fc0
movzbl (%rax,%r13), %eax
movl %eax, %r12d
movq %r12, %rax
shlq $0x5, %rax
leaq (%r15,%rax), %rbx
addq $0x20, %rbx
leaq 0x1ea65(%rip), %rax     # 0x47840
movq (%rax,%r12,8), %r13
movl 0x10(%rbx), %eax
testl %eax, %eax
je 0x29396
decl %eax
movl %eax, 0x10(%rbx)
cmpl 0x8(%rbx), %eax
jl 0x293df
movq 0x18(%rbx), %rcx
movl %eax, %eax
movq (%rcx,%rax,8), %rbp
testq %rbp, %rbp
je 0x2939d
leaq 0x3180f(%rip), %rax     # 0x5a621
movb (%rax), %al
testb %r8b, %r8b
jne 0x293cb
testb %al, %al
jne 0x293e7
leaq 0x31807(%rip), %rax     # 0x5a633
cmpb $0x1, (%rax)
je 0x2940d
incq (%rbx)
movl 0x18(%r15), %eax
incl %eax
movl %eax, 0x18(%r15)
cmpl $0xd3, %eax
je 0x2935c
andq $-0x1000, %rbp          # imm = 0xF000
jmp 0x29196
cmpq %r13, %rax
jb 0x2926d
movl %r8d, (%rsp)
testq %r14, %r14
jne 0x28e78
movq 0x28(%rdi), %r14
testq %r14, %r14
je 0x29479
addq $0xfff, %rbp            # imm = 0xFFF
andq $-0x1000, %rbp          # imm = 0xF000
movq %rbp, %rbx
addq %r13, %rbx
leaq 0x8(%r14), %r15
movq %r15, %rdi
callq 0x106d0
movq %r14, %rdi
movq %rbx, %rsi
xorl %edx, %edx
callq 0x28bc3
testq %rax, %rax
je 0x28f37
movq %rax, %r12
movq %r15, 0x8(%rsp)
leaq 0x327f3(%rip), %rax     # 0x5b6b0
movq (%rax), %r15
notq %r15
leaq -0x10(%r12), %r9
movq %r9, %rcx
andq %r15, %rcx
andq %r12, %r15
movq 0x32688(%rip), %rdi     # 0x5b560
leaq (%rcx,%rdi), %rax
negq %rax
addq %r12, %rax
addq $-0x10, %rax
movabsq $-0x5555555555555555, %rdx # imm = 0xAAAAAAAAAAAAAAAB
mulq %rdx
shrq $0x6, %rdx
movq 0x3265a(%rip), %rsi     # 0x5b558
leaq (%rdx,%rsi), %rax
movq %rax, %r8
shlq $0xc, %r8
addq %rcx, %r8
leaq (%r8,%rbp), %rcx
decq %rcx
negq %rbp
andq %rcx, %rbp
movq %rbp, %rcx
subq %r8, %rcx
subq %rcx, %rbx
movq %rbx, %rcx
subq %r13, %rcx
subq %r8, %rbp
jne 0x28f46
movq %r9, 0x10(%rsp)
jmp 0x2901e
movq %r15, %rdi
callq 0x10440
xorl %ebp, %ebp
jmp 0x29196
movq %rcx, 0x20(%rsp)
movq %rbp, %rcx
shrq $0xc, %rcx
addq %rax, %rcx
addq %r15, %rdi
leaq (%rcx,%rcx,2), %r8
shlq $0x5, %r8
addq %rdi, %r8
movq %rsi, %rdi
negq %rdi
leaq (%rdi,%rdi,2), %rdi
shlq $0x5, %rdi
leaq (%r8,%rdi), %r9
movq %r9, 0x10(%rsp)
addq %r8, %rdi
addq $0x10, %rdi
movq %rdi, 0x18(%rsp)
movq 0x68(%r15,%rdx,8), %r9
movl %r9d, %edx
andl $0x10, %edx
movl %r9d, %r8d
andl $0x4, %r8d
xorl %edi, %edi
testb $0x14, %r9b
sete %dil
shll $0x3, %edi
notq %rsi
addq %rcx, %rsi
movl 0x68(%r15,%rsi,8), %r9d
andl %edi, %r9d
orq %rdx, %r9
movl $0x1fe3, %r10d          # imm = 0x1FE3
orq %r10, %r9
movq %r9, 0x68(%r15,%rsi,8)
subq 0x3258d(%rip), %rax     # 0x5b558
movl 0x68(%r15,%rax,8), %esi
andl %edi, %esi
addq %rbp, %rbp
orq %rdx, %rbp
orq %r10, %rbp
orq %rsi, %rbp
movq %rbp, 0x68(%r15,%rax,8)
subq 0x3256e(%rip), %rcx     # 0x5b558
andl 0x68(%r15,%rcx,8), %edi
leaq (%rbx,%rbx), %rax
orq %rdx, %rax
orq %r10, %rax
orq %rdi, %rax
movq %rax, 0x68(%r15,%rcx,8)
shrl $0x2, %r8d
movq %r14, %rdi
movq %r12, %rsi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0x2c9d8
movq 0x20(%rsp), %rcx
movq 0x18(%rsp), %r12
movl (%rsp), %eax
leaq 0x1000(%r13), %rbp
cmpq $0x1000, %rcx           # imm = 0x1000
je 0x2904b
movq %r14, %rdi
movq %r15, %rsi
movq %r12, %rdx
movq %rbx, %rcx
movq %rbp, %r8
xorl %r9d, %r9d
callq 0x2db70
movl (%rsp), %eax
movzbl %al, %r8d
movq %r14, %rdi
movq %r12, %rsi
movq %rbp, %rdx
xorl %ecx, %ecx
callq 0x2bf9c
movq 0x324fa(%rip), %rcx     # 0x5b560
testb %al, %al
je 0x290c1
leaq -0x10(%r12), %rax
leaq 0x3263a(%rip), %rdx     # 0x5b6b0
andq (%rdx), %rax
subq %rcx, %rax
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
mulq %rcx
shrq $0x6, %rdx
movl 0x68(%r15,%rdx,8), %r8d
movl %r8d, %edx
andl $0x10, %edx
shrl $0x4, %edx
andl $0x4, %r8d
shrl $0x2, %r8d
xorl %ebp, %ebp
movq %r14, %rdi
movq %r12, %rsi
xorl %ecx, %ecx
callq 0x2c9d8
movq 0x8(%rsp), %rdi
callq 0x10440
jmp 0x29196
leaq 0x325e8(%rip), %rax     # 0x5b6b0
movq (%rax), %rbx
notq %rbx
movq 0x10(%rsp), %rax
andq %rax, %rbx
addq %rbx, %rcx
subq %rcx, %rax
movabsq $-0x5555555555555555, %rcx # imm = 0xAAAAAAAAAAAAAAAB
mulq %rcx
movq %rdx, %rbp
shrq $0x6, %rbp
addq 0x32461(%rip), %rbp     # 0x5b558
shlq $0xc, %rbp
cmpq $0x1000, %r13           # imm = 0x1000
ja 0x2948f
leaq -0x1(%r13), %rax
shrq $0x3, %rax
leaq 0x1eea9(%rip), %rcx     # 0x47fc0
movzbl (%rcx,%rax), %eax
movq 0x8(%rsp), %rdi
addq %rbx, %rbp
incq 0x78(%r14)
addl $-0x27, %eax
movq %r13, %xmm0
shufpd $0x2, 0x1ced8(%rip), %xmm0 # xmm0 = xmm0[0],mem[1]
movdqu 0x60(%r14), %xmm1
paddq %xmm1, %xmm0
movdqu %xmm0, 0x60(%r14)
movq 0x98(%r14), %rcx
shlq $0x5, %rax
incq (%rcx,%rax)
movdqu 0x10(%rcx,%rax), %xmm0
pcmpeqd %xmm1, %xmm1
psubq %xmm1, %xmm0
movdqu %xmm0, 0x10(%rcx,%rax)
callq 0x10440
cmpb $0x0, (%rsp)
jne 0x29196
leaq 0x314a4(%rip), %rax     # 0x5a621
cmpb $0x1, (%rax)
je 0x2949c
leaq 0x314a6(%rip), %rax     # 0x5a633
cmpb $0x1, (%rax)
je 0x294a6
movq %rbp, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movzbl %r8b, %edx
movq %r14, %rdi
movq %r13, %rsi
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x2872f
movq %rdi, %r12
movq %r13, %rdi
movl %r8d, %ebx
callq 0x2da8d
movq %r12, %rdi
movl %ebx, %r8d
jmp 0x28cc3
movl $0xffffffff, 0x8(%rbx)  # imm = 0xFFFFFFFF
movq %rdi, %rbp
movq %r14, %rsi
movq %r15, %rdx
movq %rbx, %rcx
movl %r8d, %r14d
movl %r12d, %r8d
callq 0x3cbd1
movq %rbp, %rdi
movl %r14d, %r8d
movq %rax, %rbp
testq %rax, %rax
jne 0x28d0c
jmp 0x28f3f
movq %rdi, %r14
testb %al, %al
je 0x29258
movq %r12, %rdi
movq %rbp, %rsi
callq 0x11f64
jmp 0x29258
movl %eax, 0x8(%rbx)
jmp 0x28cf9
leaq (%r12,%r12,2), %rax
shlq $0x5, %rax
leaq 0x31462(%rip), %rcx     # 0x5a6a0
movq %rdi, %r14
movq %rbp, %rdi
subq 0x8(%rax,%rcx), %rdi
movq 0x10(%rax,%rcx), %rdx
movl $0xa5, %esi
jmp 0x29260
movq %rdi, %r14
movq %rbp, %rdi
xorl %esi, %esi
movq %r13, %rdx
callq 0x10270
movq %r14, %rdi
jmp 0x28d36
leaq 0x32434(%rip), %rax     # 0x5b6a8
cmpq %rbp, (%rax)
jb 0x294c1
movzbl %r8b, %ecx
movq %r14, %rsi
movq %r13, %rdx
movq %r15, %r8
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x360a4
cmpq %r13, 0x3229c(%rip)     # 0x5b540
jb 0x294e4
movq %rdi, (%rsp)
testq %r15, %r15
je 0x29425
leaq 0x32b22(%rip), %rax     # 0x5bde0
cmpq %r13, (%rax)
jb 0x29425
movl %r8d, %r12d
movq %r13, %rdi
callq 0x2da8d
movl %eax, %eax
leaq 0x1e565(%rip), %rcx     # 0x47840
movq (%rcx,%rax,8), %rdx
shlq $0x5, %rax
leaq (%r15,%rax), %rbx
addq $0x20, %rbx
movl 0x10(%rbx), %eax
testl %eax, %eax
je 0x29502
decl %eax
movl %eax, 0x10(%rbx)
cmpl 0x8(%rbx), %eax
jl 0x2952b
movq 0x18(%rbx), %rcx
movl %eax, %eax
movq (%rcx,%rax,8), %rbp
testq %rbp, %rbp
je 0x29509
testb %r12b, %r12b
jne 0x294fb
leaq 0x312fa(%rip), %rax     # 0x5a621
cmpb $0x1, (%rax)
je 0x29533
leaq 0x312fc(%rip), %rax     # 0x5a633
cmpb $0x1, (%rax)
je 0x294fb
incq (%rbx)
movl 0x18(%r15), %eax
incl %eax
movl %eax, 0x18(%r15)
cmpl $0xd3, %eax
jne 0x28e4d
movq (%rsp), %rdi
movq %r15, %rsi
callq 0x3c7e1
jmp 0x28e4d
movzbl %r8b, %edx
movq %r14, %rdi
movq %r13, %rsi
callq 0x2872f
jmp 0x29434
movq %rdi, %r12
movq %r13, %rdi
movl %r8d, %ebx
callq 0x2da8d
movq %r12, %rdi
movl %ebx, %r8d
jmp 0x28dc2
movl $0xffffffff, 0x8(%rbx)  # imm = 0xFFFFFFFF
movq %rdi, %rbp
movq %r14, %rsi
movq %r15, %rdx
movq %rbx, %rcx
movl %r8d, %r14d
movl %r12d, %r8d
callq 0x3cbd1
movq %rbp, %rdi
movl %r14d, %r8d
movq %rax, %rbp
testq %rax, %rax
jne 0x28e0b
jmp 0x29472
movq %rdi, %r14
testb %al, %al
je 0x29410
movq %r12, %rdi
movq %rbp, %rsi
callq 0x11f17
jmp 0x29410
movl %eax, 0x8(%rbx)
jmp 0x28df8
leaq (%r12,%r12,2), %rax
shlq $0x5, %rax
leaq 0x312aa(%rip), %rcx     # 0x5a6a0
movq %rdi, %r14
movq %rbp, %rdi
subq 0x8(%rax,%rcx), %rdi
movq 0x10(%rax,%rcx), %rdx
movl $0xa5, %esi
jmp 0x29418
movq %rdi, %r14
movq %rbp, %rdi
xorl %esi, %esi
movq %r13, %rdx
callq 0x10270
movq %r14, %rdi
jmp 0x28e35
movzbl %r8b, %edx
movq %r14, %rdi
movq %r13, %rsi
callq 0x289f1
movq %rax, %rbp
jmp 0x28e4d
movl %r8d, %ebx
movq %rdi, %r12
callq 0x22135
testq %rax, %rax
je 0x28f3f
movq %rax, %r14
movl %ebx, %r8d
movq %r12, %rdi
jmp 0x28c9a
movl %r8d, %ebx
movq %rdi, %r12
callq 0x22135
testq %rax, %rax
jne 0x29545
xorl %ebp, %ebp
jmp 0x28e4d
callq 0x22135
testq %rax, %rax
je 0x28f3f
movq %rax, %r14
jmp 0x28e78
movq %r13, %rdi
callq 0x2da8d
jmp 0x2911b
movq %rbp, %rdi
movl $0xa5, %esi
jmp 0x294ab
movq %rbp, %rdi
xorl %esi, %esi
movq %r13, %rdx
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x10270
movzbl %r8b, %r8d
movq %r14, %rsi
movq %r13, %rdx
movq %rbp, %rcx
movq %r15, %r9
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x12382
movzbl %r8b, %ecx
movq %r14, %rsi
movq %r13, %rdx
movq %r15, %r8
callq 0x360a4
jmp 0x29434
movq %rbp, %rdi
xorl %esi, %esi
jmp 0x2953b
movl $0xffffffff, 0x8(%rbx)  # imm = 0xFFFFFFFF
movzbl %r12b, %eax
movq %r14, %rdi
movq %rdx, %rsi
movl %eax, %edx
callq 0x289f1
movq %rax, %rbp
testq %rax, %rax
jne 0x29343
jmp 0x29472
movl %eax, 0x8(%rbx)
jmp 0x29304
movq %rbp, %rdi
movl $0xa5, %esi
callq 0x10270
jmp 0x29340
movq %rax, %r14
movl %ebx, %r8d
movq %r12, %rdi
jmp 0x28d8c