xunge/DecIR huggingface dataset:
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isdigit(int);
void t_isdigit_0xfe() {
  Assert_real((isdigit(254) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_isdigit.c",
              1275, ("isdigit should be 0 for 0xfe"));
}


x86 assembly (clang, -O0):
<t_isdigit_0xfe>:
push   %rbp
mov    %rsp,%rbp
mov    $0xfe,%edi
call   1030 <isdigit@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%edi
lea    0xebf(%rip),%rsi
mov    $0x4fb,%edx
lea    0xf5b(%rip),%rcx
call   1040 <Assert_real@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<t_isdigit_0xfe>:
push   %rax
mov    $0xfe,%edi
call   1030 <isdigit@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x4fb,%edx
pop    %rax
jmp    1040 <Assert_real@plt>

LLVM IR (-O0):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isdigit.c\00"
@.str.1 = [29 x i8] c"isdigit should be 0 for 0xfe\00"
define void @t_isdigit_0xfe() {
%1 = call i64 @isdigit(i32 254)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 1275, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isdigit.c\00"
@.str.1 = [29 x i8] c"isdigit should be 0 for 0xfe\00"
define void @t_isdigit_0xfe() {
%1 = tail call i64 @isdigit(i32 254)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 1275, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
const char *bionet_get_network_error_string(void) {}


x86 assembly (clang, -O0):
<bionet_get_network_error_string>:
push   %rbp
mov    %rsp,%rbp
mov    -0x8(%rbp),%rax
pop    %rbp
ret

x86 assembly (clang, -O2):
<bionet_get_network_error_string>:
ret

LLVM IR (-O0):
define i8* @bionet_get_network_error_string() {
%1 = alloca i8*
%2 = load i8*, i8** %1
ret i8* %2
}

LLVM IR (-O2):
define noalias i8* @bionet_get_network_error_string() {
ret i8* undef
}
/* Variables and functions */
int /*<<< orphan*/ DEBUG_ASSERT(int);
void EthernetEnable(unsigned long ulBase) {
  DEBUG_ASSERT(ulBase == 0x40048000);
  (*((volatile unsigned long *)(ulBase + 0x00000008))) |= 0x00000010;
  (*((volatile unsigned long *)(ulBase + 0x00000008))) |= 0x00000001;
  (*((volatile unsigned long *)(ulBase + 0x0000000C))) |= 0x00000001;
  (*((volatile unsigned long *)(ulBase + 0x00000008))) |= 0x00000010;
}


x86 assembly (clang, -O0):
<EthernetEnable>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
cmpq   $0x40048000,-0x8(%rbp)
40
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <DEBUG_ASSERT@plt>
mov    -0x8(%rbp),%rax
mov    0x8(%rax),%rcx
or     $0x10,%rcx
mov    %rcx,0x8(%rax)
mov    -0x8(%rbp),%rax
mov    0x8(%rax),%rcx
or     $0x1,%rcx
mov    %rcx,0x8(%rax)
mov    -0x8(%rbp),%rax
mov    0xc(%rax),%rcx
or     $0x1,%rcx
mov    %rcx,0xc(%rax)
mov    -0x8(%rbp),%rax
mov    0x8(%rax),%rcx
or     $0x10,%rcx
mov    %rcx,0x8(%rax)
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<EthernetEnable>:
push   %rbx
mov    %rdi,%rbx
xor    %edi,%edi
cmp    $0x40048000,%rbx
sete   %dil
call   1030 <DEBUG_ASSERT@plt>
orq    $0x10,0x8(%rbx)
orq    $0x1,0x8(%rbx)
orq    $0x1,0xc(%rbx)
orq    $0x10,0x8(%rbx)
pop    %rbx
ret

LLVM IR (-O0):
define void @EthernetEnable(i64 %0) {
%2 = alloca i64
store i64 %0, i64* %2
%3 = load i64, i64* %2
%4 = icmp eq i64 %3, 1074036736
%5 = zext i1 %4 to i32
%6 = call i32 @DEBUG_ASSERT(i32 %5)
%7 = load i64, i64* %2
%8 = add i64 %7, 8
%9 = inttoptr i64 %8 to i64*
%10 = load volatile i64, i64* %9
%11 = or i64 %10, 16
store volatile i64 %11, i64* %9
%12 = load i64, i64* %2
%13 = add i64 %12, 8
%14 = inttoptr i64 %13 to i64*
%15 = load volatile i64, i64* %14
%16 = or i64 %15, 1
store volatile i64 %16, i64* %14
%17 = load i64, i64* %2
%18 = add i64 %17, 12
%19 = inttoptr i64 %18 to i64*
%20 = load volatile i64, i64* %19
%21 = or i64 %20, 1
store volatile i64 %21, i64* %19
%22 = load i64, i64* %2
%23 = add i64 %22, 8
%24 = inttoptr i64 %23 to i64*
%25 = load volatile i64, i64* %24
%26 = or i64 %25, 16
store volatile i64 %26, i64* %24
ret void
}

LLVM IR (-O2):
define void @EthernetEnable(i64 %0) {
%2 = icmp eq i64 %0, 1074036736
%3 = zext i1 %2 to i32
%4 = tail call i32 @DEBUG_ASSERT(i32 %3)
%5 = add i64 %0, 8
%6 = inttoptr i64 %5 to i64*
%7 = load volatile i64, i64* %6
%8 = or i64 %7, 16
store volatile i64 %8, i64* %6
%9 = load volatile i64, i64* %6
%10 = or i64 %9, 1
store volatile i64 %10, i64* %6
%11 = add i64 %0, 12
%12 = inttoptr i64 %11 to i64*
%13 = load volatile i64, i64* %12
%14 = or i64 %13, 1
store volatile i64 %14, i64* %12
%15 = load volatile i64, i64* %6
%16 = or i64 %15, 16
store volatile i64 %16, i64* %6
ret void
}
void GLUE_POP_PX(void *b, int wv) {
  static const unsigned int tab[3] = {
      0x80610000,
      0x81c10000,
      0x81e10000,
  };
  ((unsigned int *)b)[0] = tab[wv];
  ((unsigned int *)b)[1] = 0x38210010;
}


x86 assembly (clang, -O0):
<GLUE_POP_PX>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
movslq -0xc(%rbp),%rcx
lea    0xeea(%rip),%rax
mov    (%rax,%rcx,4),%ecx
mov    -0x8(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x8(%rbp),%rax
movl   $0x38210010,0x4(%rax)
pop    %rbp
ret

x86 assembly (clang, -O2):
<GLUE_POP_PX>:
movslq %esi,%rax
lea    0xef6(%rip),%rcx
mov    (%rcx,%rax,4),%eax
mov    %eax,(%rdi)
movl   $0x38210010,0x4(%rdi)
ret

LLVM IR (-O0):
@GLUE_POP_PX.tab = internal constant [3 x i32] [i32 -2141126656, i32 -2118057984, i32 -2115960832]
define void @GLUE_POP_PX(i8* %0, i32 %1) {
%3 = alloca i8*
%4 = alloca i32
store i8* %0, i8** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = sext i32 %5 to i64
%7 = getelementptr inbounds [3 x i32], [3 x i32]* @GLUE_POP_PX.tab, i64 0, i64 %6
%8 = load i32, i32* %7
%9 = load i8*, i8** %3
%10 = bitcast i8* %9 to i32*
%11 = getelementptr inbounds i32, i32* %10, i64 0
store i32 %8, i32* %11
%12 = load i8*, i8** %3
%13 = bitcast i8* %12 to i32*
%14 = getelementptr inbounds i32, i32* %13, i64 1
store i32 941686800, i32* %14
ret void
}

LLVM IR (-O2):
@GLUE_POP_PX.tab = internal unnamed_addr constant [3 x i32] [i32 -2141126656, i32 -2118057984, i32 -2115960832]
define void @GLUE_POP_PX(i8* nocapture writeonly %0, i32 %1) {
%3 = sext i32 %1 to i64
%4 = getelementptr inbounds [3 x i32], [3 x i32]* @GLUE_POP_PX.tab, i64 0, i64 %3
%5 = load i32, i32* %4
%6 = bitcast i8* %0 to i32*
store i32 %5, i32* %6
%7 = getelementptr inbounds i8, i8* %0, i64 4
%8 = bitcast i8* %7 to i32*
store i32 941686800, i32* %8
ret void
}
/* Type definitions */
struct t_config_option {
  int dummy;
};

/* Variables and functions */
int /*<<< orphan*/ config_file_search_with_string(char const *,
                                                  int /*<<< orphan*/ *,
                                                  int /*<<< orphan*/ *,
                                                  struct t_config_option **,
                                                  int /*<<< orphan*/ *);
struct t_config_option *plugin_api_config_get(const char *option_name) {
  struct t_config_option *ptr_option;
  config_file_search_with_string(option_name, NULL, NULL, &ptr_option, NULL);
  return ptr_option;
}


x86 assembly (clang, -O0):
<plugin_api_config_get>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
xor    %eax,%eax
mov    %eax,%r8d
lea    -0x10(%rbp),%rcx
mov    %r8,%rsi
mov    %r8,%rdx
call   1030 <config_file_search_with_string@plt>
mov    -0x10(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<plugin_api_config_get>:
push   %rax
mov    %rsp,%rcx
xor    %esi,%esi
xor    %edx,%edx
xor    %r8d,%r8d
call   1030 <config_file_search_with_string@plt>
mov    (%rsp),%rax
pop    %rcx
ret

LLVM IR (-O0):
%struct.t_config_option = type { i32 }
define %struct.t_config_option* @plugin_api_config_get(i8* %0) {
%2 = alloca i8*
%3 = alloca %struct.t_config_option*
store i8* %0, i8** %2
%4 = load i8*, i8** %2
%5 = call i32 @config_file_search_with_string(i8* %4, i32* null, i32* null, %struct.t_config_option** %3, i32* null)
%6 = load %struct.t_config_option*, %struct.t_config_option** %3
ret %struct.t_config_option* %6
}

LLVM IR (-O2):
%struct.t_config_option = type { i32 }
define %struct.t_config_option* @plugin_api_config_get(i8* %0) {
%2 = alloca %struct.t_config_option*
%3 = bitcast %struct.t_config_option** %2 to i8*
%4 = call i32 @config_file_search_with_string(i8* %0, i32* null, i32* null, %struct.t_config_option** %2, i32* null)
%5 = load %struct.t_config_option*, %struct.t_config_option** %2
ret %struct.t_config_option* %5
}
/* Variables and functions */
int fun(int);
int /*<<< orphan*/ printf(char *, int);
int main(int argc, const char *argv[]) {
  int ret = 0;
  ret = fun(1);
  printf("RETURNED %d\n", ret);
  if (ret != 2) {
    return 1;
  } else {
    return 0;
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x14(%rbp)
mov    $0x1,%edi
call   1030 <fun@plt>
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%esi
lea    0xeac(%rip),%rdi
call   1040 <printf@plt>
cmpl   $0x2,-0x14(%rbp)
je     116f <main+0x4f>
movl   $0x1,-0x4(%rbp)
jmp    1176 <main+0x56>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
mov    $0x1,%edi
call   1030 <fun@plt>
mov    %eax,%ebx
lea    0xecc(%rip),%rdi
mov    %eax,%esi
call   1040 <printf@plt>
xor    %eax,%eax
cmp    $0x2,%ebx
setne  %al
pop    %rbx
ret

LLVM IR (-O0):
@.str = [13 x i8] c"RETURNED %d\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 0, i32* %6
%7 = call i32 @fun(i32 1)
store i32 %7, i32* %6
%8 = load i32, i32* %6
%9 = call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %8)
%10 = load i32, i32* %6
%11 = icmp ne i32 %10, 2
br i1 %11, label %12, label %13
12: ; preds = %2
store i32 1, i32* %3
br label %14
13: ; preds = %2
store i32 0, i32* %3
br label %14
14: ; preds = %13, %12
%15 = load i32, i32* %3
ret i32 %15
}

LLVM IR (-O2):
@.str = [13 x i8] c"RETURNED %d\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @fun(i32 1)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %3)
%5 = icmp ne i32 %3, 2
%6 = zext i1 %5 to i32
ret i32 %6
}
/* Variables and functions */
int /*<<< orphan*/ close(int);
void msock_close_socket(int fd) { close(fd); }


x86 assembly (clang, -O0):
<msock_close_socket>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    -0x4(%rbp),%edi
call   1030 <close@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<msock_close_socket>:
jmp    1030 <close@plt>

LLVM IR (-O0):
define void @msock_close_socket(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = call i32 @close(i32 %3)
ret void
}

LLVM IR (-O2):
define void @msock_close_socket(i32 %0) {
%2 = tail call i32 @close(i32 %0)
ret void
}
int isspace(int c) {
  return (((c) <= (0x0d)) && ((c) >= (0x09))) || (c == 0x20);
}


x86 assembly (clang, -O0):
<isspace>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
cmpl   $0xd,-0x4(%rbp)
jg     1120 <isspace+0x20>
mov    $0x1,%al
cmpl   $0x9,-0x4(%rbp)
mov    %al,-0x5(%rbp)
jge    112a <isspace+0x2a>
cmpl   $0x20,-0x4(%rbp)
sete   %al
mov    %al,-0x5(%rbp)
mov    -0x5(%rbp),%al
and    $0x1,%al
movzbl %al,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<isspace>:
lea    -0x9(%rdi),%eax
cmp    $0x5,%eax
setb   %al
cmp    $0x20,%edi
sete   %cl
or     %al,%cl
movzbl %cl,%eax
ret

LLVM IR (-O0):
define i32 @isspace(i32 %0) {
%2 = alloca i32
store i32 %0, i32* %2
%3 = load i32, i32* %2
%4 = icmp sle i32 %3, 13
br i1 %4, label %5, label %8
5: ; preds = %1
%6 = load i32, i32* %2
%7 = icmp sge i32 %6, 9
br i1 %7, label %11, label %8
8: ; preds = %5, %1
%9 = load i32, i32* %2
%10 = icmp eq i32 %9, 32
br label %11
11: ; preds = %8, %5
%12 = phi i1 [ true, %5 ], [ %10, %8 ]
%13 = zext i1 %12 to i32
ret i32 %13
}

LLVM IR (-O2):
define i32 @isspace(i32 %0) {
%2 = add i32 %0, -9
%3 = icmp ult i32 %2, 5
%4 = icmp eq i32 %0, 32
%5 = or i1 %4, %3
%6 = zext i1 %5 to i32
ret i32 %6
}
/* Variables and functions */
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ printf(char *, char *, char *);
int /*<<< orphan*/ printfail();
scalar_t__ strcmp(char *, char *);
void expect_string(char *a, char *b) {
  if (strcmp(a, b)) {
    printfail();
    printf("\n  \"%s\" expected, but got \"%s\"\n", a, b);
    exit(1);
  }
}


x86 assembly (clang, -O0):
<expect_string>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
je     118c <expect_string+0x4c>
mov    $0x0,%al
call   1050 <printfail@plt>
mov    -0x8(%rbp),%rsi
mov    -0x10(%rbp),%rdx
lea    0xe83(%rip),%rdi
call   1030 <printf@plt>
mov    $0x1,%edi
call   1060 <exit@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<expect_string>:
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r14
mov    %rdi,%rbx
call   1040 <strcmp@plt>
test   %rax,%rax
jne    115c <expect_string+0x1c>
add    $0x8,%rsp
pop    %rbx
pop    %r14
ret
xor    %eax,%eax
call   1050 <printfail@plt>
lea    0xe96(%rip),%rdi
mov    %rbx,%rsi
mov    %r14,%rdx
call   1030 <printf@plt>
mov    $0x1,%edi
call   1060 <exit@plt>

LLVM IR (-O0):
@.str = [32 x i8] c"\0A \22%s\22 expected, but got \22%s\22\0A\00"
define void @expect_string(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
store i8* %0, i8** %3
store i8* %1, i8** %4
%5 = load i8*, i8** %3
%6 = load i8*, i8** %4
%7 = call i64 @strcmp(i8* %5, i8* %6)
%8 = icmp ne i64 %7, 0
br i1 %8, label %9, label %15
9: ; preds = %2
%10 = call i32 (...) @printfail()
%11 = load i8*, i8** %3
%12 = load i8*, i8** %4
%13 = call i32 @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str, i64 0, i64 0), i8* %11, i8* %12)
%14 = call i32 @exit(i32 1)
unreachable
15: ; preds = %2
ret void
}

LLVM IR (-O2):
@.str = [32 x i8] c"\0A \22%s\22 expected, but got \22%s\22\0A\00"
define void @expect_string(i8* %0, i8* %1) {
%3 = tail call i64 @strcmp(i8* %0, i8* %1)
%4 = icmp eq i64 %3, 0
br i1 %4, label %9, label %5
5: ; preds = %2
%6 = tail call i32 (...) @printfail()
%7 = tail call i32 @printf(i8* getelementptr inbounds ([32 x i8], [32 x i8]* @.str, i64 0, i64 0), i8* %0, i8* %1)
%8 = tail call i32 @exit(i32 1)
unreachable
9: ; preds = %2
ret void
}
int test_imm_D9uint16_reg(unsigned short val) {
  return ((val) & (0xD9 << 0)) ? -20 : -40;
}


x86 assembly (clang, -O0):
<test_imm_D9uint16_reg>:
push   %rbp
mov    %rsp,%rbp
mov    %di,%ax
mov    %ax,-0x2(%rbp)
movzwl -0x2(%rbp),%edx
and    $0xd9,%edx
mov    $0xffffffd8,%eax
mov    $0xffffffec,%ecx
cmp    $0x0,%edx
cmovne %ecx,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_imm_D9uint16_reg>:
test   $0xd9,%dil
mov    $0xffffffd8,%ecx
mov    $0xffffffec,%eax
cmove  %ecx,%eax
ret

LLVM IR (-O0):
define i32 @test_imm_D9uint16_reg(i16 zeroext %0) {
%2 = alloca i16
store i16 %0, i16* %2
%3 = load i16, i16* %2
%4 = zext i16 %3 to i32
%5 = and i32 %4, 217
%6 = icmp ne i32 %5, 0
%7 = zext i1 %6 to i64
%8 = select i1 %6, i32 -20, i32 -40
ret i32 %8
}

LLVM IR (-O2):
define i32 @test_imm_D9uint16_reg(i16 zeroext %0) {
%2 = and i16 %0, 217
%3 = icmp eq i16 %2, 0
%4 = select i1 %3, i32 -40, i32 -20
ret i32 %4
}
/* Variables and functions */
int /*<<< orphan*/ assert(int);
void example10() {
  int a[20];
  a[5] = 3;
  int i = 5;
  a[i] = 7;
  assert(a[5] == 7);
}


x86 assembly (clang, -O0):
<example10>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
movl   $0x3,-0x3c(%rbp)
movl   $0x5,-0x54(%rbp)
movslq -0x54(%rbp),%rax
movl   $0x7,-0x50(%rbp,%rax,4)
cmpl   $0x7,-0x3c(%rbp)
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1030 <assert@plt>
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<example10>:
mov    $0x1,%edi
jmp    1030 <assert@plt>

LLVM IR (-O0):
define void @example10() {
%1 = alloca [20 x i32]
%2 = alloca i32
%3 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 5
store i32 3, i32* %3
store i32 5, i32* %2
%4 = load i32, i32* %2
%5 = sext i32 %4 to i64
%6 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 %5
store i32 7, i32* %6
%7 = getelementptr inbounds [20 x i32], [20 x i32]* %1, i64 0, i64 5
%8 = load i32, i32* %7
%9 = icmp eq i32 %8, 7
%10 = zext i1 %9 to i32
%11 = call i32 @assert(i32 %10)
ret void
}

LLVM IR (-O2):
define void @example10() {
%1 = tail call i32 @assert(i32 1)
ret void
}
/* Variables and functions */
int execv(char *, char **);
int /*<<< orphan*/ getegid();
int /*<<< orphan*/ geteuid();
int /*<<< orphan*/ setregid(int /*<<< orphan*/, int /*<<< orphan*/);
int /*<<< orphan*/ setreuid(int /*<<< orphan*/, int /*<<< orphan*/);
int main(int argc, char *argv[]) {
  setreuid(geteuid(), geteuid());
  setregid(getegid(), getegid());
  return execv("./check_smartmon.py", argv);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x0,%al
call   1030 <geteuid@plt>
mov    %eax,-0x18(%rbp)
mov    $0x0,%al
call   1030 <geteuid@plt>
mov    -0x18(%rbp),%edi
mov    %eax,%esi
call   1050 <setreuid@plt>
mov    $0x0,%al
call   1040 <getegid@plt>
mov    %eax,-0x14(%rbp)
mov    $0x0,%al
call   1040 <getegid@plt>
mov    -0x14(%rbp),%edi
mov    %eax,%esi
call   1060 <setregid@plt>
mov    -0x10(%rbp),%rsi
lea    0xe59(%rip),%rdi
call   1070 <execv@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %rbx
push   %rax
mov    %rsi,%rbx
xor    %eax,%eax
call   1030 <geteuid@plt>
mov    %eax,%ebp
xor    %eax,%eax
call   1030 <geteuid@plt>
mov    %ebp,%edi
mov    %eax,%esi
call   1050 <setreuid@plt>
xor    %eax,%eax
call   1040 <getegid@plt>
mov    %eax,%ebp
xor    %eax,%eax
call   1040 <getegid@plt>
mov    %ebp,%edi
mov    %eax,%esi
call   1060 <setregid@plt>
lea    0xe71(%rip),%rdi
mov    %rbx,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1070 <execv@plt>

LLVM IR (-O0):
@.str = [20 x i8] c"./check_smartmon.py\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 (...) @geteuid()
%7 = call i32 (...) @geteuid()
%8 = call i32 @setreuid(i32 %6, i32 %7)
%9 = call i32 (...) @getegid()
%10 = call i32 (...) @getegid()
%11 = call i32 @setregid(i32 %9, i32 %10)
%12 = load i8**, i8*** %5
%13 = call i32 @execv(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str, i64 0, i64 0), i8** %12)
ret i32 %13
}

LLVM IR (-O2):
@.str = [20 x i8] c"./check_smartmon.py\00"
define i32 @main(i32 %0, i8** %1) {
%3 = tail call i32 (...) @geteuid()
%4 = tail call i32 (...) @geteuid()
%5 = tail call i32 @setreuid(i32 %3, i32 %4)
%6 = tail call i32 (...) @getegid()
%7 = tail call i32 (...) @getegid()
%8 = tail call i32 @setregid(i32 %6, i32 %7)
%9 = tail call i32 @execv(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str, i64 0, i64 0), i8** %1)
ret i32 %9
}
/* Variables and functions */
char char_toUpper(char);
int strlen(char *);
void str_toUpper(char *str) {
  int len = strlen(str);
  for (int i = 0; i < len; i++)
    str[i] = char_toUpper(str[i]);
}


