// File: /workspace/github_c_makefile_star2_O0/pyk[P]simple-nn/deps/pcg/src/pcg-advance-128.c
// Function: pcg_advance_lcg_128
pcg128_t pcg_advance_lcg_128(pcg128_t state, pcg128_t delta, pcg128_t cur_mult,
                             pcg128_t cur_plus)
{
    pcg128_t acc_mult = 1u;
    pcg128_t acc_plus = 0u;
    while (delta > 0) {
        if (delta & 1) {
            acc_mult *= cur_mult;
            acc_plus = acc_plus * cur_mult + cur_plus;
        }
        cur_plus = (cur_mult + 1) * cur_plus;
        cur_mult *= cur_mult;
        delta /= 2;
    }
    return acc_mult * state + acc_plus;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %r8, %rax
movq 0x10(%rbp), %r8
movq 0x18(%rbp), %r8
movq %rdi, -0x20(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %r8
movq %rdx, -0x30(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x30(%rbp), %rdx
movq -0x28(%rbp), %rsi
movq %rax, -0x40(%rbp)
movq %r9, -0x38(%rbp)
movq -0x40(%rbp), %rax
movq -0x38(%rbp), %rcx
movq %r8, -0x48(%rbp)
movq %rdi, -0x50(%rbp)
movq %rsi, -0x58(%rbp)
movq %rdx, -0x60(%rbp)
movq %rcx, -0x68(%rbp)
movq %rax, -0x70(%rbp)
movq $0x0, -0x78(%rbp)
movq $0x1, -0x80(%rbp)
movq $0x0, -0x88(%rbp)
movq $0x0, -0x90(%rbp)
movq -0x60(%rbp), %rax
movq -0x58(%rbp), %rcx
orq %rcx, %rax
je 0x3b1a
jmp 0x39d4
movb -0x60(%rbp), %al
testb $0x1, %al
je 0x3a7b
jmp 0x39e1
movq -0x70(%rbp), %rsi
movq -0x68(%rbp), %rcx
movq -0x80(%rbp), %rax
movq -0x78(%rbp), %rdx
movq %rdx, -0xa0(%rbp)
movq %rax, %rdi
imulq %rcx, %rdi
mulq %rsi
movq %rax, %rcx
movq %rdx, %rax
movq -0xa0(%rbp), %rdx
addq %rdi, %rax
imulq %rsi, %rdx
addq %rdx, %rax
movq %rcx, -0x80(%rbp)
movq %rax, -0x78(%rbp)
movq -0x90(%rbp), %rax
movq -0x88(%rbp), %rcx
movq %rcx, -0x98(%rbp)
movq -0x70(%rbp), %rsi
movq -0x68(%rbp), %rcx
movq %rax, %rdi
imulq %rcx, %rdi
mulq %rsi
movq %rax, %rcx
movq %rdx, %rax
movq -0x98(%rbp), %rdx
addq %rdi, %rax
imulq %rsi, %rdx
addq %rdx, %rax
movq 0x10(%rbp), %rsi
movq 0x18(%rbp), %rdx
addq %rsi, %rcx
adcq %rdx, %rax
movq %rcx, -0x90(%rbp)
movq %rax, -0x88(%rbp)
movq -0x70(%rbp), %rax
movq -0x68(%rbp), %rcx
addq $0x1, %rax
adcq $0x0, %rcx
movq %rcx, -0xb0(%rbp)
movq 0x10(%rbp), %rsi
movq 0x18(%rbp), %rcx
movq %rax, %rdi
imulq %rcx, %rdi
mulq %rsi
movq %rax, %rcx
movq %rdx, %rax
movq -0xb0(%rbp), %rdx
addq %rdi, %rax
imulq %rsi, %rdx
addq %rdx, %rax
movq %rcx, 0x10(%rbp)
movq %rax, 0x18(%rbp)
movq -0x70(%rbp), %rcx
movq -0x68(%rbp), %rdx
movq %rcx, %rax
imulq %rdx, %rax
movq %rax, -0xa8(%rbp)
movq %rcx, %rax
mulq %rcx
movq %rax, %rcx
movq %rdx, %rax
movq -0xa8(%rbp), %rdx
addq %rdx, %rax
addq %rdx, %rax
movq %rcx, -0x70(%rbp)
movq %rax, -0x68(%rbp)
movq -0x60(%rbp), %rdx
movq -0x58(%rbp), %rcx
movq %rcx, %rax
shldq $0x3f, %rdx, %rax
shrq %rcx
movq %rcx, -0x58(%rbp)
movq %rax, -0x60(%rbp)
jmp 0x39c1
movq -0x80(%rbp), %rax
movq -0x78(%rbp), %rcx
movq %rcx, -0xb8(%rbp)
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rcx
movq %rax, %rdi
imulq %rcx, %rdi
mulq %rsi
movq %rax, %rcx
movq %rdx, %rax
movq -0xb8(%rbp), %rdx
addq %rdi, %rax
imulq %rsi, %rdx
addq %rdx, %rax
movq -0x90(%rbp), %rsi
movq -0x88(%rbp), %rdx
addq %rsi, %rcx
adcq %rdx, %rax
movq %rcx, -0x10(%rbp)
movq %rax, -0x8(%rbp)
movq -0x10(%rbp), %rax
movq -0x8(%rbp), %rdx
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax)