#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 uintptr_t x9;
typedef uintptr_t x19;
typedef uintptr_t x18;
typedef uintptr_t x17;
typedef uintptr_t x16;
typedef uintptr_t x15;
typedef uintptr_t x14;
typedef uintptr_t x13;
typedef uintptr_t x12;
typedef uintptr_t x11;
typedef uintptr_t x10;
typedef int /*<<< orphan*/ out0;
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_p521_carry(uintptr_t out0, uintptr_t in0) {
  uintptr_t x0, x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x18, x19, x11, x12,
      x13, x14, x15, x16, x17, x20, x21, x22, x23, x24, x25, x26, x27, x28, x29,
      x30, x31, x32, x33, x34, x35, x36, x37;
  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((in0) + ((uintptr_t)40ULL), sizeof(uintptr_t));
  x6 = _br2_load((in0) + ((uintptr_t)48ULL), sizeof(uintptr_t));
  x7 = _br2_load((in0) + ((uintptr_t)56ULL), sizeof(uintptr_t));
  x8 = _br2_load((in0) + ((uintptr_t)64ULL), sizeof(uintptr_t));
  x9 = x0;
  x10 = ((x9) >> ((uintptr_t)58ULL)) + (x1);
  x11 = ((x10) >> ((uintptr_t)58ULL)) + (x2);
  x12 = ((x11) >> ((uintptr_t)58ULL)) + (x3);
  x13 = ((x12) >> ((uintptr_t)58ULL)) + (x4);
  x14 = ((x13) >> ((uintptr_t)58ULL)) + (x5);
  x15 = ((x14) >> ((uintptr_t)58ULL)) + (x6);
  x16 = ((x15) >> ((uintptr_t)58ULL)) + (x7);
  x17 = ((x16) >> ((uintptr_t)58ULL)) + (x8);
  x18 = ((x9) & ((uintptr_t)288230376151711743ULL)) +
        ((x17) >> ((uintptr_t)57ULL));
  x19 = ((x18) >> ((uintptr_t)58ULL)) +
        ((x10) & ((uintptr_t)288230376151711743ULL));
  x20 = (x18) & ((uintptr_t)288230376151711743ULL);
  x21 = (x19) & ((uintptr_t)288230376151711743ULL);
  x22 = ((x19) >> ((uintptr_t)58ULL)) +
        ((x11) & ((uintptr_t)288230376151711743ULL));
  x23 = (x12) & ((uintptr_t)288230376151711743ULL);
  x24 = (x13) & ((uintptr_t)288230376151711743ULL);
  x25 = (x14) & ((uintptr_t)288230376151711743ULL);
  x26 = (x15) & ((uintptr_t)288230376151711743ULL);
  x27 = (x16) & ((uintptr_t)288230376151711743ULL);
  x28 = (x17) & ((uintptr_t)144115188075855871ULL);
  x29 = x20;
  x30 = x21;
  x31 = x22;
  x32 = x23;
  x33 = x24;
  x34 = x25;
  x35 = x26;
  x36 = x27;
  x37 = x28;
  _br2_store((out0) + ((uintptr_t)0ULL), x29, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)8ULL), x30, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)16ULL), x31, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)24ULL), x32, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)32ULL), x33, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)40ULL), x34, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)48ULL), x35, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)56ULL), x36, sizeof(uintptr_t));
  _br2_store((out0) + ((uintptr_t)64ULL), x37, sizeof(uintptr_t));
  return;
}


