// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/htscodecs/htscodecs/tokenise_name3.c
// Function: append_uint32_var
static int append_uint32_var(char *cp, uint32_t i) {
    char *op = cp;
    uint32_t j;

    //if (i < 10)         goto b0;
    if (i < 100)        goto b1;
    //if (i < 1000)       goto b2;
    if (i < 10000)      goto b3;
    //if (i < 100000)     goto b4;
    if (i < 1000000)    goto b5;
    //if (i < 10000000)   goto b6;
    if (i < 100000000)  goto b7;

    if ((j = i / 1000000000)) {*cp++ = j + '0'; i -= j*1000000000; goto x8;}
    if ((j = i / 100000000))  {*cp++ = j + '0'; i -= j*100000000;  goto x7;}
 b7:if ((j = i / 10000000))   {*cp++ = j + '0'; i -= j*10000000;   goto x6;}
    if ((j = i / 1000000))    {*cp++ = j + '0', i -= j*1000000;    goto x5;}
 b5:if ((j = i / 100000))     {*cp++ = j + '0', i -= j*100000;     goto x4;}
    if ((j = i / 10000))      {*cp++ = j + '0', i -= j*10000;      goto x3;}
 b3:if ((j = i / 1000))       {*cp++ = j + '0', i -= j*1000;       goto x2;}
    if ((j = i / 100))        {*cp++ = j + '0', i -= j*100;        goto x1;}
 b1:if ((j = i / 10))         {*cp++ = j + '0', i -= j*10;         goto x0;}
    if (i)                     *cp++ = i + '0';
    return cp-op;

 x8:*cp++ = i / 100000000 + '0', i %= 100000000;
 x7:*cp++ = i / 10000000  + '0', i %= 10000000;
 x6:*cp++ = i / 1000000   + '0', i %= 1000000;
 x5:*cp++ = i / 100000    + '0', i %= 100000;
 x4:*cp++ = i / 10000     + '0', i %= 10000;
 x3:*cp++ = i / 1000      + '0', i %= 1000;
 x2:*cp++ = i / 100       + '0', i %= 100;
 x1:*cp++ = i / 10        + '0', i %= 10;
 x0:*cp++ = i             + '0';

    return cp-op;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
cmpl $0x64, -0x14(%rbp)
jae 0xce23e
jmp 0xce475
cmpl $0x2710, -0x14(%rbp)    # imm = 0x2710
jae 0xce24c
jmp 0xce3f4
cmpl $0xf4240, -0x14(%rbp)   # imm = 0xF4240
jae 0xce25a
jmp 0xce370
cmpl $0x5f5e100, -0x14(%rbp) # imm = 0x5F5E100
jae 0xce268
jmp 0xce2ec
movl -0x14(%rbp), %eax
movl $0x3b9aca00, %ecx       # imm = 0x3B9ACA00
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce2a9
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0x3b9aca00, -0x24(%rbp), %ecx # imm = 0x3B9ACA00
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce4e5
movl -0x14(%rbp), %eax
movl $0x5f5e100, %ecx        # imm = 0x5F5E100
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce2ea
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0x5f5e100, -0x24(%rbp), %ecx # imm = 0x5F5E100
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce516
jmp 0xce2ec
movl -0x14(%rbp), %eax
movl $0x989680, %ecx         # imm = 0x989680
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce32d
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0x989680, -0x24(%rbp), %ecx # imm = 0x989680
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce547
movl -0x14(%rbp), %eax
movl $0xf4240, %ecx          # imm = 0xF4240
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce36e
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0xf4240, -0x24(%rbp), %ecx # imm = 0xF4240
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce578
jmp 0xce370
movl -0x14(%rbp), %eax
movl $0x186a0, %ecx          # imm = 0x186A0
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce3b1
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0x186a0, -0x24(%rbp), %ecx # imm = 0x186A0
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce5a9
movl -0x14(%rbp), %eax
movl $0x2710, %ecx           # imm = 0x2710
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce3f2
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0x2710, -0x24(%rbp), %ecx # imm = 0x2710
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce5da
jmp 0xce3f4
movl -0x14(%rbp), %eax
movl $0x3e8, %ecx            # imm = 0x3E8
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce435
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0x3e8, -0x24(%rbp), %ecx # imm = 0x3E8
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce60b
movl -0x14(%rbp), %eax
movl $0x64, %ecx
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce473
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0x64, -0x24(%rbp), %ecx
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce63c
jmp 0xce475
movl -0x14(%rbp), %eax
movl $0xa, %ecx
xorl %edx, %edx
divl %ecx
movl %eax, -0x24(%rbp)
cmpl $0x0, %eax
je 0xce4b3
movl -0x24(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
imull $0xa, -0x24(%rbp), %ecx
movl -0x14(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x14(%rbp)
jmp 0xce66d
cmpl $0x0, -0x14(%rbp)
je 0xce4d2
movl -0x14(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rax
movq -0x20(%rbp), %rcx
subq %rcx, %rax
movl %eax, -0x4(%rbp)
jmp 0xce694
movl -0x14(%rbp), %eax
movl $0x5f5e100, %ecx        # imm = 0x5F5E100
xorl %edx, %edx
divl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
movl $0x5f5e100, %ecx        # imm = 0x5F5E100
xorl %edx, %edx
divl %ecx
movl %edx, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl $0x989680, %ecx         # imm = 0x989680
xorl %edx, %edx
divl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
movl $0x989680, %ecx         # imm = 0x989680
xorl %edx, %edx
divl %ecx
movl %edx, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl $0xf4240, %ecx          # imm = 0xF4240
xorl %edx, %edx
divl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
movl $0xf4240, %ecx          # imm = 0xF4240
xorl %edx, %edx
divl %ecx
movl %edx, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl $0x186a0, %ecx          # imm = 0x186A0
xorl %edx, %edx
divl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
movl $0x186a0, %ecx          # imm = 0x186A0
xorl %edx, %edx
divl %ecx
movl %edx, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl $0x2710, %ecx           # imm = 0x2710
xorl %edx, %edx
divl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
movl $0x2710, %ecx           # imm = 0x2710
xorl %edx, %edx
divl %ecx
movl %edx, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl $0x3e8, %ecx            # imm = 0x3E8
xorl %edx, %edx
divl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
movl $0x3e8, %ecx            # imm = 0x3E8
xorl %edx, %edx
divl %ecx
movl %edx, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl $0x64, %ecx
xorl %edx, %edx
divl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
movl $0x64, %ecx
xorl %edx, %edx
divl %ecx
movl %edx, -0x14(%rbp)
movl -0x14(%rbp), %eax
movl $0xa, %ecx
xorl %edx, %edx
divl %ecx
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movl -0x14(%rbp), %eax
movl $0xa, %ecx
xorl %edx, %edx
divl %ecx
movl %edx, -0x14(%rbp)
movl -0x14(%rbp), %eax
addl $0x30, %eax
movb %al, %cl
movq -0x10(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x10(%rbp)
movb %cl, (%rax)
movq -0x10(%rbp), %rax
movq -0x20(%rbp), %rcx
subq %rcx, %rax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopl (%rax)