x86 assembly (clang, -O0):
<str_toUpper>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <strlen@plt>
mov    %eax,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
mov    -0x10(%rbp),%eax
cmp    -0xc(%rbp),%eax
jge    1177 <str_toUpper+0x57>
mov    -0x8(%rbp),%rax
movslq -0x10(%rbp),%rcx
movsbl (%rax,%rcx,1),%edi
call   1040 <char_toUpper@plt>
mov    %al,%dl
mov    -0x8(%rbp),%rax
movslq -0x10(%rbp),%rcx
mov    %dl,(%rax,%rcx,1)
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    113f <str_toUpper+0x1f>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<str_toUpper>:
push   %r15
push   %r14
push   %rbx
mov    %rdi,%r15
call   1030 <strlen@plt>
test   %eax,%eax
jle    1157 <str_toUpper+0x37>
mov    %eax,%r14d
xor    %ebx,%ebx
cs nopw 0x0(%rax,%rax,1)
movsbl (%r15,%rbx,1),%edi
call   1040 <char_toUpper@plt>
mov    %al,(%r15,%rbx,1)
add    $0x1,%rbx
cmp    %rbx,%r14
jne    1140 <str_toUpper+0x20>
pop    %rbx
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
define void @str_toUpper(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
%4 = alloca i32
store i8* %0, i8** %2
%5 = load i8*, i8** %2
%6 = call i32 @strlen(i8* %5)
store i32 %6, i32* %3
store i32 0, i32* %4
br label %7
7: ; preds = %22, %1
%8 = load i32, i32* %4
%9 = load i32, i32* %3
%10 = icmp slt i32 %8, %9
br i1 %10, label %11, label %25
11: ; preds = %7
%12 = load i8*, i8** %2
%13 = load i32, i32* %4
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds i8, i8* %12, i64 %14
%16 = load i8, i8* %15
%17 = call signext i8 @char_toUpper(i8 signext %16)
%18 = load i8*, i8** %2
%19 = load i32, i32* %4
%20 = sext i32 %19 to i64
%21 = getelementptr inbounds i8, i8* %18, i64 %20
store i8 %17, i8* %21
br label %22
22: ; preds = %11
%23 = load i32, i32* %4
%24 = add nsw i32 %23, 1
store i32 %24, i32* %4
br label %7
25: ; preds = %7
ret void
}

