#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*/ buttress_array_pair(double, double, double, double, double,
                                       int, double);
int /*<<< orphan*/ cube(double, double, double, int);
int /*<<< orphan*/ endonion();
int /*<<< orphan*/ endrotate();
int /*<<< orphan*/ endxlate();
int /*<<< orphan*/ onion();
int /*<<< orphan*/ rotate(int, int /*<<< orphan*/, int /*<<< orphan*/, int);
int /*<<< orphan*/ xlate(int /*<<< orphan*/, int /*<<< orphan*/, double);
void buttressed_foundation(double width, double length, double height,
                           double buttress_angle, double buttress_interval) {
  onion();
  xlate(0, 0, height / 2.0);
  cube(length, width, height, 1);
  endxlate();
  buttress_array_pair(length * 0.10, width * 0.2, height, buttress_angle,
                      (length / 5.0) * 0.9, 5, width * 0.85);
  rotate(90, 0, 0, 1);
  buttress_array_pair(width * 0.05, length * 0.2, height, buttress_angle,
                      (width / 5.0) * 0.9, 5, length * 0.85);
  endrotate();
  endonion();
}


x86 assembly (clang, -O0):
<buttressed_foundation>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm2,-0x18(%rbp)
movsd  %xmm3,-0x20(%rbp)
movsd  %xmm4,-0x28(%rbp)
mov    $0x0,%al
call   1040 <onion@plt>
movsd  -0x18(%rbp),%xmm0
movsd  0xe7b(%rip),%xmm1
divsd  %xmm1,%xmm0
xor    %esi,%esi
mov    %esi,%edi
call   1030 <xlate@plt>
movsd  -0x10(%rbp),%xmm0
movsd  -0x8(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm2
mov    $0x1,%edi
call   10a0 <cube@plt>
mov    $0x0,%al
call   1070 <endxlate@plt>
movsd  0xe3e(%rip),%xmm0
mulsd  -0x10(%rbp),%xmm0
movsd  0xe21(%rip),%xmm1
mulsd  -0x8(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm3
movsd  -0x10(%rbp),%xmm4
movsd  0xdfd(%rip),%xmm5
divsd  %xmm5,%xmm4
movsd  0xde9(%rip),%xmm5
mulsd  %xmm5,%xmm4
movsd  0xdd5(%rip),%xmm5
mulsd  -0x8(%rbp),%xmm5
mov    $0x5,%edi
call   1090 <buttress_array_pair@plt>
mov    $0x5a,%edi
xor    %edx,%edx
mov    $0x1,%ecx
mov    %edx,%esi
call   1050 <rotate@plt>
movsd  0xdcb(%rip),%xmm0
mulsd  -0x8(%rbp),%xmm0
movsd  0xdb6(%rip),%xmm1
mulsd  -0x10(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm3
movsd  -0x8(%rbp),%xmm4
movsd  0xd92(%rip),%xmm5
divsd  %xmm5,%xmm4
movsd  0xd7e(%rip),%xmm5
mulsd  %xmm5,%xmm4
movsd  0xd6a(%rip),%xmm5
mulsd  -0x10(%rbp),%xmm5
mov    $0x5,%edi
call   1090 <buttress_array_pair@plt>
mov    $0x0,%al
call   1060 <endrotate@plt>
mov    $0x0,%al
call   1080 <endonion@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<buttressed_foundation>:
sub    $0x28,%rsp
movsd  %xmm3,0x20(%rsp)
movsd  %xmm2,0x8(%rsp)
movsd  %xmm1,0x10(%rsp)
movsd  %xmm0,0x18(%rsp)
xor    %eax,%eax
call   1040 <onion@plt>
movsd  0xe55(%rip),%xmm0
mulsd  0x8(%rsp),%xmm0
xor    %edi,%edi
xor    %esi,%esi
call   1030 <xlate@plt>
movsd  0x10(%rsp),%xmm0
movsd  0x18(%rsp),%xmm1
movsd  0x8(%rsp),%xmm2
mov    $0x1,%edi
call   10a0 <cube@plt>
xor    %eax,%eax
call   1070 <endxlate@plt>
movsd  0xe23(%rip),%xmm0
movsd  0x10(%rsp),%xmm4
mulsd  %xmm4,%xmm0
movsd  0x18(%rsp),%xmm5
movapd %xmm5,%xmm1
mulsd  0xe0f(%rip),%xmm1
divsd  0xe0f(%rip),%xmm4
mulsd  0xe0f(%rip),%xmm4
mulsd  0xe0f(%rip),%xmm5
movsd  0x8(%rsp),%xmm2
movsd  0x20(%rsp),%xmm3
mov    $0x5,%edi
call   1090 <buttress_array_pair@plt>
mov    $0x5a,%edi
xor    %esi,%esi
xor    %edx,%edx
mov    $0x1,%ecx
call   1050 <rotate@plt>
movsd  0xde6(%rip),%xmm0
movsd  0x18(%rsp),%xmm4
mulsd  %xmm4,%xmm0
movsd  0x10(%rsp),%xmm5
movsd  0xdae(%rip),%xmm1
mulsd  %xmm5,%xmm1
divsd  0xdaa(%rip),%xmm4
mulsd  0xdaa(%rip),%xmm4
mulsd  0xdaa(%rip),%xmm5
movsd  0x8(%rsp),%xmm2
movsd  0x20(%rsp),%xmm3
mov    $0x5,%edi
call   1090 <buttress_array_pair@plt>
xor    %eax,%eax
call   1060 <endrotate@plt>
xor    %eax,%eax
add    $0x28,%rsp
jmp    1080 <endonion@plt>

LLVM IR (-O0):
define void @buttressed_foundation(double %0, double %1, double %2, double %3, double %4) {
%6 = alloca double
%7 = alloca double
%8 = alloca double
%9 = alloca double
%10 = alloca double
store double %0, double* %6
store double %1, double* %7
store double %2, double* %8
store double %3, double* %9
store double %4, double* %10
%11 = call i32 (...) @onion()
%12 = load double, double* %8
%13 = fdiv double %12, 2.000000e+00
%14 = call i32 @xlate(i32 0, i32 0, double %13)
%15 = load double, double* %7
%16 = load double, double* %6
%17 = load double, double* %8
%18 = call i32 @cube(double %15, double %16, double %17, i32 1)
%19 = call i32 (...) @endxlate()
%20 = load double, double* %7
%21 = fmul double %20, 1.000000e-01
%22 = load double, double* %6
%23 = fmul double %22, 2.000000e-01
%24 = load double, double* %8
%25 = load double, double* %9
%26 = load double, double* %7
%27 = fdiv double %26, 5.000000e+00
%28 = fmul double %27, 9.000000e-01
%29 = load double, double* %6
%30 = fmul double %29, 8.500000e-01
%31 = call i32 @buttress_array_pair(double %21, double %23, double %24, double %25, double %28, i32 5, double %30)
%32 = call i32 @rotate(i32 90, i32 0, i32 0, i32 1)
%33 = load double, double* %6
%34 = fmul double %33, 5.000000e-02
%35 = load double, double* %7
%36 = fmul double %35, 2.000000e-01
%37 = load double, double* %8
%38 = load double, double* %9
%39 = load double, double* %6
%40 = fdiv double %39, 5.000000e+00
%41 = fmul double %40, 9.000000e-01
%42 = load double, double* %7
%43 = fmul double %42, 8.500000e-01
%44 = call i32 @buttress_array_pair(double %34, double %36, double %37, double %38, double %41, i32 5, double %43)
%45 = call i32 (...) @endrotate()
%46 = call i32 (...) @endonion()
ret void
}

LLVM IR (-O2):
define void @buttressed_foundation(double %0, double %1, double %2, double %3, double %4) {
%6 = tail call i32 (...) @onion()
%7 = fmul double %2, 5.000000e-01
%8 = tail call i32 @xlate(i32 0, i32 0, double %7)
%9 = tail call i32 @cube(double %1, double %0, double %2, i32 1)
%10 = tail call i32 (...) @endxlate()
%11 = fmul double %1, 1.000000e-01
%12 = fmul double %0, 2.000000e-01
%13 = fdiv double %1, 5.000000e+00
%14 = fmul double %13, 9.000000e-01
%15 = fmul double %0, 8.500000e-01
%16 = tail call i32 @buttress_array_pair(double %11, double %12, double %2, double %3, double %14, i32 5, double %15)
%17 = tail call i32 @rotate(i32 90, i32 0, i32 0, i32 1)
%18 = fmul double %0, 5.000000e-02
%19 = fmul double %1, 2.000000e-01
%20 = fdiv double %0, 5.000000e+00
%21 = fmul double %20, 9.000000e-01
%22 = fmul double %1, 8.500000e-01
%23 = tail call i32 @buttress_array_pair(double %18, double %19, double %2, double %3, double %21, i32 5, double %22)
%24 = tail call i32 (...) @endrotate()
%25 = tail call i32 (...) @endonion()
ret void
}