// File: /workspace/github_cpp_makefile_star2_O3/DoubleString[P]RtConverter/src/Rtklib/rtcm3e.cpp
// Function: bamboo::encode_msm_head(int, bamboo::rtcm_t*, int, int, int*, int*, double*, double*, unsigned char*, double*, double*, double*, double*, unsigned char*, float*)
static int encode_msm_head(int type, rtcm_t *rtcm, int sys, int sync, int *nsat,
                           int *ncell, double *rrng, double *rrate,
                           unsigned char *info, double *psrng, double *phrng,
                           double *rate, double *lock, unsigned char *half,
                           float *cnr)
{
    double tow;
    unsigned char sat_ind[64]={0},sig_ind[32]={0},cell_ind[32*64]={0};
    unsigned int dow,epoch;
    int i=24,j,nsig=0;
    
    switch (sys) {
        case SYS_GPS: type+=1070; break;
        case SYS_GLO: type+=1080; break;
        case SYS_GAL: type+=1090; break;
        case SYS_QZS: type+=1110; break;
        case SYS_SBS: type+=1100; break;
        case SYS_CMP: type+=1120; break;
        default: return 0;
    }
    /* generate msm satellite, signal and cell index */
    gen_msm_index(rtcm,sys,nsat,&nsig,ncell,sat_ind,sig_ind,cell_ind);
    
    if (sys==SYS_GLO) {
        /* glonass time (dow + tod-ms) */
        tow=time2gpst(timeadd(gpst2utc(rtcm->time),10800.0),NULL);
        dow=(unsigned int)(tow/86400.0);
        epoch=(dow<<27)+ROUND_U(fmod(tow,86400.0)*1E3);
    }
    else if (sys==SYS_CMP) {
        /* beidou time (tow-ms) */
        epoch=ROUND_U(time2gpst(gpst2bdt(rtcm->time),NULL)*1E3);
    }
    else {
        /* gps, qzs and galileo time (tow-ms) */
        epoch=ROUND_U(time2gpst(rtcm->time,NULL)*1E3);
    }
    /* encode msm header (ref [15] table 3.5-78) */
    setbitu(rtcm->buff,i,12,type       ); i+=12; /* message number */
    setbitu(rtcm->buff,i,12,rtcm->staid); i+=12; /* reference station id */
    setbitu(rtcm->buff,i,30,epoch      ); i+=30; /* epoch time */
    setbitu(rtcm->buff,i, 1,sync       ); i+= 1; /* multiple message bit */
    setbitu(rtcm->buff,i, 3,rtcm->seqno); i+= 3; /* issue of data station */
    setbitu(rtcm->buff,i, 7,0          ); i+= 7; /* reserved */
    setbitu(rtcm->buff,i, 2,0          ); i+= 2; /* clock streering indicator */
    setbitu(rtcm->buff,i, 2,0          ); i+= 2; /* external clock indicator */
    setbitu(rtcm->buff,i, 1,0          ); i+= 1; /* smoothing indicator */
    setbitu(rtcm->buff,i, 3,0          ); i+= 3; /* smoothing interval */
    
    /* satellite mask */
    for (j=0;j<64;j++) {
        setbitu(rtcm->buff,i,1,sat_ind[j]?1:0); i+=1;
    }
    /* signal mask */
    for (j=0;j<32;j++) {
        setbitu(rtcm->buff,i,1,sig_ind[j]?1:0); i+=1;
    }
    /* cell mask */
    for (j=0;j<*nsat*nsig&&j<64;j++) {
        setbitu(rtcm->buff,i,1,cell_ind[j]?1:0); i+=1;
    }
    /* generate msm satellite data fields */
    gen_msm_sat(rtcm,sys,*nsat,sat_ind,rrng,rrate,info);
    
    /* generate msm signal data fields */
    gen_msm_sig(rtcm,sys,*nsat,nsig,*ncell,sat_ind,sig_ind,cell_ind,rrng,rrate,
                psrng,phrng,rate,lock,half,cnr);
    
    return i;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x908, %rsp            # imm = 0x908
movq %r9, %r15
movq %r8, %r12
movl %ecx, -0x70(%rbp)
movl %edx, %ebx
movq %rsi, %r14
movl %edi, -0x40(%rbp)
xorpd %xmm0, %xmm0
movapd %xmm0, -0x100(%rbp)
movapd %xmm0, -0x110(%rbp)
movapd %xmm0, -0x120(%rbp)
movapd %xmm0, -0x130(%rbp)
movapd %xmm0, -0xd0(%rbp)
movapd %xmm0, -0xe0(%rbp)
leaq -0x930(%rbp), %rdi
xorl %r13d, %r13d
movl $0x800, %edx            # imm = 0x800
xorl %esi, %esi
callq 0x8390
leal -0x1(%rbx), %eax
cmpl $0x7, %eax
movq %rbx, -0x48(%rbp)
ja 0x4b9e2
leaq 0x2455c(%rip), %rcx     # 0x6ff2c
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl $0x42e, -0x30(%rbp)     # imm = 0x42E
jmp 0x4ba1b
cmpl $0x10, %ebx
je 0x4ba14
cmpl $0x20, %ebx
jne 0x4c448
movl $0x460, -0x30(%rbp)     # imm = 0x460
jmp 0x4ba1b
movl $0x442, -0x30(%rbp)     # imm = 0x442
jmp 0x4ba1b
movl $0x44c, -0x30(%rbp)     # imm = 0x44C
jmp 0x4ba1b
movl $0x438, -0x30(%rbp)     # imm = 0x438
jmp 0x4ba1b
movl $0x456, -0x30(%rbp)     # imm = 0x456
xorl %eax, %eax
movq %r15, -0x80(%rbp)
movl %eax, (%r15)
movq %r12, -0x68(%rbp)
movl %eax, (%r12)
cmpl %eax, 0x30(%r14)
movq %r14, -0x50(%rbp)
jle 0x4bac4
movl $0x18, %ebx
xorl %ecx, %ecx
leaq -0x34(%rbp), %r15
movb $0x1, %r13b
movq 0x38(%r14), %rax
movq %rcx, -0x60(%rbp)
leaq (%rcx,%rcx,2), %rcx
shlq $0x5, %rcx
movzbl 0x10(%rax,%rcx), %esi
movq -0x48(%rbp), %rdi
callq 0x4c5e2
testl %eax, %eax
je 0x4baac
movslq %eax, %r12
movq $-0x3, %r14
movq -0x50(%rbp), %rax
movq 0x38(%rax), %rax
addq %rbx, %rax
movzbl 0x3(%r14,%rax), %esi
movq -0x48(%rbp), %rdi
movq %r15, %rdx
callq 0x4c61a
testl %eax, %eax
je 0x4baa7
cltq
movb %r13b, -0xe1(%rbp,%rax)
movb %r13b, -0x131(%rbp,%r12)
incq %r14
jne 0x4ba74
movq -0x60(%rbp), %rcx
incq %rcx
movq -0x50(%rbp), %r14
movslq 0x30(%r14), %rax
addq $0x60, %rbx
cmpq %rax, %rcx
jl 0x4ba48
movl -0x40(%rbp), %eax
addl %eax, -0x30(%rbp)
xorl %eax, %eax
movq -0x68(%rbp), %rdx
cmpb $0x0, -0x130(%rbp,%rax)
je 0x4bae7
movl (%rdx), %ecx
incl %ecx
movl %ecx, (%rdx)
movb %cl, -0x130(%rbp,%rax)
incq %rax
cmpq $0x40, %rax
jne 0x4bad0
movq $0x0, -0x40(%rbp)
xorl %eax, %eax
cmpb $0x0, -0xe0(%rbp,%rax)
je 0x4bb15
movq -0x40(%rbp), %rcx
incl %ecx
movq %rcx, -0x40(%rbp)
movb %cl, -0xe0(%rbp,%rax)
incq %rax
cmpq $0x20, %rax
jne 0x4bafa
cmpl $0x0, 0x30(%r14)
movslq -0x40(%rbp), %rax
movq %rax, -0x60(%rbp)
jle 0x4bbd0
movl $0x18, %ebx
xorl %r13d, %r13d
leaq -0x34(%rbp), %r15
movq 0x38(%r14), %rax
leaq (,%r13,2), %rcx
addq %r13, %rcx
shlq $0x5, %rcx
movzbl 0x10(%rax,%rcx), %esi
movq -0x48(%rbp), %rdi
callq 0x4c5e2
testl %eax, %eax
je 0x4bbb8
movslq %eax, %r12
movq $-0x3, %r14
movq -0x50(%rbp), %rax
movq 0x38(%rax), %rax
addq %rbx, %rax
movzbl 0x3(%r14,%rax), %esi
movq -0x48(%rbp), %rdi
movq %r15, %rdx
callq 0x4c61a
testl %eax, %eax
je 0x4bbb3
cltq
movzbl -0xe1(%rbp,%rax), %eax
movzbl -0x131(%rbp,%r12), %ecx
decq %rcx
imulq -0x60(%rbp), %rcx
addq %rax, %rcx
movb $0x1, -0x931(%rbp,%rcx)
incq %r14
jne 0x4bb6c
incq %r13
movq -0x50(%rbp), %r14
movslq 0x30(%r14), %rax
addq $0x60, %rbx
cmpq %rax, %r13
jl 0x4bb3d
movq -0x68(%rbp), %r12
movl (%r12), %eax
movl %eax, %ecx
imull -0x40(%rbp), %ecx
testl %ecx, %ecx
movq -0x48(%rbp), %rsi
movq -0x80(%rbp), %rdi
jle 0x4bc1d
xorl %ecx, %ecx
cmpb $0x0, -0x930(%rbp,%rcx)
je 0x4bc0c
movl (%rdi), %edx
cmpl $0x3f, %edx
jg 0x4bc0c
incl %edx
movl %edx, (%rdi)
movb %dl, -0x930(%rbp,%rcx)
movl (%r12), %eax
incq %rcx
movl %eax, %edx
imull -0x40(%rbp), %edx
movslq %edx, %rdx
cmpq %rdx, %rcx
jl 0x4bbec
movq 0x10(%r14), %rdi
movsd 0x18(%r14), %xmm0
cmpl $0x20, %esi
je 0x4bc8c
cmpl $0x4, %esi
jne 0x4bc94
callq 0x4f9b0
movsd 0x1ee72(%rip), %xmm1    # 0x6aab0
movq %rax, %rdi
callq 0x4f4e7
movq %rax, %rdi
xorl %esi, %esi
callq 0x4f2b1
movsd 0x1ec78(%rip), %xmm1    # 0x6a8d0
movapd %xmm0, %xmm2
divsd %xmm1, %xmm2
cvttsd2si %xmm2, %rbx
shll $0x1b, %ebx
callq 0x8850
mulsd 0x1f803(%rip), %xmm0    # 0x6b478
addsd 0x1fffb(%rip), %xmm0    # 0x6bc78
callq 0x8ac0
cvttsd2si %xmm0, %r15
addl %ebx, %r15d
jmp 0x4bcb5
callq 0x4fb17
movq %rax, %rdi
xorl %esi, %esi
callq 0x4f2b1
mulsd 0x1f7d5(%rip), %xmm0    # 0x6b478
addsd 0x1ffcd(%rip), %xmm0    # 0x6bc78
callq 0x8ac0
cvttsd2si %xmm0, %r15
leaq 0x9f0c4(%r14), %r13
movq %r13, %rdi
movl $0x18, %esi
movl $0xc, %edx
movl -0x30(%rbp), %ecx
callq 0x4da98
movl (%r14), %ecx
movq %r13, %rdi
movl $0x24, %esi
movl $0xc, %edx
callq 0x4da98
movq %r13, %rdi
movl $0x30, %esi
movl $0x1e, %edx
movl %r15d, %ecx
callq 0x4da98
movq %r13, %rdi
movl $0x4e, %esi
movl $0x1, %edx
movl -0x70(%rbp), %ecx
callq 0x4da98
movl 0x8(%r14), %ecx
movq %r13, %rdi
movl $0x4f, %esi
movl $0x3, %edx
callq 0x4da98
xorl %ebx, %ebx
movq %r13, %rdi
movl $0x52, %esi
movl $0x7, %edx
xorl %ecx, %ecx
callq 0x4da98
movq %r13, %rdi
movl $0x59, %esi
movl $0x2, %edx
xorl %ecx, %ecx
callq 0x4da98
movq %r13, %rdi
movl $0x5b, %esi
movl $0x2, %edx
xorl %ecx, %ecx
callq 0x4da98
movq %r13, %rdi
movl $0x5d, %esi
movl $0x1, %edx
xorl %ecx, %ecx
callq 0x4da98
movq %r13, %rdi
movl $0x5e, %esi
movl $0x3, %edx
xorl %ecx, %ecx
callq 0x4da98
leal 0x61(%rbx), %esi
xorl %ecx, %ecx
cmpb $0x0, -0x130(%rbp,%rbx)
setne %cl
movq %r13, %rdi
movl $0x1, %edx
callq 0x4da98
incq %rbx
cmpq $0x40, %rbx
jne 0x4bd8c
xorl %ebx, %ebx
movq -0x48(%rbp), %r15
leal 0xa1(%rbx), %esi
xorl %ecx, %ecx
cmpb $0x0, -0xe0(%rbp,%rbx)
setne %cl
movq %r13, %rdi
movl $0x1, %edx
callq 0x4da98
incq %rbx
cmpq $0x20, %rbx
jne 0x4bdb8
movl (%r12), %eax
imull -0x40(%rbp), %eax
testl %eax, %eax
jle 0x4be33
xorl %eax, %eax
movq %rax, %rbx
leal 0xc1(%rax), %esi
xorl %ecx, %ecx
cmpb $0x0, -0x930(%rbp,%rax)
setne %cl
movq %r13, %rdi
movl $0x1, %edx
callq 0x4da98
leaq 0x1(%rbx), %rax
cmpq $0x3e, %rbx
ja 0x4be2a
movslq (%r12), %rcx
imulq -0x60(%rbp), %rcx
cmpq %rcx, %rax
jl 0x4bdef
leal 0xc1(%rax), %r10d
jmp 0x4be39
movl $0xc1, %r10d
xorl %eax, %eax
xorl %ecx, %ecx
movq 0x38(%rbp), %rdx
movq 0x30(%rbp), %rsi
movq 0x28(%rbp), %rdi
movq 0x18(%rbp), %r8
movq 0x10(%rbp), %r9
movq %rax, (%r8,%rcx,8)
movq %rax, (%r9,%rcx,8)
incq %rcx
cmpq $0x40, %rcx
jne 0x4be51
movq $0x0, -0x78(%rbp)
cmpl $0x0, 0x30(%r14)
movl %r10d, -0x8c(%rbp)
jle 0x4c06b
leaq 0x40(%r14), %rax
movq %rax, -0x68(%rbp)
movq $0x0, -0x88(%rbp)
xorl %ecx, %ecx
movq 0x38(%r14), %r13
movq %rcx, -0xa0(%rbp)
leaq (%rcx,%rcx,2), %r14
shlq $0x5, %r14
movzbl 0x10(%r13,%r14), %esi
movl %r15d, %edi
callq 0x4c5e2
testl %eax, %eax
je 0x4c033
movl %eax, %ebx
addq %r13, %r14
movzbl 0x10(%r14), %edi
movq -0x50(%rbp), %rsi
callq 0x4b23d
movl %eax, %ecx
testl %eax, %eax
movl $0xf, %eax
cmovsl %eax, %ecx
cmpl $0x4, %r15d
movslq %ebx, %rbx
movl $0x0, %eax
cmovnel %eax, %ecx
movl %ecx, -0x70(%rbp)
addq -0x88(%rbp), %r13
movl $0x14, %r12d
movzbl 0x4(%r13,%r12), %esi
movl %r15d, %edi
leaq -0x34(%rbp), %rdx
callq 0x4c61a
testl %eax, %eax
je 0x4c022
movzbl -0x131(%rbp,%rbx), %r15d
movzbl 0x10(%r14), %edi
movl -0x34(%rbp), %esi
decl %esi
movq -0x68(%rbp), %rdx
callq 0x52684
movsd -0x68(%r13,%r12,8), %xmm1
movsd %xmm1, -0x60(%rbp)
movss (%r13,%r12,4), %xmm1
movss %xmm1, -0x30(%rbp)
cvtss2sd %xmm1, %xmm1
mulsd %xmm0, %xmm1
movsd 0x1fd22(%rip), %xmm0    # 0x6bc78
subsd %xmm1, %xmm0
callq 0x8ac0
movsd -0x60(%rbp), %xmm3
movapd %xmm0, %xmm2
movq 0x10(%rbp), %rax
movsd -0x8(%rax,%r15,8), %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x4bfdd
jp 0x4bfdd
ucomisd %xmm1, %xmm3
jne 0x4bf87
jnp 0x4bfdd
movsd 0x22e71(%rip), %xmm0    # 0x6ee00
divsd %xmm0, %xmm3
mulsd 0x2420d(%rip), %xmm3    # 0x701a8
addsd 0x1fcd5(%rip), %xmm3    # 0x6bc78
movapd %xmm3, %xmm0
movapd %xmm2, -0x60(%rbp)
callq 0x8ac0
movapd -0x60(%rbp), %xmm2
xorpd %xmm1, %xmm1
cvttpd2dq %xmm0, %xmm0
cvtdq2pd %xmm0, %xmm0
mulsd 0x22e36(%rip), %xmm0    # 0x6ee00
mulsd 0x22e9e(%rip), %xmm0    # 0x6ee70
movq 0x10(%rbp), %rax
movsd %xmm0, -0x8(%rax,%r15,8)
movq 0x18(%rbp), %rax
movsd -0x8(%rax,%r15,8), %xmm0
ucomisd %xmm1, %xmm0
jne 0x4c00f
jp 0x4c00f
movss -0x30(%rbp), %xmm0
ucomiss 0x2428c(%rip), %xmm0    # 0x70288
jne 0x4c000
jnp 0x4c00f
cvttpd2dq %xmm2, %xmm0
cvtdq2pd %xmm0, %xmm0
movsd %xmm0, -0x8(%rax,%r15,8)
cmpq $0x0, 0x20(%rbp)
je 0x4c022
movq 0x20(%rbp), %rax
movl -0x70(%rbp), %ecx
movb %cl, -0x1(%rax,%r15)
incq %r12
cmpq $0x17, %r12
movq -0x48(%rbp), %r15
jne 0x4bef8
movq -0xa0(%rbp), %rcx
incq %rcx
movq -0x50(%rbp), %r14
movslq 0x30(%r14), %rax
addq $0x60, -0x88(%rbp)
cmpq %rax, %rcx
jl 0x4be91
testl %eax, %eax
setg %al
movq %rax, -0x78(%rbp)
movq 0x38(%rbp), %rdx
movq 0x30(%rbp), %rsi
movq 0x28(%rbp), %rdi
movq -0x80(%rbp), %rax
movslq (%rax), %rax
testq %rax, %rax
jle 0x4c0a8
xorl %ecx, %ecx
testq %rdi, %rdi
je 0x4c086
movq $0x0, (%rdi,%rcx,8)
testq %rsi, %rsi
je 0x4c093
movq $0x0, (%rsi,%rcx,8)
testq %rdx, %rdx
je 0x4c0a0
movq $0x0, (%rdx,%rcx,8)
incq %rcx
cmpq %rcx, %rax
jne 0x4c079
cmpb $0x0, -0x78(%rbp)
je 0x4c441
leaq 0x40(%r14), %rax
movq %rax, -0x78(%rbp)
leaq 0x9bdc0(%r14), %rax
movq %rax, -0xb8(%rbp)
movl $0x12, %eax
movq %rax, -0xb0(%rbp)
movq $0x0, -0xa8(%rbp)
xorl %ecx, %ecx
movq 0x38(%r14), %rax
movq %rcx, -0xe8(%rbp)
leaq (%rcx,%rcx,2), %rcx
shlq $0x5, %rcx
movq %rax, %rbx
movq %rcx, -0x60(%rbp)
movzbl 0x10(%rax,%rcx), %esi
movl %r15d, %edi
callq 0x4c5e2
testl %eax, %eax
je 0x4c416
addq %rbx, -0x60(%rbp)
cltq
movq %rax, -0x68(%rbp)
movq -0xb0(%rbp), %rax
leaq (%rbx,%rax), %r12
addq -0xa8(%rbp), %rbx
movq %rbx, -0x80(%rbp)
xorl %r14d, %r14d
movzbl 0x6(%r12), %esi
movl %r15d, %edi
leaq -0x34(%rbp), %rdx
callq 0x4c61a
testl %eax, %eax
je 0x4c401
movq -0x68(%rbp), %rcx
movzbl -0x131(%rbp,%rcx), %r13d
leal -0x1(%r13), %ebx
cltq
movzbl -0xe1(%rbp,%rax), %eax
movl %ebx, %ecx
imull -0x40(%rbp), %ecx
movslq %ecx, %rcx
addq %rax, %rcx
movzbl -0x931(%rbp,%rcx), %r15d
cmpq $0x3f, %r15
ja 0x4c401
movq -0x60(%rbp), %rax
movzbl 0x10(%rax), %edi
movl -0x34(%rbp), %esi
decl %esi
movq -0x78(%rbp), %rdx
callq 0x52684
movapd %xmm0, %xmm3
movq -0x80(%rbp), %rdx
movsd 0x38(%rdx,%r14,2), %xmm0
xorpd %xmm4, %xmm4
ucomisd %xmm4, %xmm0
xorpd %xmm1, %xmm1
jne 0x4c1bc
jnp 0x4c1cb
movq 0x10(%rbp), %rax
subsd -0x8(%rax,%r13,8), %xmm0
movapd %xmm0, %xmm1
ucomisd %xmm3, %xmm4
jae 0x4c201
movsd 0x20(%rdx,%r14,2), %xmm0
ucomisd 0x1e728(%rip), %xmm0    # 0x6a908
movq -0xb8(%rbp), %r13
jne 0x4c1eb
jnp 0x4c208
movslq %ebx, %rax
mulsd %xmm3, %xmm0
movq 0x10(%rbp), %rcx
subsd (%rcx,%rax,8), %xmm0
movapd %xmm0, %xmm4
jmp 0x4c208
movq -0xb8(%rbp), %r13
xorpd %xmm2, %xmm2
xorpd %xmm0, %xmm0
movsd %xmm0, -0x30(%rbp)
ucomisd %xmm3, %xmm2
movsd %xmm1, -0x70(%rbp)
jae 0x4c252
movss 0x50(%rdx,%r14), %xmm0
ucomiss 0x2405a(%rip), %xmm0    # 0x70288
jne 0x4c232
jnp 0x4c252
xorps 0x24057(%rip), %xmm0    # 0x70290
cvtss2sd %xmm0, %xmm0
movslq %ebx, %rax
mulsd %xmm3, %xmm0
movq 0x18(%rbp), %rcx
subsd (%rcx,%rax,8), %xmm0
movsd %xmm0, -0x30(%rbp)
movq -0x60(%rbp), %rax
movzbl 0x10(%rax), %eax
testb $0x1, 0x3(%r12)
leaq (%rax,%rax,2), %rbx
jne 0x4c293
leaq (,%rbx,8), %rax
addq %r13, %rax
movapd %xmm4, %xmm1
subsd (%rax,%r14,2), %xmm1
movapd %xmm1, %xmm0
andpd 0x1d6a9(%rip), %xmm0    # 0x69930
movb $0x1, %al
ucomisd 0x23f1f(%rip), %xmm0    # 0x701b0
jbe 0x4c2e7
movapd %xmm4, %xmm0
divsd %xmm3, %xmm0
addsd 0x1f9d5(%rip), %xmm0    # 0x6bc78
movsd %xmm3, -0x88(%rbp)
movsd %xmm4, -0xa0(%rbp)
callq 0x8ac0
cvttpd2dq %xmm0, %xmm0
cvtdq2pd %xmm0, %xmm0
mulsd -0x88(%rbp), %xmm0
leaq (,%rbx,8), %rax
addq %r13, %rax
movsd %xmm0, (%rax,%r14,2)
movsd -0xa0(%rbp), %xmm1
subsd %xmm0, %xmm1
xorl %eax, %eax
movapd %xmm1, -0xa0(%rbp)
movq -0x60(%rbp), %rcx
movq (%rcx), %rdi
movsd 0x8(%rcx), %xmm0
movl %ebx, %ecx
shll $0x4, %ecx
addq %r13, %rcx
testb %al, %al
je 0x4c326
movq 0x15b8(%rcx,%r14,4), %rsi
testq %rsi, %rsi
je 0x4c326
shll $0x4, %ebx
addq %r13, %rbx
movsd 0x15c0(%rbx,%r14,4), %xmm1
jmp 0x4c345
movq %rdi, 0x15b8(%rcx,%r14,4)
shll $0x4, %ebx
addq %r13, %rbx
movsd %xmm0, 0x15c0(%rbx,%r14,4)
movapd %xmm0, %xmm1
movq %rdi, %rsi
callq 0x4f51b
movq 0x28(%rbp), %rax
testq %rax, %rax
movsd -0x70(%rbp), %xmm1
je 0x4c36b
ucomisd 0x1e5a8(%rip), %xmm1    # 0x6a908
jne 0x4c364
jnp 0x4c36b
movsd %xmm1, -0x8(%rax,%r15,8)
movq 0x30(%rbp), %rsi
testq %rsi, %rsi
movq 0x48(%rbp), %rcx
movq 0x40(%rbp), %rax
movq 0x38(%rbp), %rdx
movapd -0xa0(%rbp), %xmm1
je 0x4c39b
ucomisd 0x1e578(%rip), %xmm1    # 0x6a908
jne 0x4c394
jnp 0x4c39b
movsd %xmm1, -0x8(%rsi,%r15,8)
testq %rdx, %rdx
movsd -0x30(%rbp), %xmm1
je 0x4c3b8
ucomisd 0x1e55b(%rip), %xmm1    # 0x6a908
jne 0x4c3b1
jnp 0x4c3b8
movsd %xmm1, -0x8(%rdx,%r15,8)
testq %rax, %rax
je 0x4c3c4
movsd %xmm0, -0x8(%rax,%r15,8)
testq %rcx, %rcx
je 0x4c3d7
movb 0x3(%r12), %al
shrb %al
andb $0x1, %al
movb %al, -0x1(%rcx,%r15)
cmpq $0x0, 0x50(%rbp)
je 0x4c401
movzbl (%r12), %eax
xorps %xmm0, %xmm0
cvtsi2sd %eax, %xmm0
mulsd 0x1e61e(%rip), %xmm0    # 0x6aa10
cvtsd2ss %xmm0, %xmm0
movq 0x50(%rbp), %rax
movss %xmm0, -0x4(%rax,%r15,4)
addq $0x4, %r14
incq %r12
cmpq $0xc, %r14
movq -0x48(%rbp), %r15
jne 0x4c133
movq -0xe8(%rbp), %rcx
incq %rcx
movq -0x50(%rbp), %r14
movslq 0x30(%r14), %rax
addq $0x60, -0xb0(%rbp)
addq $0x60, -0xa8(%rbp)
cmpq %rax, %rcx
jl 0x4c0e1
movl -0x8c(%rbp), %r13d
movl %r13d, %eax
addq $0x908, %rsp            # imm = 0x908
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq