#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*/ adelanteTiempo(int, double, int /*<<< orphan*/);
int /*<<< orphan*/ atras(int, int, int /*<<< orphan*/);
int /*<<< orphan*/ orugaOff();
int /*<<< orphan*/ orugaTraga(int);
int /*<<< orphan*/ transversal(int, int, int /*<<< orphan*/);
int /*<<< orphan*/ wait1Msec(int);
void autoAtras(int lado) {
  orugaTraga(127);
  adelanteTiempo(127, 0.4, 0);
  wait1Msec(200);
  orugaOff();
  transversal((65 * lado), 2, 0);
  atras(127, 1.1, 0);
  transversal((65 * lado), 1.6, 0);
  adelanteTiempo(127, 0.6, 0);
  atras(127, 1.3, 0);
  adelanteTiempo(127, 0.5, 0);
  transversal((65 * lado), 1, 0);
  atras(127, 1, 0);
}


x86 assembly (clang, -O0):
<autoAtras>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    $0x7f,%edi
call   1050 <orugaTraga@plt>
mov    $0x7f,%edi
movsd  0xe8e(%rip),%xmm0
xor    %esi,%esi
call   1030 <adelanteTiempo@plt>
mov    $0xc8,%edi
call   1060 <wait1Msec@plt>
mov    $0x0,%al
call   1070 <orugaOff@plt>
imul   $0x41,-0x4(%rbp),%edi
mov    $0x2,%esi
xor    %edx,%edx
call   1040 <transversal@plt>
mov    $0x7f,%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1080 <atras@plt>
imul   $0x41,-0x4(%rbp),%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1040 <transversal@plt>
mov    $0x7f,%edi
movsd  0xe30(%rip),%xmm0
xor    %esi,%esi
call   1030 <adelanteTiempo@plt>
mov    $0x7f,%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1080 <atras@plt>
mov    $0x7f,%edi
movsd  0xe03(%rip),%xmm0
xor    %esi,%esi
call   1030 <adelanteTiempo@plt>
imul   $0x41,-0x4(%rbp),%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1040 <transversal@plt>
mov    $0x7f,%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1080 <atras@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<autoAtras>:
push   %rbp
push   %rbx
push   %rax
mov    %edi,%ebp
mov    $0x7f,%edi
call   1050 <orugaTraga@plt>
movsd  0xe89(%rip),%xmm0
mov    $0x7f,%edi
xor    %esi,%esi
call   1030 <adelanteTiempo@plt>
mov    $0xc8,%edi
call   1060 <wait1Msec@plt>
xor    %eax,%eax
call   1070 <orugaOff@plt>
mov    %ebp,%ebx
shl    $0x6,%ebx
add    %ebp,%ebx
mov    %ebx,%edi
mov    $0x2,%esi
xor    %edx,%edx
call   1040 <transversal@plt>
mov    $0x7f,%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1080 <atras@plt>
mov    %ebx,%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1040 <transversal@plt>
movsd  0xe38(%rip),%xmm0
mov    $0x7f,%edi
xor    %esi,%esi
call   1030 <adelanteTiempo@plt>
mov    $0x7f,%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1080 <atras@plt>
movsd  0xe1b(%rip),%xmm0
mov    $0x7f,%edi
xor    %esi,%esi
call   1030 <adelanteTiempo@plt>
mov    %ebx,%edi
mov    $0x1,%esi
xor    %edx,%edx
call   1040 <transversal@plt>
mov    $0x7f,%edi
mov    $0x1,%esi
xor    %edx,%edx
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1080 <atras@plt>

LLVM IR (-O0):
define void @autoAtras(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = call i32 @orugaTraga(i32 127)
%4 = call i32 @adelanteTiempo(i32 127, double 4.000000e-01, i32 0)
%5 = call i32 @wait1Msec(i32 200)
%6 = call i32 (...) @orugaOff()
%7 = load i32, i32* %2
%8 = mul nsw i32 65, %7
%9 = call i32 @transversal(i32 %8, i32 2, i32 0)
%10 = call i32 @atras(i32 127, i32 1, i32 0)
%11 = load i32, i32* %2
%12 = mul nsw i32 65, %11
%13 = call i32 @transversal(i32 %12, i32 1, i32 0)
%14 = call i32 @adelanteTiempo(i32 127, double 6.000000e-01, i32 0)
%15 = call i32 @atras(i32 127, i32 1, i32 0)
%16 = call i32 @adelanteTiempo(i32 127, double 5.000000e-01, i32 0)
%17 = load i32, i32* %2
%18 = mul nsw i32 65, %17
%19 = call i32 @transversal(i32 %18, i32 1, i32 0)
%20 = call i32 @atras(i32 127, i32 1, i32 0)
ret void
}

LLVM IR (-O2):
define void @autoAtras(i32 %0) {
%2 = tail call i32 @orugaTraga(i32 127)
%3 = tail call i32 @adelanteTiempo(i32 127, double 4.000000e-01, i32 0)
%4 = tail call i32 @wait1Msec(i32 200)
%5 = tail call i32 (...) @orugaOff()
%6 = mul nsw i32 %0, 65
%7 = tail call i32 @transversal(i32 %6, i32 2, i32 0)
%8 = tail call i32 @atras(i32 127, i32 1, i32 0)
%9 = tail call i32 @transversal(i32 %6, i32 1, i32 0)
%10 = tail call i32 @adelanteTiempo(i32 127, double 6.000000e-01, i32 0)
%11 = tail call i32 @atras(i32 127, i32 1, i32 0)
%12 = tail call i32 @adelanteTiempo(i32 127, double 5.000000e-01, i32 0)
%13 = tail call i32 @transversal(i32 %6, i32 1, i32 0)
%14 = tail call i32 @atras(i32 127, i32 1, i32 0)
ret void
}