#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */
typedef int /*<<< orphan*/ out0;
typedef int /*<<< orphan*/ in1;
typedef int /*<<< orphan*/ in0;

/* Variables and functions */
uintptr_t _br2_load(int /*<<< orphan*/, int);
int /*<<< orphan*/ _br2_store(int /*<<< orphan*/, uintptr_t, int);
void internal_fiat_25519_sub(uintptr_t out0, uintptr_t in0, uintptr_t in1) {
  uintptr_t x0, x5, x1, x6, x2, x7, x3, x8, x4, x9, x10, x11, x12, x13, x14,
      x15, x16, x17, x18, x19;
  x0 = _br2_load((in0) + ((uintptr_t)0ULL), sizeof(uintptr_t));
  x1 = _br2_load((in0) + ((uintptr_t)8ULL), sizeof(uintptr_t));
  x2 = _br2_load((in0) + ((uintptr_t)16ULL), sizeof(uintptr_t));
  x3 = _br2_load((in0) + ((uintptr_t)24ULL), sizeof(uintptr_t));
  x4 = _br2_load((in0) + ((uintptr_t)32ULL), sizeof(uintptr_t));
  x5 = _br2_load((in1) + ((uintptr_t)0ULL), sizeof(uintptr_t));
  x6 = _br2_load((in1) + ((uintptr_t)8ULL), sizeof(uintptr_t));
  x7 = _br2_load((in1) + ((uintptr_t)16ULL), sizeof(uintptr_t));
  x8 = _br2_load((in1) + ((uintptr_t)24ULL), sizeof(uintptr_t));
  x9 = _br2_load((in1) + ((uintptr_t)32ULL), sizeof(uintptr_t));
  x10 = (((uintptr_t)4503599627370458ULL) + (x0)) - (x5);
  x11 = (((uintptr_t)4503599627370494ULL) + (x1)) - (x6);
  x12 = (((uintptr_t)4503599627370494ULL) + (x2)) - (x7);
  x13 = (((uintptr_t)4503599627370494ULL) + (x3)) - (x8);
  x14 = (((uintptr_t)4503599627370494ULL) + (x4)) - (x9);
  x15 = x10;
  x16 = x11;
  x17 = x12;
  x18 = x13;
  x19 = x14;
  _br2_store((out0) + ((uintptr_t)0ULL), x15, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)8ULL), x16, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)16ULL), x17, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)24ULL), x18, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)32ULL), x19, sizeof(uintptr_t));
  return;
}