LLVM IR (-O2):
define void @str_toUpper(i8* %0) {
%2 = tail call i32 @strlen(i8* %0)
%3 = icmp sgt i32 %2, 0
br i1 %3, label %4, label %6
4: ; preds = %1
%5 = zext i32 %2 to i64
br label %7
6: ; preds = %7, %1
ret void
7: ; preds = %4, %7
%8 = phi i64 [ 0, %4 ], [ %12, %7 ]
%9 = getelementptr inbounds i8, i8* %0, i64 %8
%10 = load i8, i8* %9
%11 = tail call signext i8 @char_toUpper(i8 signext %10)
store i8 %11, i8* %9
%12 = add nuw nsw i64 %8, 1
%13 = icmp eq i64 %12, %5
br i1 %13, label %6, label %7
}
unsigned int nextpow2(unsigned int x) {
  unsigned int ret;
  for (ret = 1; ret < x; ret *= 2)
    ;
  return ret;
}


x86 assembly (clang, -O0):
<nextpow2>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
movl   $0x1,-0x8(%rbp)
mov    -0x8(%rbp),%eax
cmp    -0x4(%rbp),%eax
jae    112d <nextpow2+0x2d>
jmp    111f <nextpow2+0x1f>
mov    -0x8(%rbp),%eax
shl    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    110e <nextpow2+0xe>
mov    -0x8(%rbp),%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<nextpow2>:
mov    $0x1,%ecx
cs nopw 0x0(%rax,%rax,1)
nop
mov    %ecx,%eax
lea    (%rax,%rax,1),%ecx
cmp    %edi,%eax
jb     1110 <nextpow2+0x10>
ret

