// File: /workspace/github_c_makefile_star2_O2/samtools[P]htslib/vcf_sweep.c
// Function: bcf_sweep_bwd
bcf1_t *bcf_sweep_bwd(bcf_sweep_t *sw)
{
    if ( sw->direction==SW_FWD ) sw_seek(sw, SW_BWD);
    if ( !sw->nrec ) sw_fill_buffer(sw);
    if ( !sw->nrec ) return NULL;
    return &sw->rec[ --sw->nrec ];
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
cmpl $0x0, 0x18(%rdi)
je 0x5ef1
movl 0x28(%rbx), %eax
testl %eax, %eax
jne 0x60b8
jmp 0x5f02
movl $0x1, 0x18(%rbx)
movl 0x5c(%rbx), %eax
movl %eax, 0x58(%rbx)
andl $0x0, 0x28(%rbx)
movslq 0x58(%rbx), %rax
testq %rax, %rax
je 0x60cc
leaq -0x1(%rax), %rcx
movl %ecx, 0x58(%rbx)
movq (%rbx), %rdi
movq 0x50(%rbx), %rcx
movq -0x8(%rcx,%rax,8), %rsi
xorl %edx, %edx
callq 0x1f4ec
testl %eax, %eax
jne 0x60dd
andl $0x0, 0x28(%rbx)
leaq 0x20(%rbx), %r15
movq 0x20(%rbx), %r13
leaq 0x48(%rbx), %rax
movq %rax, 0x10(%rsp)
pushq $0x1
popq %rbp
leaq 0x7c17d(%rip), %r14     # 0x820cd
pushq $0x4
popq %r12
movq (%rbx), %rdi
movq 0x8(%rbx), %rsi
movq %r13, %rdx
callq 0x9fd2
testl %eax, %eax
jne 0x601d
movq %r13, %rdi
movl %ebp, %esi
callq 0xed9c
movl 0x58(%rbx), %eax
incl %eax
cmpl 0x5c(%rbx), %eax
jge 0x5fd5
movl 0x30(%rbx), %eax
cmpl 0x10(%r13), %eax
jne 0x5fd5
movslq 0x34(%rbx), %rax
cmpq %rax, (%r13)
jne 0x5fd5
movl 0x38(%rbx), %eax
movzwl 0x1a(%r13), %ecx
cmpl %ecx, %eax
jne 0x5fd5
movq 0x88(%r13), %rdx
movq -0x8(%rdx,%rax,8), %rcx
movq (%rdx), %rsi
movl %ecx, %eax
subl %esi, %eax
incl %eax
cmpb $0x0, (%rcx)
leaq 0x1(%rcx), %rcx
jne 0x5fb1
cmpl %eax, 0x3c(%rbx)
jne 0x5fd5
movq 0x10(%rsp), %rcx
movq (%rcx), %rdi
movslq %eax, %rdx
callq 0x44e0
testl %eax, %eax
je 0x601d
movl 0x28(%rbx), %ecx
leal 0x1(%rcx), %eax
movl %eax, 0x28(%rbx)
leal 0x2(%rcx), %edi
movslq 0x2c(%rbx), %rsi
cmpl %esi, %edi
jle 0x600c
cmpl $-0x1, %ecx
cmovll %ebp, %edi
movq %r14, (%rsp)
movl $0xd0, %ecx
movq %r12, %rdx
movl %ebp, %r8d
movq %r15, %r9
callq 0x24acb
movl %eax, 0x2c(%rbx)
movl 0x28(%rbx), %eax
cltq
imulq $0xd0, %rax, %r13
addq (%r15), %r13
jmp 0x5f54
movq 0x20(%rbx), %r14
movl 0x10(%r14), %eax
movl %eax, 0x30(%rbx)
movl (%r14), %eax
movl %eax, 0x34(%rbx)
movl 0x18(%r14), %eax
shrl $0x10, %eax
movl %eax, 0x38(%rbx)
movq 0x88(%r14), %rcx
movq -0x8(%rcx,%rax,8), %rax
movq (%rcx), %rsi
movl %eax, %r15d
subl %esi, %r15d
incl %r15d
cmpb $0x0, (%rax)
leaq 0x1(%rax), %rax
jne 0x604d
movl %r15d, 0x3c(%rbx)
movslq 0x40(%rbx), %rax
cmpl %eax, %r15d
jle 0x60a5
leal -0x1(%r15), %ecx
cmpl $0x7fffffff, %ecx       # imm = 0x7FFFFFFF
cmovbl %r15d, %ebp
movslq %ebp, %rdi
leaq 0x7c05e(%rip), %rcx     # 0x820dc
movq %rcx, (%rsp)
pushq $0x4
popq %rdx
pushq $0x1
popq %rcx
movq %rax, %rsi
xorl %r8d, %r8d
movq 0x10(%rsp), %r9
callq 0x24acb
movl %eax, 0x40(%rbx)
movq 0x88(%r14), %rax
movq (%rax), %rsi
movq 0x48(%rbx), %rdi
movslq %r15d, %rdx
callq 0x43d0
movl 0x28(%rbx), %eax
testl %eax, %eax
je 0x60cc
decl %eax
movl %eax, 0x28(%rbx)
cltq
imulq $0xd0, %rax, %rax
addq 0x20(%rbx), %rax
jmp 0x60ce
xorl %eax, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x7bfb4(%rip), %rdi     # 0x82098
leaq 0x7bfb4(%rip), %rsi     # 0x8209f
leaq 0x7bfb9(%rip), %rcx     # 0x820ab
pushq $0x5e
popq %rdx
callq 0x42f0