#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*/ aspirar();
int /*<<< orphan*/ assoprar();
int /*<<< orphan*/ finalizar_ambiente();
int /*<<< orphan*/ inicializar_ambiente(int /*<<< orphan*/, int /*<<< orphan*/,
                                        int, int /*<<< orphan*/,
                                        int /*<<< orphan*/, int /*<<< orphan*/,
                                        int /*<<< orphan*/ *,
                                        int /*<<< orphan*/ *);
int /*<<< orphan*/ pontos();
int qtd_acoes();
int main(void) {
  inicializar_ambiente(0, 0, 2, 0, 0, 0, NULL, NULL);
  while (qtd_acoes() <= 1000) {
    aspirar();
    assoprar();
  }
  finalizar_ambiente();
  pontos();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
xor    %r9d,%r9d
mov    $0x2,%edx
xor    %eax,%eax
mov    %r9d,%edi
mov    %r9d,%esi
mov    %r9d,%ecx
mov    %r9d,%r8d
movq   $0x0,(%rsp)
movq   $0x0,0x8(%rsp)
call   1040 <inicializar_ambiente@plt>
mov    $0x0,%al
call   1060 <qtd_acoes@plt>
cmp    $0x3e8,%eax
jg     11c0 <main+0x60>
mov    $0x0,%al
call   1030 <aspirar@plt>
mov    $0x0,%al
call   1080 <assoprar@plt>
jmp    119b <main+0x3b>
mov    $0x0,%al
call   1070 <finalizar_ambiente@plt>
mov    $0x0,%al
call   1050 <pontos@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x18,%rsp
xorps  %xmm0,%xmm0
movups %xmm0,(%rsp)
xor    %edi,%edi
xor    %esi,%esi
mov    $0x2,%edx
xor    %ecx,%ecx
xor    %r8d,%r8d
xor    %r9d,%r9d
call   1040 <inicializar_ambiente@plt>
xor    %eax,%eax
call   1060 <qtd_acoes@plt>
cmp    $0x3e8,%eax
jg     11ac <main+0x4c>
nop
xor    %eax,%eax
call   1030 <aspirar@plt>
xor    %eax,%eax
call   1080 <assoprar@plt>
xor    %eax,%eax
call   1060 <qtd_acoes@plt>
cmp    $0x3e9,%eax
jl     1190 <main+0x30>
xor    %eax,%eax
call   1070 <finalizar_ambiente@plt>
xor    %eax,%eax
call   1050 <pontos@plt>
xor    %eax,%eax
add    $0x18,%rsp
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
store i32 0, i32* %1
%2 = call i32 @inicializar_ambiente(i32 0, i32 0, i32 2, i32 0, i32 0, i32 0, i32* null, i32* null)
br label %3
3: ; preds = %6, %0
%4 = call i32 (...) @qtd_acoes()
%5 = icmp sle i32 %4, 1000
br i1 %5, label %6, label %9
6: ; preds = %3
%7 = call i32 (...) @aspirar()
%8 = call i32 (...) @assoprar()
br label %3
9: ; preds = %3
%10 = call i32 (...) @finalizar_ambiente()
%11 = call i32 (...) @pontos()
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 @inicializar_ambiente(i32 0, i32 0, i32 2, i32 0, i32 0, i32 0, i32* null, i32* null)
%2 = tail call i32 (...) @qtd_acoes()
%3 = icmp slt i32 %2, 1001
br i1 %3, label %4, label %9
4: ; preds = %0, %4
%5 = tail call i32 (...) @aspirar()
%6 = tail call i32 (...) @assoprar()
%7 = tail call i32 (...) @qtd_acoes()
%8 = icmp slt i32 %7, 1001
br i1 %8, label %4, label %9
9: ; preds = %4, %0
%10 = tail call i32 (...) @finalizar_ambiente()
%11 = tail call i32 (...) @pontos()
ret i32 0
}