// File: /workspace/github_cpp_makefile_star2_O1/DoubleString[P]RtConverter/src/Rtklib/rtkcmn.cpp
// Function: bamboo::uniqnav(bamboo::nav_t*)
extern void uniqnav(nav_t *nav)
{
    int i,j;
    
    trace(3,"uniqnav: neph=%d ngeph=%d nseph=%d\n",nav->n,nav->ng,nav->ns);
    
    /* unique ephemeris */
    uniqeph (nav);
    uniqgeph(nav);
    uniqseph(nav);
    
    /* update carrier wave length */
    for (i=0;i<MAXRTKSAT;i++) for (j=0;j<NFREQ;j++) {
        nav->lam[i][j]=satwavelen(i+1,j,nav);
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movslq (%rdi), %rsi
testq %rsi, %rsi
jle 0x52eaf
movq 0x40(%rbx), %rdi
leaq 0x3ac4(%rip), %rcx      # 0x568bd
movl $0x120, %r14d           # imm = 0x120
movl $0x120, %edx            # imm = 0x120
callq 0x8c10
movl $0x1, %r15d
cmpl $0x2, (%rbx)
jl 0x52e76
xorl %r15d, %r15d
movl $0x1, %r12d
movq 0x40(%rbx), %rax
movl (%rax,%r14), %edx
movslq %r15d, %rcx
leaq (%rcx,%rcx,8), %rcx
shlq $0x5, %rcx
cmpl (%rax,%rcx), %edx
jne 0x52e42
addq %rax, %rcx
movl 0x4(%rax,%r14), %edx
cmpl 0x4(%rcx), %edx
je 0x52e61
leaq (%rax,%r14), %rsi
incl %r15d
movslq %r15d, %rcx
leaq (%rcx,%rcx,8), %rdi
shlq $0x5, %rdi
addq %rax, %rdi
movl $0x120, %edx            # imm = 0x120
callq 0x84f0
incq %r12
movslq (%rbx), %rax
addq $0x120, %r14            # imm = 0x120
cmpq %rax, %r12
jl 0x52e1d
incl %r15d
movl %r15d, (%rbx)
movq 0x40(%rbx), %rdi
movslq %r15d, %rax
shlq $0x5, %rax
leaq (%rax,%rax,8), %rsi
callq 0x8a80
testq %rax, %rax
je 0x52e9d
movq %rax, 0x40(%rbx)
movl (%rbx), %eax
movl %eax, 0x4(%rbx)
jmp 0x52eaf
movq 0x40(%rbx), %rdi
callq 0x87b0
xorl %eax, %eax
movq %rax, 0x40(%rbx)
movq %rax, (%rbx)
movslq 0x8(%rbx), %rsi
testq %rsi, %rsi
jle 0x52f86
movq 0x48(%rbx), %rdi
leaq 0x3a1e(%rip), %rcx      # 0x568e5
movl $0x98, %edx
callq 0x8c10
cmpl $0x0, 0x8(%rbx)
jle 0x52f45
xorl %r15d, %r15d
xorl %r12d, %r12d
xorl %r14d, %r14d
movq 0x48(%rbx), %rax
movl (%rax,%r15), %edx
movslq %r14d, %rcx
imulq $0x98, %rcx, %rcx
cmpl (%rax,%rcx), %edx
jne 0x52f0f
addq %rax, %rcx
movq 0x18(%rax,%r15), %rdx
cmpq 0x18(%rcx), %rdx
jne 0x52f0f
movl 0xc(%rax,%r15), %edx
cmpl 0xc(%rcx), %edx
je 0x52f2d
leaq (%rax,%r15), %rsi
incl %r14d
movslq %r14d, %rcx
imulq $0x98, %rcx, %rdi
addq %rax, %rdi
movl $0x98, %edx
callq 0x84f0
incq %r12
movslq 0x8(%rbx), %rax
addq $0x98, %r15
cmpq %rax, %r12
jl 0x52ee0
incl %r14d
jmp 0x52f4b
movl $0x1, %r14d
movl %r14d, 0x8(%rbx)
movq 0x48(%rbx), %rdi
movslq %r14d, %rax
imulq $0x98, %rax, %rsi
callq 0x8a80
testq %rax, %rax
je 0x52f73
movq %rax, 0x48(%rbx)
movl 0x8(%rbx), %eax
movl %eax, 0xc(%rbx)
jmp 0x52f86
movq 0x48(%rbx), %rdi
callq 0x87b0
xorl %eax, %eax
movq %rax, 0x48(%rbx)
movq %rax, 0x8(%rbx)
movslq 0x10(%rbx), %rsi
testq %rsi, %rsi
jle 0x5305f
movq 0x50(%rbx), %rdi
leaq 0x396f(%rip), %rcx      # 0x5690d
movl $0x88, %edx
callq 0x8c10
cmpl $0x0, 0x10(%rbx)
jle 0x5301a
xorl %r15d, %r15d
xorl %r12d, %r12d
xorl %r14d, %r14d
movq 0x50(%rbx), %rax
movl (%rax,%r15), %edx
movslq %r14d, %rcx
movq %rcx, %rsi
shlq $0x7, %rsi
leaq (%rsi,%rcx,8), %rcx
cmpl (%rax,%rcx), %edx
jne 0x52fe0
addq %rax, %rcx
movq 0x8(%rax,%r15), %rdx
cmpq 0x8(%rcx), %rdx
je 0x53002
leaq (%rax,%r15), %rsi
incl %r14d
movslq %r14d, %rcx
movq %rcx, %rdx
shlq $0x7, %rdx
leaq (%rdx,%rcx,8), %rdi
addq %rax, %rdi
movl $0x88, %edx
callq 0x84f0
incq %r12
movslq 0x10(%rbx), %rax
addq $0x88, %r15
cmpq %rax, %r12
jl 0x52fb7
incl %r14d
jmp 0x53020
movl $0x1, %r14d
movl %r14d, 0x10(%rbx)
movq 0x50(%rbx), %rdi
movslq %r14d, %rax
movq %rax, %rcx
shlq $0x7, %rcx
leaq (%rcx,%rax,8), %rsi
callq 0x8a80
testq %rax, %rax
je 0x5304c
movq %rax, 0x50(%rbx)
movl 0x10(%rbx), %eax
movl %eax, 0x14(%rbx)
jmp 0x5305f
movq 0x50(%rbx), %rdi
callq 0x87b0
xorl %eax, %eax
movq %rax, 0x50(%rbx)
movq %rax, 0x10(%rbx)
leaq 0x298(%rbx), %r12
xorl %r14d, %r14d
incq %r14
xorl %r15d, %r15d
movl %r14d, %edi
movl %r15d, %esi
movq %rbx, %rdx
callq 0x530a2
movsd %xmm0, (%r12,%r15,8)
incq %r15
cmpq $0x3, %r15
jne 0x5306f
addq $0x18, %r12
cmpq $0x9b, %r14
jne 0x53069
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq