#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 */
struct pstruct {
  int dummy;
};
struct f_struct {
  int dummy;
};
struct dyn_string_str {
  int dummy;
};
struct annot_str {
  int dummy;
};
struct a_struct {
  int dummy;
};
struct a_res_str {
  int dummy;
};

/* Variables and functions */
int calc_cons_u(unsigned char const *, int, unsigned char const *, int,
                struct a_res_str *, struct pstruct *, struct f_struct *, void *,
                unsigned char const *, unsigned char const *,
                struct annot_str const *, unsigned char const *,
                struct annot_str const *, int, int, int *, int /*<<< orphan*/ *,
                int /*<<< orphan*/ *, int /*<<< orphan*/ *,
                int /*<<< orphan*/ *, int /*<<< orphan*/ *,
                int /*<<< orphan*/ *, struct a_struct *, int *,
                struct dyn_string_str *, struct dyn_string_str *);
int calc_code(const unsigned char *aa0, int n0, const unsigned char *aa1,
              int n1, struct a_struct *aln, struct a_res_str *a_res,
              struct pstruct *ppst, struct dyn_string_str *align_code_dyn,
              const unsigned char *ann_arr, const unsigned char *aa0a,
              const struct annot_str *annot0_p, const unsigned char *aa1a,
              const struct annot_str *annot1_p,
              struct dyn_string_str *annot_code_dyn, int *score_delta,
              struct f_struct *f_str, void *pstat_void, int display_code) {
  int nc;
  return calc_cons_u(aa0, n0, aa1, n1, a_res, ppst, f_str, pstat_void, ann_arr,
                     aa0a, annot0_p, aa1a, annot1_p, 2, display_code, &nc, NULL,
                     NULL, NULL, NULL, NULL, NULL, aln, score_delta,
                     annot_code_dyn, align_code_dyn);
}


x86 assembly (clang, -O0):
<calc_code>:
push   %rbp
mov    %rsp,%rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x108,%rsp
mov    0x68(%rbp),%eax
mov    0x60(%rbp),%rax
mov    0x58(%rbp),%rax
mov    0x50(%rbp),%rax
mov    0x48(%rbp),%rax
mov    0x40(%rbp),%rax
mov    0x38(%rbp),%rax
mov    0x30(%rbp),%rax
mov    0x28(%rbp),%rax
mov    0x20(%rbp),%rax
mov    0x18(%rbp),%rax
mov    0x10(%rbp),%rax
mov    %rdi,-0x30(%rbp)
mov    %esi,-0x34(%rbp)
mov    %rdx,-0x40(%rbp)
mov    %ecx,-0x44(%rbp)
mov    %r8,-0x50(%rbp)
mov    %r9,-0x58(%rbp)
mov    -0x30(%rbp),%rdi
mov    -0x34(%rbp),%esi
mov    -0x40(%rbp),%rdx
mov    -0x44(%rbp),%ecx
mov    -0x58(%rbp),%r8
mov    0x10(%rbp),%r9
mov    0x58(%rbp),%rax
mov    %rax,-0x90(%rbp)
mov    0x60(%rbp),%rax
mov    %rax,-0x88(%rbp)
mov    0x20(%rbp),%rax
mov    %rax,-0x80(%rbp)
mov    0x28(%rbp),%rax
mov    %rax,-0x78(%rbp)
mov    0x30(%rbp),%rax
mov    %rax,-0x70(%rbp)
mov    0x38(%rbp),%r13
mov    0x40(%rbp),%r12
mov    0x68(%rbp),%r15d
mov    -0x50(%rbp),%rbx
mov    0x50(%rbp),%r11
mov    0x48(%rbp),%r10
mov    0x18(%rbp),%rax
mov    %rax,-0x68(%rbp)
lea    -0x5c(%rbp),%r14
xor    %eax,%eax
mov    -0x90(%rbp),%rax
mov    %rax,(%rsp)
mov    -0x88(%rbp),%rax
mov    %rax,0x8(%rsp)
mov    -0x80(%rbp),%rax
mov    %rax,0x10(%rsp)
mov    -0x78(%rbp),%rax
mov    %rax,0x18(%rsp)
mov    -0x70(%rbp),%rax
mov    %rax,0x20(%rsp)
mov    -0x68(%rbp),%rax
mov    %r13,0x28(%rsp)
mov    %r12,0x30(%rsp)
movl   $0x2,0x38(%rsp)
mov    %r15d,0x40(%rsp)
mov    %r14,0x48(%rsp)
movq   $0x0,0x50(%rsp)
movq   $0x0,0x58(%rsp)
movq   $0x0,0x60(%rsp)
movq   $0x0,0x68(%rsp)
movq   $0x0,0x70(%rsp)
movq   $0x0,0x78(%rsp)
mov    %rbx,0x80(%rsp)
mov    %r11,0x88(%rsp)
mov    %r10,0x90(%rsp)
mov    %rax,0x98(%rsp)
call   1030 <calc_cons_u@plt>
add    $0x108,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

