// File: /workspace/github_c_makefile_star2_O0/pali[P]bmfdec/./bmfdec.c
// Function: dblb_rdlen
INLINE int dblb_rdlen(bits_t *pbits)
{ unsigned u;
  RDN_PR(*pbits,u);
  switch (u&15)
  { case  1: case  3: case  5: case  7:
    case  9: case 11: case 13: case 15:
      pbits->pb++;     return 3;
    case  2: case  6:
    case 10: case 14:
      pbits->pb+=2+1;  return (1&(u>>2))+4;
    case  4: case 12:
      pbits->pb+=3+2;  return (3&(u>>3))+6;
    case  8:
      pbits->pb+=4+3;  return (7&(u>>4))+10;
    case  0: ;
  }
  switch ((u>>4)&15)
  { case  1: case  3: case  5: case  7:
    case  9: case 11: case 13: case 15:
      pbits->pb+=5+4;  return (15&(u>>5))+18;
    case  2: case  6:
    case 10: case 14:
      pbits->pb+=6+5;  return (31&(u>>6))+34;
    case  4: case 12:
      pbits->pb+=7+6;  return (63&(u>>7))+66;
    case  8:
      pbits->pb+=8+7;  return (127&(u>>8))+130;
    case  0: ;
  }
  pbits->pb+=9;
  if(u&256) return dblb_rdn(pbits,8)+258;
  return -1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x10, 0x4(%rax)
jl 0x1e93
movq -0x10(%rbp), %rax
movl (%rax), %ecx
shrl $0x10, %ecx
movl %ecx, (%rax)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
subl $0x10, %ecx
movl %ecx, 0x4(%rax)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
cmpq 0x10(%rcx), %rax
jae 0x1e91
movq -0x10(%rbp), %rcx
movq 0x8(%rcx), %rax
movq %rax, %rdx
addq $0x2, %rdx
movq %rdx, 0x8(%rcx)
movzwl (%rax), %ecx
shll $0x10, %ecx
movq -0x10(%rbp), %rax
orl (%rax), %ecx
movl %ecx, (%rax)
jmp 0x1e93
movq -0x10(%rbp), %rcx
movl (%rcx), %eax
movb 0x4(%rcx), %cl
shrl %cl, %eax
movl %eax, -0x14(%rbp)
movl -0x14(%rbp), %eax
andl $0xf, %eax
movl %eax, %ecx
movq %rcx, -0x20(%rbp)
subl $0xf, %eax
ja 0x1f48
movq -0x20(%rbp), %rax
leaq 0x615f(%rip), %rcx      # 0x8020
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x4(%rax)
movl $0x3, -0x4(%rbp)
jmp 0x202c
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x3, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
shrl $0x2, %eax
andl $0x1, %eax
addl $0x4, %eax
movl %eax, -0x4(%rbp)
jmp 0x202c
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x5, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
shrl $0x3, %eax
andl $0x3, %eax
addl $0x6, %eax
movl %eax, -0x4(%rbp)
jmp 0x202c
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x7, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
shrl $0x4, %eax
andl $0x7, %eax
addl $0xa, %eax
movl %eax, -0x4(%rbp)
jmp 0x202c
jmp 0x1f48
movl -0x14(%rbp), %eax
shrl $0x4, %eax
andl $0xf, %eax
movl %eax, %ecx
movq %rcx, -0x28(%rbp)
subl $0xf, %eax
ja 0x1ff3
movq -0x28(%rbp), %rax
leaq 0x60f5(%rip), %rcx      # 0x8060
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x9, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
shrl $0x5, %eax
andl $0xf, %eax
addl $0x12, %eax
movl %eax, -0x4(%rbp)
jmp 0x202c
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0xb, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
shrl $0x6, %eax
andl $0x1f, %eax
addl $0x22, %eax
movl %eax, -0x4(%rbp)
jmp 0x202c
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0xd, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
shrl $0x7, %eax
andl $0x3f, %eax
addl $0x42, %eax
movl %eax, -0x4(%rbp)
jmp 0x202c
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0xf, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
shrl $0x8, %eax
andl $0x7f, %eax
addl $0x82, %eax
movl %eax, -0x4(%rbp)
jmp 0x202c
jmp 0x1ff3
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
addl $0x9, %ecx
movl %ecx, 0x4(%rax)
movl -0x14(%rbp), %eax
andl $0x100, %eax            # imm = 0x100
cmpl $0x0, %eax
je 0x2025
movq -0x10(%rbp), %rdi
movl $0x8, %esi
callq 0x15e0
addl $0x102, %eax            # imm = 0x102
movl %eax, -0x4(%rbp)
jmp 0x202c
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)