#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(double, double, double, double, double, int);
int /*<<< orphan*/ endrotate();
int /*<<< orphan*/ endxlate();
int /*<<< orphan*/ rotate(int, int /*<<< orphan*/, int /*<<< orphan*/, int);
int /*<<< orphan*/ xlate(int /*<<< orphan*/, double, int /*<<< orphan*/);
void buttress_array_pair(double width, double length, double height,
                         double angle, double spacing, int count,
                         double span_between_arrays) {
  xlate(0, -span_between_arrays / 2.0, 0);
  buttress_array(width, length, height, angle, spacing, count);
  endxlate();
  rotate(180, 0, 0, 1);
  xlate(0, -span_between_arrays / 2.0, 0);
  buttress_array(width, length, height, angle, spacing, count);
  endxlate();
  endrotate();
}


x86 assembly (clang, -O0):
<buttress_array_pair>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movsd  %xmm0,-0x8(%rbp)
movsd  %xmm1,-0x10(%rbp)
movsd  %xmm2,-0x18(%rbp)
movsd  %xmm3,-0x20(%rbp)
movsd  %xmm4,-0x28(%rbp)
mov    %edi,-0x2c(%rbp)
movsd  %xmm5,-0x38(%rbp)
movsd  -0x38(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  0xe63(%rip),%xmm1
divsd  %xmm1,%xmm0
xor    %esi,%esi
mov    %esi,%edi
call   1030 <xlate@plt>
movsd  -0x8(%rbp),%xmm0
movsd  -0x10(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm3
movsd  -0x28(%rbp),%xmm4
mov    -0x2c(%rbp),%edi
call   1070 <buttress_array@plt>
mov    $0x0,%al
call   1060 <endxlate@plt>
mov    $0xb4,%edi
xor    %edx,%edx
mov    $0x1,%ecx
mov    %edx,%esi
call   1040 <rotate@plt>
movsd  -0x38(%rbp),%xmm0
movq   %xmm0,%rax
movabs $0x8000000000000000,%rcx
xor    %rcx,%rax
movq   %rax,%xmm0
movsd  0xdf7(%rip),%xmm1
divsd  %xmm1,%xmm0
xor    %esi,%esi
mov    %esi,%edi
call   1030 <xlate@plt>
movsd  -0x8(%rbp),%xmm0
movsd  -0x10(%rbp),%xmm1
movsd  -0x18(%rbp),%xmm2
movsd  -0x20(%rbp),%xmm3
movsd  -0x28(%rbp),%xmm4
mov    -0x2c(%rbp),%edi
call   1070 <buttress_array@plt>
mov    $0x0,%al
call   1060 <endxlate@plt>
mov    $0x0,%al
call   1050 <endrotate@plt>
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<buttress_array_pair>:
push   %rbx
sub    $0x30,%rsp
mov    %edi,%ebx
movsd  %xmm4,0x20(%rsp)
movsd  %xmm3,0x18(%rsp)
movsd  %xmm2,0x10(%rsp)
movsd  %xmm1,0x8(%rsp)
movsd  %xmm0,(%rsp)
movapd %xmm5,%xmm0
mulsd  0xe80(%rip),%xmm0
movsd  %xmm0,0x28(%rsp)
xor    %edi,%edi
xor    %esi,%esi
call   1030 <xlate@plt>
movsd  (%rsp),%xmm0
movsd  0x8(%rsp),%xmm1
movsd  0x10(%rsp),%xmm2
movsd  0x18(%rsp),%xmm3
movsd  0x20(%rsp),%xmm4
mov    %ebx,%edi
call   1070 <buttress_array@plt>
xor    %eax,%eax
call   1060 <endxlate@plt>
mov    $0xb4,%edi
xor    %esi,%esi
xor    %edx,%edx
mov    $0x1,%ecx
call   1040 <rotate@plt>
xor    %edi,%edi
movsd  0x28(%rsp),%xmm0
xor    %esi,%esi
call   1030 <xlate@plt>
movsd  (%rsp),%xmm0
movsd  0x8(%rsp),%xmm1
movsd  0x10(%rsp),%xmm2
movsd  0x18(%rsp),%xmm3
movsd  0x20(%rsp),%xmm4
mov    %ebx,%edi
call   1070 <buttress_array@plt>
xor    %eax,%eax
call   1060 <endxlate@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbx
jmp    1050 <endrotate@plt>

LLVM IR (-O0):
define void @buttress_array_pair(double %0, double %1, double %2, double %3, double %4, i32 %5, double %6) {
%8 = alloca double
%9 = alloca double
%10 = alloca double
%11 = alloca double
%12 = alloca double
%13 = alloca i32
%14 = alloca double
store double %0, double* %8
store double %1, double* %9
store double %2, double* %10
store double %3, double* %11
store double %4, double* %12
store i32 %5, i32* %13
store double %6, double* %14
%15 = load double, double* %14
%16 = fneg double %15
%17 = fdiv double %16, 2.000000e+00
%18 = call i32 @xlate(i32 0, double %17, i32 0)
%19 = load double, double* %8
%20 = load double, double* %9
%21 = load double, double* %10
%22 = load double, double* %11
%23 = load double, double* %12
%24 = load i32, i32* %13
%25 = call i32 @buttress_array(double %19, double %20, double %21, double %22, double %23, i32 %24)
%26 = call i32 (...) @endxlate()
%27 = call i32 @rotate(i32 180, i32 0, i32 0, i32 1)
%28 = load double, double* %14
%29 = fneg double %28
%30 = fdiv double %29, 2.000000e+00
%31 = call i32 @xlate(i32 0, double %30, i32 0)
%32 = load double, double* %8
%33 = load double, double* %9
%34 = load double, double* %10
%35 = load double, double* %11
%36 = load double, double* %12
%37 = load i32, i32* %13
%38 = call i32 @buttress_array(double %32, double %33, double %34, double %35, double %36, i32 %37)
%39 = call i32 (...) @endxlate()
%40 = call i32 (...) @endrotate()
ret void
}

LLVM IR (-O2):
define void @buttress_array_pair(double %0, double %1, double %2, double %3, double %4, i32 %5, double %6) {
%8 = fmul double %6, -5.000000e-01
%9 = tail call i32 @xlate(i32 0, double %8, i32 0)
%10 = tail call i32 @buttress_array(double %0, double %1, double %2, double %3, double %4, i32 %5)
%11 = tail call i32 (...) @endxlate()
%12 = tail call i32 @rotate(i32 180, i32 0, i32 0, i32 1)
%13 = tail call i32 @xlate(i32 0, double %8, i32 0)
%14 = tail call i32 @buttress_array(double %0, double %1, double %2, double %3, double %4, i32 %5)
%15 = tail call i32 (...) @endxlate()
%16 = tail call i32 (...) @endrotate()
ret void
}