// File: /workspace/github_c_makefile_star2_O0/LoupVaillant[P]Monocypher-Utils/src/monocypher.c
// Function: fe_tobytes
static void fe_tobytes(u8 s[32], const fe h)
{
    i32 t[10];
    FOR (i, 0, 10) {
        t[i] = h[i];
    }
    i32 q = (19 * t[9] + (((i32) 1) << 24)) >> 25;
    FOR (i, 0, 5) {
        q += t[2*i  ]; q >>= 26;
        q += t[2*i+1]; q >>= 25;
    }
    t[0] += 19 * q;

    i32 c0 = t[0] >> 26; t[1] += c0; t[0] -= c0 * (1 << 26);
    i32 c1 = t[1] >> 25; t[2] += c1; t[1] -= c1 * (1 << 25);
    i32 c2 = t[2] >> 26; t[3] += c2; t[2] -= c2 * (1 << 26);
    i32 c3 = t[3] >> 25; t[4] += c3; t[3] -= c3 * (1 << 25);
    i32 c4 = t[4] >> 26; t[5] += c4; t[4] -= c4 * (1 << 26);
    i32 c5 = t[5] >> 25; t[6] += c5; t[5] -= c5 * (1 << 25);
    i32 c6 = t[6] >> 26; t[7] += c6; t[6] -= c6 * (1 << 26);
    i32 c7 = t[7] >> 25; t[8] += c7; t[7] -= c7 * (1 << 25);
    i32 c8 = t[8] >> 26; t[9] += c8; t[8] -= c8 * (1 << 26);
    i32 c9 = t[9] >> 25;             t[9] -= c9 * (1 << 25);

    store32_le(s +  0, ((u32)t[0] >>  0) | ((u32)t[1] << 26));
    store32_le(s +  4, ((u32)t[1] >>  6) | ((u32)t[2] << 19));
    store32_le(s +  8, ((u32)t[2] >> 13) | ((u32)t[3] << 13));
    store32_le(s + 12, ((u32)t[3] >> 19) | ((u32)t[4] <<  6));
    store32_le(s + 16, ((u32)t[5] >>  0) | ((u32)t[6] << 25));
    store32_le(s + 20, ((u32)t[6] >>  7) | ((u32)t[7] << 19));
    store32_le(s + 24, ((u32)t[7] >> 13) | ((u32)t[8] << 12));
    store32_le(s + 28, ((u32)t[8] >> 20) | ((u32)t[9] <<  6));

    WIPE_BUFFER(t);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq $0x0, -0x48(%rbp)
cmpq $0xa, -0x48(%rbp)
jae 0xa9f3
movq -0x10(%rbp), %rax
movq -0x48(%rbp), %rcx
movl (%rax,%rcx,4), %ecx
movq -0x48(%rbp), %rax
movl %ecx, -0x40(%rbp,%rax,4)
movq -0x48(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x48(%rbp)
jmp 0xa9cb
imull $0x13, -0x1c(%rbp), %eax
addl $0x1000000, %eax        # imm = 0x1000000
sarl $0x19, %eax
movl %eax, -0x4c(%rbp)
movq $0x0, -0x58(%rbp)
cmpq $0x5, -0x58(%rbp)
jae 0xaa53
movq -0x58(%rbp), %rax
shlq %rax
movl -0x40(%rbp,%rax,4), %eax
addl -0x4c(%rbp), %eax
movl %eax, -0x4c(%rbp)
movl -0x4c(%rbp), %eax
sarl $0x1a, %eax
movl %eax, -0x4c(%rbp)
movq -0x58(%rbp), %rax
shlq %rax
movl -0x3c(%rbp,%rax,4), %eax
addl -0x4c(%rbp), %eax
movl %eax, -0x4c(%rbp)
movl -0x4c(%rbp), %eax
sarl $0x19, %eax
movl %eax, -0x4c(%rbp)
movq -0x58(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x58(%rbp)
jmp 0xaa0a
imull $0x13, -0x4c(%rbp), %eax
addl -0x40(%rbp), %eax
movl %eax, -0x40(%rbp)
movl -0x40(%rbp), %eax
sarl $0x1a, %eax
movl %eax, -0x5c(%rbp)
movl -0x5c(%rbp), %eax
addl -0x3c(%rbp), %eax
movl %eax, -0x3c(%rbp)
movl -0x5c(%rbp), %ecx
shll $0x1a, %ecx
movl -0x40(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x40(%rbp)
movl -0x3c(%rbp), %eax
sarl $0x19, %eax
movl %eax, -0x60(%rbp)
movl -0x60(%rbp), %eax
addl -0x38(%rbp), %eax
movl %eax, -0x38(%rbp)
movl -0x60(%rbp), %ecx
shll $0x19, %ecx
movl -0x3c(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x3c(%rbp)
movl -0x38(%rbp), %eax
sarl $0x1a, %eax
movl %eax, -0x64(%rbp)
movl -0x64(%rbp), %eax
addl -0x34(%rbp), %eax
movl %eax, -0x34(%rbp)
movl -0x64(%rbp), %ecx
shll $0x1a, %ecx
movl -0x38(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x38(%rbp)
movl -0x34(%rbp), %eax
sarl $0x19, %eax
movl %eax, -0x68(%rbp)
movl -0x68(%rbp), %eax
addl -0x30(%rbp), %eax
movl %eax, -0x30(%rbp)
movl -0x68(%rbp), %ecx
shll $0x19, %ecx
movl -0x34(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x34(%rbp)
movl -0x30(%rbp), %eax
sarl $0x1a, %eax
movl %eax, -0x6c(%rbp)
movl -0x6c(%rbp), %eax
addl -0x2c(%rbp), %eax
movl %eax, -0x2c(%rbp)
movl -0x6c(%rbp), %ecx
shll $0x1a, %ecx
movl -0x30(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x30(%rbp)
movl -0x2c(%rbp), %eax
sarl $0x19, %eax
movl %eax, -0x70(%rbp)
movl -0x70(%rbp), %eax
addl -0x28(%rbp), %eax
movl %eax, -0x28(%rbp)
movl -0x70(%rbp), %ecx
shll $0x19, %ecx
movl -0x2c(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x2c(%rbp)
movl -0x28(%rbp), %eax
sarl $0x1a, %eax
movl %eax, -0x74(%rbp)
movl -0x74(%rbp), %eax
addl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x74(%rbp), %ecx
shll $0x1a, %ecx
movl -0x28(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x28(%rbp)
movl -0x24(%rbp), %eax
sarl $0x19, %eax
movl %eax, -0x78(%rbp)
movl -0x78(%rbp), %eax
addl -0x20(%rbp), %eax
movl %eax, -0x20(%rbp)
movl -0x78(%rbp), %ecx
shll $0x19, %ecx
movl -0x24(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x24(%rbp)
movl -0x20(%rbp), %eax
sarl $0x1a, %eax
movl %eax, -0x7c(%rbp)
movl -0x7c(%rbp), %eax
addl -0x1c(%rbp), %eax
movl %eax, -0x1c(%rbp)
movl -0x7c(%rbp), %ecx
shll $0x1a, %ecx
movl -0x20(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x20(%rbp)
movl -0x1c(%rbp), %eax
sarl $0x19, %eax
movl %eax, -0x80(%rbp)
movl -0x80(%rbp), %ecx
shll $0x19, %ecx
movl -0x1c(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x1c(%rbp)
movq -0x8(%rbp), %rdi
movl -0x40(%rbp), %esi
shrl $0x0, %esi
movl -0x3c(%rbp), %eax
shll $0x1a, %eax
orl %eax, %esi
callq 0x22b0
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
movl -0x3c(%rbp), %esi
shrl $0x6, %esi
movl -0x38(%rbp), %eax
shll $0x13, %eax
orl %eax, %esi
callq 0x22b0
movq -0x8(%rbp), %rdi
addq $0x8, %rdi
movl -0x38(%rbp), %esi
shrl $0xd, %esi
movl -0x34(%rbp), %eax
shll $0xd, %eax
orl %eax, %esi
callq 0x22b0
movq -0x8(%rbp), %rdi
addq $0xc, %rdi
movl -0x34(%rbp), %esi
shrl $0x13, %esi
movl -0x30(%rbp), %eax
shll $0x6, %eax
orl %eax, %esi
callq 0x22b0
movq -0x8(%rbp), %rdi
addq $0x10, %rdi
movl -0x2c(%rbp), %esi
shrl $0x0, %esi
movl -0x28(%rbp), %eax
shll $0x19, %eax
orl %eax, %esi
callq 0x22b0
movq -0x8(%rbp), %rdi
addq $0x14, %rdi
movl -0x28(%rbp), %esi
shrl $0x7, %esi
movl -0x24(%rbp), %eax
shll $0x13, %eax
orl %eax, %esi
callq 0x22b0
movq -0x8(%rbp), %rdi
addq $0x18, %rdi
movl -0x24(%rbp), %esi
shrl $0xd, %esi
movl -0x20(%rbp), %eax
shll $0xc, %eax
orl %eax, %esi
callq 0x22b0
movq -0x8(%rbp), %rdi
addq $0x1c, %rdi
movl -0x20(%rbp), %esi
shrl $0x14, %esi
movl -0x1c(%rbp), %eax
shll $0x6, %eax
orl %eax, %esi
callq 0x22b0
leaq -0x40(%rbp), %rdi
movl $0x28, %esi
callq 0x1b40
addq $0x80, %rsp
popq %rbp
retq
nop