// File: /workspace/github_c_makefile_star2_O0/gplessis[P]dotdeb-redis/src/t_zset.c
// Function: zslDeleteRangeByScore
unsigned long zslDeleteRangeByScore(zskiplist *zsl, zrangespec *range, dict *dict) {
    zskiplistNode *update[ZSKIPLIST_MAXLEVEL], *x;
    unsigned long removed = 0;
    int i;

    x = zsl->header;
    for (i = zsl->level-1; i >= 0; i--) {
        while (x->level[i].forward && (range->minex ?
            x->level[i].forward->score <= range->min :
            x->level[i].forward->score < range->min))
                x = x->level[i].forward;
        update[i] = x;
    }

    /* Current node is the last with score < or <= min. */
    x = x->level[0].forward;

    /* Delete nodes while in range. */
    while (x &&
           (range->maxex ? x->score < range->max : x->score <= range->max))
    {
        zskiplistNode *next = x->level[0].forward;
        zslDeleteNode(zsl,x,update);
        dictDelete(dict,x->obj);
        zslFreeNode(x);
        removed++;
        x = next;
    }
    return removed;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x150, %rsp            # imm = 0x150
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq $0x0, -0x130(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x128(%rbp)
movq -0x8(%rbp), %rax
movl 0x18(%rax), %eax
subl $0x1, %eax
movl %eax, -0x134(%rbp)
cmpl $0x0, -0x134(%rbp)
jl 0x5ef7c
jmp 0x5ee5f
movq -0x128(%rbp), %rcx
addq $0x18, %rcx
movslq -0x134(%rbp), %rax
shlq $0x4, %rax
addq %rax, %rcx
xorl %eax, %eax
cmpq $0x0, (%rcx)
movb %al, -0x141(%rbp)
je 0x5ef1e
movq -0x10(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x5eed1
movq -0x128(%rbp), %rax
addq $0x18, %rax
movslq -0x134(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movsd 0x8(%rax), %xmm1
movq -0x10(%rbp), %rax
movsd (%rax), %xmm0
ucomisd %xmm1, %xmm0
setae %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x148(%rbp)
jmp 0x5ef0c
movq -0x128(%rbp), %rax
addq $0x18, %rax
movslq -0x134(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movsd 0x8(%rax), %xmm1
movq -0x10(%rbp), %rax
movsd (%rax), %xmm0
ucomisd %xmm1, %xmm0
seta %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x148(%rbp)
movl -0x148(%rbp), %eax
cmpl $0x0, %eax
setne %al
movb %al, -0x141(%rbp)
movb -0x141(%rbp), %al
testb $0x1, %al
jne 0x5ef2a
jmp 0x5ef52
movq -0x128(%rbp), %rax
addq $0x18, %rax
movslq -0x134(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq %rax, -0x128(%rbp)
jmp 0x5ee5f
movq -0x128(%rbp), %rcx
movslq -0x134(%rbp), %rax
movq %rcx, -0x120(%rbp,%rax,8)
movl -0x134(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x134(%rbp)
jmp 0x5ee50
movq -0x128(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x128(%rbp)
xorl %eax, %eax
cmpq $0x0, -0x128(%rbp)
movb %al, -0x149(%rbp)
je 0x5f00c
movq -0x10(%rbp), %rax
cmpl $0x0, 0x14(%rax)
je 0x5efd3
movq -0x128(%rbp), %rax
movsd 0x8(%rax), %xmm1
movq -0x10(%rbp), %rax
movsd 0x8(%rax), %xmm0
ucomisd %xmm1, %xmm0
seta %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x150(%rbp)
jmp 0x5effa
movq -0x128(%rbp), %rax
movsd 0x8(%rax), %xmm1
movq -0x10(%rbp), %rax
movsd 0x8(%rax), %xmm0
ucomisd %xmm1, %xmm0
setae %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x150(%rbp)
movl -0x150(%rbp), %eax
cmpl $0x0, %eax
setne %al
movb %al, -0x149(%rbp)
movb -0x149(%rbp), %al
testb $0x1, %al
jne 0x5f018
jmp 0x5f085
movq -0x128(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x140(%rbp)
movq -0x8(%rbp), %rdi
movq -0x128(%rbp), %rsi
leaq -0x120(%rbp), %rdx
callq 0x5e670
movq -0x18(%rbp), %rdi
movq -0x128(%rbp), %rax
movq (%rax), %rsi
callq 0x2de50
movq -0x128(%rbp), %rdi
callq 0x5e070
movq -0x130(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x130(%rbp)
movq -0x140(%rbp), %rax
movq %rax, -0x128(%rbp)
jmp 0x5ef8e
movq -0x130(%rbp), %rax
addq $0x150, %rsp            # imm = 0x150
popq %rbp
retq
nopw %cs:(%rax,%rax)