#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*/ enclosure(int, double, double);
int /*<<< orphan*/ endonion();
int /*<<< orphan*/ endscale();
int /*<<< orphan*/ endxlate();
int /*<<< orphan*/ keep_foundation(int, int, int);
int /*<<< orphan*/ onion();
int /*<<< orphan*/ recursive_keep(int /*<<< orphan*/, int /*<<< orphan*/, int,
                                  int, int, int);
int /*<<< orphan*/ scale(double, double, double);
int /*<<< orphan*/ xlate(int /*<<< orphan*/, int /*<<< orphan*/, int);
void make_castle(void) {
  scale(0.85, 0.85, 0.85);
  onion();
  scale(0.15, 0.15, 0.15);
  onion();
  keep_foundation(350, 200, 150);
  endonion();
  xlate(0, 0, 150);
  recursive_keep(0, 0, 200, 350, 50, 4);
  endxlate();
  endscale();
  enclosure(8, 65.0, 90.0 * (0.33));
  enclosure(6, 38.0, 140.0 * (0.33));
  endonion();
  endscale();
}


x86 assembly (clang, -O0):
<make_castle>:
push   %rbp
mov    %rsp,%rbp
movsd  0xe8c(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1090 <scale@plt>
mov    $0x0,%al
call   1040 <onion@plt>
movsd  0xe6a(%rip),%xmm2
movaps %xmm2,%xmm0
movaps %xmm2,%xmm1
call   1090 <scale@plt>
mov    $0x0,%al
call   1040 <onion@plt>
mov    $0x15e,%edi
mov    $0xc8,%esi
mov    $0x96,%edx
call   1060 <keep_foundation@plt>
mov    $0x0,%al
call   10a0 <endonion@plt>
xor    %esi,%esi
mov    $0x96,%edx
mov    %esi,%edi
call   1030 <xlate@plt>
xor    %esi,%esi
mov    $0xc8,%edx
mov    $0x15e,%ecx
mov    $0x32,%r8d
mov    $0x4,%r9d
mov    %esi,%edi
call   1050 <recursive_keep@plt>
mov    $0x0,%al
call   1080 <endxlate@plt>
mov    $0x0,%al
call   1070 <endscale@plt>
mov    $0x8,%edi
movsd  0xde5(%rip),%xmm0
movsd  0xde5(%rip),%xmm1
call   10b0 <enclosure@plt>
mov    $0x6,%edi
movsd  0xdbb(%rip),%xmm0
movsd  0xdbb(%rip),%xmm1
call   10b0 <enclosure@plt>
mov    $0x0,%al
call   10a0 <endonion@plt>
mov    $0x0,%al
call   1070 <endscale@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<make_castle>:
push   %rax
movsd  0xe67(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1090 <scale@plt>
xor    %eax,%eax
call   1040 <onion@plt>
movsd  0xe55(%rip),%xmm0
movaps %xmm0,%xmm1
movaps %xmm0,%xmm2
call   1090 <scale@plt>
xor    %eax,%eax
call   1040 <onion@plt>
mov    $0x15e,%edi
mov    $0xc8,%esi
mov    $0x96,%edx
call   1060 <keep_foundation@plt>
xor    %eax,%eax
call   10a0 <endonion@plt>
xor    %edi,%edi
xor    %esi,%esi
mov    $0x96,%edx
call   1030 <xlate@plt>
xor    %edi,%edi
xor    %esi,%esi
mov    $0xc8,%edx
mov    $0x15e,%ecx
mov    $0x32,%r8d
mov    $0x4,%r9d
call   1050 <recursive_keep@plt>
xor    %eax,%eax
call   1080 <endxlate@plt>
xor    %eax,%eax
call   1070 <endscale@plt>
movsd  0xded(%rip),%xmm0
movsd  0xded(%rip),%xmm1
mov    $0x8,%edi
call   10b0 <enclosure@plt>
movsd  0xde3(%rip),%xmm0
movsd  0xde3(%rip),%xmm1
mov    $0x6,%edi
call   10b0 <enclosure@plt>
xor    %eax,%eax
call   10a0 <endonion@plt>
xor    %eax,%eax
pop    %rcx
jmp    1070 <endscale@plt>

LLVM IR (-O0):
define void @make_castle() {
%1 = call i32 @scale(double 8.500000e-01, double 8.500000e-01, double 8.500000e-01)
%2 = call i32 (...) @onion()
%3 = call i32 @scale(double 1.500000e-01, double 1.500000e-01, double 1.500000e-01)
%4 = call i32 (...) @onion()
%5 = call i32 @keep_foundation(i32 350, i32 200, i32 150)
%6 = call i32 (...) @endonion()
%7 = call i32 @xlate(i32 0, i32 0, i32 150)
%8 = call i32 @recursive_keep(i32 0, i32 0, i32 200, i32 350, i32 50, i32 4)
%9 = call i32 (...) @endxlate()
%10 = call i32 (...) @endscale()
%11 = call i32 @enclosure(i32 8, double 6.500000e+01, double 0x403DB33333333334)
%12 = call i32 @enclosure(i32 6, double 3.800000e+01, double 4.620000e+01)
%13 = call i32 (...) @endonion()
%14 = call i32 (...) @endscale()
ret void
}

LLVM IR (-O2):
define void @make_castle() {
%1 = tail call i32 @scale(double 8.500000e-01, double 8.500000e-01, double 8.500000e-01)
%2 = tail call i32 (...) @onion()
%3 = tail call i32 @scale(double 1.500000e-01, double 1.500000e-01, double 1.500000e-01)
%4 = tail call i32 (...) @onion()
%5 = tail call i32 @keep_foundation(i32 350, i32 200, i32 150)
%6 = tail call i32 (...) @endonion()
%7 = tail call i32 @xlate(i32 0, i32 0, i32 150)
%8 = tail call i32 @recursive_keep(i32 0, i32 0, i32 200, i32 350, i32 50, i32 4)
%9 = tail call i32 (...) @endxlate()
%10 = tail call i32 (...) @endscale()
%11 = tail call i32 @enclosure(i32 8, double 6.500000e+01, double 0x403DB33333333334)
%12 = tail call i32 @enclosure(i32 6, double 3.800000e+01, double 4.620000e+01)
%13 = tail call i32 (...) @endonion()
%14 = tail call i32 (...) @endscale()
ret void
}