x86 assembly (clang, -O2):
<calc_code>:
push   %r15
push   %r14
push   %rbx
sub    $0xb0,%rsp
mov    %r9,%r15
mov    0xd0(%rsp),%r9
movups 0x118(%rsp),%xmm0
movaps 0xe0(%rsp),%xmm1
movaps 0xf0(%rsp),%xmm2
mov    0x100(%rsp),%r10
mov    0x128(%rsp),%r11d
mov    0x110(%rsp),%r14
mov    0x108(%rsp),%rbx
mov    0xd8(%rsp),%rax
mov    %rax,0x98(%rsp)
mov    %rbx,0x90(%rsp)
mov    %r14,0x88(%rsp)
mov    %r8,0x80(%rsp)
xorps  %xmm3,%xmm3
movups %xmm3,0x70(%rsp)
movups %xmm3,0x60(%rsp)
movups %xmm3,0x50(%rsp)
lea    0xac(%rsp),%rax
mov    %rax,0x48(%rsp)
mov    %r11d,0x40(%rsp)
mov    %r10,0x30(%rsp)
movups %xmm2,0x20(%rsp)
movups %xmm1,0x10(%rsp)
movups %xmm0,(%rsp)
movl   $0x2,0x38(%rsp)
mov    %r15,%r8
call   1030 <calc_cons_u@plt>
add    $0xb0,%rsp
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
%struct.a_struct = type { i32 }
%struct.a_res_str = type { i32 }
%struct.pstruct = type { i32 }
%struct.annot_str = type { i32 }
%struct.dyn_string_str = type { i32 }
%struct.f_struct = type { i32 }
define i32 @calc_code(i8* %0, i32 %1, i8* %2, i32 %3, %struct.a_struct* %4, %struct.a_res_str* %5, %struct.pstruct* %6, %struct.dyn_string_str* %7, i8* %8, i8* %9, %struct.annot_str* %10, i8* %11, %struct.annot_str* %12, %struct.dyn_string_str* %13, i32* %14, %struct.f_struct* %15, i8* %16, i32 %17) {
%19 = alloca i8*
%20 = alloca i32
%21 = alloca i8*
%22 = alloca i32
%23 = alloca %struct.a_struct*
%24 = alloca %struct.a_res_str*
%25 = alloca %struct.pstruct*
%26 = alloca %struct.dyn_string_str*
%27 = alloca i8*
%28 = alloca i8*
%29 = alloca %struct.annot_str*
%30 = alloca i8*
%31 = alloca %struct.annot_str*
%32 = alloca %struct.dyn_string_str*
%33 = alloca i32*
%34 = alloca %struct.f_struct*
%35 = alloca i8*
%36 = alloca i32
%37 = alloca i32
store i8* %0, i8** %19
store i32 %1, i32* %20
store i8* %2, i8** %21
store i32 %3, i32* %22
store %struct.a_struct* %4, %struct.a_struct** %23
store %struct.a_res_str* %5, %struct.a_res_str** %24
store %struct.pstruct* %6, %struct.pstruct** %25
store %struct.dyn_string_str* %7, %struct.dyn_string_str** %26
store i8* %8, i8** %27
store i8* %9, i8** %28
store %struct.annot_str* %10, %struct.annot_str** %29
store i8* %11, i8** %30
store %struct.annot_str* %12, %struct.annot_str** %31
store %struct.dyn_string_str* %13, %struct.dyn_string_str** %32
store i32* %14, i32** %33
store %struct.f_struct* %15, %struct.f_struct** %34
store i8* %16, i8** %35
store i32 %17, i32* %36
%38 = load i8*, i8** %19
%39 = load i32, i32* %20
%40 = load i8*, i8** %21
%41 = load i32, i32* %22
%42 = load %struct.a_res_str*, %struct.a_res_str** %24
%43 = load %struct.pstruct*, %struct.pstruct** %25
%44 = load %struct.f_struct*, %struct.f_struct** %34
%45 = load i8*, i8** %35
%46 = load i8*, i8** %27
%47 = load i8*, i8** %28
%48 = load %struct.annot_str*, %struct.annot_str** %29
%49 = load i8*, i8** %30
%50 = load %struct.annot_str*, %struct.annot_str** %31
%51 = load i32, i32* %36
%52 = load %struct.a_struct*, %struct.a_struct** %23
%53 = load i32*, i32** %33
%54 = load %struct.dyn_string_str*, %struct.dyn_string_str** %32
%55 = load %struct.dyn_string_str*, %struct.dyn_string_str** %26
%56 = call i32 @calc_cons_u(i8* %38, i32 %39, i8* %40, i32 %41, %struct.a_res_str* %42, %struct.pstruct* %43, %struct.f_struct* %44, i8* %45, i8* %46, i8* %47, %struct.annot_str* %48, i8* %49, %struct.annot_str* %50, i32 2, i32 %51, i32* %37, i32* null, i32* null, i32* null, i32* null, i32* null, i32* null, %struct.a_struct* %52, i32* %53, %struct.dyn_string_str* %54, %struct.dyn_string_str* %55)
ret i32 %56
}

LLVM IR (-O2):
%struct.a_struct = type { i32 }
%struct.a_res_str = type { i32 }
%struct.pstruct = type { i32 }
%struct.annot_str = type { i32 }
%struct.dyn_string_str = type { i32 }
%struct.f_struct = type { i32 }
define i32 @calc_code(i8* %0, i32 %1, i8* %2, i32 %3, %struct.a_struct* %4, %struct.a_res_str* %5, %struct.pstruct* %6, %struct.dyn_string_str* %7, i8* %8, i8* %9, %struct.annot_str* %10, i8* %11, %struct.annot_str* %12, %struct.dyn_string_str* %13, i32* %14, %struct.f_struct* %15, i8* %16, i32 %17) {
%19 = alloca i32
%20 = bitcast i32* %19 to i8*
%21 = call i32 @calc_cons_u(i8* %0, i32 %1, i8* %2, i32 %3, %struct.a_res_str* %5, %struct.pstruct* %6, %struct.f_struct* %15, i8* %16, i8* %8, i8* %9, %struct.annot_str* %10, i8* %11, %struct.annot_str* %12, i32 2, i32 %17, i32* %19, i32* null, i32* null, i32* null, i32* null, i32* null, i32* null, %struct.a_struct* %4, i32* %14, %struct.dyn_string_str* %13, %struct.dyn_string_str* %7)
ret i32 %21
}