LLVM IR (-O0):
define i32 @nextpow2(i32 %0) {
%2 = alloca i32
%3 = alloca i32
store i32 %0, i32* %2
store i32 1, i32* %3
br label %4
4: ; preds = %9, %1
%5 = load i32, i32* %3
%6 = load i32, i32* %2
%7 = icmp ult i32 %5, %6
br i1 %7, label %8, label %12
8: ; preds = %4
br label %9
9: ; preds = %8
%10 = load i32, i32* %3
%11 = mul i32 %10, 2
store i32 %11, i32* %3
br label %4
12: ; preds = %4
%13 = load i32, i32* %3
ret i32 %13
}

LLVM IR (-O2):
define i32 @nextpow2(i32 %0) {
br label %2
2: ; preds = %2, %1
%3 = phi i32 [ 1, %1 ], [ %5, %2 ]
%4 = icmp ult i32 %3, %0
%5 = shl i32 %3, 1
br i1 %4, label %2, label %6
6: ; preds = %2
ret i32 %3
}
void gtk_widget_get_pointer() {}


x86 assembly (clang, -O0):
<gtk_widget_get_pointer>:
push   %rbp
mov    %rsp,%rbp
pop    %rbp
ret

x86 assembly (clang, -O2):
<gtk_widget_get_pointer>:
ret

