// File: /workspace/github_c_makefile_star2_O0/zhiyb[P]png2tlg/./stb_image.h
// Function: stbi__process_marker(stbi__jpeg*, int)
static int stbi__process_marker(stbi__jpeg *z, int m)
{
   int L;
   switch (m) {
      case STBI__MARKER_none: // no marker found
         return stbi__err("expected marker","Corrupt JPEG");

      case 0xDD: // DRI - specify restart interval
         if (stbi__get16be(z->s) != 4) return stbi__err("bad DRI len","Corrupt JPEG");
         z->restart_interval = stbi__get16be(z->s);
         return 1;

      case 0xDB: // DQT - define quantization table
         L = stbi__get16be(z->s)-2;
         while (L > 0) {
            int q = stbi__get8(z->s);
            int p = q >> 4, sixteen = (p != 0);
            int t = q & 15,i;
            if (p != 0 && p != 1) return stbi__err("bad DQT type","Corrupt JPEG");
            if (t > 3) return stbi__err("bad DQT table","Corrupt JPEG");

            for (i=0; i < 64; ++i)
               z->dequant[t][stbi__jpeg_dezigzag[i]] = (stbi__uint16)(sixteen ? stbi__get16be(z->s) : stbi__get8(z->s));
            L -= (sixteen ? 129 : 65);
         }
         return L==0;

      case 0xC4: // DHT - define huffman table
         L = stbi__get16be(z->s)-2;
         while (L > 0) {
            stbi_uc *v;
            int sizes[16],i,n=0;
            int q = stbi__get8(z->s);
            int tc = q >> 4;
            int th = q & 15;
            if (tc > 1 || th > 3) return stbi__err("bad DHT header","Corrupt JPEG");
            for (i=0; i < 16; ++i) {
               sizes[i] = stbi__get8(z->s);
               n += sizes[i];
            }
            L -= 17;
            if (tc == 0) {
               if (!stbi__build_huffman(z->huff_dc+th, sizes)) return 0;
               v = z->huff_dc[th].values;
            } else {
               if (!stbi__build_huffman(z->huff_ac+th, sizes)) return 0;
               v = z->huff_ac[th].values;
            }
            for (i=0; i < n; ++i)
               v[i] = stbi__get8(z->s);
            if (tc != 0)
               stbi__build_fast_ac(z->fast_ac[th], z->huff_ac + th);
            L -= n;
         }
         return L==0;
   }

   // check for comment block or APP blocks
   if ((m >= 0xE0 && m <= 0xEF) || m == 0xFE) {
      L = stbi__get16be(z->s);
      if (L < 2) {
         if (m == 0xFE)
            return stbi__err("bad COM len","Corrupt JPEG");
         else
            return stbi__err("bad APP len","Corrupt JPEG");
      }
      L -= 2;

      if (m == 0xE0 && L >= 5) { // JFIF APP0 segment
         static const unsigned char tag[5] = {'J','F','I','F','\0'};
         int ok = 1;
         int i;
         for (i=0; i < 5; ++i)
            if (stbi__get8(z->s) != tag[i])
               ok = 0;
         L -= 5;
         if (ok)
            z->jfif = 1;
      } else if (m == 0xEE && L >= 12) { // Adobe APP14 segment
         static const unsigned char tag[6] = {'A','d','o','b','e','\0'};
         int ok = 1;
         int i;
         for (i=0; i < 6; ++i)
            if (stbi__get8(z->s) != tag[i])
               ok = 0;
         L -= 6;
         if (ok) {
            stbi__get8(z->s); // version
            stbi__get16be(z->s); // flags0
            stbi__get16be(z->s); // flags1
            z->app14_color_transform = stbi__get8(z->s); // color transform
            L -= 6;
         }
      }

      stbi__skip(z->s, L);
      return 1;
   }

   return stbi__err("unknown marker","Corrupt JPEG");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl %eax, -0xa8(%rbp)
subl $0xc4, %eax
je 0x120cf
jmp 0x11f08
movl -0xa8(%rbp), %eax
subl $0xdb, %eax
je 0x11f9a
jmp 0x11f1b
movl -0xa8(%rbp), %eax
subl $0xdd, %eax
je 0x11f51
jmp 0x11f2a
movl -0xa8(%rbp), %eax
subl $0xff, %eax
jne 0x12317
jmp 0x11f3d
leaq 0xe91b(%rip), %rdi      # 0x2085f
callq 0x2680
movl %eax, -0x4(%rbp)
jmp 0x12519
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12fa0
cmpl $0x4, %eax
je 0x11f76
leaq 0xe906(%rip), %rdi      # 0x2086f
callq 0x2680
movl %eax, -0x4(%rbp)
jmp 0x12519
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12fa0
movl %eax, %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x4868(%rax)
movl $0x1, -0x4(%rbp)
jmp 0x12519
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12fa0
subl $0x2, %eax
movl %eax, -0x18(%rbp)
cmpl $0x0, -0x18(%rbp)
jle 0x120bb
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movzbl %al, %eax
movl %eax, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
sarl $0x4, %eax
movl %eax, -0x20(%rbp)
cmpl $0x0, -0x20(%rbp)
setne %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x24(%rbp)
movl -0x1c(%rbp), %eax
andl $0xf, %eax
movl %eax, -0x28(%rbp)
cmpl $0x0, -0x20(%rbp)
je 0x12009
cmpl $0x1, -0x20(%rbp)
je 0x12009
leaq 0xe87f(%rip), %rdi      # 0x2087b
callq 0x2680
movl %eax, -0x4(%rbp)
jmp 0x12519
cmpl $0x3, -0x28(%rbp)
jle 0x12023
leaq 0xe872(%rip), %rdi      # 0x20888
callq 0x2680
movl %eax, -0x4(%rbp)
jmp 0x12519
movl $0x0, -0x2c(%rbp)
cmpl $0x40, -0x2c(%rbp)
jge 0x1209b
cmpl $0x0, -0x24(%rbp)
je 0x1204a
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12fa0
movl %eax, -0xac(%rbp)
jmp 0x1205f
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movzbl %al, %eax
movl %eax, -0xac(%rbp)
movl -0xac(%rbp), %eax
movw %ax, %dx
movq -0x10(%rbp), %rax
addq $0x3488, %rax           # imm = 0x3488
movslq -0x28(%rbp), %rcx
shlq $0x7, %rcx
addq %rcx, %rax
movslq -0x2c(%rbp), %rsi
leaq 0xe1f8(%rip), %rcx      # 0x20280
movzbl (%rcx,%rsi), %ecx
movw %dx, (%rax,%rcx,2)
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x1202a
movl -0x24(%rbp), %edx
movl $0x41, %ecx
movl $0x81, %eax
cmpl $0x0, %edx
cmovnel %eax, %ecx
movl -0x18(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x18(%rbp)
jmp 0x11fac
cmpl $0x0, -0x18(%rbp)
sete %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x4(%rbp)
jmp 0x12519
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12fa0
subl $0x2, %eax
movl %eax, -0x18(%rbp)
cmpl $0x0, -0x18(%rbp)
jle 0x12303
movl $0x0, -0x88(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movzbl %al, %eax
movl %eax, -0x8c(%rbp)
movl -0x8c(%rbp), %eax
sarl $0x4, %eax
movl %eax, -0x90(%rbp)
movl -0x8c(%rbp), %eax
andl $0xf, %eax
movl %eax, -0x94(%rbp)
cmpl $0x1, -0x90(%rbp)
jg 0x1213a
cmpl $0x3, -0x94(%rbp)
jle 0x1214e
leaq 0xe755(%rip), %rdi      # 0x20896
callq 0x2680
movl %eax, -0x4(%rbp)
jmp 0x12519
movl $0x0, -0x84(%rbp)
cmpl $0x10, -0x84(%rbp)
jge 0x121a3
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movzbl %al, %ecx
movslq -0x84(%rbp), %rax
movl %ecx, -0x80(%rbp,%rax,4)
movslq -0x84(%rbp), %rax
movl -0x80(%rbp,%rax,4), %eax
addl -0x88(%rbp), %eax
movl %eax, -0x88(%rbp)
movl -0x84(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x84(%rbp)
jmp 0x12158
movl -0x18(%rbp), %eax
subl $0x11, %eax
movl %eax, -0x18(%rbp)
cmpl $0x0, -0x90(%rbp)
jne 0x1220d
movq -0x10(%rbp), %rdi
addq $0x8, %rdi
movslq -0x94(%rbp), %rax
imulq $0x690, %rax, %rax      # imm = 0x690
addq %rax, %rdi
leaq -0x80(%rbp), %rsi
callq 0x12fe0
cmpl $0x0, %eax
jne 0x121e8
movl $0x0, -0x4(%rbp)
jmp 0x12519
movq -0x10(%rbp), %rax
addq $0x8, %rax
movslq -0x94(%rbp), %rcx
imulq $0x690, %rcx, %rcx      # imm = 0x690
addq %rcx, %rax
addq $0x400, %rax            # imm = 0x400
movq %rax, -0x38(%rbp)
jmp 0x12268
movq -0x10(%rbp), %rdi
addq $0x1a48, %rdi           # imm = 0x1A48
movslq -0x94(%rbp), %rax
imulq $0x690, %rax, %rax      # imm = 0x690
addq %rax, %rdi
leaq -0x80(%rbp), %rsi
callq 0x12fe0
cmpl $0x0, %eax
jne 0x12243
movl $0x0, -0x4(%rbp)
jmp 0x12519
movq -0x10(%rbp), %rax
addq $0x1a48, %rax           # imm = 0x1A48
movslq -0x94(%rbp), %rcx
imulq $0x690, %rcx, %rcx      # imm = 0x690
addq %rcx, %rax
addq $0x400, %rax            # imm = 0x400
movq %rax, -0x38(%rbp)
movl $0x0, -0x84(%rbp)
movl -0x84(%rbp), %eax
cmpl -0x88(%rbp), %eax
jge 0x122ad
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movb %al, %dl
movq -0x38(%rbp), %rax
movslq -0x84(%rbp), %rcx
movb %dl, (%rax,%rcx)
movl -0x84(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x84(%rbp)
jmp 0x12272
cmpl $0x0, -0x90(%rbp)
je 0x122f0
movq -0x10(%rbp), %rdi
addq $0x3688, %rdi           # imm = 0x3688
movslq -0x94(%rbp), %rax
shlq $0xa, %rax
addq %rax, %rdi
movq -0x10(%rbp), %rsi
addq $0x1a48, %rsi           # imm = 0x1A48
movslq -0x94(%rbp), %rax
imulq $0x690, %rax, %rax      # imm = 0x690
addq %rax, %rsi
callq 0x13220
movl -0x88(%rbp), %ecx
movl -0x18(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x18(%rbp)
jmp 0x120e1
cmpl $0x0, -0x18(%rbp)
sete %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x4(%rbp)
jmp 0x12519
cmpl $0xe0, -0x14(%rbp)
jl 0x12329
cmpl $0xef, -0x14(%rbp)
jle 0x12336
cmpl $0xfe, -0x14(%rbp)
jne 0x1250a
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12fa0
movl %eax, -0x18(%rbp)
cmpl $0x2, -0x18(%rbp)
jge 0x1237c
cmpl $0xfe, -0x14(%rbp)
jne 0x12368
leaq 0xe54a(%rip), %rdi      # 0x208a5
callq 0x2680
movl %eax, -0x4(%rbp)
jmp 0x12519
leaq 0xe542(%rip), %rdi      # 0x208b1
callq 0x2680
movl %eax, -0x4(%rbp)
jmp 0x12519
movl -0x18(%rbp), %eax
subl $0x2, %eax
movl %eax, -0x18(%rbp)
cmpl $0xe0, -0x14(%rbp)
jne 0x12420
cmpl $0x5, -0x18(%rbp)
jl 0x12420
movl $0x1, -0x98(%rbp)
movl $0x0, -0x9c(%rbp)
cmpl $0x5, -0x9c(%rbp)
jge 0x123fb
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movzbl %al, %eax
movslq -0x9c(%rbp), %rdx
leaq 0xdef9(%rip), %rcx      # 0x202cf
movzbl (%rcx,%rdx), %ecx
cmpl %ecx, %eax
je 0x123e8
movl $0x0, -0x98(%rbp)
jmp 0x123ea
movl -0x9c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x9c(%rbp)
jmp 0x123b0
movl -0x18(%rbp), %eax
subl $0x5, %eax
movl %eax, -0x18(%rbp)
cmpl $0x0, -0x98(%rbp)
je 0x1241b
movq -0x10(%rbp), %rax
movl $0x1, 0x4848(%rax)
jmp 0x124f2
cmpl $0xee, -0x14(%rbp)
jne 0x124f0
cmpl $0xc, -0x18(%rbp)
jl 0x124f0
movl $0x1, -0xa0(%rbp)
movl $0x0, -0xa4(%rbp)
cmpl $0x6, -0xa4(%rbp)
jge 0x12496
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movzbl %al, %eax
movslq -0xa4(%rbp), %rdx
leaq 0xde63(%rip), %rcx      # 0x202d4
movzbl (%rcx,%rdx), %ecx
cmpl %ecx, %eax
je 0x12483
movl $0x0, -0xa0(%rbp)
jmp 0x12485
movl -0xa4(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xa4(%rbp)
jmp 0x1244b
movl -0x18(%rbp), %eax
subl $0x6, %eax
movl %eax, -0x18(%rbp)
cmpl $0x0, -0xa0(%rbp)
je 0x124ee
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12fa0
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12fa0
movq -0x10(%rbp), %rax
movq (%rax), %rdi
callq 0x12e60
movzbl %al, %ecx
movq -0x10(%rbp), %rax
movl %ecx, 0x484c(%rax)
movl -0x18(%rbp), %eax
subl $0x6, %eax
movl %eax, -0x18(%rbp)
jmp 0x124f0
jmp 0x124f2
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movl -0x18(%rbp), %esi
callq 0x13350
movl $0x1, -0x4(%rbp)
jmp 0x12519
leaq 0xe3ac(%rip), %rdi      # 0x208bd
callq 0x2680
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0xb0, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)