#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*/ cu_fail_assertion(char *, int, char *);
int /*<<< orphan*/ cu_success_assertion();
int /*<<< orphan*/ strnicmp(char *, char *, int);
void test_strnicmp(void) {
  if (((0)) == ((strnicmp("Hello", "Hello", sizeof("Hello"))))) {
    cu_success_assertion();
  } else {
    cu_fail_assertion("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                      "outputs/2022-01-22/02-19-57/repos/wilhelmtell/inspext/"
                      "refs/heads/master/test/test_string.c",
                      32,
                      "0"
                      " not equals "
                      "strnicmp(\"Hello\", \"Hello\", sizeof(\"Hello\"))");
  };
  if (((0)) == ((strnicmp("Hello", "HELLO", sizeof("Hello"))))) {
    cu_success_assertion();
  } else {
    cu_fail_assertion("/scratch/repos/new/home/jordi_armengol_estape/c-scraper/"
                      "outputs/2022-01-22/02-19-57/repos/wilhelmtell/inspext/"
                      "refs/heads/master/test/test_string.c",
                      33,
                      "0"
                      " not equals "
                      "strnicmp(\"Hello\", \"HELLO\", sizeof(\"Hello\"))");
  };
}


x86 assembly (clang, -O0):
<test_strnicmp>:
push   %rbp
mov    %rsp,%rbp
lea    0xec5(%rip),%rsi
mov    $0x6,%edx
mov    %rsi,%rdi
call   1030 <strnicmp@plt>
mov    %eax,%ecx
xor    %eax,%eax
cmp    %ecx,%eax
jne    1160 <test_strnicmp+0x30>
mov    $0x0,%al
call   1040 <cu_success_assertion@plt>
jmp    1178 <test_strnicmp+0x48>
lea    0xe9f(%rip),%rdi
mov    $0x20,%esi
lea    0xf26(%rip),%rdx
call   1050 <cu_fail_assertion@plt>
lea    0xe81(%rip),%rdi
lea    0xf4c(%rip),%rsi
mov    $0x6,%edx
call   1030 <strnicmp@plt>
mov    %eax,%ecx
xor    %eax,%eax
cmp    %ecx,%eax
jne    11a8 <test_strnicmp+0x78>
mov    $0x0,%al
call   1040 <cu_success_assertion@plt>
jmp    11c0 <test_strnicmp+0x90>
lea    0xe57(%rip),%rdi
mov    $0x21,%esi
lea    0xf1d(%rip),%rdx
call   1050 <cu_fail_assertion@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_strnicmp>:
push   %rax
lea    0xec8(%rip),%rdi
mov    %rdi,%rsi
mov    $0x6,%edx
call   1030 <strnicmp@plt>
test   %eax,%eax
je     1163 <test_strnicmp+0x33>
lea    0xeb6(%rip),%rdi
lea    0xf42(%rip),%rdx
mov    $0x20,%esi
call   1050 <cu_fail_assertion@plt>
jmp    116a <test_strnicmp+0x3a>
xor    %eax,%eax
call   1040 <cu_success_assertion@plt>
lea    0xe8f(%rip),%rdi
lea    0xf5a(%rip),%rsi
mov    $0x6,%edx
call   1030 <strnicmp@plt>
test   %eax,%eax
je     119f <test_strnicmp+0x6f>
lea    0xe79(%rip),%rdi
lea    0xf44(%rip),%rdx
mov    $0x21,%esi
pop    %rax
jmp    1050 <cu_fail_assertion@plt>
xor    %eax,%eax
pop    %rcx
jmp    1040 <cu_success_assertion@plt>

LLVM IR (-O0):
@.str = [6 x i8] c"Hello\00"
@.str.1 = [147 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/wilhelmtell/inspext/refs/heads/master/test/test_string.c\00"
@.str.2 = [57 x i8] c"0 not equals strnicmp(\22Hello\22, \22Hello\22, sizeof(\22Hello\22))\00"
@.str.3 = [6 x i8] c"HELLO\00"
@.str.4 = [57 x i8] c"0 not equals strnicmp(\22Hello\22, \22HELLO\22, sizeof(\22Hello\22))\00"
define void @test_strnicmp() {
%1 = call i32 @strnicmp(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 6)
%2 = icmp eq i32 0, %1
br i1 %2, label %3, label %5
3: ; preds = %0
%4 = call i32 (...) @cu_success_assertion()
br label %7
5: ; preds = %0
%6 = call i32 @cu_fail_assertion(i8* getelementptr inbounds ([147 x i8], [147 x i8]* @.str.1, i64 0, i64 0), i32 32, i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.2, i64 0, i64 0))
br label %7
7: ; preds = %5, %3
%8 = call i32 @strnicmp(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i32 6)
%9 = icmp eq i32 0, %8
br i1 %9, label %10, label %12
10: ; preds = %7
%11 = call i32 (...) @cu_success_assertion()
br label %14
12: ; preds = %7
%13 = call i32 @cu_fail_assertion(i8* getelementptr inbounds ([147 x i8], [147 x i8]* @.str.1, i64 0, i64 0), i32 33, i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.4, i64 0, i64 0))
br label %14
14: ; preds = %12, %10
ret void
}

LLVM IR (-O2):
@.str = [6 x i8] c"Hello\00"
@.str.1 = [147 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/wilhelmtell/inspext/refs/heads/master/test/test_string.c\00"
@.str.2 = [57 x i8] c"0 not equals strnicmp(\22Hello\22, \22Hello\22, sizeof(\22Hello\22))\00"
@.str.3 = [6 x i8] c"HELLO\00"
@.str.4 = [57 x i8] c"0 not equals strnicmp(\22Hello\22, \22HELLO\22, sizeof(\22Hello\22))\00"
define void @test_strnicmp() {
%1 = tail call i32 @strnicmp(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i32 6)
%2 = icmp eq i32 %1, 0
br i1 %2, label %3, label %5
3: ; preds = %0
%4 = tail call i32 (...) @cu_success_assertion()
br label %7
5: ; preds = %0
%6 = tail call i32 @cu_fail_assertion(i8* getelementptr inbounds ([147 x i8], [147 x i8]* @.str.1, i64 0, i64 0), i32 32, i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.2, i64 0, i64 0))
br label %7
7: ; preds = %5, %3
%8 = tail call i32 @strnicmp(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i32 6)
%9 = icmp eq i32 %8, 0
br i1 %9, label %10, label %12
10: ; preds = %7
%11 = tail call i32 (...) @cu_success_assertion()
br label %14
12: ; preds = %7
%13 = tail call i32 @cu_fail_assertion(i8* getelementptr inbounds ([147 x i8], [147 x i8]* @.str.1, i64 0, i64 0), i32 33, i8* getelementptr inbounds ([57 x i8], [57 x i8]* @.str.4, i64 0, i64 0))
br label %14
14: ; preds = %12, %10
ret void
}