LLVM IR (-O0):
define void @gtk_widget_get_pointer() {
ret void
}

LLVM IR (-O2):
define void @gtk_widget_get_pointer() {
ret void
}
struct gas_query *gas_query_init(struct wpa_supplicant *wpa_s) {
  return (void *)1;
}


x86 assembly (clang, -O0):
<gas_query_init>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    $0x1,%eax
pop    %rbp
ret

x86 assembly (clang, -O2):
<gas_query_init>:
mov    $0x1,%eax
ret

LLVM IR (-O0):
%struct.gas_query = type opaque
%struct.wpa_supplicant = type opaque
define %struct.gas_query* @gas_query_init(%struct.wpa_supplicant* %0) {
%2 = alloca %struct.wpa_supplicant*
store %struct.wpa_supplicant* %0, %struct.wpa_supplicant** %2
ret %struct.gas_query* inttoptr (i64 1 to %struct.gas_query*)
}

LLVM IR (-O2):
%struct.gas_query = type opaque
%struct.wpa_supplicant = type opaque
define %struct.gas_query* @gas_query_init(%struct.wpa_supplicant* nocapture readnone %0) {
ret %struct.gas_query* inttoptr (i64 1 to %struct.gas_query*)
}
void test_p1788_setup() {}


x86 assembly (clang, -O0):
<test_p1788_setup>:
push   %rbp
mov    %rsp,%rbp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_p1788_setup>:
ret

LLVM IR (-O0):
define void @test_p1788_setup() {
ret void
}

LLVM IR (-O2):
define void @test_p1788_setup() {
ret void
}
void init_menu(struct menu_item *menu) {
  char *menu_options[5] = {"New game", "Load game", "High scores", "Quit",
                           "FAQ"};
}


x86 assembly (clang, -O0):
<init_menu>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
lea    -0x30(%rbp),%rdi
xor    %esi,%esi
mov    $0x28,%edx
call   1030 <memset@plt>
lea    0xecd(%rip),%rax
mov    %rax,-0x30(%rbp)
lea    0xecb(%rip),%rax
mov    %rax,-0x28(%rbp)
lea    0xeca(%rip),%rax
mov    %rax,-0x20(%rbp)
lea    0xecb(%rip),%rax
mov    %rax,-0x18(%rbp)
lea    0xec5(%rip),%rax
mov    %rax,-0x10(%rbp)
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<init_menu>:
ret

LLVM IR (-O0):
%struct.menu_item = type opaque
@.str = [9 x i8] c"New game\00"
@.str.1 = [10 x i8] c"Load game\00"
@.str.2 = [12 x i8] c"High scores\00"
@.str.3 = [5 x i8] c"Quit\00"
@.str.4 = [4 x i8] c"FAQ\00"
define void @init_menu(%struct.menu_item* %0) {
%2 = alloca %struct.menu_item*
%3 = alloca [5 x i8*]
store %struct.menu_item* %0, %struct.menu_item** %2
%4 = bitcast [5 x i8*]* %3 to i8*
%5 = bitcast i8* %4 to [5 x i8*]*
%6 = getelementptr inbounds [5 x i8*], [5 x i8*]* %5, i32 0, i32 0
store i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str, i32 0, i32 0), i8** %6
%7 = getelementptr inbounds [5 x i8*], [5 x i8*]* %5, i32 0, i32 1
store i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.1, i32 0, i32 0), i8** %7
%8 = getelementptr inbounds [5 x i8*], [5 x i8*]* %5, i32 0, i32 2
store i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.2, i32 0, i32 0), i8** %8
%9 = getelementptr inbounds [5 x i8*], [5 x i8*]* %5, i32 0, i32 3
store i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.3, i32 0, i32 0), i8** %9
%10 = getelementptr inbounds [5 x i8*], [5 x i8*]* %5, i32 0, i32 4
store i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i32 0, i32 0), i8** %10
ret void
}

LLVM IR (-O2):
%struct.menu_item = type opaque
define void @init_menu(%struct.menu_item* nocapture %0) {
ret void
}
/* Variables and functions */
char *find_last_char_count(char const *, char, int /*<<< orphan*/);
int /*<<< orphan*/ strlen(char const *);
char *find_last_char(const char *str, char c) {
  return (find_last_char_count(str, c, strlen(str)));
}


