#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 *);
int signal_type_alarm();
int main(void) {
  int ret = -1;
  printf("=====================test mask=================\n");
  if (ret < 0) {
  }
  printf("=====================test Action=================\n");
  if (ret < 0) {
  }
  printf("=====================test USER1=================\n");
  if (ret < 0) {
  }
  printf("=====================test ALARM=================\n");
  ret = signal_type_alarm();
  if (ret < 0) {
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0xffffffff,-0x8(%rbp)
lea    0xec3(%rip),%rdi
call   1030 <printf@plt>
cmpl   $0x0,-0x8(%rbp)
jge    1151 <main+0x31>
jmp    1151 <main+0x31>
lea    0xed9(%rip),%rdi
call   1030 <printf@plt>
cmpl   $0x0,-0x8(%rbp)
jge    116c <main+0x4c>
jmp    116c <main+0x4c>
lea    0xef1(%rip),%rdi
call   1030 <printf@plt>
cmpl   $0x0,-0x8(%rbp)
jge    1187 <main+0x67>
jmp    1187 <main+0x67>
lea    0xf08(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <signal_type_alarm@plt>
mov    %eax,-0x8(%rbp)
cmpl   $0x0,-0x8(%rbp)
jge    11ac <main+0x8c>
jmp    11ac <main+0x8c>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xed8(%rip),%rdi
call   1030 <puts@plt>
lea    0xefc(%rip),%rdi
call   1030 <puts@plt>
lea    0xf22(%rip),%rdi
call   1030 <puts@plt>
lea    0xf47(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
call   1040 <signal_type_alarm@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@.str = [49 x i8] c"=====================test mask=================\0A\00"
@.str.1 = [51 x i8] c"=====================test Action=================\0A\00"
@.str.2 = [50 x i8] c"=====================test USER1=================\0A\00"
@.str.3 = [50 x i8] c"=====================test ALARM=================\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
store i32 -1, i32* %2
%3 = call i32 @printf(i8* getelementptr inbounds ([49 x i8], [49 x i8]* @.str, i64 0, i64 0))
%4 = load i32, i32* %2
%5 = icmp slt i32 %4, 0
br i1 %5, label %6, label %7
6: ; preds = %0
br label %7
7: ; preds = %6, %0
%8 = call i32 @printf(i8* getelementptr inbounds ([51 x i8], [51 x i8]* @.str.1, i64 0, i64 0))
%9 = load i32, i32* %2
%10 = icmp slt i32 %9, 0
br i1 %10, label %11, label %12
11: ; preds = %7
br label %12
12: ; preds = %11, %7
%13 = call i32 @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.2, i64 0, i64 0))
%14 = load i32, i32* %2
%15 = icmp slt i32 %14, 0
br i1 %15, label %16, label %17
16: ; preds = %12
br label %17
17: ; preds = %16, %12
%18 = call i32 @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.3, i64 0, i64 0))
%19 = call i32 (...) @signal_type_alarm()
store i32 %19, i32* %2
%20 = load i32, i32* %2
%21 = icmp slt i32 %20, 0
br i1 %21, label %22, label %23
22: ; preds = %17
br label %23
23: ; preds = %22, %17
ret i32 0
}

LLVM IR (-O2):
@str = [48 x i8] c"=====================test mask=================\00"
@str.4 = [50 x i8] c"=====================test Action=================\00"
@str.5 = [49 x i8] c"=====================test USER1=================\00"
@str.6 = [49 x i8] c"=====================test ALARM=================\00"
define i32 @main() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([48 x i8], [48 x i8]* @str, i64 0, i64 0))
%2 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([50 x i8], [50 x i8]* @str.4, i64 0, i64 0))
%3 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([49 x i8], [49 x i8]* @str.5, i64 0, i64 0))
%4 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([49 x i8], [49 x i8]* @str.6, i64 0, i64 0))
%5 = tail call i32 (...) @signal_type_alarm()
ret i32 0
}