x86 assembly (clang, -O0):
<internal_fiat_p521_carry>:
push   %rbp
mov    %rsp,%rbp
sub    $0x140,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x10(%rbp),%rax
add    $0x0,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rax
add    $0x8,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x20(%rbp)
mov    -0x10(%rbp),%rax
add    $0x10,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x28(%rbp)
mov    -0x10(%rbp),%rax
add    $0x18,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x30(%rbp)
mov    -0x10(%rbp),%rax
add    $0x20,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x38(%rbp)
mov    -0x10(%rbp),%rax
add    $0x28,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x40(%rbp)
mov    -0x10(%rbp),%rax
add    $0x30,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x48(%rbp)
mov    -0x10(%rbp),%rax
add    $0x38,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x50(%rbp)
mov    -0x10(%rbp),%rax
add    $0x40,%rax
mov    %eax,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,-0x58(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x60(%rbp)
mov    -0x60(%rbp),%rax
shr    $0x3a,%rax
add    -0x20(%rbp),%rax
mov    %rax,-0x68(%rbp)
mov    -0x68(%rbp),%rax
shr    $0x3a,%rax
add    -0x28(%rbp),%rax
mov    %rax,-0x80(%rbp)
mov    -0x80(%rbp),%rax
shr    $0x3a,%rax
add    -0x30(%rbp),%rax
mov    %rax,-0x88(%rbp)
mov    -0x88(%rbp),%rax
shr    $0x3a,%rax
add    -0x38(%rbp),%rax
mov    %rax,-0x90(%rbp)
mov    -0x90(%rbp),%rax
shr    $0x3a,%rax
add    -0x40(%rbp),%rax
mov    %rax,-0x98(%rbp)
mov    -0x98(%rbp),%rax
shr    $0x3a,%rax
add    -0x48(%rbp),%rax
mov    %rax,-0xa0(%rbp)
mov    -0xa0(%rbp),%rax
shr    $0x3a,%rax
add    -0x50(%rbp),%rax
mov    %rax,-0xa8(%rbp)
mov    -0xa8(%rbp),%rax
shr    $0x3a,%rax
add    -0x58(%rbp),%rax
mov    %rax,-0xb0(%rbp)
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    -0x60(%rbp),%rax
mov    -0xb0(%rbp),%rcx
shr    $0x39,%rcx
add    %rcx,%rax
mov    %rax,-0x70(%rbp)
mov    -0x70(%rbp),%rax
shr    $0x3a,%rax
movabs $0x3ffffffffffffff,%rcx
ff ff 03
and    -0x68(%rbp),%rcx
add    %rcx,%rax
mov    %rax,-0x78(%rbp)
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    -0x70(%rbp),%rax
mov    %rax,-0xb8(%rbp)
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    -0x78(%rbp),%rax
mov    %rax,-0xc0(%rbp)
mov    -0x78(%rbp),%rax
shr    $0x3a,%rax
movabs $0x3ffffffffffffff,%rcx
ff ff 03
and    -0x80(%rbp),%rcx
add    %rcx,%rax
mov    %rax,-0xc8(%rbp)
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    -0x88(%rbp),%rax
mov    %rax,-0xd0(%rbp)
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    -0x90(%rbp),%rax
mov    %rax,-0xd8(%rbp)
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    -0x98(%rbp),%rax
mov    %rax,-0xe0(%rbp)
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    -0xa0(%rbp),%rax
mov    %rax,-0xe8(%rbp)
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    -0xa8(%rbp),%rax
mov    %rax,-0xf0(%rbp)
movabs $0x1ffffffffffffff,%rax
ff ff 01
and    -0xb0(%rbp),%rax
mov    %rax,-0xf8(%rbp)
mov    -0xb8(%rbp),%rax
mov    %rax,-0x100(%rbp)
mov    -0xc0(%rbp),%rax
mov    %rax,-0x108(%rbp)
mov    -0xc8(%rbp),%rax
mov    %rax,-0x110(%rbp)
mov    -0xd0(%rbp),%rax
mov    %rax,-0x118(%rbp)
mov    -0xd8(%rbp),%rax
mov    %rax,-0x120(%rbp)
mov    -0xe0(%rbp),%rax
mov    %rax,-0x128(%rbp)
mov    -0xe8(%rbp),%rax
mov    %rax,-0x130(%rbp)
mov    -0xf0(%rbp),%rax
mov    %rax,-0x138(%rbp)
mov    -0xf8(%rbp),%rax
mov    %rax,-0x140(%rbp)
mov    -0x8(%rbp),%rax
add    $0x0,%rax
mov    %eax,%edi
mov    -0x100(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x8,%rax
mov    %eax,%edi
mov    -0x108(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x10,%rax
mov    %eax,%edi
mov    -0x110(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x18,%rax
mov    %eax,%edi
mov    -0x118(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x20,%rax
mov    %eax,%edi
mov    -0x120(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x28,%rax
mov    %eax,%edi
mov    -0x128(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x30,%rax
mov    %eax,%edi
mov    -0x130(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x38,%rax
mov    %eax,%edi
mov    -0x138(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    -0x8(%rbp),%rax
add    $0x40,%rax
mov    %eax,%edi
mov    -0x140(%rbp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
add    $0x140,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<internal_fiat_p521_carry>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x28,%rsp
mov    %rsi,%rbx
mov    %rdi,0x20(%rsp)
mov    %ebx,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%r12
lea    0x8(%rbx),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%rbp
lea    0x10(%rbx),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%r13
lea    0x18(%rbx),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%r14
lea    0x20(%rbx),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,0x18(%rsp)
lea    0x28(%rbx),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,0x10(%rsp)
lea    0x30(%rbx),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,%r15
lea    0x38(%rbx),%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %rax,0x8(%rsp)
add    $0x40,%ebx
mov    %ebx,%edi
mov    $0x8,%esi
call   1030 <_br2_load@plt>
mov    %r12,%rdx
mov    %r12,%rcx
shr    $0x3a,%rcx
add    %rbp,%rcx
mov    %rcx,%rbp
shr    $0x3a,%rbp
add    %r13,%rbp
mov    %rbp,%r13
shr    $0x3a,%r13
add    %r14,%r13
mov    %r13,%r12
shr    $0x3a,%r12
add    0x18(%rsp),%r12
mov    %r12,%r14
shr    $0x3a,%r14
add    0x10(%rsp),%r14
mov    %r14,%rsi
shr    $0x3a,%rsi
add    %r15,%rsi
mov    %rsi,%rdi
mov    %rsi,%r8
shr    $0x3a,%rdi
add    0x8(%rsp),%rdi
mov    %rdi,%rsi
shr    $0x3a,%rsi
add    %rax,%rsi
movabs $0x3ffffffffffffff,%rax
ff ff 03
and    %rax,%rdx
movabs $0x1ffffffffffffff,%rbx
ff ff 01
and    %rsi,%rbx
mov    %rbx,0x18(%rsp)
shr    $0x39,%rsi
add    %rdx,%rsi
mov    %rsi,%rdx
shr    $0x3a,%rdx
and    %rax,%rcx
add    %rdx,%rcx
and    %rax,%rsi
mov    %rcx,%r15
and    %rax,%r15
shr    $0x3a,%rcx
and    %rax,%rbp
add    %rcx,%rbp
and    %rax,%r13
and    %rax,%r12
and    %rax,%r14
and    %rax,%r8
mov    %r8,0x8(%rsp)
and    %rax,%rdi
mov    %rdi,0x10(%rsp)
mov    0x20(%rsp),%rbx
mov    %ebx,%edi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x8(%rbx),%edi
mov    %r15,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x10(%rbx),%edi
mov    %rbp,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x18(%rbx),%edi
mov    %r13,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x20(%rbx),%edi
mov    %r12,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x28(%rbx),%edi
mov    %r14,%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x30(%rbx),%edi
mov    0x8(%rsp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
lea    0x38(%rbx),%edi
mov    0x10(%rsp),%rsi
mov    $0x8,%edx
call   1040 <_br2_store@plt>
mov    %rbx,%rdi
add    $0x40,%edi
mov    0x18(%rsp),%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_p521_carry(i64 %0, i64 %1) {
%3 = alloca i64
%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
%27 = alloca i64
%28 = alloca i64
%29 = alloca i64
%30 = alloca i64
%31 = alloca i64
%32 = alloca i64
%33 = alloca i64
%34 = alloca i64
%35 = alloca i64
%36 = alloca i64
%37 = alloca i64
%38 = alloca i64
%39 = alloca i64
%40 = alloca i64
%41 = alloca i64
%42 = alloca i64
store i64 %0, i64* %3
store i64 %1, i64* %4
%43 = load i64, i64* %4
%44 = add i64 %43, 0
%45 = trunc i64 %44 to i32
%46 = call i64 @_br2_load(i32 %45, i32 8)
store i64 %46, i64* %5
%47 = load i64, i64* %4
%48 = add i64 %47, 8
%49 = trunc i64 %48 to i32
%50 = call i64 @_br2_load(i32 %49, i32 8)
store i64 %50, i64* %6
%51 = load i64, i64* %4
%52 = add i64 %51, 16
%53 = trunc i64 %52 to i32
%54 = call i64 @_br2_load(i32 %53, i32 8)
store i64 %54, i64* %7
%55 = load i64, i64* %4
%56 = add i64 %55, 24
%57 = trunc i64 %56 to i32
%58 = call i64 @_br2_load(i32 %57, i32 8)
store i64 %58, i64* %8
%59 = load i64, i64* %4
%60 = add i64 %59, 32
%61 = trunc i64 %60 to i32
%62 = call i64 @_br2_load(i32 %61, i32 8)
store i64 %62, i64* %9
%63 = load i64, i64* %4
%64 = add i64 %63, 40
%65 = trunc i64 %64 to i32
%66 = call i64 @_br2_load(i32 %65, i32 8)
store i64 %66, i64* %10
%67 = load i64, i64* %4
%68 = add i64 %67, 48
%69 = trunc i64 %68 to i32
%70 = call i64 @_br2_load(i32 %69, i32 8)
store i64 %70, i64* %11
%71 = load i64, i64* %4
%72 = add i64 %71, 56
%73 = trunc i64 %72 to i32
%74 = call i64 @_br2_load(i32 %73, i32 8)
store i64 %74, i64* %12
%75 = load i64, i64* %4
%76 = add i64 %75, 64
%77 = trunc i64 %76 to i32
%78 = call i64 @_br2_load(i32 %77, i32 8)
store i64 %78, i64* %13
%79 = load i64, i64* %5
store i64 %79, i64* %14
%80 = load i64, i64* %14
%81 = lshr i64 %80, 58
%82 = load i64, i64* %6
%83 = add i64 %81, %82
store i64 %83, i64* %15
%84 = load i64, i64* %15
%85 = lshr i64 %84, 58
%86 = load i64, i64* %7
%87 = add i64 %85, %86
store i64 %87, i64* %18
%88 = load i64, i64* %18
%89 = lshr i64 %88, 58
%90 = load i64, i64* %8
%91 = add i64 %89, %90
store i64 %91, i64* %19
%92 = load i64, i64* %19
%93 = lshr i64 %92, 58
%94 = load i64, i64* %9
%95 = add i64 %93, %94
store i64 %95, i64* %20
%96 = load i64, i64* %20
%97 = lshr i64 %96, 58
%98 = load i64, i64* %10
%99 = add i64 %97, %98
store i64 %99, i64* %21
%100 = load i64, i64* %21
%101 = lshr i64 %100, 58
%102 = load i64, i64* %11
%103 = add i64 %101, %102
store i64 %103, i64* %22
%104 = load i64, i64* %22
%105 = lshr i64 %104, 58
%106 = load i64, i64* %12
%107 = add i64 %105, %106
store i64 %107, i64* %23
%108 = load i64, i64* %23
%109 = lshr i64 %108, 58
%110 = load i64, i64* %13
%111 = add i64 %109, %110
store i64 %111, i64* %24
%112 = load i64, i64* %14
%113 = and i64 %112, 288230376151711743
%114 = load i64, i64* %24
%115 = lshr i64 %114, 57
%116 = add i64 %113, %115
store i64 %116, i64* %16
%117 = load i64, i64* %16
%118 = lshr i64 %117, 58
%119 = load i64, i64* %15
%120 = and i64 %119, 288230376151711743
%121 = add i64 %118, %120
store i64 %121, i64* %17
%122 = load i64, i64* %16
%123 = and i64 %122, 288230376151711743
store i64 %123, i64* %25
%124 = load i64, i64* %17
%125 = and i64 %124, 288230376151711743
store i64 %125, i64* %26
%126 = load i64, i64* %17
%127 = lshr i64 %126, 58
%128 = load i64, i64* %18
%129 = and i64 %128, 288230376151711743
%130 = add i64 %127, %129
store i64 %130, i64* %27
%131 = load i64, i64* %19
%132 = and i64 %131, 288230376151711743
store i64 %132, i64* %28
%133 = load i64, i64* %20
%134 = and i64 %133, 288230376151711743
store i64 %134, i64* %29
%135 = load i64, i64* %21
%136 = and i64 %135, 288230376151711743
store i64 %136, i64* %30
%137 = load i64, i64* %22
%138 = and i64 %137, 288230376151711743
store i64 %138, i64* %31
%139 = load i64, i64* %23
%140 = and i64 %139, 288230376151711743
store i64 %140, i64* %32
%141 = load i64, i64* %24
%142 = and i64 %141, 144115188075855871
store i64 %142, i64* %33
%143 = load i64, i64* %25
store i64 %143, i64* %34
%144 = load i64, i64* %26
store i64 %144, i64* %35
%145 = load i64, i64* %27
store i64 %145, i64* %36
%146 = load i64, i64* %28
store i64 %146, i64* %37
%147 = load i64, i64* %29
store i64 %147, i64* %38
%148 = load i64, i64* %30
store i64 %148, i64* %39
%149 = load i64, i64* %31
store i64 %149, i64* %40
%150 = load i64, i64* %32
store i64 %150, i64* %41
%151 = load i64, i64* %33
store i64 %151, i64* %42
%152 = load i64, i64* %3
%153 = add i64 %152, 0
%154 = trunc i64 %153 to i32
%155 = load i64, i64* %34
%156 = call i32 @_br2_store(i32 %154, i64 %155, i32 8)
%157 = load i64, i64* %3
%158 = add i64 %157, 8
%159 = trunc i64 %158 to i32
%160 = load i64, i64* %35
%161 = call i32 @_br2_store(i32 %159, i64 %160, i32 8)
%162 = load i64, i64* %3
%163 = add i64 %162, 16
%164 = trunc i64 %163 to i32
%165 = load i64, i64* %36
%166 = call i32 @_br2_store(i32 %164, i64 %165, i32 8)
%167 = load i64, i64* %3
%168 = add i64 %167, 24
%169 = trunc i64 %168 to i32
%170 = load i64, i64* %37
%171 = call i32 @_br2_store(i32 %169, i64 %170, i32 8)
%172 = load i64, i64* %3
%173 = add i64 %172, 32
%174 = trunc i64 %173 to i32
%175 = load i64, i64* %38
%176 = call i32 @_br2_store(i32 %174, i64 %175, i32 8)
%177 = load i64, i64* %3
%178 = add i64 %177, 40
%179 = trunc i64 %178 to i32
%180 = load i64, i64* %39
%181 = call i32 @_br2_store(i32 %179, i64 %180, i32 8)
%182 = load i64, i64* %3
%183 = add i64 %182, 48
%184 = trunc i64 %183 to i32
%185 = load i64, i64* %40
%186 = call i32 @_br2_store(i32 %184, i64 %185, i32 8)
%187 = load i64, i64* %3
%188 = add i64 %187, 56
%189 = trunc i64 %188 to i32
%190 = load i64, i64* %41
%191 = call i32 @_br2_store(i32 %189, i64 %190, i32 8)
%192 = load i64, i64* %3
%193 = add i64 %192, 64
%194 = trunc i64 %193 to i32
%195 = load i64, i64* %42
%196 = call i32 @_br2_store(i32 %194, i64 %195, i32 8)
ret void
}

LLVM IR (-O2):
define void @internal_fiat_p521_carry(i64 %0, i64 %1) {
%3 = trunc i64 %1 to i32
%4 = tail call i64 @_br2_load(i32 %3, i32 8)
%5 = add i32 %3, 8
%6 = tail call i64 @_br2_load(i32 %5, i32 8)
%7 = add i32 %3, 16
%8 = tail call i64 @_br2_load(i32 %7, i32 8)
%9 = add i32 %3, 24
%10 = tail call i64 @_br2_load(i32 %9, i32 8)
%11 = add i32 %3, 32
%12 = tail call i64 @_br2_load(i32 %11, i32 8)
%13 = add i32 %3, 40
%14 = tail call i64 @_br2_load(i32 %13, i32 8)
%15 = add i32 %3, 48
%16 = tail call i64 @_br2_load(i32 %15, i32 8)
%17 = add i32 %3, 56
%18 = tail call i64 @_br2_load(i32 %17, i32 8)
%19 = add i32 %3, 64
%20 = tail call i64 @_br2_load(i32 %19, i32 8)
%21 = lshr i64 %4, 58
%22 = add i64 %21, %6
%23 = lshr i64 %22, 58
%24 = add i64 %23, %8
%25 = lshr i64 %24, 58
%26 = add i64 %25, %10
%27 = lshr i64 %26, 58
%28 = add i64 %27, %12
%29 = lshr i64 %28, 58
%30 = add i64 %29, %14
%31 = lshr i64 %30, 58
%32 = add i64 %31, %16
%33 = lshr i64 %32, 58
%34 = add i64 %33, %18
%35 = lshr i64 %34, 58
%36 = add i64 %35, %20
%37 = and i64 %4, 288230376151711743
%38 = lshr i64 %36, 57
%39 = add nuw nsw i64 %38, %37
%40 = lshr i64 %39, 58
%41 = and i64 %22, 288230376151711743
%42 = add nuw nsw i64 %40, %41
%43 = and i64 %39, 288230376151711743
%44 = and i64 %42, 288230376151711743
%45 = lshr i64 %42, 58
%46 = and i64 %24, 288230376151711743
%47 = add nuw nsw i64 %45, %46
%48 = and i64 %26, 288230376151711743
%49 = and i64 %28, 288230376151711743
%50 = and i64 %30, 288230376151711743
%51 = and i64 %32, 288230376151711743
%52 = and i64 %34, 288230376151711743
%53 = and i64 %36, 144115188075855871
%54 = trunc i64 %0 to i32
%55 = tail call i32 @_br2_store(i32 %54, i64 %43, i32 8)
%56 = add i32 %54, 8
%57 = tail call i32 @_br2_store(i32 %56, i64 %44, i32 8)
%58 = add i32 %54, 16
%59 = tail call i32 @_br2_store(i32 %58, i64 %47, i32 8)
%60 = add i32 %54, 24
%61 = tail call i32 @_br2_store(i32 %60, i64 %48, i32 8)
%62 = add i32 %54, 32
%63 = tail call i32 @_br2_store(i32 %62, i64 %49, i32 8)
%64 = add i32 %54, 40
%65 = tail call i32 @_br2_store(i32 %64, i64 %50, i32 8)
%66 = add i32 %54, 48
%67 = tail call i32 @_br2_store(i32 %66, i64 %51, i32 8)
%68 = add i32 %54, 56
%69 = tail call i32 @_br2_store(i32 %68, i64 %52, i32 8)
%70 = add i32 %54, 64
%71 = tail call i32 @_br2_store(i32 %70, i64 %53, i32 8)
ret void
}