#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*/ TST_assert(int, char *);
int /*<<< orphan*/ TST_assert_not(int, char *);
int /*<<< orphan*/ TST_finalizar();
int /*<<< orphan*/ TST_iniciar();
int main(int argc, char **argv) {
  TST_iniciar();
  TST_assert(1 == 1, "Este teste é verdadeiro e deve passar");
  TST_assert((2 + 2) == 5, "Este teste deve falhar 2 + 2 = 5");
  TST_assert_not((3 * 3) == 900, "Este teste deve passar");
  TST_assert_not((2 + 2) == 4, "Este teste deve falhar");
  TST_finalizar();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1040 <TST_iniciar@plt>
mov    $0x1,%edi
lea    0xe97(%rip),%rsi
call   1050 <TST_assert@plt>
xor    %edi,%edi
lea    0xeb0(%rip),%rsi
call   1050 <TST_assert@plt>
xor    %edi,%edi
lea    0xec3(%rip),%rsi
call   1030 <TST_assert_not@plt>
mov    $0x1,%edi
lea    0xec9(%rip),%rsi
call   1030 <TST_assert_not@plt>
mov    $0x0,%al
call   1060 <TST_finalizar@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1040 <TST_iniciar@plt>
lea    0xeb1(%rip),%rsi
mov    $0x1,%edi
call   1050 <TST_assert@plt>
lea    0xec7(%rip),%rsi
xor    %edi,%edi
call   1050 <TST_assert@plt>
lea    0xeda(%rip),%rsi
xor    %edi,%edi
call   1030 <TST_assert_not@plt>
lea    0xee3(%rip),%rsi
mov    $0x1,%edi
call   1030 <TST_assert_not@plt>
xor    %eax,%eax
call   1060 <TST_finalizar@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [39 x i8] c"Este teste \C3\A9 verdadeiro e deve passar\00"
@.str.1 = [33 x i8] c"Este teste deve falhar 2 + 2 = 5\00"
@.str.2 = [23 x i8] c"Este teste deve passar\00"
@.str.3 = [23 x i8] c"Este teste deve falhar\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%6 = call i32 (...) @TST_iniciar()
%7 = call i32 @TST_assert(i32 1, i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str, i64 0, i64 0))
%8 = call i32 @TST_assert(i32 0, i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.1, i64 0, i64 0))
%9 = call i32 @TST_assert_not(i32 0, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.2, i64 0, i64 0))
%10 = call i32 @TST_assert_not(i32 1, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.3, i64 0, i64 0))
%11 = call i32 (...) @TST_finalizar()
ret i32 0
}

LLVM IR (-O2):
@.str = [39 x i8] c"Este teste \C3\A9 verdadeiro e deve passar\00"
@.str.1 = [33 x i8] c"Este teste deve falhar 2 + 2 = 5\00"
@.str.2 = [23 x i8] c"Este teste deve passar\00"
@.str.3 = [23 x i8] c"Este teste deve falhar\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 (...) @TST_iniciar()
%4 = tail call i32 @TST_assert(i32 1, i8* getelementptr inbounds ([39 x i8], [39 x i8]* @.str, i64 0, i64 0))
%5 = tail call i32 @TST_assert(i32 0, i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str.1, i64 0, i64 0))
%6 = tail call i32 @TST_assert_not(i32 0, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.2, i64 0, i64 0))
%7 = tail call i32 @TST_assert_not(i32 1, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.3, i64 0, i64 0))
%8 = tail call i32 (...) @TST_finalizar()
ret i32 0
}