// File: /workspace/github_c_makefile_star2_O1/c-zhou[P]oatk/path.c
// Function: gfa_aux_parse
static int gfa_aux_parse(char *s, uint8_t **data, int *max)
{
    char *q, *p;
    kstring_t str;
    if (s == 0) return 0;
    str.l = 0, str.m = *max, str.s = (char*)*data;
    if (*s == '\t') ++s;
    for (p = q = s;; ++p) {
        if (*p == 0 || *p == '\t') {
            int c = *p;
            *p = 0;
            if (p - q >= 5 && q[2] == ':' && q[4] == ':' && (q[3] == 'A' || q[3] == 'i' || q[3] == 'f' || q[3] == 'Z' || q[3] == 'B')) {
                int type = q[3];
                kputsn_(q, 2, &str);
                q += 5;
                if (type == 'A') {
                    kputc_('A', &str);
                    kputc_(*q, &str);
                } else if (type == 'i') {
                    int64_t x;
                    x = strtoll(q, &q, 10);
                    kputc_(type, &str); kputsn_((char*)&x, 8, &str);
                } else if (type == 'f') {
                    double x;
                    x = strtod(q, &q);
                    kputc_('f', &str); kputsn_(&x, 8, &str);
                } else if (type == 'Z') {
                    kputc_('Z', &str); kputsn_(q, p - q + 1, &str); // note that this include the trailing NULL
                } else if (type == 'B') {
                    type = *q++; // q points to the first ',' following the typing byte
                    if (p - q >= 2 && (type == 'c' || type == 'C' || type == 's' || type == 'S' || type == 'i' || type == 'I' || type != 'f')) {
                        int32_t n;
                        char *r;
                        for (r = q, n = 0; *r; ++r)
                            if (*r == ',') ++n;
                        kputc_('B', &str); kputc_(type, &str); kputsn_(&n, 4, &str);
                        // TODO: to evaluate which is faster: a) aligned array and then memmove(); b) unaligned array; c) kputsn_()
                        if (type == 'c')      while (q + 1 < p) { int8_t   x = strtol(q + 1, &q, 0);  kputc_(x, &str); }
                        else if (type == 'C') while (q + 1 < p) { uint8_t  x = strtol(q + 1, &q, 0);  kputc_(x, &str); }
                        else if (type == 's') while (q + 1 < p) { int16_t  x = strtol(q + 1, &q, 0);  kputsn_(&x, 2, &str); }
                        else if (type == 'S') while (q + 1 < p) { uint16_t x = strtol(q + 1, &q, 0);  kputsn_(&x, 2, &str); }
                        else if (type == 'i') while (q + 1 < p) { int64_t  x = strtoll(q + 1, &q, 0); kputsn_(&x, 8, &str); }
                        else if (type == 'I') while (q + 1 < p) { uint64_t x = strtoll(q + 1, &q, 0); kputsn_(&x, 8, &str); }
                        else if (type == 'f') while (q + 1 < p) { double   x = strtod(q + 1, &q);     kputsn_(&x, 8, &str); }
                    }
                } // should not be here, as we have tested all types
            }
            q = p + 1;
            if (c == 0) break;
        }
    }
    if (str.l > 0 && str.l == str.m) ks_resize(&str, str.l + 1);
    if (str.s) str.s[str.l] = 0;
    *max = str.m, *data = (uint8_t*)str.s;
    return str.l;
}