x86 assembly (clang, -O0):
<internal_fiat_25519_sub>:
push   %rbp
mov    %rsp,%rbp
sub    $0xc0,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    -0x10(%rbp),%rax
add    $0x0,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x20(%rbp)
mov    -0x10(%rbp),%rax
add    $0x8,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x30(%rbp)
mov    -0x10(%rbp),%rax
add    $0x10,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x40(%rbp)
mov    -0x10(%rbp),%rax
add    $0x18,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x50(%rbp)
mov    -0x10(%rbp),%rax
add    $0x20,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x60(%rbp)
mov    -0x18(%rbp),%rax
add    $0x0,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x28(%rbp)
mov    -0x18(%rbp),%rax
add    $0x8,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x38(%rbp)
mov    -0x18(%rbp),%rax
add    $0x10,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x48(%rbp)
mov    -0x18(%rbp),%rax
add    $0x18,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x58(%rbp)
mov    -0x18(%rbp),%rax
add    $0x20,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x68(%rbp)
movabs $0xfffffffffffda,%rax
add    -0x20(%rbp),%rax
sub    -0x28(%rbp),%rax
mov    %rax,-0x70(%rbp)
movabs $0xffffffffffffe,%rax
add    -0x30(%rbp),%rax
sub    -0x38(%rbp),%rax
mov    %rax,-0x78(%rbp)
movabs $0xffffffffffffe,%rax
add    -0x40(%rbp),%rax
sub    -0x48(%rbp),%rax
mov    %rax,-0x80(%rbp)
movabs $0xffffffffffffe,%rax
add    -0x50(%rbp),%rax
sub    -0x58(%rbp),%rax
mov    %rax,-0x88(%rbp)
movabs $0xffffffffffffe,%rax
add    -0x60(%rbp),%rax
sub    -0x68(%rbp),%rax
mov    %rax,-0x90(%rbp)
mov    -0x70(%rbp),%rax
mov    %rax,-0x98(%rbp)
mov    -0x78(%rbp),%rax
mov    %rax,-0xa0(%rbp)
mov    -0x80(%rbp),%rax
mov    %rax,-0xa8(%rbp)
mov    -0x88(%rbp),%rax
mov    %rax,-0xb0(%rbp)
mov    -0x90(%rbp),%rax
mov    %rax,-0xb8(%rbp)
mov    -0x8(%rbp),%rax
add    $0x0,%rax
mov    %eax,%edi
mov    -0x98(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x8,%rax
mov    %eax,%edi
mov    -0xa0(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x10,%rax
mov    %eax,%edi
mov    -0xa8(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x18,%rax
mov    %eax,%edi
mov    -0xb0(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x20,%rax
mov    %eax,%edi
mov    -0xb8(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
add    $0xc0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<internal_fiat_25519_sub>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x28,%rsp
mov    %rdx,%r15
mov    %rsi,%rbp
mov    %rdi,%r14
mov    %ebp,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%rbx
lea    0x8(%rbp),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,0x20(%rsp)
lea    0x10(%rbp),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%r12
lea    0x18(%rbp),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%r13
add    $0x20,%ebp
mov    %ebp,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%rbp
mov    %r15d,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,0x18(%rsp)
lea    0x8(%r15),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,0x10(%rsp)
lea    0x10(%r15),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,0x8(%rsp)
lea    0x18(%r15),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,(%rsp)
add    $0x20,%r15d
mov    %r15d,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
movabs $0xffffffffffffe,%rcx
add    %rcx,%rbx
sub    0x18(%rsp),%rbx
add    $0xffffffffffffffdc,%rbx
mov    0x20(%rsp),%r15
add    %rcx,%r15
sub    0x10(%rsp),%r15
add    %rcx,%r12
sub    0x8(%rsp),%r12
add    %rcx,%r13
sub    (%rsp),%r13
add    %rcx,%rbp
sub    %rax,%rbp
mov    %r14d,%edi
mov    %rbx,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x8(%r14),%edi
mov    %r15,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x10(%r14),%edi
mov    %r12,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x18(%r14),%edi
mov    %r13,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
add    $0x20,%r14d
mov    %r14d,%edi
mov    %rbp,%rsi
mov    $0x8,%edx
add    $0x28,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1040 <_br2_store@plt>

LLVM IR (-O0):
define void @internal_fiat_25519_sub(i64 %0, i64 %1, i64 %2) {
%4 = alloca i64
%5 = alloca i64
%6 = alloca i64
%7 = alloca i64
%8 = alloca i64
%9 = alloca i64
%10 = alloca i64
%11 = alloca i64
%12 = alloca i64
%13 = alloca i64
%14 = alloca i64
%15 = alloca i64
%16 = alloca i64
%17 = alloca i64
%18 = alloca i64
%19 = alloca i64
%20 = alloca i64
%21 = alloca i64
%22 = alloca i64
%23 = alloca i64
%24 = alloca i64
%25 = alloca i64
%26 = alloca i64
store i64 %0, i64* %4
store i64 %1, i64* %5
store i64 %2, i64* %6
%27 = load i64, i64* %5
%28 = add i64 %27, 0
%29 = trunc i64 %28 to i32
%30 = call i64 @_br2_load(i32 %29, i32 8)
store i64 %30, i64* %7
%31 = load i64, i64* %5
%32 = add i64 %31, 8
%33 = trunc i64 %32 to i32
%34 = call i64 @_br2_load(i32 %33, i32 8)
store i64 %34, i64* %9
%35 = load i64, i64* %5
%36 = add i64 %35, 16
%37 = trunc i64 %36 to i32
%38 = call i64 @_br2_load(i32 %37, i32 8)
store i64 %38, i64* %11
%39 = load i64, i64* %5
%40 = add i64 %39, 24
%41 = trunc i64 %40 to i32
%42 = call i64 @_br2_load(i32 %41, i32 8)
store i64 %42, i64* %13
%43 = load i64, i64* %5
%44 = add i64 %43, 32
%45 = trunc i64 %44 to i32
%46 = call i64 @_br2_load(i32 %45, i32 8)
store i64 %46, i64* %15
%47 = load i64, i64* %6
%48 = add i64 %47, 0
%49 = trunc i64 %48 to i32
%50 = call i64 @_br2_load(i32 %49, i32 8)
store i64 %50, i64* %8
%51 = load i64, i64* %6
%52 = add i64 %51, 8
%53 = trunc i64 %52 to i32
%54 = call i64 @_br2_load(i32 %53, i32 8)
store i64 %54, i64* %10
%55 = load i64, i64* %6
%56 = add i64 %55, 16
%57 = trunc i64 %56 to i32
%58 = call i64 @_br2_load(i32 %57, i32 8)
store i64 %58, i64* %12
%59 = load i64, i64* %6
%60 = add i64 %59, 24
%61 = trunc i64 %60 to i32
%62 = call i64 @_br2_load(i32 %61, i32 8)
store i64 %62, i64* %14
%63 = load i64, i64* %6
%64 = add i64 %63, 32
%65 = trunc i64 %64 to i32
%66 = call i64 @_br2_load(i32 %65, i32 8)
store i64 %66, i64* %16
%67 = load i64, i64* %7
%68 = add i64 4503599627370458, %67
%69 = load i64, i64* %8
%70 = sub i64 %68, %69
store i64 %70, i64* %17
%71 = load i64, i64* %9
%72 = add i64 4503599627370494, %71
%73 = load i64, i64* %10
%74 = sub i64 %72, %73
store i64 %74, i64* %18
%75 = load i64, i64* %11
%76 = add i64 4503599627370494, %75
%77 = load i64, i64* %12
%78 = sub i64 %76, %77
store i64 %78, i64* %19
%79 = load i64, i64* %13
%80 = add i64 4503599627370494, %79
%81 = load i64, i64* %14
%82 = sub i64 %80, %81
store i64 %82, i64* %20
%83 = load i64, i64* %15
%84 = add i64 4503599627370494, %83
%85 = load i64, i64* %16
%86 = sub i64 %84, %85
store i64 %86, i64* %21
%87 = load i64, i64* %17
store i64 %87, i64* %22
%88 = load i64, i64* %18
store i64 %88, i64* %23
%89 = load i64, i64* %19
store i64 %89, i64* %24
%90 = load i64, i64* %20
store i64 %90, i64* %25
%91 = load i64, i64* %21
store i64 %91, i64* %26
%92 = load i64, i64* %4
%93 = add i64 %92, 0
%94 = trunc i64 %93 to i32
%95 = load i64, i64* %22
%96 = call i32 @_br2_store(i32 %94, i64 %95, i32 8)
%97 = load i64, i64* %4
%98 = add i64 %97, 8
%99 = trunc i64 %98 to i32
%100 = load i64, i64* %23
%101 = call i32 @_br2_store(i32 %99, i64 %100, i32 8)
%102 = load i64, i64* %4
%103 = add i64 %102, 16
%104 = trunc i64 %103 to i32
%105 = load i64, i64* %24
%106 = call i32 @_br2_store(i32 %104, i64 %105, i32 8)
%107 = load i64, i64* %4
%108 = add i64 %107, 24
%109 = trunc i64 %108 to i32
%110 = load i64, i64* %25
%111 = call i32 @_br2_store(i32 %109, i64 %110, i32 8)
%112 = load i64, i64* %4
%113 = add i64 %112, 32
%114 = trunc i64 %113 to i32
%115 = load i64, i64* %26
%116 = call i32 @_br2_store(i32 %114, i64 %115, i32 8)
ret void
}

LLVM IR (-O2):
define void @internal_fiat_25519_sub(i64 %0, i64 %1, i64 %2) {
%4 = trunc i64 %1 to i32
%5 = tail call i64 @_br2_load(i32 %4, i32 8)
%6 = add i32 %4, 8
%7 = tail call i64 @_br2_load(i32 %6, i32 8)
%8 = add i32 %4, 16
%9 = tail call i64 @_br2_load(i32 %8, i32 8)
%10 = add i32 %4, 24
%11 = tail call i64 @_br2_load(i32 %10, i32 8)
%12 = add i32 %4, 32
%13 = tail call i64 @_br2_load(i32 %12, i32 8)
%14 = trunc i64 %2 to i32
%15 = tail call i64 @_br2_load(i32 %14, i32 8)
%16 = add i32 %14, 8
%17 = tail call i64 @_br2_load(i32 %16, i32 8)
%18 = add i32 %14, 16
%19 = tail call i64 @_br2_load(i32 %18, i32 8)
%20 = add i32 %14, 24
%21 = tail call i64 @_br2_load(i32 %20, i32 8)
%22 = add i32 %14, 32
%23 = tail call i64 @_br2_load(i32 %22, i32 8)
%24 = add i64 %5, 4503599627370458
%25 = sub i64 %24, %15
%26 = add i64 %7, 4503599627370494
%27 = sub i64 %26, %17
%28 = add i64 %9, 4503599627370494
%29 = sub i64 %28, %19
%30 = add i64 %11, 4503599627370494
%31 = sub i64 %30, %21
%32 = add i64 %13, 4503599627370494
%33 = sub i64 %32, %23
%34 = trunc i64 %0 to i32
%35 = tail call i32 @_br2_store(i32 %34, i64 %25, i32 8)
%36 = add i32 %34, 8
%37 = tail call i32 @_br2_store(i32 %36, i64 %27, i32 8)
%38 = add i32 %34, 16
%39 = tail call i32 @_br2_store(i32 %38, i64 %29, i32 8)
%40 = add i32 %34, 24
%41 = tail call i32 @_br2_store(i32 %40, i64 %31, i32 8)
%42 = add i32 %34, 32
%43 = tail call i32 @_br2_store(i32 %42, i64 %33, i32 8)
ret void
}