// File: /workspace/github_cpp_makefile_star2_O1/DoubleString[P]RtConverter/src/Rtklib/rcvraw.cpp
// Function: bamboo::decode_frame(unsigned char const*, bamboo::eph_t*, bamboo::alm_t*, double*, double*, int*)
extern int decode_frame(const unsigned char *buff, eph_t *eph, alm_t *alm,
                        double *ion, double *utc, int *leaps)
{
    int id=getbitu(buff,43,3); /* subframe id */
    
    trace(3,"decodefrm: id=%d\n",id);
    
    switch (id) {
        case 1: return decode_subfrm1(buff,eph);
        case 2: return decode_subfrm2(buff,eph);
        case 3: return decode_subfrm3(buff,eph);
        case 4: return decode_subfrm4(buff,alm,ion,utc,leaps);
        case 5: return decode_subfrm5(buff,alm,ion,utc,leaps);
    }
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %r9, -0x40(%rbp)
movq %r8, -0x30(%rbp)
movq %rcx, -0x38(%rbp)
movq %rdx, %r12
movq %rsi, %r15
movq %rdi, %rbx
movl $0x2b, %esi
movl $0x3, %edx
callq 0x4e341
movl %eax, %r13d
leaq 0x37308(%rip), %rsi     # 0x6d1a3
xorl %r14d, %r14d
movl $0x3, %edi
movl %eax, %edx
xorl %eax, %eax
callq 0x4ded0
decl %r13d
cmpl $0x4, %r13d
ja 0x3687c
leaq 0x36ef0(%rip), %rax     # 0x6cdb0
movslq (%rax,%r13,4), %rcx
addq %rax, %rcx
jmpq *%rcx
leaq 0x3733e(%rip), %rsi     # 0x6d20e
movl $0x4, %edi
xorl %eax, %eax
callq 0x4ded0
leaq 0x3733c(%rip), %rsi     # 0x6d21f
movl $0x5, %edi
xorl %eax, %eax
callq 0x4ded0
movl $0x5, %edi
movq %rbx, %rsi
movl $0x1e, %edx
callq 0x53eee
movq %rbx, %rdi
movl $0x18, %esi
movl $0x11, %edx
callq 0x4e341
movl %eax, %eax
cvtsi2sd %rax, %xmm0
mulsd 0x34b16(%rip), %xmm0    # 0x6aa38
movsd %xmm0, -0x30(%rbp)
movq %rbx, %rdi
movl $0x30, %esi
movl $0xa, %edx
callq 0x4e341
movl %eax, -0x40(%rbp)
movq %rbx, %rdi
movl $0x3a, %esi
movl $0x2, %edx
callq 0x4e341
movl %eax, 0x18(%r15)
movq %rbx, %rdi
movl $0x3c, %esi
movl $0x4, %edx
callq 0x4e341
movl %eax, 0xc(%r15)
movq %rbx, %rdi
movl $0x40, %esi
movl $0x6, %edx
callq 0x4e341
movl %eax, 0x10(%r15)
movq %rbx, %rdi
movl $0x46, %esi
movl $0x2, %edx
callq 0x4e341
movl %eax, %r13d
movq %rbx, %rdi
movl $0x48, %esi
movl $0x1, %edx
callq 0x4e341
movl %eax, 0x1c(%r15)
movq %rbx, %rdi
movl $0xa0, %esi
movl $0x8, %edx
callq 0x4e390
movl %eax, %r14d
movq %rbx, %rdi
movl $0xa8, %esi
movl $0x8, %edx
callq 0x4e341
movl %eax, %r12d
movq %rbx, %rdi
movl $0xb0, %esi
movl $0x10, %edx
callq 0x4e341
movl %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
mulsd 0x36d81(%rip), %xmm0    # 0x6cd78
movsd %xmm0, -0x38(%rbp)
movq %rbx, %rdi
movl $0xc0, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36d63(%rip), %xmm0    # 0x6cd80
movsd %xmm0, 0xe8(%r15)
movq %rbx, %rdi
movl $0xc8, %esi
movl $0x10, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36c89(%rip), %xmm0    # 0x6ccd0
movsd %xmm0, 0xe0(%r15)
movq %rbx, %rdi
movl $0xd8, %esi
movl $0x16, %edx
callq 0x4e390
cvtsi2sd %eax, %xmm1
movsd 0x36c4a(%rip), %xmm0    # 0x6ccb8
mulsd %xmm0, %xmm1
movsd %xmm1, 0xd8(%r15)
xorpd %xmm1, %xmm1
cmpl $-0x80, %r14d
je 0x36091
xorps %xmm1, %xmm1
cvtsi2sd %r14d, %xmm1
mulsd %xmm0, %xmm1
movsd %xmm1, 0xf0(%r15)
shll $0x8, %r13d
addl %r13d, %r12d
movl %r12d, 0x8(%r15)
movl -0x40(%rbp), %edi
callq 0x5081e
movl %eax, 0x14(%r15)
movl %eax, %edi
movsd -0x30(%rbp), %xmm0
callq 0x4fbc6
movq %rax, 0x40(%r15)
movsd %xmm0, 0x48(%r15)
movl 0x14(%r15), %edi
movsd -0x38(%rbp), %xmm0
callq 0x4fbc6
movq %rax, 0x30(%r15)
movsd %xmm0, 0x38(%r15)
movl $0x1, %r14d
jmp 0x3687c
movq %rbx, %rdi
movl $0x30, %esi
movl $0x2, %edx
callq 0x4e341
movl %eax, %r15d
leaq 0x371c7(%rip), %rsi     # 0x6d2cd
movl $0x4, %edi
movl %eax, %edx
xorl %eax, %eax
callq 0x4ded0
leaq 0x371cd(%rip), %rsi     # 0x6d2e8
movl $0x5, %edi
xorl %eax, %eax
callq 0x4ded0
movl $0x5, %edi
movq %rbx, %rsi
movl $0x1e, %edx
callq 0x53eee
cmpl $0x3, %r15d
je 0x36683
cmpl $0x1, %r15d
jne 0x36696
movq %rbx, %rdi
movl $0x32, %esi
movl $0x6, %edx
callq 0x4e341
leal -0x1(%rax), %ecx
cmpl $0x17, %ecx
ja 0x366bf
movq %rbx, %rdi
movl $0x32, %esi
movl $0x6, %edx
callq 0x4e341
leal -0x1(%rax), %ecx
cmpl $0x1f, %ecx
ja 0x36696
movq %rbx, %rdi
movl %eax, %esi
movq %r12, %rdx
callq 0x374e6
jmp 0x36696
leaq 0x370ba(%rip), %rsi     # 0x6d25c
movl $0x4, %edi
xorl %eax, %eax
callq 0x4ded0
leaq 0x370b8(%rip), %rsi     # 0x6d26d
movl $0x5, %edi
xorl %eax, %eax
callq 0x4ded0
movl $0x5, %edi
movq %rbx, %rsi
movl $0x1e, %edx
callq 0x53eee
movq %rbx, %rdi
movl $0x30, %esi
movl $0x10, %edx
callq 0x4e390
cvtsi2sd %eax, %xmm0
mulsd 0x36ae7(%rip), %xmm0    # 0x6ccd8
movsd %xmm0, 0xb8(%r15)
movq %rbx, %rdi
movl $0x40, %esi
movl $0x20, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36a9d(%rip), %xmm0    # 0x6ccb8
mulsd 0x35b85(%rip), %xmm0    # 0x6bda8
movsd %xmm0, 0x68(%r15)
movq %rbx, %rdi
movl $0x60, %esi
movl $0x10, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36a8e(%rip), %xmm0    # 0x6ccd8
movsd %xmm0, 0xc0(%r15)
movq %rbx, %rdi
movl $0x70, %esi
movl $0x20, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36a44(%rip), %xmm0    # 0x6ccb8
mulsd 0x35b2c(%rip), %xmm0    # 0x6bda8
movsd %xmm0, 0x60(%r15)
movq %rbx, %rdi
movl $0x90, %esi
movl $0x10, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36a3d(%rip), %xmm0    # 0x6cce0
movsd %xmm0, 0x98(%r15)
movq %rbx, %rdi
movl $0xa0, %esi
movl $0x20, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x369eb(%rip), %xmm0    # 0x6ccb8
mulsd 0x35ad3(%rip), %xmm0    # 0x6bda8
movsd %xmm0, 0x70(%r15)
movq %rbx, %rdi
movl $0xc0, %esi
movl $0x18, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x369d4(%rip), %xmm0    # 0x6ccd0
mulsd 0x35aa4(%rip), %xmm0    # 0x6bda8
movsd %xmm0, 0x88(%r15)
movq %rbx, %rdi
movl $0xd8, %esi
movl $0x8, %edx
callq 0x4e341
movl %eax, %r12d
movq %rbx, %rdi
movl $0xe0, %esi
movl $0xe, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x3698d(%rip), %xmm0    # 0x6ccd0
mulsd 0x35a5d(%rip), %xmm0    # 0x6bda8
movsd %xmm0, 0x90(%r15)
cmpl 0x4(%r15), %r12d
jne 0x36650
movzbl 0x8(%r15), %eax
cmpl %eax, %r12d
movl $0x0, %r14d
jne 0x3687c
movq 0x40(%r15), %rdi
movsd 0x48(%r15), %xmm0
leaq 0x14(%r15), %rbx
movq %rbx, %rsi
callq 0x4fc2d
movsd %xmm0, -0x30(%rbp)
movq 0x30(%r15), %rdi
movsd 0x38(%r15), %xmm0
xorl %esi, %esi
callq 0x4fc2d
movsd -0x30(%rbp), %xmm2
movsd %xmm0, -0x38(%rbp)
movsd 0xc8(%r15), %xmm0
movsd 0x35a17(%rip), %xmm1    # 0x6bdd0
addsd %xmm2, %xmm1
ucomisd %xmm0, %xmm1
jbe 0x36809
movsd 0x35a11(%rip), %xmm1    # 0x6bde0
movl $0x1, %eax
jmp 0x36828
movq %rbx, %rdi
movl $0x30, %esi
movl $0x2, %edx
callq 0x4e341
movl %eax, %r15d
leaq 0x36e8e(%rip), %rsi     # 0x6d283
movl $0x4, %edi
movl %eax, %edx
xorl %eax, %eax
callq 0x4ded0
leaq 0x36e94(%rip), %rsi     # 0x6d29e
movl $0x5, %edi
xorl %eax, %eax
callq 0x4ded0
movl $0x5, %edi
movq %rbx, %rsi
movl $0x1e, %edx
callq 0x53eee
cmpl $0x3, %r15d
je 0x366a1
cmpl $0x1, %r15d
jne 0x366b4
movq %rbx, %rdi
movl $0x32, %esi
movl $0x6, %edx
callq 0x4e341
leal -0x19(%rax), %ecx
cmpl $0x7, %ecx
ja 0x3677c
movq %rbx, %rdi
movl $0x32, %esi
movl $0x6, %edx
callq 0x4e341
leal -0x1(%rax), %ecx
cmpl $0x1f, %ecx
ja 0x366b4
movq %rbx, %rdi
movl %eax, %esi
movq %r12, %rdx
callq 0x374e6
jmp 0x366b4
leaq 0x36da4(%rip), %rsi     # 0x6d235
movl $0x4, %edi
xorl %eax, %eax
callq 0x4ded0
leaq 0x36da2(%rip), %rsi     # 0x6d246
movl $0x5, %edi
xorl %eax, %eax
callq 0x4ded0
movl $0x5, %edi
movq %rbx, %rsi
movl $0x1e, %edx
callq 0x53eee
movq %rbx, %rdi
movl $0x30, %esi
movl $0x8, %edx
callq 0x4e341
movl %eax, 0x4(%r15)
movq %rbx, %rdi
movl $0x38, %esi
movl $0x10, %edx
callq 0x4e390
cvtsi2sd %eax, %xmm0
mulsd 0x367ea(%rip), %xmm0    # 0x6cce0
movsd %xmm0, 0xa0(%r15)
movq %rbx, %rdi
movl $0x48, %esi
movl $0x10, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x367b0(%rip), %xmm0    # 0x6ccd0
mulsd 0x35880(%rip), %xmm0    # 0x6bda8
movsd %xmm0, 0x80(%r15)
movq %rbx, %rdi
movl $0x58, %esi
movl $0x20, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36766(%rip), %xmm0    # 0x6ccb8
mulsd 0x3584e(%rip), %xmm0    # 0x6bda8
movsd %xmm0, 0x78(%r15)
movq %rbx, %rdi
movl $0x78, %esi
movl $0x10, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36757(%rip), %xmm0    # 0x6ccd8
movsd %xmm0, 0xa8(%r15)
movq %rbx, %rdi
movl $0x88, %esi
movl $0x20, %edx
callq 0x4e341
movl %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
mulsd 0x36712(%rip), %xmm0    # 0x6ccc0
movsd %xmm0, 0x58(%r15)
movq %rbx, %rdi
movl $0xa8, %esi
movl $0x10, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36703(%rip), %xmm0    # 0x6ccd8
movsd %xmm0, 0xb0(%r15)
movq %rbx, %rdi
movl $0xb8, %esi
movl $0x20, %edx
callq 0x4e341
movl %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
mulsd 0x366c6(%rip), %xmm0    # 0x6ccc8
movsd %xmm0, -0x30(%rbp)
movq %rbx, %rdi
movl $0xd8, %esi
movl $0x10, %edx
callq 0x4e341
movl %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
mulsd 0x3674d(%rip), %xmm0    # 0x6cd78
movsd %xmm0, 0xc8(%r15)
movq %rbx, %rdi
movl $0xe8, %esi
movl $0x1, %edx
callq 0x4e341
testl %eax, %eax
je 0x36658
xorpd %xmm0, %xmm0
jmp 0x36660
xorl %r14d, %r14d
jmp 0x3687c
movsd 0x34248(%rip), %xmm0    # 0x6a8a8
movsd %xmm0, 0xd0(%r15)
movsd -0x30(%rbp), %xmm0
mulsd %xmm0, %xmm0
movsd %xmm0, 0x50(%r15)
movl $0x2, %r14d
jmp 0x3687c
movq %rbx, %rdi
movq %r12, %rsi
movq -0x38(%rbp), %rdx
movq -0x30(%rbp), %rcx
callq 0x371b0
movl $0x5, %r14d
jmp 0x3687c
movq %rbx, %rdi
movq %r12, %rsi
movq -0x38(%rbp), %rdx
movq -0x30(%rbp), %rcx
callq 0x371b0
movl $0x4, %r14d
jmp 0x3687c
cmpl $0x33, %eax
setne %al
testq %r12, %r12
sete %cl
orb %al, %cl
jne 0x36696
movq %rbx, %rdi
movl $0x38, %esi
movl $0x8, %edx
callq 0x4e341
movq %rax, -0x30(%rbp)
movq %rbx, %rdi
movl $0x40, %esi
movl $0x8, %edx
callq 0x4e341
movl %eax, %edi
callq 0x5081e
movl %eax, %r15d
movl $0x48, %r13d
movl $0x4, %r14d
movq %rbx, %rdi
movl %r13d, %esi
movl $0x6, %edx
callq 0x4e341
movl %eax, (%r12,%r14)
addl $0x6, %r13d
addq $0x70, %r14
cmpq $0xa84, %r14            # imm = 0xA84
jne 0x3670d
movq -0x30(%rbp), %rax
shll $0xc, %eax
cvtsi2sd %rax, %xmm0
movsd %xmm0, -0x30(%rbp)
xorl %ebx, %ebx
movsd -0x30(%rbp), %xmm0
movsd %xmm0, 0x58(%r12,%rbx)
movl %r15d, 0xc(%r12,%rbx)
movl %r15d, %edi
callq 0x4fbc6
movq %rax, 0x10(%r12,%rbx)
movsd %xmm0, 0x18(%r12,%rbx)
addq $0x70, %rbx
cmpq $0xe00, %rbx            # imm = 0xE00
jne 0x36745
jmp 0x36696
cmpl $0x38, %eax
je 0x3688e
cmpl $0x3f, %eax
movl $0x4, %r14d
jne 0x3687c
movl $0x38, %r14d
movl $0x2, %r15d
testq %r12, %r12
je 0x367b9
movq %rbx, %rdi
movl %r14d, %esi
movl $0x4, %edx
callq 0x4e341
movl %eax, (%r12,%r15,4)
addl $0x4, %r14d
addq $0x1c, %r15
cmpq $0x382, %r15            # imm = 0x382
jne 0x367a0
movl $0xba, %r15d
xorl %r13d, %r13d
movl $0x4, %r14d
testq %r12, %r12
je 0x367f6
movq %rbx, %rdi
movl %r15d, %esi
movl $0x6, %edx
callq 0x4e341
movl %eax, 0xa84(%r12,%r13)
addl $0x6, %r15d
addq $0x70, %r13
cmpq $0x380, %r13            # imm = 0x380
jne 0x367d9
jmp 0x3687c
movsd 0x355c7(%rip), %xmm1    # 0x6bdd8
addsd %xmm2, %xmm1
ucomisd %xmm1, %xmm0
jbe 0x3682e
movsd 0x355c5(%rip), %xmm1    # 0x6bde8
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
addl %eax, (%rbx)
addsd %xmm1, %xmm2
movsd %xmm2, -0x30(%rbp)
movl 0x14(%r15), %edi
callq 0x4fbc6
movq %rax, 0x20(%r15)
movsd %xmm0, 0x28(%r15)
movl 0x14(%r15), %edi
movsd -0x38(%rbp), %xmm0
callq 0x4fbc6
movq %rax, 0x30(%r15)
movsd %xmm0, 0x38(%r15)
movl 0x14(%r15), %edi
movsd -0x30(%rbp), %xmm0
callq 0x4fbc6
movq %rax, 0x40(%r15)
movsd %xmm0, 0x48(%r15)
movl $0x3, %r14d
movl %r14d, %eax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq -0x38(%rbp), %r14
testq %r14, %r14
je 0x369cf
movq %rbx, %rdi
movl $0x38, %esi
movl $0x8, %edx
callq 0x4e390
cvtsi2sd %eax, %xmm0
mulsd 0x36477(%rip), %xmm0    # 0x6cd30
movsd %xmm0, (%r14)
movq %rbx, %rdi
movl $0x40, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36469(%rip), %xmm0    # 0x6cd48
movsd %xmm0, 0x8(%r14)
movq %rbx, %rdi
movl $0x48, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x3644a(%rip), %xmm0    # 0x6cd50
movsd %xmm0, 0x10(%r14)
movq %rbx, %rdi
movl $0x50, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36423(%rip), %xmm0    # 0x6cd50
movsd %xmm0, 0x18(%r14)
movq %rbx, %rdi
movl $0x58, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36404(%rip), %xmm0    # 0x6cd58
movsd %xmm0, 0x20(%r14)
movq %rbx, %rdi
movl $0x60, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x363e5(%rip), %xmm0    # 0x6cd60
movsd %xmm0, 0x28(%r14)
movq %rbx, %rdi
movl $0x68, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x363c6(%rip), %xmm0    # 0x6cd68
movsd %xmm0, 0x30(%r14)
movq %rbx, %rdi
movl $0x70, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x3639f(%rip), %xmm0    # 0x6cd68
movsd %xmm0, 0x38(%r14)
movq -0x30(%rbp), %r15
testq %r15, %r15
je 0x36a72
movq %rbx, %rdi
movl $0x78, %esi
movl $0x18, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x3631b(%rip), %xmm0    # 0x6cd18
movsd %xmm0, 0x8(%r15)
movq %rbx, %rdi
movl $0x90, %esi
movl $0x20, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x3630c(%rip), %xmm0    # 0x6cd30
movsd %xmm0, (%r15)
movq %rbx, %rdi
movl $0xb0, %esi
movl $0x8, %edx
callq 0x4e390
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x36326(%rip), %xmm0    # 0x6cd70
movsd %xmm0, 0x10(%r15)
movq %rbx, %rdi
movl $0xb8, %esi
movl $0x8, %edx
callq 0x4e341
movl %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
movsd %xmm0, 0x18(%r15)
movq -0x40(%rbp), %r15
testq %r15, %r15
je 0x366b4
movq %rbx, %rdi
movl $0xc0, %esi
movl $0x8, %edx
callq 0x4e390
movl %eax, (%r15)
jmp 0x366b4