// File: /workspace/github_c_makefile_star2_O2/gplessis[P]dotdeb-redis/deps/jemalloc/src/ctl.c
// Function: arena_i_dss_ctl
static int
arena_i_dss_ctl(const size_t *mib, size_t miblen, void *oldp, size_t *oldlenp,
    void *newp, size_t newlen)
{
	int ret;
	const char *dss = NULL;
	unsigned arena_ind = mib[1];
	dss_prec_t dss_prec_old = dss_prec_limit;
	dss_prec_t dss_prec = dss_prec_limit;

	malloc_mutex_lock(&ctl_mtx);
	WRITE(dss, const char *);
	if (dss != NULL) {
		int i;
		bool match = false;

		for (i = 0; i < dss_prec_limit; i++) {
			if (strcmp(dss_prec_names[i], dss) == 0) {
				dss_prec = i;
				match = true;
				break;
			}
		}

		if (!match) {
			ret = EINVAL;
			goto label_return;
		}
	}

	if (arena_ind < ctl_stats.narenas) {
		arena_t *arena = arena_get(tsd_fetch(), arena_ind, false, true);
		if (arena == NULL || (dss_prec != dss_prec_limit &&
		    arena_dss_prec_set(arena, dss_prec))) {
			ret = EFAULT;
			goto label_return;
		}
		dss_prec_old = arena_dss_prec_get(arena);
	} else {
		if (dss_prec != dss_prec_limit &&
		    chunk_dss_prec_set(dss_prec)) {
			ret = EFAULT;
			goto label_return;
		}
		dss_prec_old = chunk_dss_prec_get();
	}

	dss = dss_prec_names[dss_prec_old];
	READ(dss, const char *);

	ret = 0;
label_return:
	malloc_mutex_unlock(&ctl_mtx);
	return (ret);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %r9, %r12
movq %r8, %r15
movq %rcx, %r14
movq %rdx, %rbx
movl 0x8(%rdi), %ebp
leaq 0x2b947(%rip), %rdi     # 0x57708
callq 0x106d0
pushq $0x16
popq %r13
testq %r15, %r15
je 0x2be0b
cmpq $0x8, %r12
jne 0x2beee
movq (%r15), %r12
testq %r12, %r12
je 0x2be0b
xorl %r15d, %r15d
leaq 0x2a5b5(%rip), %r13     # 0x563a0
cmpq $0x3, %r15
je 0x2be7f
movq (%r13,%r15,8), %rdi
movq %r12, %rsi
callq 0x10380
testl %eax, %eax
je 0x2be84
incq %r15
jmp 0x2bdeb
cmpl %ebp, 0x2b947(%rip)     # 0x57758
jbe 0x2bea6
pushq $0x3
popq %r15
movq 0x281ce(%rip), %rax     # 0x53ff0
movq %fs:0x0, %r12
addq %rax, %r12
movl %fs:(%rax), %ecx
testl %ecx, %ecx
je 0x2bf0e
cmpl $0x2, %ecx
je 0x2bf17
pushq $0x1
popq %rcx
movq %r12, %rdi
movl %ebp, %esi
xorl %edx, %edx
callq 0x2a9a9
pushq $0xe
popq %rbp
testq %rax, %rax
je 0x2bef1
movq %rax, %r12
cmpl $0x3, %r15d
je 0x2be75
movq %r12, %rdi
movl %r15d, %esi
callq 0x256a6
testb %al, %al
jne 0x2bef1
movq %r12, %rdi
callq 0x2567b
jmp 0x2beab
pushq $0x16
popq %rbp
jmp 0x2bef1
cmpl %ebp, 0x2b8ce(%rip)     # 0x57758
jbe 0x2be92
pushq $0x16
popq %r13
jmp 0x2be1b
movl %r15d, %edi
callq 0x29b95
testb %al, %al
pushq $0x16
popq %r13
je 0x2bea6
pushq $0xe
jmp 0x2be81
callq 0x29b6c
movl %eax, %eax
leaq 0x2a4ec(%rip), %rcx     # 0x563a0
movq (%rcx,%rax,8), %rax
movq %rax, (%rsp)
testq %rbx, %rbx
sete %cl
testq %r14, %r14
sete %dl
xorl %ebp, %ebp
orb %cl, %dl
jne 0x2bef1
movq (%r14), %rcx
cmpq $0x8, %rcx
jne 0x2bedc
movq %rax, (%rbx)
jmp 0x2bef1
pushq $0x8
popq %rdx
cmovbq %rcx, %rdx
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x10400
movl %r13d, %ebp
leaq 0x2b810(%rip), %rdi     # 0x57708
callq 0x10440
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x1, %fs:(%rax)
jmp 0x2bf1e
movl $0x3, %fs:(%rax)
leaq 0x2beef(%rip), %rax     # 0x57e14
movl (%rax), %edi
movq %r12, %rsi
callq 0x106f0
testl %eax, %eax
je 0x2be42
leaq 0x16f7b(%rip), %rdi     # 0x42eb9
callq 0x37d1c
leaq 0x2a6d6(%rip), %rax     # 0x56620
cmpb $0x1, (%rax)
jne 0x2be42
callq 0x10090