#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*/ printf(char *);
scalar_t__ testIntMatrix();
scalar_t__ testStringMatrix();
int main(int argc, char **argv) {
  if (testIntMatrix()) {
    printf("Int Matrix Test Failed!\r\n");
    return -1;
  }
  if (testStringMatrix()) {
    printf("String Matrix Test Failed!\r\n");
    return -1;
  }
  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   1050 <testIntMatrix@plt>
cmp    $0x0,%rax
je     116f <main+0x3f>
lea    0xea2(%rip),%rdi
call   1040 <printf@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    119f <main+0x6f>
mov    $0x0,%al
call   1030 <testStringMatrix@plt>
cmp    $0x0,%rax
je     1198 <main+0x68>
lea    0xe93(%rip),%rdi
call   1040 <printf@plt>
movl   $0xffffffff,-0x4(%rbp)
jmp    119f <main+0x6f>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
xor    %ebx,%ebx
xor    %eax,%eax
call   1050 <testIntMatrix@plt>
test   %rax,%rax
je     1148 <main+0x18>
lea    0xed6(%rip),%rdi
jmp    115b <main+0x2b>
xor    %eax,%eax
call   1040 <testStringMatrix@plt>
test   %rax,%rax
je     1165 <main+0x35>
lea    0xea5(%rip),%rdi
call   1030 <puts@plt>
mov    $0xffffffff,%ebx
mov    %ebx,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [26 x i8] c"Int Matrix Test Failed!\0D\0A\00"
@.str.1 = [29 x i8] c"String Matrix Test Failed!\0D\0A\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 i64 (...) @testIntMatrix()
%7 = icmp ne i64 %6, 0
br i1 %7, label %8, label %10
8: ; preds = %2
%9 = call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0))
store i32 -1, i32* %3
br label %16
10: ; preds = %2
%11 = call i64 (...) @testStringMatrix()
%12 = icmp ne i64 %11, 0
br i1 %12, label %13, label %15
13: ; preds = %10
%14 = call i32 @printf(i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
store i32 -1, i32* %3
br label %16
15: ; preds = %10
store i32 0, i32* %3
br label %16
16: ; preds = %15, %13, %8
%17 = load i32, i32* %3
ret i32 %17
}

LLVM IR (-O2):
@str = [28 x i8] c"String Matrix Test Failed!\0D\00"
@str.2 = [25 x i8] c"Int Matrix Test Failed!\0D\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i64 (...) @testIntMatrix()
%4 = icmp eq i64 %3, 0
br i1 %4, label %5, label %8
5: ; preds = %2
%6 = tail call i64 (...) @testStringMatrix()
%7 = icmp eq i64 %6, 0
br i1 %7, label %11, label %8
8: ; preds = %5, %2
%9 = phi i8* [ getelementptr inbounds ([25 x i8], [25 x i8]* @str.2, i64 0, i64 0), %2 ], [ getelementptr inbounds ([28 x i8], [28 x i8]* @str, i64 0, i64 0), %5 ]
%10 = tail call i32 @puts(i8* dereferenceable(1) %9)
br label %11
11: ; preds = %8, %5
%12 = phi i32 [ 0, %5 ], [ -1, %8 ]
ret i32 %12
}