#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*/ assert(int);
int /*<<< orphan*/ free(char *);
char *malloc(int);
int strlen(char *);
int /*<<< orphan*/ strncpy(char *, char *, int);
int test_memchr(char *, char, int, char *);
int test_memcmp(char *, char *, int, int);
int test_memmove(char *, char *, int, char *, char *, int);
scalar_t__ test_memset(char *, int, int);
int test_strcasecmp(char *, char *, int);
int test_strchr(char *, char, char *);
int test_strcmp(char *, char *, int);
int test_strncasecmp(char *, char *, int, int);
int test_strrchr(char *, char, char *);
int main(void) {
  char *buf;
  char *buf2;
  buf = malloc(100);
  assert(test_memset(buf, 0x42, 100) == 0);
  free(buf);
  buf = malloc(128);
  assert(test_memset(buf, 0, 128) == 0);
  assert(test_memset(buf + 1, 0, 127) == 0);
  free(buf);
  buf = malloc(1024);
  assert(test_memset(buf, 0, 1024) == 0);
  free(buf);
  buf = malloc(20);
  strncpy(buf, "Hello World!", 20);
  assert(test_memchr(buf, 'o', strlen(buf), buf + 4));
  assert(test_memchr(buf, 'a', strlen(buf), NULL));
  assert(test_memcmp(buf, "Hello World!", strlen(buf), 0));
  assert(test_memcmp(buf, "Hfllow World", strlen(buf), -1));
  assert(test_strcmp(buf, "Hello World!", 0));
  assert(test_strcmp(buf, "Hfllow World", -1));
  assert(test_strchr(buf, 'H', buf));
  assert(test_strchr(buf, 'e', buf + 1));
  assert(test_strchr(buf, 'a', NULL));
  assert(test_strchr(buf, '!', buf + 11));
  assert(test_strrchr(buf, 'H', buf));
  assert(test_strrchr(buf, 'o', buf + 7));
  assert(test_strrchr(buf, 'a', NULL));
  assert(test_strrchr(buf, 'l', buf + 9));
  assert(test_strrchr(buf, '!', buf + 11));
  assert(test_strcasecmp(buf, "Hello World!", 0));
  assert(test_strcasecmp(buf, "HELLO WORLD!", 0));
  assert(test_strcasecmp(buf, "IELLO world!", -1));
  assert(test_strcasecmp(buf, "HeLLo WOrlc!", 1));
  assert(test_strncasecmp(buf, "Hello World!", strlen(buf), 0));
  assert(test_strncasecmp(buf, "HELLO WORLD!", strlen(buf), 0));
  assert(test_strncasecmp(buf, "IELLO world!", strlen(buf), -1));
  assert(test_strncasecmp(buf, "HeLLo WOrlc!", strlen(buf), 1));
  assert(test_strncasecmp(buf, "HeLLo WOrlc!", 0, 0));
  assert(test_strncasecmp(buf, "HeLLo WOrlc!", 1, 0));
  assert(test_strncasecmp(buf, "HeLLo WOrlc!", 2, 0));
  assert(test_strncasecmp(buf, "HeLLp WOrlc!", 5, -1));
  free(buf);
  buf = malloc(20);
  buf2 = malloc(20);
  strncpy(buf, "Hello", 20);
  strncpy(buf2, " World!", 20);
  assert(test_memmove(buf + 5, buf2, strlen(buf2), buf, "Hello World!",
                      strlen("Hello World!")));
  strncpy(buf, "HHello World!", 20);
  assert(test_memmove(buf, buf + 1, strlen("Hello World!"), buf, "Hello World!",
                      strlen("Hello World!")));
  strncpy(buf, "0123456789", 20);
  assert(test_memmove(buf + 1, buf, strlen("0123456789"), buf, "00123456789",
                      strlen("00123456789")));
  free(buf);
  free(buf2);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0xc0,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x64,%edi
call   10b0 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
mov    $0x42,%esi
mov    $0x64,%edx
call   1060 <test_memset@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
call   1030 <free@plt>
mov    $0x80,%edi
call   10b0 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
xor    %esi,%esi
mov    $0x80,%edx
call   1060 <test_memset@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
add    $0x1,%rdi
xor    %esi,%esi
mov    $0x7f,%edx
call   1060 <test_memset@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
call   1030 <free@plt>
mov    $0x400,%edi
call   10b0 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
xor    %esi,%esi
mov    $0x400,%edx
call   1060 <test_memset@plt>
cmp    $0x0,%rax
sete   %al
and    $0x1,%al
movzbl %al,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
call   1030 <free@plt>
mov    $0x14,%edi
call   10b0 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    -0x10(%rbp),%rdi
lea    0xd6d(%rip),%rsi
mov    $0x14,%edx
call   1040 <strncpy@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0xb8(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0xb8(%rbp),%rdi
mov    %eax,%edx
mov    -0x10(%rbp),%rcx
add    $0x4,%rcx
mov    $0x6f,%esi
call   10d0 <test_memchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0xb0(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0xb0(%rbp),%rdi
mov    %eax,%edx
mov    $0x61,%esi
xor    %eax,%eax
mov    %eax,%ecx
call   10d0 <test_memchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0xa8(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0xa8(%rbp),%rdi
mov    %eax,%edx
lea    0xcd7(%rip),%rsi
xor    %ecx,%ecx
call   1100 <test_memcmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0xa0(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0xa0(%rbp),%rdi
mov    %eax,%edx
lea    0xc5d(%rip),%rsi
mov    $0xffffffff,%ecx
call   1100 <test_memcmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0xc89(%rip),%rsi
xor    %edx,%edx
call   10c0 <test_strcmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0xc28(%rip),%rsi
mov    $0xffffffff,%edx
call   10c0 <test_strcmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    -0x10(%rbp),%rdx
mov    $0x48,%esi
call   10f0 <test_strchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    -0x10(%rbp),%rdx
add    $0x1,%rdx
mov    $0x65,%esi
call   10f0 <test_strchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    $0x61,%esi
xor    %eax,%eax
mov    %eax,%edx
call   10f0 <test_strchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    -0x10(%rbp),%rdx
add    $0xb,%rdx
mov    $0x21,%esi
call   10f0 <test_strchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    -0x10(%rbp),%rdx
mov    $0x48,%esi
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    -0x10(%rbp),%rdx
add    $0x7,%rdx
mov    $0x6f,%esi
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    $0x61,%esi
xor    %eax,%eax
mov    %eax,%edx
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    -0x10(%rbp),%rdx
add    $0x9,%rdx
mov    $0x6c,%esi
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
mov    -0x10(%rbp),%rdx
add    $0xb,%rdx
mov    $0x21,%esi
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0xb5f(%rip),%rsi
xor    %edx,%edx
call   1090 <test_strcasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0xb0b(%rip),%rsi
xor    %edx,%edx
call   1090 <test_strcasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0xaff(%rip),%rsi
mov    $0xffffffff,%edx
call   1090 <test_strcasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0xaf0(%rip),%rsi
mov    $0x1,%edx
call   1090 <test_strcasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x98(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0x98(%rbp),%rdi
mov    %eax,%edx
lea    0xadc(%rip),%rsi
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x90(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0x90(%rbp),%rdi
mov    %eax,%edx
lea    0xa6f(%rip),%rsi
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x88(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0x88(%rbp),%rdi
mov    %eax,%edx
lea    0xa4a(%rip),%rsi
mov    $0xffffffff,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x80(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0x80(%rbp),%rdi
mov    %eax,%edx
lea    0xa28(%rip),%rsi
mov    $0x1,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0xa0c(%rip),%rsi
xor    %ecx,%ecx
mov    %ecx,%edx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0x9f1(%rip),%rsi
mov    $0x1,%edx
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0x9d3(%rip),%rsi
mov    $0x2,%edx
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0x9c2(%rip),%rsi
mov    $0x5,%edx
mov    $0xffffffff,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
call   1030 <free@plt>
mov    $0x14,%edi
call   10b0 <malloc@plt>
mov    %rax,-0x10(%rbp)
mov    $0x14,%edi
call   10b0 <malloc@plt>
mov    %rax,-0x18(%rbp)
mov    -0x10(%rbp),%rdi
lea    0x989(%rip),%rsi
mov    $0x14,%edx
call   1040 <strncpy@plt>
mov    -0x18(%rbp),%rdi
lea    0x980(%rip),%rsi
mov    $0x14,%edx
call   1040 <strncpy@plt>
mov    -0x10(%rbp),%rax
add    $0x5,%rax
mov    %rax,-0x78(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x70(%rbp)
mov    -0x18(%rbp),%rdi
call   1050 <strlen@plt>
mov    %eax,-0x64(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x60(%rbp)
lea    0x942(%rip),%rdi
call   1050 <strlen@plt>
mov    -0x78(%rbp),%rdi
mov    -0x70(%rbp),%rsi
mov    -0x64(%rbp),%edx
mov    -0x60(%rbp),%rcx
mov    %eax,%r9d
lea    0x924(%rip),%r8
call   10a0 <test_memmove@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0x90c(%rip),%rsi
mov    $0x14,%edx
call   1040 <strncpy@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x58(%rbp)
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x50(%rbp)
lea    0x8e8(%rip),%rdi
call   1050 <strlen@plt>
mov    %eax,-0x44(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x40(%rbp)
lea    0x8d1(%rip),%rdi
call   1050 <strlen@plt>
mov    -0x58(%rbp),%rdi
mov    -0x50(%rbp),%rsi
mov    -0x44(%rbp),%edx
mov    -0x40(%rbp),%rcx
mov    %eax,%r9d
lea    0x8b3(%rip),%r8
call   10a0 <test_memmove@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
lea    0x8aa(%rip),%rsi
mov    $0x14,%edx
call   1040 <strncpy@plt>
mov    -0x10(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0x38(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x30(%rbp)
lea    0x885(%rip),%rdi
call   1050 <strlen@plt>
mov    %eax,-0x24(%rbp)
mov    -0x10(%rbp),%rax
mov    %rax,-0x20(%rbp)
lea    0x86d(%rip),%rdi
call   1050 <strlen@plt>
mov    -0x38(%rbp),%rdi
mov    -0x30(%rbp),%rsi
mov    -0x24(%rbp),%edx
mov    -0x20(%rbp),%rcx
mov    %eax,%r9d
lea    0x84f(%rip),%r8
call   10a0 <test_memmove@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    -0x10(%rbp),%rdi
call   1030 <free@plt>
mov    -0x18(%rbp),%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0xc0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    $0x64,%edi
call   10b0 <malloc@plt>
mov    %rax,%rbx
mov    %rax,%rdi
mov    $0x42,%esi
mov    $0x64,%edx
call   1060 <test_memset@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
mov    $0x80,%edi
call   10b0 <malloc@plt>
mov    %rax,%rbx
mov    %rax,%rdi
xor    %esi,%esi
mov    $0x80,%edx
call   1060 <test_memset@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
call   1080 <assert@plt>
lea    0x1(%rbx),%rdi
xor    %esi,%esi
mov    $0x7f,%edx
call   1060 <test_memset@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
mov    $0x400,%edi
call   10b0 <malloc@plt>
mov    %rax,%rbx
mov    %rax,%rdi
xor    %esi,%esi
mov    $0x400,%edx
call   1060 <test_memset@plt>
xor    %edi,%edi
test   %rax,%rax
sete   %dil
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
mov    $0x14,%edi
call   10b0 <malloc@plt>
mov    %rax,%rbx
lea    0xd92(%rip),%r14
mov    %rax,%rdi
mov    %r14,%rsi
mov    $0x14,%edx
call   1040 <strncpy@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
lea    0x4(%rbx),%rcx
mov    %rbx,%rdi
mov    $0x6f,%esi
mov    %eax,%edx
call   10d0 <test_memchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
mov    %rbx,%rdi
mov    $0x61,%esi
mov    %eax,%edx
xor    %ecx,%ecx
call   10d0 <test_memchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    %eax,%edx
xor    %ecx,%ecx
call   1100 <test_memcmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
lea    0xccb(%rip),%r15
mov    %rbx,%rdi
mov    %r15,%rsi
mov    %eax,%edx
mov    $0xffffffff,%ecx
call   1100 <test_memcmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %edx,%edx
call   10c0 <test_strcmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
mov    $0xffffffff,%edx
call   10c0 <test_strcmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    $0x48,%esi
mov    %rbx,%rdx
call   10f0 <test_strchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0x1(%rbx),%rdx
mov    %rbx,%rdi
mov    $0x65,%esi
call   10f0 <test_strchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    $0x61,%esi
xor    %edx,%edx
call   10f0 <test_strchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0xb(%rbx),%r15
mov    %rbx,%rdi
mov    $0x21,%esi
mov    %r15,%rdx
call   10f0 <test_strchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    $0x48,%esi
mov    %rbx,%rdx
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0x7(%rbx),%rdx
mov    %rbx,%rdi
mov    $0x6f,%esi
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    $0x61,%esi
xor    %edx,%edx
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0x9(%rbx),%rdx
mov    %rbx,%rdi
mov    $0x6c,%esi
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    $0x21,%esi
mov    %r15,%rdx
call   1070 <test_strrchr@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %edx,%edx
call   1090 <test_strcasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0xba5(%rip),%r13
mov    %rbx,%rdi
mov    %r13,%rsi
xor    %edx,%edx
call   1090 <test_strcasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0xb97(%rip),%r12
mov    %rbx,%rdi
mov    %r12,%rsi
mov    $0xffffffff,%edx
call   1090 <test_strcasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0xb86(%rip),%r15
mov    %rbx,%rdi
mov    %r15,%rsi
mov    $0x1,%edx
call   1090 <test_strcasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    %eax,%edx
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
mov    %rbx,%rdi
mov    %r13,%rsi
mov    %eax,%edx
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
mov    %rbx,%rdi
mov    %r12,%rsi
mov    %eax,%edx
mov    $0xffffffff,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1050 <strlen@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
mov    %eax,%edx
mov    $0x1,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
xor    %edx,%edx
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
mov    $0x1,%edx
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
mov    $0x2,%edx
xor    %ecx,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0xaaf(%rip),%rsi
mov    %rbx,%rdi
mov    $0x5,%edx
mov    $0xffffffff,%ecx
call   10e0 <test_strncasecmp@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
mov    $0x14,%edi
call   10b0 <malloc@plt>
mov    %rax,%rbx
mov    $0x14,%edi
call   10b0 <malloc@plt>
mov    %rax,%r15
lea    0xa7a(%rip),%rsi
mov    %rbx,%rdi
mov    $0x14,%edx
call   1040 <strncpy@plt>
lea    0xa72(%rip),%rsi
mov    %r15,%rdi
mov    $0x14,%edx
call   1040 <strncpy@plt>
lea    0x5(%rbx),%r12
mov    %r15,%rdi
call   1050 <strlen@plt>
mov    %eax,%ebp
mov    %r14,%rdi
call   1050 <strlen@plt>
mov    %r12,%rdi
mov    %r15,%rsi
mov    %ebp,%edx
mov    %rbx,%rcx
mov    %r14,%r8
mov    %eax,%r9d
call   10a0 <test_memmove@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0xa25(%rip),%rsi
mov    %rbx,%rdi
mov    $0x14,%edx
call   1040 <strncpy@plt>
lea    0x1(%rbx),%r12
mov    %r14,%rdi
call   1050 <strlen@plt>
mov    %eax,%ebp
mov    %r14,%rdi
call   1050 <strlen@plt>
mov    %rbx,%rdi
mov    %r12,%rsi
mov    %ebp,%edx
mov    %rbx,%rcx
mov    %r14,%r8
mov    %eax,%r9d
call   10a0 <test_memmove@plt>
mov    %eax,%edi
call   1080 <assert@plt>
lea    0x9ed(%rip),%rbp
mov    %rbx,%rdi
mov    %rbp,%rsi
mov    $0x14,%edx
call   1040 <strncpy@plt>
mov    %rbp,%rdi
call   1050 <strlen@plt>
mov    %eax,%ebp
lea    0x9cb(%rip),%r14
mov    %r14,%rdi
call   1050 <strlen@plt>
mov    %r12,%rdi
mov    %rbx,%rsi
mov    %ebp,%edx
mov    %rbx,%rcx
mov    %r14,%r8
mov    %eax,%r9d
call   10a0 <test_memmove@plt>
mov    %eax,%edi
call   1080 <assert@plt>
mov    %rbx,%rdi
call   1030 <free@plt>
mov    %r15,%rdi
call   1030 <free@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [13 x i8] c"Hello World!\00"
@.str.1 = [13 x i8] c"Hfllow World\00"
@.str.2 = [13 x i8] c"HELLO WORLD!\00"
@.str.3 = [13 x i8] c"IELLO world!\00"
@.str.4 = [13 x i8] c"HeLLo WOrlc!\00"
@.str.5 = [13 x i8] c"HeLLp WOrlc!\00"
@.str.6 = [6 x i8] c"Hello\00"
@.str.7 = [8 x i8] c" World!\00"
@.str.8 = [14 x i8] c"HHello World!\00"
@.str.9 = [11 x i8] c"0123456789\00"
@.str.10 = [12 x i8] c"00123456789\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i8*
%3 = alloca i8*
store i32 0, i32* %1
%4 = call i8* @malloc(i32 100)
store i8* %4, i8** %2
%5 = load i8*, i8** %2
%6 = call i64 @test_memset(i8* %5, i32 66, i32 100)
%7 = icmp eq i64 %6, 0
%8 = zext i1 %7 to i32
%9 = call i32 @assert(i32 %8)
%10 = load i8*, i8** %2
%11 = call i32 @free(i8* %10)
%12 = call i8* @malloc(i32 128)
store i8* %12, i8** %2
%13 = load i8*, i8** %2
%14 = call i64 @test_memset(i8* %13, i32 0, i32 128)
%15 = icmp eq i64 %14, 0
%16 = zext i1 %15 to i32
%17 = call i32 @assert(i32 %16)
%18 = load i8*, i8** %2
%19 = getelementptr inbounds i8, i8* %18, i64 1
%20 = call i64 @test_memset(i8* %19, i32 0, i32 127)
%21 = icmp eq i64 %20, 0
%22 = zext i1 %21 to i32
%23 = call i32 @assert(i32 %22)
%24 = load i8*, i8** %2
%25 = call i32 @free(i8* %24)
%26 = call i8* @malloc(i32 1024)
store i8* %26, i8** %2
%27 = load i8*, i8** %2
%28 = call i64 @test_memset(i8* %27, i32 0, i32 1024)
%29 = icmp eq i64 %28, 0
%30 = zext i1 %29 to i32
%31 = call i32 @assert(i32 %30)
%32 = load i8*, i8** %2
%33 = call i32 @free(i8* %32)
%34 = call i8* @malloc(i32 20)
store i8* %34, i8** %2
%35 = load i8*, i8** %2
%36 = call i32 @strncpy(i8* %35, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 20)
%37 = load i8*, i8** %2
%38 = load i8*, i8** %2
%39 = call i32 @strlen(i8* %38)
%40 = load i8*, i8** %2
%41 = getelementptr inbounds i8, i8* %40, i64 4
%42 = call i32 @test_memchr(i8* %37, i8 signext 111, i32 %39, i8* %41)
%43 = call i32 @assert(i32 %42)
%44 = load i8*, i8** %2
%45 = load i8*, i8** %2
%46 = call i32 @strlen(i8* %45)
%47 = call i32 @test_memchr(i8* %44, i8 signext 97, i32 %46, i8* null)
%48 = call i32 @assert(i32 %47)
%49 = load i8*, i8** %2
%50 = load i8*, i8** %2
%51 = call i32 @strlen(i8* %50)
%52 = call i32 @test_memcmp(i8* %49, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %51, i32 0)
%53 = call i32 @assert(i32 %52)
%54 = load i8*, i8** %2
%55 = load i8*, i8** %2
%56 = call i32 @strlen(i8* %55)
%57 = call i32 @test_memcmp(i8* %54, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0), i32 %56, i32 -1)
%58 = call i32 @assert(i32 %57)
%59 = load i8*, i8** %2
%60 = call i32 @test_strcmp(i8* %59, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 0)
%61 = call i32 @assert(i32 %60)
%62 = load i8*, i8** %2
%63 = call i32 @test_strcmp(i8* %62, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0), i32 -1)
%64 = call i32 @assert(i32 %63)
%65 = load i8*, i8** %2
%66 = load i8*, i8** %2
%67 = call i32 @test_strchr(i8* %65, i8 signext 72, i8* %66)
%68 = call i32 @assert(i32 %67)
%69 = load i8*, i8** %2
%70 = load i8*, i8** %2
%71 = getelementptr inbounds i8, i8* %70, i64 1
%72 = call i32 @test_strchr(i8* %69, i8 signext 101, i8* %71)
%73 = call i32 @assert(i32 %72)
%74 = load i8*, i8** %2
%75 = call i32 @test_strchr(i8* %74, i8 signext 97, i8* null)
%76 = call i32 @assert(i32 %75)
%77 = load i8*, i8** %2
%78 = load i8*, i8** %2
%79 = getelementptr inbounds i8, i8* %78, i64 11
%80 = call i32 @test_strchr(i8* %77, i8 signext 33, i8* %79)
%81 = call i32 @assert(i32 %80)
%82 = load i8*, i8** %2
%83 = load i8*, i8** %2
%84 = call i32 @test_strrchr(i8* %82, i8 signext 72, i8* %83)
%85 = call i32 @assert(i32 %84)
%86 = load i8*, i8** %2
%87 = load i8*, i8** %2
%88 = getelementptr inbounds i8, i8* %87, i64 7
%89 = call i32 @test_strrchr(i8* %86, i8 signext 111, i8* %88)
%90 = call i32 @assert(i32 %89)
%91 = load i8*, i8** %2
%92 = call i32 @test_strrchr(i8* %91, i8 signext 97, i8* null)
%93 = call i32 @assert(i32 %92)
%94 = load i8*, i8** %2
%95 = load i8*, i8** %2
%96 = getelementptr inbounds i8, i8* %95, i64 9
%97 = call i32 @test_strrchr(i8* %94, i8 signext 108, i8* %96)
%98 = call i32 @assert(i32 %97)
%99 = load i8*, i8** %2
%100 = load i8*, i8** %2
%101 = getelementptr inbounds i8, i8* %100, i64 11
%102 = call i32 @test_strrchr(i8* %99, i8 signext 33, i8* %101)
%103 = call i32 @assert(i32 %102)
%104 = load i8*, i8** %2
%105 = call i32 @test_strcasecmp(i8* %104, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 0)
%106 = call i32 @assert(i32 %105)
%107 = load i8*, i8** %2
%108 = call i32 @test_strcasecmp(i8* %107, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i32 0)
%109 = call i32 @assert(i32 %108)
%110 = load i8*, i8** %2
%111 = call i32 @test_strcasecmp(i8* %110, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0), i32 -1)
%112 = call i32 @assert(i32 %111)
%113 = load i8*, i8** %2
%114 = call i32 @test_strcasecmp(i8* %113, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 1)
%115 = call i32 @assert(i32 %114)
%116 = load i8*, i8** %2
%117 = load i8*, i8** %2
%118 = call i32 @strlen(i8* %117)
%119 = call i32 @test_strncasecmp(i8* %116, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %118, i32 0)
%120 = call i32 @assert(i32 %119)
%121 = load i8*, i8** %2
%122 = load i8*, i8** %2
%123 = call i32 @strlen(i8* %122)
%124 = call i32 @test_strncasecmp(i8* %121, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i32 %123, i32 0)
%125 = call i32 @assert(i32 %124)
%126 = load i8*, i8** %2
%127 = load i8*, i8** %2
%128 = call i32 @strlen(i8* %127)
%129 = call i32 @test_strncasecmp(i8* %126, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0), i32 %128, i32 -1)
%130 = call i32 @assert(i32 %129)
%131 = load i8*, i8** %2
%132 = load i8*, i8** %2
%133 = call i32 @strlen(i8* %132)
%134 = call i32 @test_strncasecmp(i8* %131, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 %133, i32 1)
%135 = call i32 @assert(i32 %134)
%136 = load i8*, i8** %2
%137 = call i32 @test_strncasecmp(i8* %136, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 0, i32 0)
%138 = call i32 @assert(i32 %137)
%139 = load i8*, i8** %2
%140 = call i32 @test_strncasecmp(i8* %139, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 1, i32 0)
%141 = call i32 @assert(i32 %140)
%142 = load i8*, i8** %2
%143 = call i32 @test_strncasecmp(i8* %142, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 2, i32 0)
%144 = call i32 @assert(i32 %143)
%145 = load i8*, i8** %2
%146 = call i32 @test_strncasecmp(i8* %145, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.5, i64 0, i64 0), i32 5, i32 -1)
%147 = call i32 @assert(i32 %146)
%148 = load i8*, i8** %2
%149 = call i32 @free(i8* %148)
%150 = call i8* @malloc(i32 20)
store i8* %150, i8** %2
%151 = call i8* @malloc(i32 20)
store i8* %151, i8** %3
%152 = load i8*, i8** %2
%153 = call i32 @strncpy(i8* %152, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.6, i64 0, i64 0), i32 20)
%154 = load i8*, i8** %3
%155 = call i32 @strncpy(i8* %154, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.7, i64 0, i64 0), i32 20)
%156 = load i8*, i8** %2
%157 = getelementptr inbounds i8, i8* %156, i64 5
%158 = load i8*, i8** %3
%159 = load i8*, i8** %3
%160 = call i32 @strlen(i8* %159)
%161 = load i8*, i8** %2
%162 = call i32 @strlen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%163 = call i32 @test_memmove(i8* %157, i8* %158, i32 %160, i8* %161, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %162)
%164 = call i32 @assert(i32 %163)
%165 = load i8*, i8** %2
%166 = call i32 @strncpy(i8* %165, i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.8, i64 0, i64 0), i32 20)
%167 = load i8*, i8** %2
%168 = load i8*, i8** %2
%169 = getelementptr inbounds i8, i8* %168, i64 1
%170 = call i32 @strlen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%171 = load i8*, i8** %2
%172 = call i32 @strlen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%173 = call i32 @test_memmove(i8* %167, i8* %169, i32 %170, i8* %171, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %172)
%174 = call i32 @assert(i32 %173)
%175 = load i8*, i8** %2
%176 = call i32 @strncpy(i8* %175, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.9, i64 0, i64 0), i32 20)
%177 = load i8*, i8** %2
%178 = getelementptr inbounds i8, i8* %177, i64 1
%179 = load i8*, i8** %2
%180 = call i32 @strlen(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.9, i64 0, i64 0))
%181 = load i8*, i8** %2
%182 = call i32 @strlen(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0))
%183 = call i32 @test_memmove(i8* %178, i8* %179, i32 %180, i8* %181, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), i32 %182)
%184 = call i32 @assert(i32 %183)
%185 = load i8*, i8** %2
%186 = call i32 @free(i8* %185)
%187 = load i8*, i8** %3
%188 = call i32 @free(i8* %187)
ret i32 0
}

LLVM IR (-O2):
@.str = [13 x i8] c"Hello World!\00"
@.str.1 = [13 x i8] c"Hfllow World\00"
@.str.2 = [13 x i8] c"HELLO WORLD!\00"
@.str.3 = [13 x i8] c"IELLO world!\00"
@.str.4 = [13 x i8] c"HeLLo WOrlc!\00"
@.str.5 = [13 x i8] c"HeLLp WOrlc!\00"
@.str.6 = [6 x i8] c"Hello\00"
@.str.7 = [8 x i8] c" World!\00"
@.str.8 = [14 x i8] c"HHello World!\00"
@.str.9 = [11 x i8] c"0123456789\00"
@.str.10 = [12 x i8] c"00123456789\00"
define i32 @main() {
%1 = tail call dereferenceable_or_null(100) i8* @malloc(i32 100)
%2 = tail call i64 @test_memset(i8* %1, i32 66, i32 100)
%3 = icmp eq i64 %2, 0
%4 = zext i1 %3 to i32
%5 = tail call i32 @assert(i32 %4)
%6 = tail call i32 @free(i8* %1)
%7 = tail call dereferenceable_or_null(128) i8* @malloc(i32 128)
%8 = tail call i64 @test_memset(i8* %7, i32 0, i32 128)
%9 = icmp eq i64 %8, 0
%10 = zext i1 %9 to i32
%11 = tail call i32 @assert(i32 %10)
%12 = getelementptr inbounds i8, i8* %7, i64 1
%13 = tail call i64 @test_memset(i8* %12, i32 0, i32 127)
%14 = icmp eq i64 %13, 0
%15 = zext i1 %14 to i32
%16 = tail call i32 @assert(i32 %15)
%17 = tail call i32 @free(i8* %7)
%18 = tail call dereferenceable_or_null(1024) i8* @malloc(i32 1024)
%19 = tail call i64 @test_memset(i8* %18, i32 0, i32 1024)
%20 = icmp eq i64 %19, 0
%21 = zext i1 %20 to i32
%22 = tail call i32 @assert(i32 %21)
%23 = tail call i32 @free(i8* %18)
%24 = tail call dereferenceable_or_null(20) i8* @malloc(i32 20)
%25 = tail call i32 @strncpy(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 20)
%26 = tail call i32 @strlen(i8* %24)
%27 = getelementptr inbounds i8, i8* %24, i64 4
%28 = tail call i32 @test_memchr(i8* %24, i8 signext 111, i32 %26, i8* %27)
%29 = tail call i32 @assert(i32 %28)
%30 = tail call i32 @strlen(i8* %24)
%31 = tail call i32 @test_memchr(i8* %24, i8 signext 97, i32 %30, i8* null)
%32 = tail call i32 @assert(i32 %31)
%33 = tail call i32 @strlen(i8* %24)
%34 = tail call i32 @test_memcmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %33, i32 0)
%35 = tail call i32 @assert(i32 %34)
%36 = tail call i32 @strlen(i8* %24)
%37 = tail call i32 @test_memcmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0), i32 %36, i32 -1)
%38 = tail call i32 @assert(i32 %37)
%39 = tail call i32 @test_strcmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 0)
%40 = tail call i32 @assert(i32 %39)
%41 = tail call i32 @test_strcmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.1, i64 0, i64 0), i32 -1)
%42 = tail call i32 @assert(i32 %41)
%43 = tail call i32 @test_strchr(i8* %24, i8 signext 72, i8* %24)
%44 = tail call i32 @assert(i32 %43)
%45 = getelementptr inbounds i8, i8* %24, i64 1
%46 = tail call i32 @test_strchr(i8* %24, i8 signext 101, i8* %45)
%47 = tail call i32 @assert(i32 %46)
%48 = tail call i32 @test_strchr(i8* %24, i8 signext 97, i8* null)
%49 = tail call i32 @assert(i32 %48)
%50 = getelementptr inbounds i8, i8* %24, i64 11
%51 = tail call i32 @test_strchr(i8* %24, i8 signext 33, i8* %50)
%52 = tail call i32 @assert(i32 %51)
%53 = tail call i32 @test_strrchr(i8* %24, i8 signext 72, i8* %24)
%54 = tail call i32 @assert(i32 %53)
%55 = getelementptr inbounds i8, i8* %24, i64 7
%56 = tail call i32 @test_strrchr(i8* %24, i8 signext 111, i8* %55)
%57 = tail call i32 @assert(i32 %56)
%58 = tail call i32 @test_strrchr(i8* %24, i8 signext 97, i8* null)
%59 = tail call i32 @assert(i32 %58)
%60 = getelementptr inbounds i8, i8* %24, i64 9
%61 = tail call i32 @test_strrchr(i8* %24, i8 signext 108, i8* %60)
%62 = tail call i32 @assert(i32 %61)
%63 = tail call i32 @test_strrchr(i8* %24, i8 signext 33, i8* %50)
%64 = tail call i32 @assert(i32 %63)
%65 = tail call i32 @test_strcasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 0)
%66 = tail call i32 @assert(i32 %65)
%67 = tail call i32 @test_strcasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i32 0)
%68 = tail call i32 @assert(i32 %67)
%69 = tail call i32 @test_strcasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0), i32 -1)
%70 = tail call i32 @assert(i32 %69)
%71 = tail call i32 @test_strcasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 1)
%72 = tail call i32 @assert(i32 %71)
%73 = tail call i32 @strlen(i8* %24)
%74 = tail call i32 @test_strncasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %73, i32 0)
%75 = tail call i32 @assert(i32 %74)
%76 = tail call i32 @strlen(i8* %24)
%77 = tail call i32 @test_strncasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.2, i64 0, i64 0), i32 %76, i32 0)
%78 = tail call i32 @assert(i32 %77)
%79 = tail call i32 @strlen(i8* %24)
%80 = tail call i32 @test_strncasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.3, i64 0, i64 0), i32 %79, i32 -1)
%81 = tail call i32 @assert(i32 %80)
%82 = tail call i32 @strlen(i8* %24)
%83 = tail call i32 @test_strncasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 %82, i32 1)
%84 = tail call i32 @assert(i32 %83)
%85 = tail call i32 @test_strncasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 0, i32 0)
%86 = tail call i32 @assert(i32 %85)
%87 = tail call i32 @test_strncasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 1, i32 0)
%88 = tail call i32 @assert(i32 %87)
%89 = tail call i32 @test_strncasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.4, i64 0, i64 0), i32 2, i32 0)
%90 = tail call i32 @assert(i32 %89)
%91 = tail call i32 @test_strncasecmp(i8* %24, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.5, i64 0, i64 0), i32 5, i32 -1)
%92 = tail call i32 @assert(i32 %91)
%93 = tail call i32 @free(i8* %24)
%94 = tail call dereferenceable_or_null(20) i8* @malloc(i32 20)
%95 = tail call dereferenceable_or_null(20) i8* @malloc(i32 20)
%96 = tail call i32 @strncpy(i8* %94, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.6, i64 0, i64 0), i32 20)
%97 = tail call i32 @strncpy(i8* %95, i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.7, i64 0, i64 0), i32 20)
%98 = getelementptr inbounds i8, i8* %94, i64 5
%99 = tail call i32 @strlen(i8* %95)
%100 = tail call i32 @strlen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%101 = tail call i32 @test_memmove(i8* %98, i8* %95, i32 %99, i8* %94, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %100)
%102 = tail call i32 @assert(i32 %101)
%103 = tail call i32 @strncpy(i8* %94, i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.8, i64 0, i64 0), i32 20)
%104 = getelementptr inbounds i8, i8* %94, i64 1
%105 = tail call i32 @strlen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%106 = tail call i32 @strlen(i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%107 = tail call i32 @test_memmove(i8* %94, i8* %104, i32 %105, i8* %94, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0), i32 %106)
%108 = tail call i32 @assert(i32 %107)
%109 = tail call i32 @strncpy(i8* %94, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.9, i64 0, i64 0), i32 20)
%110 = tail call i32 @strlen(i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.9, i64 0, i64 0))
%111 = tail call i32 @strlen(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0))
%112 = tail call i32 @test_memmove(i8* %104, i8* %94, i32 %110, i8* %94, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), i32 %111)
%113 = tail call i32 @assert(i32 %112)
%114 = tail call i32 @free(i8* %94)
%115 = tail call i32 @free(i8* %95)
ret i32 0
}