#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 */

/* Variables and functions */
int /*<<< orphan*/ myfunction1(int ***);
int main(void) {
  int apricout[2][3][5] = {};
  myfunction1(apricout);
  myfunction1(apricout);
  myfunction1(apricout);
  int(*p)[3][5] = apricout;
  myfunction1(p);
  myfunction1(p);
  myfunction1(p);
  int(*q)[2][3][5] = &apricout;
  myfunction1(*q);
  myfunction1(*q);
  myfunction1(*q);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x90,%rsp
movl   $0x0,-0x4(%rbp)
lea    -0x80(%rbp),%rdi
xor    %esi,%esi
mov    $0x78,%edx
call   1030 <memset@plt>
lea    -0x80(%rbp),%rdi
call   1040 <myfunction1@plt>
lea    -0x80(%rbp),%rdi
call   1040 <myfunction1@plt>
lea    -0x80(%rbp),%rdi
call   1040 <myfunction1@plt>
lea    -0x80(%rbp),%rax
mov    %rax,-0x88(%rbp)
mov    -0x88(%rbp),%rdi
call   1040 <myfunction1@plt>
mov    -0x88(%rbp),%rdi
call   1040 <myfunction1@plt>
mov    -0x88(%rbp),%rdi
call   1040 <myfunction1@plt>
lea    -0x80(%rbp),%rax
mov    %rax,-0x90(%rbp)
mov    -0x90(%rbp),%rdi
call   1040 <myfunction1@plt>
mov    -0x90(%rbp),%rdi
call   1040 <myfunction1@plt>
mov    -0x90(%rbp),%rdi
call   1040 <myfunction1@plt>
xor    %eax,%eax
add    $0x90,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x80,%rsp
xorps  %xmm0,%xmm0
movaps %xmm0,0x60(%rsp)
movaps %xmm0,0x50(%rsp)
movaps %xmm0,0x40(%rsp)
movaps %xmm0,0x30(%rsp)
movaps %xmm0,0x20(%rsp)
movaps %xmm0,0x10(%rsp)
movaps %xmm0,(%rsp)
movq   $0x0,0x70(%rsp)
mov    %rsp,%rbx
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
mov    %rbx,%rdi
call   1030 <myfunction1@plt>
xor    %eax,%eax
add    $0x80,%rsp
pop    %rbx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca [2 x [3 x [5 x i32]]]
%3 = alloca [3 x [5 x i32]]*
%4 = alloca [2 x [3 x [5 x i32]]]*
store i32 0, i32* %1
%5 = bitcast [2 x [3 x [5 x i32]]]* %2 to i8*
%6 = getelementptr inbounds [2 x [3 x [5 x i32]]], [2 x [3 x [5 x i32]]]* %2, i64 0, i64 0
%7 = bitcast [3 x [5 x i32]]* %6 to i32***
%8 = call i32 @myfunction1(i32*** %7)
%9 = getelementptr inbounds [2 x [3 x [5 x i32]]], [2 x [3 x [5 x i32]]]* %2, i64 0, i64 0
%10 = bitcast [3 x [5 x i32]]* %9 to i32***
%11 = call i32 @myfunction1(i32*** %10)
%12 = getelementptr inbounds [2 x [3 x [5 x i32]]], [2 x [3 x [5 x i32]]]* %2, i64 0, i64 0
%13 = bitcast [3 x [5 x i32]]* %12 to i32***
%14 = call i32 @myfunction1(i32*** %13)
%15 = getelementptr inbounds [2 x [3 x [5 x i32]]], [2 x [3 x [5 x i32]]]* %2, i64 0, i64 0
store [3 x [5 x i32]]* %15, [3 x [5 x i32]]** %3
%16 = load [3 x [5 x i32]]*, [3 x [5 x i32]]** %3
%17 = bitcast [3 x [5 x i32]]* %16 to i32***
%18 = call i32 @myfunction1(i32*** %17)
%19 = load [3 x [5 x i32]]*, [3 x [5 x i32]]** %3
%20 = bitcast [3 x [5 x i32]]* %19 to i32***
%21 = call i32 @myfunction1(i32*** %20)
%22 = load [3 x [5 x i32]]*, [3 x [5 x i32]]** %3
%23 = bitcast [3 x [5 x i32]]* %22 to i32***
%24 = call i32 @myfunction1(i32*** %23)
store [2 x [3 x [5 x i32]]]* %2, [2 x [3 x [5 x i32]]]** %4
%25 = load [2 x [3 x [5 x i32]]]*, [2 x [3 x [5 x i32]]]** %4
%26 = getelementptr inbounds [2 x [3 x [5 x i32]]], [2 x [3 x [5 x i32]]]* %25, i64 0, i64 0
%27 = bitcast [3 x [5 x i32]]* %26 to i32***
%28 = call i32 @myfunction1(i32*** %27)
%29 = load [2 x [3 x [5 x i32]]]*, [2 x [3 x [5 x i32]]]** %4
%30 = getelementptr inbounds [2 x [3 x [5 x i32]]], [2 x [3 x [5 x i32]]]* %29, i64 0, i64 0
%31 = bitcast [3 x [5 x i32]]* %30 to i32***
%32 = call i32 @myfunction1(i32*** %31)
%33 = load [2 x [3 x [5 x i32]]]*, [2 x [3 x [5 x i32]]]** %4
%34 = getelementptr inbounds [2 x [3 x [5 x i32]]], [2 x [3 x [5 x i32]]]* %33, i64 0, i64 0
%35 = bitcast [3 x [5 x i32]]* %34 to i32***
%36 = call i32 @myfunction1(i32*** %35)
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = alloca [2 x [3 x [5 x i32]]]
%2 = bitcast [2 x [3 x [5 x i32]]]* %1 to i8*
%3 = bitcast [2 x [3 x [5 x i32]]]* %1 to i32***
%4 = call i32 @myfunction1(i32*** %3)
%5 = call i32 @myfunction1(i32*** %3)
%6 = call i32 @myfunction1(i32*** %3)
%7 = call i32 @myfunction1(i32*** %3)
%8 = call i32 @myfunction1(i32*** %3)
%9 = call i32 @myfunction1(i32*** %3)
%10 = call i32 @myfunction1(i32*** %3)
%11 = call i32 @myfunction1(i32*** %3)
%12 = call i32 @myfunction1(i32*** %3)
ret i32 0
}