// File: /workspace/github_c_makefile_star2_O3/patriciogonzalezvivo[P]tprint/include/std/stb_image.h
// Function: stbi__tga_info(stbi__context*, int*, int*, int*)
static int stbi__tga_info(stbi__context *s, int *x, int *y, int *comp)
{
    int tga_w, tga_h, tga_comp;
    int sz;
    stbi__get8(s);                   // discard Offset
    sz = stbi__get8(s);              // color type
    if( sz > 1 ) {
        stbi__rewind(s);
        return 0;      // only RGB or indexed allowed
    }
    sz = stbi__get8(s);              // image type
    // only RGB or grey allowed, +/- RLE
    if ((sz != 1) && (sz != 2) && (sz != 3) && (sz != 9) && (sz != 10) && (sz != 11)) return 0;
    stbi__skip(s,9);
    tga_w = stbi__get16le(s);
    if( tga_w < 1 ) {
        stbi__rewind(s);
        return 0;   // test width
    }
    tga_h = stbi__get16le(s);
    if( tga_h < 1 ) {
        stbi__rewind(s);
        return 0;   // test height
    }
    sz = stbi__get8(s);               // bits per pixel
    // only RGB or RGBA or grey allowed
    if ((sz != 8) && (sz != 16) && (sz != 24) && (sz != 32)) {
        stbi__rewind(s);
        return 0;
    }
    tga_comp = sz;
    if (x) *x = tga_w;
    if (y) *y = tga_h;
    if (comp) *comp = tga_comp / 8;
    return 1;                   // seems to have passed everything
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %r15
movq 0xb8(%rdi), %rax
movq 0xc0(%rdi), %r13
cmpq %r13, %rax
jae 0x1f2e3
incq %rax
jmp 0x1f324
cmpl $0x0, 0x30(%r15)
je 0x1f32b
movq 0x28(%r15), %rdi
leaq 0x38(%r15), %r13
movl 0x34(%r15), %edx
movq %r13, %rsi
callq *0x10(%r15)
testl %eax, %eax
je 0x1f308
cltq
addq %rax, %r13
jmp 0x1f319
movl $0x0, 0x30(%r15)
leaq 0x39(%r15), %r13
movb $0x0, 0x38(%r15)
movq %r13, 0xc0(%r15)
leaq 0x39(%r15), %rax
movq %rax, 0xb8(%r15)
cmpq %r13, %rax
jae 0x1f342
leaq 0x1(%rax), %rdx
movq %rdx, 0xb8(%r15)
movb (%rax), %cl
movq %rdx, %rax
jmp 0x1f390
cmpl $0x0, 0x30(%r15)
je 0x1f3a5
movq 0x28(%r15), %rdi
leaq 0x38(%r15), %rbp
movl 0x34(%r15), %edx
movq %rbp, %rsi
callq *0x10(%r15)
testl %eax, %eax
je 0x1f36b
movslq %eax, %r13
addq %rbp, %r13
movb (%rbp), %cl
jmp 0x1f37e
movl $0x0, 0x30(%r15)
leaq 0x39(%r15), %r13
movb $0x0, 0x38(%r15)
xorl %ecx, %ecx
movq %r13, 0xc0(%r15)
leaq 0x39(%r15), %rax
movq %rax, 0xb8(%r15)
cmpb $0x2, %cl
jb 0x1f3a5
movq 0xc8(%r15), %rax
movq %rax, 0xb8(%r15)
jmp 0x1f3e2
cmpq %r13, %rax
jae 0x1f3b9
leaq 0x1(%rax), %rcx
movq %rcx, 0xb8(%r15)
movb (%rax), %al
jmp 0x1f40e
cmpl $0x0, 0x30(%r15)
je 0x1f3e2
movq 0x28(%r15), %rdi
leaq 0x38(%r15), %rbp
movl 0x34(%r15), %edx
movq %rbp, %rsi
callq *0x10(%r15)
testl %eax, %eax
je 0x1f3e9
movslq %eax, %r13
addq %rbp, %r13
movb (%rbp), %al
jmp 0x1f3fc
xorl %ebp, %ebp
jmp 0x1f530
movl $0x0, 0x30(%r15)
leaq 0x39(%r15), %r13
movb $0x0, 0x38(%r15)
xorl %eax, %eax
movq %r13, 0xc0(%r15)
leaq 0x39(%r15), %rcx
movq %rcx, 0xb8(%r15)
andb $-0x9, %al
addb $-0x4, %al
xorl %ebp, %ebp
cmpb $-0x3, %al
jb 0x1f530
cmpq $0x0, 0x10(%r15)
je 0x1f445
movl %r13d, %eax
subl %ecx, %eax
cmpl $0x8, %eax
jg 0x1f445
movq %r13, 0xb8(%r15)
movq 0x28(%r15), %rdi
movl $0x9, %esi
subl %eax, %esi
callq *0x18(%r15)
jmp 0x1f450
addq $0x9, %rcx
movq %rcx, 0xb8(%r15)
movq %r15, %rdi
callq 0x1d56e
testl %eax, %eax
je 0x1f522
movl %eax, %r13d
movq %r15, %rdi
callq 0x1d56e
testl %eax, %eax
je 0x1f522
movq 0xb8(%r15), %rdx
cmpq 0xc0(%r15), %rdx
jae 0x1f492
leaq 0x1(%rdx), %rcx
movq %rcx, 0xb8(%r15)
movb (%rdx), %dl
jmp 0x1f4f2
cmpl $0x0, 0x30(%r15)
je 0x1f4c5
movl %eax, 0xc(%rsp)
movq 0x28(%r15), %rdi
leaq 0x38(%r15), %rsi
movl 0x34(%r15), %edx
movq %rsi, 0x10(%rsp)
callq *0x10(%r15)
testl %eax, %eax
je 0x1f4c9
movslq %eax, %rcx
movq 0x10(%rsp), %rax
addq %rax, %rcx
movb (%rax), %dl
jmp 0x1f4dc
xorl %edx, %edx
jmp 0x1f4f2
movl $0x0, 0x30(%r15)
leaq 0x39(%r15), %rcx
movb $0x0, 0x38(%r15)
xorl %edx, %edx
movq %rcx, 0xc0(%r15)
leaq 0x39(%r15), %rcx
movq %rcx, 0xb8(%r15)
movl 0xc(%rsp), %eax
leal -0x8(%rdx), %ecx
rolb $0x5, %cl
cmpb $0x4, %cl
jae 0x1f522
testq %r12, %r12
je 0x1f506
movl %r13d, (%r12)
testq %r14, %r14
je 0x1f50e
movl %eax, (%r14)
movl $0x1, %ebp
testq %rbx, %rbx
je 0x1f530
shrb $0x3, %dl
movzbl %dl, %eax
movl %eax, (%rbx)
jmp 0x1f530
movq 0xc8(%r15), %rax
movq %rax, 0xb8(%r15)
movl %ebp, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq