// File: /workspace/github_c_makefile_star2_O0/patriciogonzalezvivo[P]tprint/include/std/stb_image.h
// Function: stbi__out_gif_code(stbi__gif*, unsigned short)
static void stbi__out_gif_code(stbi__gif *g, stbi__uint16 code)
{
   stbi_uc *p, *c;

   // recurse to decode the prefixes, since the linked-list is backwards,
   // and working backwards through an interleaved image would be nasty
   if (g->codes[code].prefix >= 0)
      stbi__out_gif_code(g, g->codes[code].prefix);

   if (g->cur_y >= g->max_y) return;

   p = &g->out[g->cur_x + g->cur_y];
   c = &g->color_table[g->codes[code].suffix * 4];

   if (c[3] >= 128) {
      p[0] = c[2];
      p[1] = c[1];
      p[2] = c[0];
      p[3] = c[3];
   }
   g->cur_x += 4;

   if (g->cur_x >= g->max_x) {
      g->cur_x = g->start_x;
      g->cur_y += g->step;

      while (g->cur_y >= g->max_y && g->parse > 0) {
         g->step = (1 << g->parse) * g->line_size;
         g->cur_y = g->start_y + (g->step >> 1);
         --g->parse;
      }
   }
}

// Assembly:
subq $0x28, %rsp
movw %si, %ax
movq %rdi, 0x20(%rsp)
movw %ax, 0x1e(%rsp)
movq 0x20(%rsp), %rax
movzwl 0x1e(%rsp), %ecx
movswl 0x824(%rax,%rcx,4), %eax
cmpl $0x0, %eax
jl 0x29974
movq 0x20(%rsp), %rdi
movq 0x20(%rsp), %rax
movzwl 0x1e(%rsp), %ecx
movzwl 0x824(%rax,%rcx,4), %esi
callq 0x29930
movq 0x20(%rsp), %rax
movl 0x4850(%rax), %eax
movq 0x20(%rsp), %rcx
cmpl 0x4848(%rcx), %eax
jl 0x29991
jmp 0x29b3d
movq 0x20(%rsp), %rax
movq 0x8(%rax), %rax
movq 0x20(%rsp), %rcx
movl 0x484c(%rcx), %ecx
movq 0x20(%rsp), %rdx
addl 0x4850(%rdx), %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, 0x10(%rsp)
movq 0x20(%rsp), %rax
movq 0x4828(%rax), %rax
movq 0x20(%rsp), %rcx
movzwl 0x1e(%rsp), %edx
movzbl 0x827(%rcx,%rdx,4), %ecx
shll $0x2, %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rax
movzbl 0x3(%rax), %eax
cmpl $0x80, %eax
jl 0x29a35
movq 0x8(%rsp), %rax
movb 0x2(%rax), %cl
movq 0x10(%rsp), %rax
movb %cl, (%rax)
movq 0x8(%rsp), %rax
movb 0x1(%rax), %cl
movq 0x10(%rsp), %rax
movb %cl, 0x1(%rax)
movq 0x8(%rsp), %rax
movb (%rax), %cl
movq 0x10(%rsp), %rax
movb %cl, 0x2(%rax)
movq 0x8(%rsp), %rax
movb 0x3(%rax), %cl
movq 0x10(%rsp), %rax
movb %cl, 0x3(%rax)
movq 0x20(%rsp), %rax
movl 0x484c(%rax), %ecx
addl $0x4, %ecx
movl %ecx, 0x484c(%rax)
movq 0x20(%rsp), %rax
movl 0x484c(%rax), %eax
movq 0x20(%rsp), %rcx
cmpl 0x4844(%rcx), %eax
jl 0x29b3d
movq 0x20(%rsp), %rax
movl 0x483c(%rax), %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x484c(%rax)
movq 0x20(%rsp), %rax
movl 0x4834(%rax), %ecx
movq 0x20(%rsp), %rax
addl 0x4850(%rax), %ecx
movl %ecx, 0x4850(%rax)
movq 0x20(%rsp), %rax
movl 0x4850(%rax), %ecx
movq 0x20(%rsp), %rdx
xorl %eax, %eax
cmpl 0x4848(%rdx), %ecx
movb %al, 0x7(%rsp)
jl 0x29ac8
movq 0x20(%rsp), %rax
cmpl $0x0, 0x4830(%rax)
setg %al
movb %al, 0x7(%rsp)
movb 0x7(%rsp), %al
testb $0x1, %al
jne 0x29ad2
jmp 0x29b3b
movq 0x20(%rsp), %rax
movl 0x4830(%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, %ecx
movq 0x20(%rsp), %rax
imull 0x4854(%rax), %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x4834(%rax)
movq 0x20(%rsp), %rax
movl 0x4840(%rax), %ecx
movq 0x20(%rsp), %rax
movl 0x4834(%rax), %eax
sarl %eax
addl %eax, %ecx
movq 0x20(%rsp), %rax
movl %ecx, 0x4850(%rax)
movq 0x20(%rsp), %rax
movl 0x4830(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0x4830(%rax)
jmp 0x29a97
jmp 0x29b3d
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)