x86 assembly (clang, -O0):
<find_last_char>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %sil,%al
mov    %rdi,-0x8(%rbp)
mov    %al,-0x9(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x18(%rbp)
mov    -0x9(%rbp),%al
mov    %al,-0xa(%rbp)
mov    -0x8(%rbp),%rdi
call   1040 <strlen@plt>
mov    -0x18(%rbp),%rdi
mov    %eax,%edx
mov    -0xa(%rbp),%al
movsbl %al,%esi
call   1030 <find_last_char_count@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<find_last_char>:
push   %rbp
push   %rbx
push   %rax
mov    %esi,%ebp
mov    %rdi,%rbx
call   1040 <strlen@plt>
mov    %rbx,%rdi
mov    %ebp,%esi
mov    %eax,%edx
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1030 <find_last_char_count@plt>

LLVM IR (-O0):
define i8* @find_last_char(i8* %0, i8 signext %1) {
%3 = alloca i8*
%4 = alloca i8
store i8* %0, i8** %3
store i8 %1, i8* %4
%5 = load i8*, i8** %3
%6 = load i8, i8* %4
%7 = load i8*, i8** %3
%8 = call i32 @strlen(i8* %7)
%9 = call i8* @find_last_char_count(i8* %5, i8 signext %6, i32 %8)
ret i8* %9
}

LLVM IR (-O2):
define i8* @find_last_char(i8* %0, i8 signext %1) {
%3 = tail call i32 @strlen(i8* %0)
%4 = tail call i8* @find_last_char_count(i8* %0, i8 signext %1, i32 %3)
ret i8* %4
}
/* Variables and functions */
double dsfmt_gv_genrand_close_open();
double genrand_close_open(void) { return dsfmt_gv_genrand_close_open(); }


x86 assembly (clang, -O0):
<genrand_close_open>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1030 <dsfmt_gv_genrand_close_open@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<genrand_close_open>:
xor    %eax,%eax
jmp    1030 <dsfmt_gv_genrand_close_open@plt>

LLVM IR (-O0):
define double @genrand_close_open() {
%1 = call double (...) @dsfmt_gv_genrand_close_open()
ret double %1
}

LLVM IR (-O2):
define double @genrand_close_open() {
%1 = tail call double (...) @dsfmt_gv_genrand_close_open()
ret double %1
}
/* Variables and functions */
int /*<<< orphan*/ japi_sethgap(int, int);
void j_sethgap(int arg0, int arg1) { japi_sethgap(arg0, arg1); }


x86 assembly (clang, -O0):
<j_sethgap>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%edi
mov    -0x8(%rbp),%esi
call   1030 <japi_sethgap@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<j_sethgap>:
jmp    1030 <japi_sethgap@plt>

LLVM IR (-O0):
define void @j_sethgap(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %3
%6 = load i32, i32* %4
%7 = call i32 @japi_sethgap(i32 %5, i32 %6)
ret void
}

LLVM IR (-O2):
define void @j_sethgap(i32 %0, i32 %1) {
%3 = tail call i32 @japi_sethgap(i32 %0, i32 %1)
ret void
}
/* Variables and functions */
int /*<<< orphan*/ irq_enter();
int /*<<< orphan*/ irq_exit();
int /*<<< orphan*/ local_irq_disable();
int /*<<< orphan*/ local_irq_enable();
int /*<<< orphan*/ rcu_check_callbacks(int /*<<< orphan*/);
void do_IRQ(void) {
  local_irq_disable();
  irq_enter();
  rcu_check_callbacks(0);
  local_irq_enable();
  irq_exit();
}


x86 assembly (clang, -O0):
<do_IRQ>:
push   %rbp
mov    %rsp,%rbp
mov    $0x0,%al
call   1050 <local_irq_disable@plt>
mov    $0x0,%al
call   1040 <irq_enter@plt>
xor    %edi,%edi
call   1030 <rcu_check_callbacks@plt>
mov    $0x0,%al
call   1060 <local_irq_enable@plt>
mov    $0x0,%al
call   1070 <irq_exit@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<do_IRQ>:
push   %rax
xor    %eax,%eax
call   1050 <local_irq_disable@plt>
xor    %eax,%eax
call   1040 <irq_enter@plt>
xor    %edi,%edi
call   1030 <rcu_check_callbacks@plt>
xor    %eax,%eax
call   1060 <local_irq_enable@plt>
xor    %eax,%eax
pop    %rcx
jmp    1070 <irq_exit@plt>

LLVM IR (-O0):
define void @do_IRQ() {
%1 = call i32 (...) @local_irq_disable()
%2 = call i32 (...) @irq_enter()
%3 = call i32 @rcu_check_callbacks(i32 0)
%4 = call i32 (...) @local_irq_enable()
%5 = call i32 (...) @irq_exit()
ret void
}

LLVM IR (-O2):
define void @do_IRQ() {
%1 = tail call i32 (...) @local_irq_disable()
%2 = tail call i32 (...) @irq_enter()
%3 = tail call i32 @rcu_check_callbacks(i32 0)
%4 = tail call i32 (...) @local_irq_enable()
%5 = tail call i32 (...) @irq_exit()
ret void
}
/* Variables and functions */
int /*<<< orphan*/ Assert_real(int, char *, int, char *);
scalar_t__ isascii(int);
void t_isascii_0x99() {
  Assert_real((isascii(153) == 0),
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/"
              "dg/z88dk/test/suites/ctype/test_isascii.c",
              770, ("isascii should be 0 for 0x99"));
}


x86 assembly (clang, -O0):
<t_isascii_0x99>:
push   %rbp
mov    %rsp,%rbp
mov    $0x99,%edi
call   1030 <isascii@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%edi
lea    0xebf(%rip),%rsi
mov    $0x302,%edx
lea    0xf5b(%rip),%rcx
call   1040 <Assert_real@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<t_isascii_0x99>:
push   %rax
mov    $0x99,%edi
call   1030 <isascii@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
lea    0xec5(%rip),%rsi
lea    0xf66(%rip),%rcx
mov    $0x302,%edx
pop    %rax
jmp    1040 <Assert_real@plt>

LLVM IR (-O0):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isascii.c\00"
@.str.1 = [29 x i8] c"isascii should be 0 for 0x99\00"
define void @t_isascii_0x99() {
%1 = call i64 @isascii(i32 153)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 770, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [168 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/bitfixer/bitfixer/refs/heads/master/dg/z88dk/test/suites/ctype/test_isascii.c\00"
@.str.1 = [29 x i8] c"isascii should be 0 for 0x99\00"
define void @t_isascii_0x99() {
%1 = tail call i64 @isascii(i32 153)
%2 = icmp eq i64 %1, 0
%3 = zext i1 %2 to i32
%4 = tail call i32 @Assert_real(i32 %3, i8* getelementptr inbounds ([168 x i8], [168 x i8]* @.str, i64 0, i64 0), i32 770, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ assert_dbl_not_equal_(char *, int, double, double, double);
void test_dbl_not_equal_fail() {
  assert_dbl_not_equal_("/scratch/repos/new/home/jordi_armengol_estape/"
                        "c-scraper/outputs/2022-01-22/02-19-57/repos/hughbien/"
                        "assertive/refs/heads/master/test/fail_test.c",
                        42, (1.0), (1.05), (0.1));
}


x86 assembly (clang, -O0):
<test_dbl_not_equal_fail>:
push   %rbp
mov    %rsp,%rbp
lea    0xefd(%rip),%rdi
mov    $0x2a,%esi
movsd  0xed8(%rip),%xmm0
movsd  0xed8(%rip),%xmm1
movsd  0xed8(%rip),%xmm2
call   1030 <assert_dbl_not_equal_@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_dbl_not_equal_fail>:
lea    0xf01(%rip),%rdi
movsd  0xee1(%rip),%xmm0
movsd  0xee1(%rip),%xmm1
movsd  0xee1(%rip),%xmm2
mov    $0x2a,%esi
jmp    1030 <assert_dbl_not_equal_@plt>

LLVM IR (-O0):
@.str = [144 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/hughbien/assertive/refs/heads/master/test/fail_test.c\00"
define void @test_dbl_not_equal_fail() {
%1 = call i32 @assert_dbl_not_equal_(i8* getelementptr inbounds ([144 x i8], [144 x i8]* @.str, i64 0, i64 0), i32 42, double 1.000000e+00, double 1.050000e+00, double 1.000000e-01)
ret void
}

LLVM IR (-O2):
@.str = [144 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/hughbien/assertive/refs/heads/master/test/fail_test.c\00"
define void @test_dbl_not_equal_fail() {
%1 = tail call i32 @assert_dbl_not_equal_(i8* getelementptr inbounds ([144 x i8], [144 x i8]* @.str, i64 0, i64 0), i32 42, double 1.000000e+00, double 1.050000e+00, double 1.000000e-01)
ret void
}
void snd_info_set_text_ops(struct snd_info_entry *entry __attribute__((unused)),
                           void *private_data,
                           void (*read)(struct snd_info_entry *,
                                        struct snd_info_buffer *)) {}


x86 assembly (clang, -O0):
<snd_info_set_text_ops>:
push   %rbp
mov    %rsp,%rbp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
pop    %rbp
ret

x86 assembly (clang, -O2):
<snd_info_set_text_ops>:
ret

LLVM IR (-O0):
%struct.snd_info_entry = type opaque
%struct.snd_info_buffer = type opaque
define void @snd_info_set_text_ops(%struct.snd_info_entry* %0, i8* %1, void (%struct.snd_info_entry*, %struct.snd_info_buffer*)* %2) {
%4 = alloca %struct.snd_info_entry*
%5 = alloca i8*
%6 = alloca void (%struct.snd_info_entry*, %struct.snd_info_buffer*)*
store %struct.snd_info_entry* %0, %struct.snd_info_entry** %4
store i8* %1, i8** %5
store void (%struct.snd_info_entry*, %struct.snd_info_buffer*)* %2, void (%struct.snd_info_entry*, %struct.snd_info_buffer*)** %6
ret void
}

LLVM IR (-O2):
%struct.snd_info_entry = type opaque
%struct.snd_info_buffer = type opaque
define void @snd_info_set_text_ops(%struct.snd_info_entry* nocapture %0, i8* nocapture %1, void (%struct.snd_info_entry*, %struct.snd_info_buffer*)* nocapture %2) {
ret void
}
void outsl(int port, const void *addr, int cnt) {}


x86 assembly (clang, -O0):
<outsl>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
pop    %rbp
ret

x86 assembly (clang, -O2):
<outsl>:
ret

LLVM IR (-O0):
define void @outsl(i32 %0, i8* %1, i32 %2) {
%4 = alloca i32
%5 = alloca i8*
%6 = alloca i32
store i32 %0, i32* %4
store i8* %1, i8** %5
store i32 %2, i32* %6
ret void
}

LLVM IR (-O2):
define void @outsl(i32 %0, i8* nocapture %1, i32 %2) {
ret void
}
/* Variables and functions */
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, char *, char *);
int /*<<< orphan*/ stderr;
void print_version(void) { fprintf(stderr, "%s %s\n", "bin2ppm", "1.0"); }


x86 assembly (clang, -O0):
<print_version>:
push   %rbp
mov    %rsp,%rbp
mov    0x2ec5(%rip),%rax
mov    (%rax),%edi
lea    0xedc(%rip),%rsi
lea    0xedc(%rip),%rdx
lea    0xedd(%rip),%rcx
call   1030 <fprintf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_version>:
mov    0x2ec9(%rip),%rax
mov    (%rax),%edi
lea    0xee0(%rip),%rsi
lea    0xee0(%rip),%rdx
lea    0xee1(%rip),%rcx
jmp    1030 <fprintf@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [7 x i8] c"%s %s\0A\00"
@.str.1 = [8 x i8] c"bin2ppm\00"
@.str.2 = [4 x i8] c"1.0\00"
define void @print_version() {
%1 = load i32, i32* @stderr
%2 = call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [7 x i8] c"%s %s\0A\00"
@.str.1 = [8 x i8] c"bin2ppm\00"
@.str.2 = [4 x i8] c"1.0\00"
define void @print_version() {
%1 = load i32, i32* @stderr
%2 = tail call i32 @fprintf(i32 %1, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
ret void
}
/* Variables and functions */
int /*<<< orphan*/ printf(char *);
void func1() { printf("This is first function, should be executed second.\n"); }


x86 assembly (clang, -O0):
<func1>:
push   %rbp
mov    %rsp,%rbp
lea    0xee5(%rip),%rdi
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<func1>:
lea    0xee9(%rip),%rdi
jmp    1030 <puts@plt>

LLVM IR (-O0):
@.str = [52 x i8] c"This is first function, should be executed second.\0A\00"
define void @func1() {
%1 = call i32 @printf(i8* getelementptr inbounds ([52 x i8], [52 x i8]* @.str, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@str = [51 x i8] c"This is first function, should be executed second.\00"
define void @func1() {
%1 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([51 x i8], [51 x i8]* @str, i64 0, i64 0))
ret void
}
void h_ate1(char *name, int argc, char **argv, void *user_data) {
  int i;
  printf("Called: %s\n", __FUNCTION__);
}


x86 assembly (clang, -O0):
<h_ate1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
lea    0xed2(%rip),%rdi
lea    0xed7(%rip),%rsi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<h_ate1>:
lea    0xee9(%rip),%rdi
lea    0xeee(%rip),%rsi
xor    %eax,%eax
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [12 x i8] c"Called: %s\0A\00"
@__FUNCTION__.h_ate1 = [7 x i8] c"h_ate1\00"
define void @h_ate1(i8* %0, i32 %1, i8** %2, i8* %3) {
%5 = alloca i8*
%6 = alloca i32
%7 = alloca i8**
%8 = alloca i8*
%9 = alloca i32
store i8* %0, i8** %5
store i32 %1, i32* %6
store i8** %2, i8*** %7
store i8* %3, i8** %8
%10 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @__FUNCTION__.h_ate1, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str = [12 x i8] c"Called: %s\0A\00"
@__FUNCTION__.h_ate1 = [7 x i8] c"h_ate1\00"
define void @h_ate1(i8* nocapture readnone %0, i32 %1, i8** nocapture readnone %2, i8* nocapture readnone %3) {
%5 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @__FUNCTION__.h_ate1, i64 0, i64 0))
ret void
}
/* Type definitions */
struct _Locale_ctype {
  int dummy;
};

/* Variables and functions */
int tolower(int);
int _Locale_tolower(struct _Locale_ctype *lctype, int c) { return tolower(c); }


x86 assembly (clang, -O0):
<_Locale_tolower>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    -0xc(%rbp),%edi
call   1030 <tolower@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<_Locale_tolower>:
mov    %esi,%edi
jmp    1030 <tolower@plt>

LLVM IR (-O0):
%struct._Locale_ctype = type { i32 }
define i32 @_Locale_tolower(%struct._Locale_ctype* %0, i32 %1) {
%3 = alloca %struct._Locale_ctype*
%4 = alloca i32
store %struct._Locale_ctype* %0, %struct._Locale_ctype** %3
store i32 %1, i32* %4
%5 = load i32, i32* %4
%6 = call i32 @tolower(i32 %5)
ret i32 %6
}

LLVM IR (-O2):
%struct._Locale_ctype = type { i32 }
define i32 @_Locale_tolower(%struct._Locale_ctype* nocapture readnone %0, i32 %1) {
%3 = tail call i32 @tolower(i32 %1)
ret i32 %3
}
/* Variables and functions */
int /*<<< orphan*/ delay(int);
int /*<<< orphan*/ mbus_remote_register_write(int, int, int);
int /*<<< orphan*/ set_pmu_sar_override(int);
void set_pmu_motion(void) {
  mbus_remote_register_write(0x8, 0x1A,
                             ((1 << 13) | (4 << 9) | (2 << 5) | (8)));
  delay(200);
  mbus_remote_register_write(0x8, 0x1A,
                             ((1 << 13) | (4 << 9) | (2 << 5) | (8)));
  delay(200);
  mbus_remote_register_write(0x8, 0x16,
                             ((0 << 19) | (0 << 18) | (0 << 17) | (3 << 14) |
                              (1 << 13) | (4 << 9) | (4 << 5) | (15)));
  delay(200);
  set_pmu_sar_override(47);
}


x86 assembly (clang, -O0):
<set_pmu_motion>:
push   %rbp
mov    %rsp,%rbp
mov    $0x8,%edi
mov    $0x1a,%esi
mov    $0x2848,%edx
call   1050 <mbus_remote_register_write@plt>
mov    $0xc8,%edi
call   1040 <delay@plt>
mov    $0x8,%edi
mov    $0x1a,%esi
mov    $0x2848,%edx
call   1050 <mbus_remote_register_write@plt>
mov    $0xc8,%edi
call   1040 <delay@plt>
mov    $0x8,%edi
mov    $0x16,%esi
mov    $0xe88f,%edx
call   1050 <mbus_remote_register_write@plt>
mov    $0xc8,%edi
call   1040 <delay@plt>
mov    $0x2f,%edi
call   1030 <set_pmu_sar_override@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<set_pmu_motion>:
push   %rax
mov    $0x8,%edi
mov    $0x1a,%esi
mov    $0x2848,%edx
call   1050 <mbus_remote_register_write@plt>
mov    $0xc8,%edi
call   1040 <delay@plt>
mov    $0x8,%edi
mov    $0x1a,%esi
mov    $0x2848,%edx
call   1050 <mbus_remote_register_write@plt>
mov    $0xc8,%edi
call   1040 <delay@plt>
mov    $0x8,%edi
mov    $0x16,%esi
mov    $0xe88f,%edx
call   1050 <mbus_remote_register_write@plt>
mov    $0xc8,%edi
call   1040 <delay@plt>
mov    $0x2f,%edi
pop    %rax
jmp    1030 <set_pmu_sar_override@plt>

LLVM IR (-O0):
define void @set_pmu_motion() {
%1 = call i32 @mbus_remote_register_write(i32 8, i32 26, i32 10312)
%2 = call i32 @delay(i32 200)
%3 = call i32 @mbus_remote_register_write(i32 8, i32 26, i32 10312)
%4 = call i32 @delay(i32 200)
%5 = call i32 @mbus_remote_register_write(i32 8, i32 22, i32 59535)
%6 = call i32 @delay(i32 200)
%7 = call i32 @set_pmu_sar_override(i32 47)
ret void
}

LLVM IR (-O2):
define void @set_pmu_motion() {
%1 = tail call i32 @mbus_remote_register_write(i32 8, i32 26, i32 10312)
%2 = tail call i32 @delay(i32 200)
%3 = tail call i32 @mbus_remote_register_write(i32 8, i32 26, i32 10312)
%4 = tail call i32 @delay(i32 200)
%5 = tail call i32 @mbus_remote_register_write(i32 8, i32 22, i32 59535)
%6 = tail call i32 @delay(i32 200)
%7 = tail call i32 @set_pmu_sar_override(i32 47)
ret void
}
/* Variables and functions */
scalar_t__ malloc(int);
int /*<<< orphan*/ sprintf(char *, char *, char *);
int strlen(char *);
char *R2Settings_getWrongParams(char *param) {
  int length = strlen("Wrong parameter '%s'") - 2 + strlen(param);
  char *finalStr = (char *)malloc(sizeof(char) * length);
  sprintf(finalStr, "Wrong parameter '%s'", param);
  return finalStr;
}


x86 assembly (clang, -O0):
<R2Settings_getWrongParams>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
lea    0xebd(%rip),%rdi
call   1030 <strlen@plt>
sub    $0x2,%eax
mov    %eax,-0x1c(%rbp)
mov    -0x8(%rbp),%rdi
call   1030 <strlen@plt>
mov    %eax,%ecx
mov    -0x1c(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0xc(%rbp)
movslq -0xc(%rbp),%rax
shl    $0x0,%rax
mov    %eax,%edi
call   1040 <malloc@plt>
mov    %rax,-0x18(%rbp)
mov    -0x18(%rbp),%rdi
mov    -0x8(%rbp),%rdx
lea    0xe7d(%rip),%rsi
call   1050 <sprintf@plt>
mov    -0x18(%rbp),%rax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<R2Settings_getWrongParams>:
push   %r15
push   %r14
push   %r12
push   %rbx
push   %rax
mov    %rdi,%r12
lea    0xebe(%rip),%r14
mov    %r14,%rdi
call   1030 <strlen@plt>
mov    %eax,%r15d
mov    %r12,%rdi
call   1030 <strlen@plt>
lea    (%r15,%rax,1),%edi
add    $0xfffffffe,%edi
call   1040 <malloc@plt>
mov    %rax,%rbx
mov    %rax,%rdi
mov    %r14,%rsi
mov    %r12,%rdx
call   1050 <sprintf@plt>
mov    %rbx,%rax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
ret

LLVM IR (-O0):
@.str = [21 x i8] c"Wrong parameter '%s'\00"
define i8* @R2Settings_getWrongParams(i8* %0) {
%2 = alloca i8*
%3 = alloca i32
%4 = alloca i8*
store i8* %0, i8** %2
%5 = call i32 @strlen(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0))
%6 = sub nsw i32 %5, 2
%7 = load i8*, i8** %2
%8 = call i32 @strlen(i8* %7)
%9 = add nsw i32 %6, %8
store i32 %9, i32* %3
%10 = load i32, i32* %3
%11 = sext i32 %10 to i64
%12 = mul i64 1, %11
%13 = trunc i64 %12 to i32
%14 = call i64 @malloc(i32 %13)
%15 = inttoptr i64 %14 to i8*
store i8* %15, i8** %4
%16 = load i8*, i8** %4
%17 = load i8*, i8** %2
%18 = call i32 @sprintf(i8* %16, i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i8* %17)
%19 = load i8*, i8** %4
ret i8* %19
}

LLVM IR (-O2):
@.str = [21 x i8] c"Wrong parameter '%s'\00"
define i8* @R2Settings_getWrongParams(i8* %0) {
%2 = tail call i32 @strlen(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0))
%3 = add nsw i32 %2, -2
%4 = tail call i32 @strlen(i8* %0)
%5 = add nsw i32 %3, %4
%6 = tail call i64 @malloc(i32 %5)
%7 = inttoptr i64 %6 to i8*
%8 = tail call i32 @sprintf(i8* dereferenceable(1) %7, i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str, i64 0, i64 0), i8* %0)
ret i8* %7
}
/* Variables and functions */
int /*<<< orphan*/ geschwindigkeitsetzen(int /*<<< orphan*/);
void stop() { geschwindigkeitsetzen(0); }


x86 assembly (clang, -O0):
<stop>:
push   %rbp
mov    %rsp,%rbp
xor    %edi,%edi
call   1030 <geschwindigkeitsetzen@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<stop>:
xor    %edi,%edi
jmp    1030 <geschwindigkeitsetzen@plt>

LLVM IR (-O0):
define void @stop() {
%1 = call i32 @geschwindigkeitsetzen(i32 0)
ret void
}

LLVM IR (-O2):
define void @stop() {
%1 = tail call i32 @geschwindigkeitsetzen(i32 0)
ret void
}