// Assembly:
testq %rdi, %rdi
je 0x11572
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdx, 0x30(%rsp)
movslq (%rdx), %rbp
movq %rsi, 0x20(%rsp)
movq (%rsi), %r9
xorl %r15d, %r15d
cmpb $0x9, (%rdi)
sete %r15b
addq %rdi, %r15
leaq 0x8(%rsp), %rax
movq %r15, (%rax)
xorl %r8d, %r8d
movzbl (%r15), %ebx
cmpl $0x9, %ebx
je 0x10b7f
testl %ebx, %ebx
jne 0x1101d
movb $0x0, (%r15)
movq 0x8(%rsp), %r14
movq %r15, %rax
subq %r14, %rax
cmpq $0x5, %rax
jl 0x1100c
cmpb $0x3a, 0x2(%r14)
jne 0x1100c
cmpb $0x3a, 0x4(%r14)
jne 0x1100c
movzbl 0x3(%r14), %r12d
leal -0x41(%r12), %eax
cmpl $0x28, %eax
ja 0x1100c
movabsq $0x12002000003, %rcx    # imm = 0x12002000003
btq %rax, %rcx
jae 0x1100c
leaq 0x2(%r8), %r13
cmpq %rbp, %r13
jbe 0x10c38
leaq 0x1(%r8), %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rbp
shrq $0x10, %rbp
orq %rax, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
movl %ebx, 0x10(%rsp)
movq %r13, %rbx
movq %r8, %r13
callq 0x3330
movq %r13, %r8
movq %rbx, %r13
movl 0x10(%rsp), %ebx
movq %rax, %r9
movzwl (%r14), %eax
movw %ax, (%r9,%r8)
leaq 0x5(%r14), %rdi
movq %rdi, 0x8(%rsp)
cmpl $0x59, %r12d
jle 0x10ce8
cmpl $0x5a, %r12d
je 0x10d29
cmpl $0x66, %r12d
je 0x10e07
cmpl $0x69, %r12d
jne 0x10d21
movq %r9, %r12
leaq 0x8(%rsp), %rsi
movl $0xa, %edx
movq %r8, %r14
callq 0x3260
leaq 0x3(%r14), %rdx
cmpq %rbp, %rdx
movq %rax, 0x10(%rsp)
movq %rdx, 0x18(%rsp)
jbe 0x10fa0
movq %r13, %rax
shrq %rax
orq %r13, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r12, %rdi
movq %rbp, %rsi
callq 0x3330
movq %r14, %rcx
movq %rax, %r9
jmp 0x10fa6
cmpl $0x41, %r12d
je 0x10e79
cmpl $0x42, %r12d
jne 0x10d21
leaq 0x6(%r14), %rax
movq %rax, 0x8(%rsp)
movb 0x5(%r14), %dil
movq %r15, %rcx
subq %rax, %rcx
cmpq $0x2, %rcx
setl %cl
cmpb $0x66, %dil
sete %dl
orb %cl, %dl
je 0x11025
movq %r13, %r8
jmp 0x1100c
addq $0x3, %r8
cmpq %rbp, %r8
jbe 0x10d7a
movq %r13, %rax
shrq %rax
orq %r13, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
movq %r8, %r14
callq 0x3330
movq %r14, %r8
movq %rax, %r9
movb $0x5a, (%r9,%r13)
movq 0x8(%rsp), %rsi
movl %r15d, %eax
subl %esi, %eax
incl %eax
movslq %eax, %r14
leaq (%r14,%r8), %r12
cmpq %rbp, %r12
jbe 0x10dee
leaq -0x1(%r12), %rax
movq %rsi, 0x10(%rsp)
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rbp
shrq $0x10, %rbp
orq %rax, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
movq %r8, %r13
callq 0x3330
movq 0x10(%rsp), %rsi
movq %r13, %r8
movq %rax, %r9
addq %r9, %r8
movq %r8, %rdi
movq %r9, %r13
movq %r14, %rdx
callq 0x32c0
movq %r13, %r9
jmp 0x11009
movq %r9, %r12
leaq 0x8(%rsp), %rsi
movq %r8, %r14
callq 0x30d0
movsd %xmm0, 0x10(%rsp)
leaq 0x3(%r14), %rdx
movq %rdx, 0x18(%rsp)
cmpq %rbp, %rdx
jbe 0x10f32
movq %r13, %rax
shrq %rax
orq %r13, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r12, %rdi
movq %rbp, %rsi
callq 0x3330
movq %r14, %rcx
movq %rax, %r9
jmp 0x10f38
leaq 0x3(%r8), %r14
cmpq %rbp, %r14
jbe 0x10eca
movq %r13, %rax
shrq %rax
orq %r13, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
movq %r8, %r12
callq 0x3330
movq %r12, %r8
movq %rax, %r9
movb $0x41, 0x2(%r9,%r8)
movq 0x8(%rsp), %rax
movb (%rax), %r12b
addq $0x4, %r8
cmpq %rbp, %r8
jbe 0x10f29
movq %r14, %rax
shrq %rax
orq %r14, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
movq %r8, %r13
callq 0x3330
movq %r13, %r8
movq %rax, %r9
movb %r12b, (%r9,%r14)
jmp 0x1100c
movq %r14, %rcx
movq %r12, %r9
movb $0x66, 0x2(%r9,%rcx)
leaq 0xb(%rcx), %r12
cmpq %rbp, %r12
jbe 0x10f8d
addq $0xa, %rcx
movq %rcx, %rax
shrq %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
callq 0x3330
movq %rax, %r9
movsd 0x10(%rsp), %xmm0
movq 0x18(%rsp), %rax
movsd %xmm0, (%r9,%rax)
jmp 0x11009
movq %r14, %rcx
movq %r12, %r9
movb $0x69, 0x2(%r9,%rcx)
leaq 0xb(%rcx), %r12
cmpq %rbp, %r12
jbe 0x10ffb
addq $0xa, %rcx
movq %rcx, %rax
shrq %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
callq 0x3330
movq %rax, %r9
movq 0x10(%rsp), %rax
movq 0x18(%rsp), %rcx
movq %rax, (%r9,%rcx)
movq %r12, %r8
leaq 0x1(%r15), %rax
movq %rax, 0x8(%rsp)
testb %bl, %bl
je 0x11510
incq %r15
jmp 0x10b6e
movzbl %dil, %ecx
movl %ecx, 0x10(%rsp)
xorl %r14d, %r14d
movzbl (%rax), %ecx
cmpl $0x2c, %ecx
je 0x1103e
testl %ecx, %ecx
jne 0x11041
jmp 0x11046
incl %r14d
incq %rax
jmp 0x11030
leaq 0x3(%r8), %r12
cmpq %rbp, %r12
movb %dil, 0x18(%rsp)
jbe 0x1109c
movq %r13, %rax
shrq %rax
orq %r13, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
movq %r8, %r13
callq 0x3330
movq %r13, %r8
movq %rax, %r9
movb $0x42, 0x2(%r9,%r8)
leaq 0x4(%r8), %rcx
movq %rcx, 0x28(%rsp)
cmpq %rbp, %rcx
jbe 0x110f8
movq %r12, %rax
shrq %rax
orq %r12, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
movq %r8, %r12
callq 0x3330
movq %r12, %r8
movq %rax, %r9
movb 0x18(%rsp), %al
movb %al, 0x3(%r9,%r8)
leaq 0x8(%r8), %r13
cmpq %rbp, %r13
jbe 0x11150
addq $0x7, %r8
movq %r8, %rax
shrq %rax
orq %r8, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
callq 0x3330
movq %rax, %r9
movl 0x10(%rsp), %eax
movq 0x28(%rsp), %rcx
movl %r14d, (%r9,%rcx)
cmpl $0x62, %eax
jg 0x11216
cmpl $0x43, %eax
je 0x112c6
cmpl $0x49, %eax
je 0x113e8
cmpl $0x53, %eax
jne 0x10d21
movq 0x8(%rsp), %rdi
incq %rdi
movq %r13, %r8
cmpq %r15, %rdi
jae 0x1100c
movq %r9, %r12
leaq 0x8(%rsp), %rsi
xorl %edx, %edx
callq 0x32b0
movq %rax, %r14
leaq 0x2(%r13), %r8
cmpq %rbp, %r8
jbe 0x111fe
leaq 0x1(%r13), %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rbp
shrq $0x10, %rbp
orq %rax, %rbp
incq %rbp
movq %r12, %rdi
movq %rbp, %rsi
movq %r8, %r12
callq 0x3330
movq %r12, %r8
movq %rax, %r9
jmp 0x11201
movq %r12, %r9
movw %r14w, (%r9,%r13)
movq 0x8(%rsp), %rdi
incq %rdi
movq %r8, %r13
jmp 0x1118c
cmpl $0x63, %eax
je 0x11356
cmpl $0x69, %eax
je 0x1147c
cmpl $0x73, %eax
jne 0x10d21
movq 0x8(%rsp), %rdi
incq %rdi
movq %r13, %r8
cmpq %r15, %rdi
jae 0x1100c
movq %r9, %r12
leaq 0x8(%rsp), %rsi
xorl %edx, %edx
callq 0x32b0
movq %rax, %r14
leaq 0x2(%r13), %r8
cmpq %rbp, %r8
jbe 0x112ae
leaq 0x1(%r13), %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rbp
shrq $0x10, %rbp
orq %rax, %rbp
incq %rbp
movq %r12, %rdi
movq %rbp, %rsi
movq %r8, %r12
callq 0x3330
movq %r12, %r8
movq %rax, %r9
jmp 0x112b1
movq %r12, %r9
movw %r14w, (%r9,%r13)
movq 0x8(%rsp), %rdi
incq %rdi
movq %r8, %r13
jmp 0x1123c
movq 0x8(%rsp), %rdi
incq %rdi
movq %r13, %r8
cmpq %r15, %rdi
jae 0x1100c
movq %r9, %r12
leaq 0x8(%rsp), %rsi
xorl %edx, %edx
callq 0x32b0
movq %rax, %r14
leaq 0x1(%r13), %r8
cmpq %rbp, %r8
jbe 0x1133f
movq %r13, %rax
shrq %rax
orq %r13, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r12, %rdi
movq %rbp, %rsi
movq %r8, %r12
callq 0x3330
movq %r12, %r8
movq %rax, %r9
jmp 0x11342
movq %r12, %r9
movb %r14b, (%r9,%r13)
movq 0x8(%rsp), %rdi
incq %rdi
movq %r8, %r13
jmp 0x112d1
movq 0x8(%rsp), %rdi
incq %rdi
cmpq %r15, %rdi
jae 0x10d21
movq %r9, %r12
leaq 0x8(%rsp), %rsi
xorl %edx, %edx
callq 0x32b0
movq %rax, %r14
leaq 0x1(%r13), %r8
cmpq %rbp, %r8
jbe 0x113cc
movq %r13, %rax
shrq %rax
orq %r13, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r12, %rdi
movq %rbp, %rsi
movq %r8, %r12
callq 0x3330
movq %r12, %r8
movq %rax, %r9
jmp 0x113cf
movq %r12, %r9
movb %r14b, (%r9,%r13)
movq 0x8(%rsp), %rdi
incq %rdi
movq %r8, %r13
cmpq %r15, %rdi
jb 0x11367
jmp 0x1100c
movq 0x8(%rsp), %rdi
incq %rdi
movq %r13, %r8
cmpq %r15, %rdi
jae 0x1100c
movq %r9, %r12
leaq 0x8(%rsp), %rsi
xorl %edx, %edx
callq 0x3260
movq %rax, %r14
leaq 0x8(%r13), %r8
cmpq %rbp, %r8
jbe 0x11465
leaq 0x7(%r13), %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rbp
shrq $0x10, %rbp
orq %rax, %rbp
incq %rbp
movq %r12, %rdi
movq %rbp, %rsi
movq %r8, %r12
callq 0x3330
movq %r12, %r8
movq %rax, %r9
jmp 0x11468
movq %r12, %r9
movq %r14, (%r9,%r13)
movq 0x8(%rsp), %rdi
incq %rdi
movq %r8, %r13
jmp 0x113f3
movq 0x8(%rsp), %rdi
incq %rdi
movq %r13, %r8
cmpq %r15, %rdi
jae 0x1100c
movq %r9, %r12
leaq 0x8(%rsp), %rsi
xorl %edx, %edx
callq 0x3260
movq %rax, %r14
leaq 0x8(%r13), %r8
cmpq %rbp, %r8
jbe 0x114f9
leaq 0x7(%r13), %rax
movq %rax, %rcx
shrq %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x2, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x4, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x8, %rax
orq %rcx, %rax
movq %rax, %rbp
shrq $0x10, %rbp
orq %rax, %rbp
incq %rbp
movq %r12, %rdi
movq %rbp, %rsi
movq %r8, %r12
callq 0x3330
movq %r12, %r8
movq %rax, %r9
jmp 0x114fc
movq %r12, %r9
movq %r14, (%r9,%r13)
movq 0x8(%rsp), %rdi
incq %rdi
movq %r8, %r13
jmp 0x11487
testq %r8, %r8
je 0x11577
cmpq %rbp, %r8
movq 0x20(%rsp), %rbx
jne 0x1157c
leaq 0x1(%r8), %rax
cmpq %rax, %rbp
jae 0x1157c
movq %r8, %rax
shrq %rax
orq %r8, %rax
movq %rax, %rcx
shrq $0x2, %rcx
orq %rax, %rcx
movq %rcx, %rax
shrq $0x4, %rax
orq %rcx, %rax
movq %rax, %rcx
shrq $0x8, %rcx
orq %rax, %rcx
movq %rcx, %rbp
shrq $0x10, %rbp
orq %rcx, %rbp
incq %rbp
movq %r9, %rdi
movq %rbp, %rsi
movq %r8, %r14
callq 0x3330
movq %r14, %r8
movq %rax, %r9
jmp 0x1157c
xorl %r8d, %r8d
jmp 0x1159e
movq 0x20(%rsp), %rbx
testq %r9, %r9
je 0x11586
movb $0x0, (%r9,%r8)
movq 0x30(%rsp), %rax
movl %ebp, (%rax)
movq %r9, (%rbx)
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
movl %r8d, %eax
retq