// File: /workspace/github_cpp_makefile_star2_O1/cloudinary[P]fuif/./import/read_gif.h
// Function: gd_get_frame(gd_GIF*)
int
gd_get_frame(gd_GIF *gif)
{
    char sep;

    dispose(gif);
    read(gif->fd, &sep, 1);
    while (sep != ',') {
        if (sep == ';')
            return 0;
        if (sep == '!')
            read_ext(gif);
        else return -1;
        read(gif->fd, &sep, 1);
    }
    if (read_image(gif) == -1)
        return -1;
    return 1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdi, %rbx
movzbl 0x1b(%rdi), %eax
cmpl $0x3, %eax
je 0x1d9f6
cmpl $0x2, %eax
jne 0x1d9e7
cmpw $0x0, 0x656(%rbx)
je 0x1d9f6
movq 0x28(%rbx), %rax
movzbl 0x658(%rbx), %ecx
leaq (%rcx,%rcx,2), %rcx
addq %rcx, %rax
addq $0x4, %rax
movzwl 0x10(%rbx), %ecx
movzwl 0x652(%rbx), %edx
imull %ecx, %edx
movzwl 0x650(%rbx), %ecx
addl %edx, %ecx
xorl %edx, %edx
cmpw $0x0, 0x654(%rbx)
je 0x1d9d2
movl %ecx, %esi
shlq $0x2, %rsi
xorl %edi, %edi
movq 0x660(%rbx), %r8
addq %rsi, %r8
movb 0x2(%rax), %r9b
movb %r9b, 0x2(%r8,%rdi,4)
movzwl (%rax), %r9d
movw %r9w, (%r8,%rdi,4)
cmpl $0x0, 0x20(%rbx)
je 0x1d9b0
movb 0x658(%rbx), %r8b
cmpb 0x1a(%rbx), %r8b
setne %r8b
negb %r8b
jmp 0x1d9b3
movb $-0x1, %r8b
movq 0x660(%rbx), %r9
addq %rsi, %r9
movb %r8b, 0x3(%r9,%rdi,4)
incq %rdi
movzwl 0x654(%rbx), %r8d
cmpq %r8, %rdi
jb 0x1d97a
movzwl 0x10(%rbx), %esi
addl %esi, %ecx
incl %edx
movzwl 0x656(%rbx), %esi
cmpl %esi, %edx
jb 0x1d968
jmp 0x1d9f6
movq 0x660(%rbx), %rsi
movq %rbx, %rdi
callq 0x1e296
movl (%rbx), %edi
leaq 0xe(%rsp), %r15
movl $0x1, %edx
movq %r15, %rsi
callq 0x3420
leaq 0x1a(%rbx), %rax
movq %rax, 0x20(%rsp)
leaq 0x10(%rsp), %r13
leaq 0x11(%rsp), %rbp
leaq 0x19(%rsp), %r12
movzbl 0xe(%rsp), %eax
cmpl $0x21, %eax
jne 0x1dd4a
movl (%rbx), %edi
movl $0x1, %edx
movq %r13, %rsi
callq 0x3420
movzbl 0x10(%rsp), %edx
cmpl $0xfd, %edx
jg 0x1dae1
cmpl $0x1, %edx
je 0x1db70
cmpl $0xf9, %edx
jne 0x1dd30
movl (%rbx), %edi
movl $0x1, %esi
movl $0x1, %edx
callq 0x35c0
movl (%rbx), %edi
movl $0x1, %edx
movq %r12, %rsi
callq 0x3420
movzbl 0x19(%rsp), %eax
movd %eax, %xmm0
shrb $0x2, %al
andb $0x3, %al
movb %al, 0x1b(%rbx)
punpcklbw %xmm0, %xmm0    # xmm0 = xmm0[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7]
pand 0x944e(%rip), %xmm0     # 0x26ef0
pxor %xmm1, %xmm1
punpcklbw %xmm1, %xmm0    # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1],xmm0[2],xmm1[2],xmm0[3],xmm1[3],xmm0[4],xmm1[4],xmm0[5],xmm1[5],xmm0[6],xmm1[6],xmm0[7],xmm1[7]
punpcklwd %xmm1, %xmm0    # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1],xmm0[2],xmm1[2],xmm0[3],xmm1[3]
movq %xmm0, 0x1c(%rbx)
movl (%rbx), %edi
movl $0x2, %edx
movq %rbp, %rsi
callq 0x3420
movzwl 0x11(%rsp), %eax
movw %ax, 0x18(%rbx)
movl (%rbx), %edi
movl $0x1, %edx
movq 0x20(%rsp), %rsi
callq 0x3420
jmp 0x1dcfd
cmpl $0xfe, %edx
je 0x1dc98
cmpl $0xff, %edx
jne 0x1dd30
movl (%rbx), %edi
movl $0x1, %esi
movl $0x1, %edx
callq 0x35c0
movl (%rbx), %edi
movl $0x8, %edx
movq %rbp, %rsi
callq 0x3420
movl (%rbx), %edi
movl $0x3, %edx
movq %r12, %rsi
callq 0x3420
movabsq $0x455041435354454e, %rax # imm = 0x455041435354454E
cmpq %rax, 0x11(%rsp)
je 0x1dcd2
cmpq $0x0, 0x648(%rbx)
je 0x1dcc8
movl (%rbx), %edi
xorl %esi, %esi
movl $0x1, %edx
callq 0x35c0
movq %rax, %r14
movq %rbx, %rdi
movq %rbp, %rsi
movq %r12, %rdx
callq *0x648(%rbx)
jmp 0x1dcbc
cmpq $0x0, 0x638(%rbx)
je 0x1dd22
movl (%rbx), %edi
movl $0x1, %esi
movl $0x1, %edx
callq 0x35c0
movl (%rbx), %edi
movl $0x2, %edx
movq %rbp, %rsi
callq 0x3420
movzwl 0x11(%rsp), %r15d
movl (%rbx), %edi
movl $0x2, %edx
movq %rbp, %rsi
callq 0x3420
movzwl 0x11(%rsp), %eax
movl %eax, 0x30(%rsp)
movl (%rbx), %edi
movl $0x2, %edx
movq %rbp, %rsi
callq 0x3420
movzwl 0x11(%rsp), %eax
movl %eax, 0x2c(%rsp)
movl (%rbx), %edi
movl $0x2, %edx
movq %rbp, %rsi
callq 0x3420
movzwl 0x11(%rsp), %eax
movl %eax, 0x1c(%rsp)
movl (%rbx), %edi
movl $0x1, %edx
movq %rbp, %rsi
callq 0x3420
movl (%rbx), %edi
movl $0x1, %edx
movq %r12, %rsi
callq 0x3420
movl (%rbx), %edi
movl $0x1, %edx
leaq 0xc(%rsp), %rsi
callq 0x3420
movl (%rbx), %edi
movl $0x1, %edx
leaq 0xf(%rsp), %rsi
callq 0x3420
movl (%rbx), %edi
xorl %esi, %esi
movl $0x1, %edx
callq 0x35c0
movq %r12, %r14
movq %rbp, %r12
movq %r13, %rbp
movq %rax, %r13
movzbl 0x11(%rsp), %r9d
movzbl 0x19(%rsp), %eax
movzbl 0xc(%rsp), %r10d
movzbl 0xf(%rsp), %r11d
subq $0x8, %rsp
movq %rbx, %rdi
movl %r15d, %esi
leaq 0x16(%rsp), %r15
movl 0x38(%rsp), %edx
movl 0x34(%rsp), %ecx
movl 0x24(%rsp), %r8d
pushq %r11
pushq %r10
pushq %rax
callq *0x638(%rbx)
addq $0x20, %rsp
movl (%rbx), %edi
movq %r13, %rsi
movq %rbp, %r13
movq %r12, %rbp
movq %r14, %r12
jmp 0x1dcc1
cmpq $0x0, 0x640(%rbx)
je 0x1dcc8
movl (%rbx), %edi
xorl %esi, %esi
movl $0x1, %edx
callq 0x35c0
movq %rax, %r14
movq %rbx, %rdi
callq *0x640(%rbx)
movl (%rbx), %edi
movq %r14, %rsi
xorl %edx, %edx
callq 0x35c0
movq %rbx, %rdi
callq 0x23e43
jmp 0x1dd0e
movl (%rbx), %edi
movl $0x2, %esi
movl $0x1, %edx
callq 0x35c0
movl (%rbx), %edi
movl $0x2, %edx
leaq 0xc(%rsp), %rsi
callq 0x3420
movzwl 0xc(%rsp), %eax
movw %ax, 0x16(%rbx)
movl (%rbx), %edi
movl $0x1, %esi
movl $0x1, %edx
callq 0x35c0
movl (%rbx), %edi
movl $0x1, %edx
movq %r15, %rsi
callq 0x3420
jmp 0x1da22
movl (%rbx), %edi
movl $0xd, %esi
movl $0x1, %edx
jmp 0x1dcc3
movq 0x122a1(%rip), %rax     # 0x2ffd8
movq (%rax), %rdi
leaq 0xac30(%rip), %rsi      # 0x28971
xorl %eax, %eax
callq 0x3400
jmp 0x1dd0e
cmpl $0x2c, %eax
je 0x1dd5f
cmpl $0x3b, %eax
jne 0x1e132
xorl %ebp, %ebp
jmp 0x1e137
movl (%rbx), %edi
leaq 0x11(%rsp), %r14
movl $0x2, %edx
movq %r14, %rsi
callq 0x3420
movzwl (%r14), %eax
movw %ax, 0x650(%rbx)
movl (%rbx), %edi
leaq 0x11(%rsp), %r14
movl $0x2, %edx
movq %r14, %rsi
callq 0x3420
movzwl (%r14), %eax
movw %ax, 0x652(%rbx)
movl (%rbx), %edi
leaq 0x11(%rsp), %r14
movl $0x2, %edx
movq %r14, %rsi
callq 0x3420
movzwl (%r14), %eax
movw %ax, 0x654(%rbx)
movl (%rbx), %edi
leaq 0x11(%rsp), %r14
movl $0x2, %edx
movq %r14, %rsi
callq 0x3420
movzwl (%r14), %eax
movw %ax, 0x656(%rbx)
movl (%rbx), %edi
leaq 0xf(%rsp), %r14
movl $0x1, %edx
movq %r14, %rsi
callq 0x3420
movzbl (%r14), %eax
testb %al, %al
movq %rax, 0x50(%rsp)
js 0x1de05
leaq 0x334(%rbx), %r14
jmp 0x1de2b
movl %eax, %ecx
andb $0x7, %cl
movl $0x2, %eax
shll %cl, %eax
leaq 0x30(%rbx), %r14
movl %eax, 0x30(%rbx)
movl (%rbx), %edi
leaq 0x34(%rbx), %rsi
movl $0x6, %edx
shlq %cl, %rdx
callq 0x3420
movq %r14, 0x28(%rbx)
movl (%rbx), %edi
leaq 0xc(%rsp), %r14
movl $0x1, %edx
movq %r14, %rsi
callq 0x3420
movzbl (%r14), %ebp
movl (%rbx), %edi
movl $0x1, %r15d
xorl %esi, %esi
movl $0x1, %edx
callq 0x35c0
movq %rax, %r14
movq %rbx, %rdi
callq 0x23e43
movl (%rbx), %edi
xorl %esi, %esi
movl $0x1, %edx
callq 0x35c0
movq %rax, 0x48(%rsp)
movl (%rbx), %edi
movq %r14, %rsi
xorl %edx, %edx
callq 0x35c0
movl %ebp, %ecx
shll %cl, %r15d
movq %r15, 0x20(%rsp)
movl $0x2, %eax
movl %ebp, %r12d
shll %cl, %eax
cmpl $0x101, %eax            # imm = 0x101
movl $0x100, %r14d           # imm = 0x100
cmovgel %eax, %r14d
leaq (%r14,%r14,2), %rax
leaq 0x10(,%rax,2), %rdi
callq 0x33c0
movq %rax, %r15
testq %rax, %rax
je 0x1df13
movl %r14d, (%r15)
movq 0x20(%rsp), %rax
addl $0x2, %eax
movl %eax, 0x4(%r15)
movq %r15, %rax
addq $0x10, %rax
movq %rax, 0x8(%r15)
cmpl $0x1f, %r12d
je 0x1df13
movq 0x20(%rsp), %rcx
cmpl $0x2, %ecx
movl $0x1, %eax
cmovgel %ecx, %eax
movl $0x4, %ecx
xorl %edx, %edx
movq 0x8(%r15), %rsi
movl $0xfff0001, -0x4(%rsi,%rcx) # imm = 0xFFF0001
movb %dl, (%rsi,%rcx)
incq %rdx
addq $0x6, %rcx
cmpq %rdx, %rax
jne 0x1def8
movl %r12d, %ebp
incl %ebp
leaq 0x19(%rsp), %rcx
xorl %eax, %eax
movb %al, (%rcx)
leaq 0x11(%rsp), %rdx
movb %al, (%rdx)
leaq 0xc(%rsp), %r8
movq %rbx, %rdi
movl %ebp, %esi
callq 0x23e87
movl %eax, %r12d
movq 0x20(%rsp), %rax
leal 0x2(%rax), %ecx
movl %ecx, 0x2c(%rsp)
incl %eax
movl %eax, 0x44(%rsp)
movl %eax, 0x1c(%rsp)
movq $0x0, 0x38(%rsp)
movl $0x0, 0x34(%rsp)
movl %ebp, 0x30(%rsp)
incl 0x1c(%rsp)
movq 0x20(%rsp), %rax
cmpw %ax, %r12w
jne 0x1df88
movl 0x2c(%rsp), %eax
movl %eax, 0x4(%r15)
xorl %r13d, %r13d
movl 0x30(%rsp), %ebp
jmp 0x1e020
testl %r13d, %r13d
jne 0x1e020
movslq (%r15), %rax
cmpl %eax, 0x4(%r15)
jne 0x1dfcb
leal (%rax,%rax), %ecx
movl %ecx, (%r15)
leaq (%rax,%rax,2), %rax
leaq 0x10(,%rax,4), %rsi
movq %r15, %rdi
callq 0x3530
testq %rax, %rax
je 0x1e04d
movq %rax, %rcx
addq $0x10, %rcx
movq %rcx, 0x8(%rax)
movq %rax, %r15
movq 0x8(%r15), %rax
movslq 0x4(%r15), %rcx
leaq (%rcx,%rcx,2), %rcx
movl 0x1c(%rsp), %edx
movw %dx, (%rax,%rcx,2)
movw %r12w, 0x2(%rax,%rcx,2)
movb %r14b, 0x4(%rax,%rcx,2)
movl 0x4(%r15), %eax
leal 0x1(%rax), %ecx
movl %ecx, 0x4(%r15)
xorl %edx, %edx
testl %eax, %ecx
sete %dl
cmpl $-0x1, %edx
je 0x1e12a
xorl %r13d, %r13d
cmpl $0x1000, 0x4(%r15)      # imm = 0x1000
sete %r13b
movl $0x0, %eax
cmovel %eax, %edx
movl %edx, 0x34(%rsp)
movq %rbx, %rdi
movl %ebp, %esi
leaq 0x11(%rsp), %rdx
leaq 0x19(%rsp), %rcx
leaq 0xc(%rsp), %r8
callq 0x23e87
movl %eax, %r12d
movq 0x20(%rsp), %rax
cmpw %ax, %r12w
je 0x1df6e
jmp 0x1e054
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
jmp 0x1dffc
cmpw 0x44(%rsp), %r12w
je 0x1e148
movzwl %r12w, %ecx
movq 0x8(%r15), %rax
leaq (%rcx,%rcx,2), %rdx
leaq (%rax,%rdx,2), %r8
movzwl (%r8), %edx
movzwl %dx, %esi
movq 0x38(%rsp), %rax
leal -0x1(%rax), %edi
movl %edx, 0x1c(%rsp)
movl %edx, %eax
movzwl 0x2(%r8), %r9d
movzwl %ax, %eax
addl %edi, %eax
movzwl 0x652(%rbx), %r10d
movzwl 0x654(%rbx), %r11d
cltd
idivl %r11d
addl %r10d, %eax
movzwl 0x10(%rbx), %r10d
imull %eax, %r10d
movzwl 0x650(%rbx), %eax
addl %edx, %eax
addl %r10d, %eax
movb 0x4(%r8), %r14b
movq 0x668(%rbx), %rdx
cltq
movb %r14b, (%rdx,%rax)
cmpq $0xfff, %r9             # imm = 0xFFF
je 0x1e0e7
movq 0x8(%r15), %rax
leaq (%r9,%r9,2), %rdx
leaq (%rax,%rdx,2), %r8
movzwl (%r8), %eax
jmp 0x1e085
xorl %eax, %eax
cmpl $0x1, 0x34(%rsp)
sete %al
addl %eax, %ebp
movq 0x38(%rsp), %rax
addl %esi, %eax
movq %rax, 0x38(%rsp)
movl 0x4(%r15), %eax
decl %eax
cmpl %ecx, %eax
jle 0x1df65
testl %r13d, %r13d
jne 0x1df65
movq 0x8(%r15), %rcx
movl %eax, %eax
leaq (%rax,%rax,2), %rax
movb %r14b, 0x4(%rcx,%rax,2)
jmp 0x1df65
movq %r15, %rdi
callq 0x3380
movl $0xffffffff, %ebp       # imm = 0xFFFFFFFF
movl %ebp, %eax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r15, %rdi
callq 0x3380
movl (%rbx), %edi
leaq 0x11(%rsp), %rsi
movl $0x1, %edx
callq 0x3420
movl (%rbx), %edi
movq 0x48(%rsp), %rsi
xorl %edx, %edx
callq 0x35c0
movl $0x1, %ebp
testb $0x40, 0x50(%rsp)
je 0x1e137
movzwl 0x10(%rbx), %eax
movzwl 0x12(%rbx), %r15d
imulq %rax, %r15
movq %r15, %rdi
callq 0x33c0
movq 0x668(%rbx), %rsi
movq %rax, 0x20(%rsp)
movq %rax, %rdi
movq %r15, %rdx
callq 0x3260
cmpw $0x0, 0x656(%rbx)
je 0x1e23d
movl $0x8, %r15d
xorl %r12d, %r12d
xorl %r13d, %r13d
xorl %eax, %eax
movzwl 0x652(%rbx), %esi
movslq %eax, %r14
leaq (%r14,%rsi), %rax
movzwl 0x10(%rbx), %ecx
movq %rcx, %rdx
imulq %rax, %rdx
movzwl 0x650(%rbx), %eax
leaq (%rax,%rdx), %rdi
addq 0x668(%rbx), %rdi
addl %r12d, %esi
imull %ecx, %esi
addl %eax, %esi
addq 0x20(%rsp), %rsi
movzwl 0x654(%rbx), %edx
callq 0x3260
addl %r15d, %r14d
leal 0x1(%r13), %ecx
movl $0x10, %edx
shrl %cl, %edx
movl $0x8, %eax
shrl %cl, %eax
movzwl 0x656(%rbx), %esi
cmpl %esi, %r14d
cmovll %r14d, %eax
cmovll %r13d, %ecx
cmovgel %edx, %r15d
incl %r12d
movl %ecx, %r13d
cmpl %esi, %r12d
jb 0x1e1c3
movq 0x20(%rsp), %rdi
callq 0x3380
jmp 0x1e137