#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*/ lead(char *, char *);
int /*<<< orphan*/ printf(char *, int);
int /*<<< orphan*/ signature(char *, int /*<<< orphan*/ *);
int /*<<< orphan*/ unlink(char *);
int main(int argc, char *argv[]) {
  printf("DEBUG: sizeof(char): %ld\n", sizeof(char));
  printf("DEBUG: sizeof(short): %ld\n", sizeof(short));
  unlink("/tmp/test-0.1.0-1.rpm");
  lead("/tmp/test-0.1.0-1.rpm", "test-0.1.0-1");
  signature("/tmp/test-0.1.0-1.rpm", NULL);
  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)
lea    0xea3(%rip),%rdi
mov    $0x1,%esi
call   1050 <printf@plt>
lea    0xeac(%rip),%rdi
mov    $0x2,%esi
call   1050 <printf@plt>
lea    0xeb6(%rip),%rdi
call   1030 <unlink@plt>
lea    0xeaa(%rip),%rdi
lea    0xeb9(%rip),%rsi
call   1040 <lead@plt>
lea    0xe97(%rip),%rdi
xor    %eax,%eax
mov    %eax,%esi
call   1060 <signature@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
lea    0xeb8(%rip),%rdi
mov    $0x1,%esi
call   1050 <printf@plt>
lea    0xec1(%rip),%rdi
mov    $0x2,%esi
call   1050 <printf@plt>
lea    0xecb(%rip),%rbx
mov    %rbx,%rdi
call   1030 <unlink@plt>
lea    0xed2(%rip),%rsi
mov    %rbx,%rdi
call   1040 <lead@plt>
mov    %rbx,%rdi
xor    %esi,%esi
call   1060 <signature@plt>
xor    %eax,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [26 x i8] c"DEBUG: sizeof(char): %ld\0A\00"
@.str.1 = [27 x i8] c"DEBUG: sizeof(short): %ld\0A\00"
@.str.2 = [22 x i8] c"/tmp/test-0.1.0-1.rpm\00"
@.str.3 = [13 x i8] c"test-0.1.0-1\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 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0), i32 1)
%7 = call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0), i32 2)
%8 = call i32 @unlink(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0))
%9 = call i32 @lead(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0))
%10 = call i32 @signature(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0), i32* null)
ret i32 0
}

LLVM IR (-O2):
@.str = [26 x i8] c"DEBUG: sizeof(char): %ld\0A\00"
@.str.1 = [27 x i8] c"DEBUG: sizeof(short): %ld\0A\00"
@.str.2 = [22 x i8] c"/tmp/test-0.1.0-1.rpm\00"
@.str.3 = [13 x i8] c"test-0.1.0-1\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @printf(i8* getelementptr inbounds ([26 x i8], [26 x i8]* @.str, i64 0, i64 0), i32 1)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0), i32 2)
%5 = tail call i32 @unlink(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0))
%6 = tail call i32 @lead(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0))
%7 = tail call i32 @signature(i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.2, i64 0, i64 0), i32* null)
ret i32 0
}