// File: /workspace/github_c_makefile_star2_O2/icebert[P]pblat/htslib/sam.c
// Function: sam_parse1
int sam_parse1(kstring_t *s, bam_hdr_t *h, bam1_t *b)
{
#define _read_token(_p) (_p); for (; *(_p) && *(_p) != '\t'; ++(_p)); if (*(_p) != '\t') goto err_ret; *(_p)++ = 0
#define _read_token_aux(_p) (_p); for (; *(_p) && *(_p) != '\t'; ++(_p)); *(_p)++ = 0 // this is different in that it does not test *(_p)=='\t'
#define _get_mem(type_t, _x, _s, _l) ks_resize((_s), (_s)->l + (_l)); *(_x) = (type_t*)((_s)->s + (_s)->l); (_s)->l += (_l)
#define _parse_err(cond, msg) do { if ((cond) && hts_verbose >= 1) { fprintf(stderr, "[E::%s] " msg "\n", __func__); goto err_ret; } } while (0)
#define _parse_warn(cond, msg) if ((cond) && hts_verbose >= 2) fprintf(stderr, "[W::%s] " msg "\n", __func__)

    uint8_t *t;
    char *p = s->s, *q;
    int i;
    kstring_t str;
    bam1_core_t *c = &b->core;

    str.l = b->l_data = 0;
    str.s = (char*)b->data; str.m = b->m_data;
    memset(c, 0, 32);
    if (h->cigar_tab == 0) {
        h->cigar_tab = (int8_t*) malloc(128);
        for (i = 0; i < 128; ++i)
            h->cigar_tab[i] = -1;
        for (i = 0; BAM_CIGAR_STR[i]; ++i)
            h->cigar_tab[(int)BAM_CIGAR_STR[i]] = i;
    }
    // qname
    q = _read_token(p);
    _parse_warn(p - q <= 1, "empty query name");
    _parse_err(p - q > 255, "query name too long");
    kputsn_(q, p - q, &str);
    c->l_qname = p - q;
    // flag
    c->flag = strtol(p, &p, 0);
    if (*p++ != '\t') goto err_ret; // malformated flag
    // chr
    q = _read_token(p);
    if (strcmp(q, "*")) {
        _parse_err(h->n_targets == 0, "missing SAM header");
        c->tid = bam_name2id(h, q);
        _parse_warn(c->tid < 0, "urecognized reference name; treated as unmapped");
    } else c->tid = -1;
    // pos
    c->pos = strtol(p, &p, 10) - 1;
    if (*p++ != '\t') goto err_ret;
    if (c->pos < 0 && c->tid >= 0) {
        _parse_warn(1, "mapped query cannot have zero coordinate; treated as unmapped");
        c->tid = -1;
    }
    if (c->tid < 0) c->flag |= BAM_FUNMAP;
    // mapq
    c->qual = strtol(p, &p, 10);
    if (*p++ != '\t') goto err_ret;
    // cigar
    if (*p != '*') {
        uint32_t *cigar;
        size_t n_cigar = 0;
        for (q = p; *p && *p != '\t'; ++p)
            if (!isdigit(*p)) ++n_cigar;
        if (*p++ != '\t') goto err_ret;
        _parse_err(n_cigar == 0, "no CIGAR operations");
        _parse_err(n_cigar >= 65536, "too many CIGAR operations");
        c->n_cigar = n_cigar;
        _get_mem(uint32_t, &cigar, &str, c->n_cigar * sizeof(uint32_t));
        for (i = 0; i < c->n_cigar; ++i, ++q) {
            int op;
            cigar[i] = strtol(q, &q, 10)<<BAM_CIGAR_SHIFT;
            op = (uint8_t)*q >= 128? -1 : h->cigar_tab[(int)*q];
            _parse_err(op < 0, "unrecognized CIGAR operator");
            cigar[i] |= op;
        }
        // can't use bam_endpos() directly as some fields not yet set up
        i = (!(c->flag&BAM_FUNMAP))? bam_cigar2rlen(c->n_cigar, cigar) : 1;
    } else {
        _parse_warn(!(c->flag&BAM_FUNMAP), "mapped query must have a CIGAR; treated as unmapped");
        c->flag |= BAM_FUNMAP;
        q = _read_token(p);
        i = 1;
    }
    c->bin = hts_reg2bin(c->pos, c->pos + i, 14, 5);
    // mate chr
    q = _read_token(p);
    if (strcmp(q, "=") == 0) c->mtid = c->tid;
    else if (strcmp(q, "*") == 0) c->mtid = -1;
    else c->mtid = bam_name2id(h, q);
    // mpos
    c->mpos = strtol(p, &p, 10) - 1;
    if (*p++ != '\t') goto err_ret;
    if (c->mpos < 0 && c->mtid >= 0) {
        _parse_warn(1, "mapped mate cannot have zero coordinate; treated as unmapped");
        c->mtid = -1;
    }
    // tlen
    c->isize = strtol(p, &p, 10);
    if (*p++ != '\t') goto err_ret;
    // seq
    q = _read_token(p);
    if (strcmp(q, "*")) {
        c->l_qseq = p - q - 1;
        i = bam_cigar2qlen(c->n_cigar, (uint32_t*)(str.s + c->l_qname));
        _parse_err(c->n_cigar && i != c->l_qseq, "CIGAR and query sequence are of different length");
        i = (c->l_qseq + 1) >> 1;
        _get_mem(uint8_t, &t, &str, i);
        memset(t, 0, i);
        for (i = 0; i < c->l_qseq; ++i)
            t[i>>1] |= seq_nt16_table[(int)q[i]] << ((~i&1)<<2);
    } else c->l_qseq = 0;
    // qual
    q = _read_token_aux(p);
    _get_mem(uint8_t, &t, &str, c->l_qseq);
    if (strcmp(q, "*")) {
        _parse_err(p - q - 1 != c->l_qseq, "SEQ and QUAL are of different length");
        for (i = 0; i < c->l_qseq; ++i) t[i] = q[i] - 33;
    } else memset(t, 0xff, c->l_qseq);
    // aux
    // Note that (like the bam1_core_t fields) this aux data in b->data is
    // stored in host endianness; so there is no byte swapping needed here.
    while (p < s->s + s->l) {
        uint8_t type;
        q = _read_token_aux(p); // FIXME: can be accelerated for long 'B' arrays
        _parse_err(p - q - 1 < 6, "incomplete aux field");
        kputsn_(q, 2, &str);
        q += 3; type = *q++; ++q; // q points to value
        if (type == 'A' || type == 'a' || type == 'c' || type == 'C') {
            kputc_('A', &str);
            kputc_(*q, &str);
        } else if (type == 'i' || type == 'I') {
            if (*q == '-') {
                long x = strtol(q, &q, 10);
                if (x >= INT8_MIN) {
                    kputc_('c', &str); kputc_(x, &str);
                } else if (x >= INT16_MIN) {
                    int16_t y = x;
                    kputc_('s', &str); kputsn_((char*)&y, 2, &str);
                } else {
                    int32_t y = x;
                    kputc_('i', &str); kputsn_(&y, 4, &str);
                }
            } else {
                unsigned long x = strtoul(q, &q, 10);
                if (x <= UINT8_MAX) {
                    kputc_('C', &str); kputc_(x, &str);
                } else if (x <= UINT16_MAX) {
                    uint16_t y = x;
                    kputc_('S', &str); kputsn_(&y, 2, &str);
                } else {
                    uint32_t y = x;
                    kputc_('I', &str); kputsn_(&y, 4, &str);
                }
            }
        } else if (type == 'f') {
            float x;
            x = strtod(q, &q);
            kputc_('f', &str); kputsn_(&x, 4, &str);
        } else if (type == 'd') {
            double x;
            x = strtod(q, &q);
            kputc_('d', &str); kputsn_(&x, 8, &str);
        } else if (type == 'Z' || type == 'H') {
            kputc_(type, &str);kputsn_(q, p - q, &str); // note that this include the trailing NULL
        } else if (type == 'B') {
            int32_t n;
            char *r;
            _parse_err(p - q - 1 < 3, "incomplete B-typed aux field");
            type = *q++; // q points to the first ',' following the typing byte
            for (r = q, n = 0; *r; ++r)
                if (*r == ',') ++n;
            kputc_('B', &str); kputc_(type, &str); kputsn_(&n, 4, &str);
            // FIXME: 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 = strtoul(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 = strtoul(q + 1, &q, 0); kputsn_(&x, 2, &str); }
            else if (type == 'i') while (q + 1 < p) { int32_t  x = strtol(q + 1, &q, 0); kputsn_(&x, 4, &str); }
            else if (type == 'I') while (q + 1 < p) { uint32_t x = strtoul(q + 1, &q, 0); kputsn_(&x, 4, &str); }
            else if (type == 'f') while (q + 1 < p) { float    x = strtod(q + 1, &q);    kputsn_(&x, 4, &str); }
            else _parse_err(1, "unrecognized type");
        } else _parse_err(1, "unrecognized type");
    }
    b->data = (uint8_t*)str.s; b->l_data = str.l; b->m_data = str.m;
    return 0;

#undef _parse_warn
#undef _parse_err
#undef _get_mem
#undef _read_token_aux
#undef _read_token
err_ret:
    b->data = (uint8_t*)str.s; b->l_data = str.l; b->m_data = str.m;
    return -2;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movq %rdx, %rbx
movq %rsi, %r15
movq %rdi, 0x50(%rsp)
movq 0x10(%rdi), %r12
andl $0x0, 0x20(%rdx)
andq $0x0, 0x30(%rsp)
movq 0x28(%rdx), %rax
movq %rax, 0x40(%rsp)
movslq 0x24(%rdx), %rax
movq %rax, 0x38(%rsp)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rdx)
movups %xmm0, (%rdx)
cmpq $0x0, 0x18(%rsi)
je 0x62cec
movq %rbx, 0x8(%rsp)
movq %r12, (%rsp)
leaq 0x1(%r12), %r13
movl $0x1000000, %ebx        # imm = 0x1000000
pushq $0x1
popq %r14
pushq $-0x2
popq %rbp
movzbl -0x1(%r13), %eax
testl %eax, %eax
je 0x62dea
cmpl $0x9, %eax
je 0x62c45
incq %r13
addq $0x1000000, %rbx        # imm = 0x1000000
incq %r14
jmp 0x62c24
movq %r13, 0x28(%rsp)
movb $0x0, -0x1(%r13)
cmpq $0x2, %r14
setl %cl
leaq 0x5218b(%rip), %rax     # 0xb4de8
movl (%rax), %eax
cmpl $0x2, %eax
setge %dl
andb %cl, %dl
cmpb $0x1, %dl
je 0x62da7
cmpq $0x100, %r14            # imm = 0x100
setge %cl
testl %eax, %eax
setg %al
andb %cl, %al
cmpb $0x1, %al
je 0x62dcb
leaq 0x30(%rsp), %rdx
movq %r12, %rdi
movl %r14d, %esi
callq 0x63949
shrl $0x18, %ebx
movq 0x8(%rsp), %rax
movb %bl, 0xb(%rax)
movq %rax, %rbx
leaq 0x28(%rsp), %r14
movq %r13, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x6a60
movw %ax, 0xc(%rbx)
movq (%r14), %rax
cmpb $0x9, (%rax)
jne 0x62def
leaq 0x1(%rax), %rsi
movq %rsi, (%rsp)
leaq 0x2(%rax), %r14
movzbl -0x1(%r14), %ecx
testl %ecx, %ecx
je 0x62def
cmpl $0x9, %ecx
je 0x62d35
incq %r14
jmp 0x62cd5
movl $0x80, %edi
callq 0x69d0
movq %rax, 0x18(%r15)
xorl %eax, %eax
cmpq $0x80, %rax
je 0x62d11
movq 0x18(%r15), %rcx
movb $-0x1, (%rcx,%rax)
incq %rax
jmp 0x62cfc
xorl %eax, %eax
leaq 0x26657(%rip), %rcx     # 0x89371
cmpq $0xa, %rax
je 0x62c0a
movsbq (%rax,%rcx), %rdx
movq 0x18(%r15), %rsi
movb %al, (%rsi,%rdx)
incq %rax
jmp 0x62d1a
movq %r14, 0x28(%rsp)
movb $0x0, -0x1(%r14)
cmpb $0x2a, (%rsi)
jne 0x62d4e
cmpb $0x0, 0x2(%rax)
je 0x62e15
cmpl $0x0, (%r15)
jne 0x62d64
leaq 0x5208d(%rip), %rax     # 0xb4de8
cmpl $0x0, (%rax)
jg 0x63076
movq %r15, %rdi
callq 0x61879
movl %eax, (%rbx)
testl %eax, %eax
jns 0x62e18
leaq 0x5206b(%rip), %rax     # 0xb4de8
cmpl $0x2, (%rax)
jl 0x62e18
movq 0x5024b(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x26643(%rip), %rsi     # 0x893da
leaq 0x265f8(%rip), %rdx     # 0x89396
xorl %eax, %eax
callq 0x6a90
jmp 0x62e18
movq 0x5022a(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x265c4(%rip), %rsi     # 0x8937c
leaq 0x265d7(%rip), %rdx     # 0x89396
xorl %eax, %eax
callq 0x6a90
jmp 0x62c89
movq 0x50206(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x265c5(%rip), %rsi     # 0x893a1
leaq 0x265b3(%rip), %rdx     # 0x89396
xorl %eax, %eax
callq 0x6a90
movq 0x8(%rsp), %rbx
movq 0x40(%rsp), %rax
movq %rax, 0x28(%rbx)
pshufd $0xe8, 0x30(%rsp), %xmm0 # xmm0 = mem[0,2,2,3]
movq %xmm0, 0x20(%rbx)
movl %ebp, %eax
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
orl $-0x1, (%rbx)
leaq 0x28(%rsp), %r12
pushq $0xa
popq %rdx
movq %r14, %rdi
movq %r12, %rsi
callq 0x6a60
decl %eax
movl %eax, 0x4(%rbx)
movq (%r12), %rcx
leaq 0x1(%rcx), %r14
movq %r14, (%r12)
cmpb $0x9, (%rcx)
jne 0x62def
movl (%rbx), %ecx
testl %eax, %eax
js 0x62e4d
testl %ecx, %ecx
jns 0x62e68
jmp 0x62e64
testl %ecx, %ecx
js 0x62e64
leaq 0x51f90(%rip), %rax     # 0xb4de8
cmpl $0x2, (%rax)
jge 0x63304
orl $-0x1, (%rbx)
orb $0x4, 0xc(%rbx)
leaq 0x28(%rsp), %r12
pushq $0xa
popq %rdx
movq %r14, %rdi
movq %r12, %rsi
callq 0x6a60
movq 0x8(%rbx), %rcx
movzbl %al, %eax
shll $0x10, %eax
movq %rcx, %rsi
andq $-0xff0001, %rsi        # imm = 0xFF00FFFF
orq %rax, %rsi
movq %rsi, 0x8(%rbx)
movq (%r12), %r12
cmpb $0x9, (%r12)
jne 0x62def
leaq 0x1(%r12), %r13
movb (%r13), %r14b
pushq $0x1
popq %rdx
cmpb $0x2a, %r14b
jne 0x62f04
movabsq $0x400000000, %rbx      # imm = 0x400000000
btq $0x22, %rcx
jb 0x62ed8
leaq 0x51f19(%rip), %rax     # 0xb4de8
cmpl $0x2, (%rax)
jge 0x631e5
orq %rbx, %rsi
movq 0x8(%rsp), %rbx
movq %rsi, 0x8(%rbx)
addq $0x2, %r12
movzbl -0x1(%r12), %eax
testl %eax, %eax
je 0x62def
cmpl $0x9, %eax
je 0x63051
incq %r12
jmp 0x62ee8
movq %rsi, 0x18(%rsp)
movq %r13, (%rsp)
addq $0x2, %r12
xorl %ebx, %ebx
testb %r14b, %r14b
je 0x62f42
movzbl %r14b, %eax
cmpl $0x9, %eax
je 0x62f42
callq 0x6790
movq (%rax), %rax
movsbq %r14b, %rcx
movb 0x1(%rax,%rcx,2), %al
andb $0x8, %al
cmpb $0x1, %al
adcq $0x0, %rbx
movb (%r12), %r14b
incq %r12
jmp 0x62f13
movq %r12, 0x28(%rsp)
cmpb $0x9, %r14b
movq 0x18(%rsp), %rsi
jne 0x62dea
testq %rbx, %rbx
sete %cl
leaq 0x51e85(%rip), %rax     # 0xb4de8
movl (%rax), %eax
testl %eax, %eax
setg %dl
andb %cl, %dl
cmpb $0x1, %dl
je 0x63328
testl %eax, %eax
setg %al
cmpq $0x10000, %rbx          # imm = 0x10000
setae %cl
andb %al, %cl
cmpb $0x1, %cl
je 0x6333e
movq %rbx, %rax
shlq $0x30, %rax
movabsq $0xffffffffffff, %rcx   # imm = 0xFFFFFFFFFFFF
andq %rcx, %rsi
orq %rax, %rsi
movq 0x8(%rsp), %rax
movq %rsi, 0x8(%rax)
movzwl %bx, %esi
shll $0x2, %esi
leaq 0x30(%rsp), %rbx
addq (%rbx), %rsi
movq %rbx, %rdi
callq 0x639d1
movq (%rbx), %rcx
movq 0x10(%rbx), %r14
addq %rcx, %r14
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, %rdx
shrq $0x30, %rdx
leaq (%rcx,%rdx,4), %rcx
movq %rcx, (%rbx)
xorl %ebx, %ebx
movq %rax, %rdi
shrq $0x30, %rdi
cmpq %rdi, %rbx
jae 0x6305e
movq %r13, %rdi
movq %rsp, %rsi
pushq $0xa
popq %rdx
callq 0x6a60
shll $0x4, %eax
movl %eax, (%r14,%rbx,4)
movq (%rsp), %r13
movsbq (%r13), %rdx
pushq $-0x1
popq %rcx
testq %rdx, %rdx
js 0x63022
movq 0x18(%r15), %rcx
movsbl (%rcx,%rdx), %ecx
testl %ecx, %ecx
jns 0x63036
leaq 0x51dbb(%rip), %rdx     # 0xb4de8
cmpl $0x0, (%rdx)
jg 0x63354
orl %eax, %ecx
movl %ecx, (%r14,%rbx,4)
incq %rbx
incq %r13
movq %r13, (%rsp)
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rax
jmp 0x62fe8
movq %r12, 0x28(%rsp)
movb $0x0, -0x1(%r12)
jmp 0x630a2
btq $0x22, %rax
jb 0x6309a
movq %r14, %rsi
callq 0x61a2c
movl %eax, %edx
movq 0x8(%rsp), %rbx
jmp 0x630a2
movq 0x4ff5b(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x26337(%rip), %rsi     # 0x893be
leaq 0x26308(%rip), %rdx     # 0x89396
xorl %eax, %eax
callq 0x6a90
jmp 0x62def
movq 0x8(%rsp), %rbx
pushq $0x1
popq %rdx
movslq 0x4(%rbx), %r9
movslq %edx, %rax
leaq (%r9,%rax), %r10
decq %r10
movl $0x1249, %r8d           # imm = 0x1249
pushq $0xe
popq %rdx
pushq $0xc
popq %rsi
xorl %edi, %edi
pushq $-0x1
popq %rax
cmpl $-0x3, %esi
je 0x630fe
movq %r9, %r11
movl %edx, %ecx
sarq %cl, %r11
movq %r10, %rbx
sarq %cl, %rbx
cmpq %rbx, %r11
je 0x630f2
movl %eax, %r11d
movl %esi, %ecx
shll %cl, %r11d
addq $0x3, %rdx
addl %r11d, %r8d
addl $-0x3, %esi
movq 0x8(%rsp), %rbx
jmp 0x630c1
addl %r11d, %r8d
movzwl %r8w, %edi
movq 0x8(%rsp), %rbx
movw %di, 0x8(%rbx)
movq %r12, (%rsp)
leaq 0x1(%r12), %r14
movzbl -0x1(%r14), %ecx
testl %ecx, %ecx
je 0x62def
cmpl $0x9, %ecx
je 0x63122
incq %r14
jmp 0x6310b
movq %r14, 0x28(%rsp)
movb $0x0, -0x1(%r14)
movzbl (%r12), %ecx
cmpl $0x2a, %ecx
je 0x63147
cmpl $0x3d, %ecx
jne 0x6314f
cmpb $0x0, 0x1(%r12)
jne 0x6314f
movl (%rbx), %eax
jmp 0x6315a
cmpb $0x0, 0x1(%r12)
je 0x6315a
movq %r15, %rdi
movq %r12, %rsi
callq 0x61879
movl %eax, 0x14(%rbx)
leaq 0x28(%rsp), %r15
pushq $0xa
popq %rdx
movq %r14, %rdi
movq %r15, %rsi
callq 0x6a60
decl %eax
movl %eax, 0x18(%rbx)
movq (%r15), %rcx
leaq 0x1(%rcx), %r14
movq %r14, (%r15)
cmpb $0x9, (%rcx)
jne 0x62def
testl %eax, %eax
jns 0x631a6
cmpl $0x0, 0x14(%rbx)
js 0x631a6
leaq 0x51c4f(%rip), %rax     # 0xb4de8
cmpl $0x2, (%rax)
jge 0x638cd
orl $-0x1, 0x14(%rbx)
leaq 0x28(%rsp), %r15
pushq $0xa
popq %rdx
movq %r14, %rdi
movq %r15, %rsi
callq 0x6a60
movl %eax, 0x1c(%rbx)
movq (%r15), %r12
cmpb $0x9, (%r12)
jne 0x62def
xorl %r15d, %r15d
movzbl 0x1(%r12,%r15), %eax
testl %eax, %eax
je 0x62def
cmpl $0x9, %eax
je 0x63218
incq %r15
jmp 0x631cd
movq 0x4fdec(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x262c9(%rip), %rsi     # 0x894bf
movl %edx, %r14d
leaq 0x26196(%rip), %rdx     # 0x89396
xorl %eax, %eax
callq 0x6a90
movl %r14d, %edx
movq 0x8(%rsp), %rax
movq 0x8(%rax), %rsi
jmp 0x62ed8
leaq (%r12,%r15), %r13
addq $0x2, %r13
movq %r13, 0x28(%rsp)
movb $0x0, -0x1(%r13)
cmpb $0x2a, 0x1(%r12)
jne 0x6323e
cmpb $0x0, 0x2(%r12)
je 0x6336a
movl %r15d, 0x10(%rbx)
movq 0x8(%rbx), %rbx
movq %rbx, %rdi
shrq $0x30, %rdi
movl %ebx, %esi
shrl $0x18, %esi
addq 0x40(%rsp), %rsi
callq 0x619f1
movabsq $0xffffffffffff, %rcx   # imm = 0xFFFFFFFFFFFF
incq %rcx
cmpq %rcx, %rbx
jb 0x63285
movl %eax, %eax
cmpl %r15d, %eax
je 0x63285
leaq 0x51b6c(%rip), %rax     # 0xb4de8
cmpl $0x0, (%rax)
jg 0x6391d
leal 0x1(%r15), %eax
sarl %eax
cltq
leaq 0x30(%rsp), %r14
movq (%r14), %rsi
addq %rax, %rsi
movq %rax, %rbx
movq %r14, %rdi
callq 0x639d1
movq (%r14), %rax
movq %r14, %rcx
movq 0x10(%r14), %r14
addq %rax, %r14
movq %rbx, %rdx
addq %rbx, %rax
movq %rax, (%rcx)
xorl %ebx, %ebx
movq %r14, %rdi
xorl %esi, %esi
callq 0x63b0
leaq 0x23ed4(%rip), %rax     # 0x871a0
xorl %edx, %edx
movq 0x8(%rsp), %rcx
movslq 0x10(%rcx), %rcx
cmpq %rcx, %rdx
jge 0x6336e
movsbq 0x1(%r12,%rdx), %rcx
movb (%rax,%rcx), %sil
movl %ebx, %ecx
notb %cl
andb $0x4, %cl
shlb %cl, %sil
movl %edx, %ecx
shrl %ecx
orb %sil, (%r14,%rcx)
incq %rdx
addb $0x4, %bl
jmp 0x632ce
movq 0x4fccd(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x260fe(%rip), %rsi     # 0x89413
leaq 0x2607a(%rip), %rdx     # 0x89396
xorl %eax, %eax
callq 0x6a90
jmp 0x62e61
movq 0x4fca9(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x26121(%rip), %rsi     # 0x8945a
jmp 0x62ddc
movq 0x4fc93(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x26128(%rip), %rsi     # 0x89477
jmp 0x62ddc
movq 0x4fc7d(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x26135(%rip), %rsi     # 0x8949a
jmp 0x62ddc
andl $0x0, 0x10(%rbx)
leaq (%r12,%r15), %rax
addq $0x3, %rax
movq %r13, (%rsp)
xorl %ebx, %ebx
movzbl -0x1(%rax), %ecx
testl %ecx, %ecx
je 0x63391
cmpl $0x9, %ecx
je 0x63391
incq %rax
incq %rbx
jmp 0x6337c
movq %rax, 0x28(%rsp)
movb $0x0, -0x1(%rax)
movq 0x8(%rsp), %r14
movslq 0x10(%r14), %rsi
leaq 0x30(%rsp), %rdi
addq (%rdi), %rsi
callq 0x639d1
leaq 0x30(%rsp), %rax
movq (%rax), %rcx
movq 0x10(%rax), %rdi
movq %rax, %rsi
addq %rcx, %rdi
movl 0x10(%r14), %eax
movslq %eax, %rdx
addq %rdx, %rcx
movq %rcx, (%rsi)
cmpb $0x2a, (%r13)
jne 0x633de
cmpb $0x0, 0x3(%r12,%r15)
je 0x63415
cmpq %rbx, %rdx
je 0x633f3
leaq 0x519fe(%rip), %rcx     # 0xb4de8
cmpl $0x0, (%rcx)
jg 0x63907
xorl %ecx, %ecx
movq 0x8(%rsp), %rbx
cltq
cmpq %rax, %rcx
jge 0x63424
movb (%r13), %al
addb $-0x21, %al
movb %al, (%rdi,%rcx)
incq %rcx
movl 0x10(%rbx), %eax
incq %r13
jmp 0x633fa
movl $0xff, %esi
callq 0x63b0
movq 0x8(%rsp), %rbx
movq 0x28(%rsp), %r13
leaq 0x26198(%rip), %rax     # 0x895c8
movq %rax, 0x48(%rsp)
movq 0x50(%rsp), %rcx
movq 0x10(%rcx), %rax
addq (%rcx), %rax
cmpq %rax, %r13
jae 0x638c6
movq %r13, (%rsp)
pushq $0x4
popq %r15
movq %r13, %r12
movzbl (%r12), %eax
testl %eax, %eax
je 0x6346b
cmpl $0x9, %eax
je 0x6346b
incq %r12
decq %r15
jmp 0x63455
movb $0x0, (%r12)
leaq -0x5(%r15), %rax
cmpq $-0x6, %rax
jl 0x6348a
leaq 0x51967(%rip), %rax     # 0xb4de8
cmpl $0x0, (%rax)
jg 0x638f1
leaq 0x1(%r12), %rax
movq %rax, 0x18(%rsp)
movq %r13, %rdi
pushq $0x2
popq %rsi
leaq 0x30(%rsp), %rdx
callq 0x63949
leaq 0x4(%r13), %rax
movq %rax, (%rsp)
movzbl 0x3(%r13), %edi
leaq 0x5(%r13), %r14
movq %r14, (%rsp)
leal -0x41(%rdi), %eax
cmpl $0x22, %eax
ja 0x634f7
movabsq $0x500000005, %rcx      # imm = 0x500000005
btq %rax, %rcx
jae 0x634f7
pushq $0x41
popq %rdi
leaq 0x30(%rsp), %r15
movq %r15, %rsi
callq 0x63a2a
movsbl (%r14), %edi
movq %r15, %rsi
callq 0x63a2a
movq 0x18(%rsp), %r13
jmp 0x63435
movl %edi, %eax
andb $-0x21, %al
cmpb $0x49, %al
jne 0x63524
cmpb $0x2d, (%r14)
jne 0x63565
movq %r14, %rdi
movq %rsp, %rsi
pushq $0xa
popq %rdx
callq 0x6a60
movq %rax, %r14
cmpq $-0x80, %rax
jl 0x635b4
pushq $0x63
jmp 0x63580
cmpl $0x42, %edi
je 0x63641
cmpl $0x48, %edi
je 0x63596
cmpl $0x5a, %edi
je 0x63596
cmpl $0x64, %edi
je 0x635fa
cmpl $0x66, %edi
jne 0x63627
movq %r14, %rdi
movq %rsp, %rsi
callq 0x6500
cvtsd2ss %xmm0, %xmm0
movss %xmm0, 0x20(%rsp)
pushq $0x66
jmp 0x6383d
movq %r14, %rdi
movq %rsp, %rsi
pushq $0xa
popq %rdx
callq 0x6200
movq %rax, %r14
cmpq $0xff, %rax
ja 0x635cb
pushq $0x43
popq %rdi
leaq 0x30(%rsp), %r15
movq %r15, %rsi
callq 0x63a2a
movl %r14d, %edi
jmp 0x634e5
leaq 0x30(%rsp), %r12
movq %r12, %rsi
callq 0x63a2a
negl %r15d
movq %r14, %rdi
movl %r15d, %esi
movq %r12, %rdx
jmp 0x63856
cmpq $-0x8000, %r14          # imm = 0x8000
jb 0x6382d
movw %r14w, 0x20(%rsp)
pushq $0x73
jmp 0x635e0
cmpq $0xffff, %r14           # imm = 0xFFFF
ja 0x63836
movw %r14w, 0x20(%rsp)
pushq $0x53
popq %rdi
leaq 0x30(%rsp), %r14
movq %r14, %rsi
callq 0x63a2a
leaq 0x20(%rsp), %rdi
pushq $0x2
jmp 0x63852
movq %r14, %rdi
movq %rsp, %rsi
callq 0x6500
movsd %xmm0, 0x20(%rsp)
pushq $0x64
popq %rdi
leaq 0x30(%rsp), %r14
movq %r14, %rsi
callq 0x63a2a
leaq 0x20(%rsp), %rdi
pushq $0x8
jmp 0x63852
leaq 0x517ba(%rip), %rax     # 0xb4de8
cmpl $0x0, (%rax)
movq 0x18(%rsp), %r13
jle 0x63435
jmp 0x63933
cmpq $-0x3, %r15
jl 0x63657
leaq 0x5179a(%rip), %rax     # 0xb4de8
cmpl $0x0, (%rax)
jg 0x638ab
leaq 0x6(%r13), %r15
movq %r15, (%rsp)
movzbl 0x5(%r13), %r14d
andl $0x0, 0x20(%rsp)
xorl %eax, %eax
movq %r15, %rcx
movzbl (%rcx), %edx
cmpl $0x2c, %edx
je 0x6367c
testl %edx, %edx
jne 0x6367e
jmp 0x63683
incl %eax
incq %rcx
jmp 0x6366e
movl %eax, 0x20(%rsp)
pushq $0x42
popq %rdi
leaq 0x30(%rsp), %r13
movq %r13, %rsi
callq 0x63a2a
movl %r14d, %edi
movq %r13, %rsi
callq 0x63a2a
leaq 0x20(%rsp), %rdi
pushq $0x4
popq %rsi
movq %r13, %rdx
callq 0x63949
cmpl $0x43, %r14d
je 0x63860
cmpl $0x49, %r14d
movq %rsp, %r13
je 0x63823
cmpl $0x53, %r14d
je 0x637ef
cmpl $0x63, %r14d
je 0x63751
cmpl $0x73, %r14d
je 0x637ba
cmpl $0x69, %r14d
je 0x63785
cmpl $0x66, %r14d
jne 0x6388f
cmpq %r12, %r15
jae 0x634ed
incq %r15
movq %r15, %rdi
movq %r13, %rsi
callq 0x6500
cvtsd2ss %xmm0, %xmm0
movss %xmm0, 0x14(%rsp)
leaq 0x14(%rsp), %rdi
pushq $0x4
popq %rsi
leaq 0x30(%rsp), %rdx
callq 0x63949
movq (%rsp), %r15
jmp 0x636f7
incq %r15
movq %r15, %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x6a60
movsbl %al, %edi
leaq 0x30(%rsp), %rsi
callq 0x63a2a
movq (%rsp), %r15
cmpq %r12, %r15
jb 0x63730
jmp 0x634ed
incq %r15
movq %r15, %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x6a60
movl %eax, 0x14(%rsp)
leaq 0x14(%rsp), %rdi
pushq $0x4
popq %rsi
leaq 0x30(%rsp), %rdx
callq 0x63949
movq (%rsp), %r15
cmpq %r12, %r15
jb 0x6375b
jmp 0x634ed
incq %r15
movq %r15, %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x6a60
movw %ax, 0x14(%rsp)
leaq 0x14(%rsp), %rdi
pushq $0x2
popq %rsi
leaq 0x30(%rsp), %rdx
callq 0x63949
movq (%rsp), %r15
cmpq %r12, %r15
jb 0x6378f
jmp 0x634ed
incq %r15
movq %r15, %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x6200
movw %ax, 0x14(%rsp)
leaq 0x14(%rsp), %rdi
pushq $0x2
popq %rsi
leaq 0x30(%rsp), %rdx
callq 0x63949
movq (%rsp), %r15
cmpq %r12, %r15
jb 0x637c4
jmp 0x634ed
incq %r15
movq %r15, %rdi
movq %r13, %rsi
xorl %edx, %edx
callq 0x6200
movl %eax, 0x14(%rsp)
leaq 0x14(%rsp), %rdi
pushq $0x4
popq %rsi
leaq 0x30(%rsp), %rdx
callq 0x63949
movq (%rsp), %r15
cmpq %r12, %r15
jb 0x637f9
jmp 0x634ed
movl %r14d, 0x20(%rsp)
pushq $0x69
jmp 0x6383d
movl %r14d, 0x20(%rsp)
pushq $0x49
popq %rdi
leaq 0x30(%rsp), %r14
movq %r14, %rsi
callq 0x63a2a
leaq 0x20(%rsp), %rdi
pushq $0x4
popq %rsi
movq %r14, %rdx
callq 0x63949
jmp 0x634ed
movq %rsp, %r14
cmpq %r12, %r15
jae 0x634ed
incq %r15
movq %r15, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x6200
movzbl %al, %edi
leaq 0x30(%rsp), %rsi
callq 0x63a2a
movq (%rsp), %r15
jmp 0x63863
leaq 0x51552(%rip), %rax     # 0xb4de8
cmpl $0x0, (%rax)
jle 0x634ed
leaq 0x25d48(%rip), %rax     # 0x895ee
movq %rax, 0x48(%rsp)
movq 0x4f726(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x25ada(%rip), %rdx     # 0x89396
movq 0x48(%rsp), %rsi
jmp 0x62de3
xorl %ebp, %ebp
jmp 0x62def
movq 0x4f704(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x25c1e(%rip), %rsi     # 0x894fc
leaq 0x25ab1(%rip), %rdx     # 0x89396
xorl %eax, %eax
callq 0x6a90
jmp 0x631a2
movq 0x4f6e0(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x25ca8(%rip), %rsi     # 0x895aa
jmp 0x63087
movq 0x4f6ca(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x25c64(%rip), %rsi     # 0x8957c
jmp 0x62ddc
movq 0x4f6b4(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x25c14(%rip), %rsi     # 0x89542
jmp 0x62ddc
movq 0x4f69e(%rip), %rax     # 0xb2fd8
movq (%rax), %rdi
leaq 0x25caa(%rip), %rsi     # 0x895ee
jmp 0x63087