void test_cmps(void *mem) {
  unsigned char *m1 = mem, *m2 = mem + 1024;
  unsigned char m3[1024];
  void *rsi, *rdi;
  long rcx, tmp;
  for (int i = 0; i < 100; ++i)
    m1[i] = m2[i] = m3[i] = i;
  for (int i = 100; i < 200; ++i)
    m1[i] = (m3[i] = m2[i] = i) + 1;
  rsi = m1;
  rdi = m3;
  rcx = 30;
  asm volatile("xor %[tmp], %[tmp] \n\t"
               "repe/cmpsb"
               : "+S"(rsi), "+D"(rdi), "+c"(rcx), [tmp] "=&r"(tmp)
               :
               : "cc");
  report("repe/cmpsb (1)", rcx == 0 && rsi == m1 + 30 && rdi == m3 + 30);
  rsi = m1;
  rdi = m3;
  rcx = 15;
  asm volatile("xor %[tmp], %[tmp] \n\t"
               "repe/cmpsw"
               : "+S"(rsi), "+D"(rdi), "+c"(rcx), [tmp] "=&r"(tmp)
               :
               : "cc");
  report("repe/cmpsw (1)", rcx == 0 && rsi == m1 + 30 && rdi == m3 + 30);
  rsi = m1;
  rdi = m3;
  rcx = 7;
  asm volatile("xor %[tmp], %[tmp] \n\t"
               "repe/cmpsl"
               : "+S"(rsi), "+D"(rdi), "+c"(rcx), [tmp] "=&r"(tmp)
               :
               : "cc");
  report("repe/cmpll (1)", rcx == 0 && rsi == m1 + 28 && rdi == m3 + 28);
  rsi = m1;
  rdi = m3;
  rcx = 4;
  asm volatile("xor %[tmp], %[tmp] \n\t"
               "repe/cmpsq"
               : "+S"(rsi), "+D"(rdi), "+c"(rcx), [tmp] "=&r"(tmp)
               :
               : "cc");
  report("repe/cmpsq (1)", rcx == 0 && rsi == m1 + 32 && rdi == m3 + 32);
  rsi = m1;
  rdi = m3;
  rcx = 130;
  asm volatile("xor %[tmp], %[tmp] \n\t"
               "repe/cmpsb"
               : "+S"(rsi), "+D"(rdi), "+c"(rcx), [tmp] "=&r"(tmp)
               :
               : "cc");
  report("repe/cmpsb (2)", rcx == 29 && rsi == m1 + 101 && rdi == m3 + 101);
  rsi = m1;
  rdi = m3;
  rcx = 65;
  asm volatile("xor %[tmp], %[tmp] \n\t"
               "repe/cmpsw"
               : "+S"(rsi), "+D"(rdi), "+c"(rcx), [tmp] "=&r"(tmp)
               :
               : "cc");
  report("repe/cmpsw (2)", rcx == 14 && rsi == m1 + 102 && rdi == m3 + 102);
  rsi = m1;
  rdi = m3;
  rcx = 32;
  asm volatile("xor %[tmp], %[tmp] \n\t"
               "repe/cmpsl"
               : "+S"(rsi), "+D"(rdi), "+c"(rcx), [tmp] "=&r"(tmp)
               :
               : "cc");
  report("repe/cmpll (2)", rcx == 6 && rsi == m1 + 104 && rdi == m3 + 104);
  rsi = m1;
  rdi = m3;
  rcx = 16;
  asm volatile("xor %[tmp], %[tmp] \n\t"
               "repe/cmpsq"
               : "+S"(rsi), "+D"(rdi), "+c"(rcx), [tmp] "=&r"(tmp)
               :
               : "cc");
  report("repe/cmpsq (2)", rcx == 3 && rsi == m1 + 104 && rdi == m3 + 104);
}


x86 assembly (clang, -O0):
<test_cmps>:
push   %rbp
mov    %rsp,%rbp
sub    $0x450,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x10(%rbp)
mov    -0x8(%rbp),%rax
add    $0x400,%rax
mov    %rax,-0x18(%rbp)
movl   $0x0,-0x444(%rbp)
cmpl   $0x64,-0x444(%rbp)
jge    1192 <test_cmps+0x82>
mov    -0x444(%rbp),%eax
mov    %al,%dl
movslq -0x444(%rbp),%rax
mov    %dl,-0x420(%rbp,%rax,1)
mov    -0x18(%rbp),%rax
movslq -0x444(%rbp),%rcx
mov    %dl,(%rax,%rcx,1)
mov    -0x10(%rbp),%rax
movslq -0x444(%rbp),%rcx
mov    %dl,(%rax,%rcx,1)
mov    -0x444(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x444(%rbp)
jmp    113f <test_cmps+0x2f>
movl   $0x64,-0x448(%rbp)
cmpl   $0xc8,-0x448(%rbp)
jge    11f8 <test_cmps+0xe8>
mov    -0x448(%rbp),%eax
mov    -0x18(%rbp),%rcx
movslq -0x448(%rbp),%rdx
mov    %al,(%rcx,%rdx,1)
movslq -0x448(%rbp),%rcx
mov    %al,-0x420(%rbp,%rcx,1)
movzbl %al,%eax
add    $0x1,%eax
mov    %al,%dl
mov    -0x10(%rbp),%rax
movslq -0x448(%rbp),%rcx
mov    %dl,(%rax,%rcx,1)
mov    -0x448(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x448(%rbp)
jmp    119c <test_cmps+0x8c>
mov    -0x10(%rbp),%rax
mov    %rax,-0x428(%rbp)
lea    -0x420(%rbp),%rax
mov    %rax,-0x430(%rbp)
movq   $0x1e,-0x438(%rbp)
mov    -0x428(%rbp),%rsi
mov    -0x430(%rbp),%rdi
mov    -0x438(%rbp),%rcx
xor    %rax,%rax
repz cmpsb %es:(%rdi),%ds:(%rsi)
mov    %rsi,-0x428(%rbp)
mov    %rdi,-0x430(%rbp)
mov    %rcx,-0x438(%rbp)
mov    %rax,-0x440(%rbp)
xor    %eax,%eax
cmpq   $0x0,-0x438(%rbp)
mov    %al,-0x449(%rbp)
jne    12a6 <test_cmps+0x196>
mov    -0x428(%rbp),%rcx
mov    -0x10(%rbp),%rdx
add    $0x1e,%rdx
xor    %eax,%eax
cmp    %rdx,%rcx
mov    %al,-0x449(%rbp)
jne    12a6 <test_cmps+0x196>
mov    -0x430(%rbp),%rax
lea    -0x420(%rbp),%rcx
add    $0x1e,%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x449(%rbp)
mov    -0x449(%rbp),%al
and    $0x1,%al
movzbl %al,%esi
lea    0xd48(%rip),%rdi
mov    $0x0,%al
call   1030 <report@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x428(%rbp)
lea    -0x420(%rbp),%rax
mov    %rax,-0x430(%rbp)
movq   $0xf,-0x438(%rbp)
mov    -0x428(%rbp),%rsi
mov    -0x430(%rbp),%rdi
mov    -0x438(%rbp),%rcx
xor    %rax,%rax
repz cmpsw %es:(%rdi),%ds:(%rsi)
mov    %rsi,-0x428(%rbp)
mov    %rdi,-0x430(%rbp)
mov    %rcx,-0x438(%rbp)
mov    %rax,-0x440(%rbp)
xor    %eax,%eax
cmpq   $0x0,-0x438(%rbp)
mov    %al,-0x44a(%rbp)
jne    136e <test_cmps+0x25e>
mov    -0x428(%rbp),%rcx
mov    -0x10(%rbp),%rdx
add    $0x1e,%rdx
xor    %eax,%eax
cmp    %rdx,%rcx
mov    %al,-0x44a(%rbp)
jne    136e <test_cmps+0x25e>
mov    -0x430(%rbp),%rax
lea    -0x420(%rbp),%rcx
add    $0x1e,%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x44a(%rbp)
mov    -0x44a(%rbp),%al
and    $0x1,%al
movzbl %al,%esi
lea    0xc8f(%rip),%rdi
mov    $0x0,%al
call   1030 <report@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x428(%rbp)
lea    -0x420(%rbp),%rax
mov    %rax,-0x430(%rbp)
movq   $0x7,-0x438(%rbp)
mov    -0x428(%rbp),%rsi
mov    -0x430(%rbp),%rdi
mov    -0x438(%rbp),%rcx
xor    %rax,%rax
repz cmpsl %es:(%rdi),%ds:(%rsi)
mov    %rsi,-0x428(%rbp)
mov    %rdi,-0x430(%rbp)
mov    %rcx,-0x438(%rbp)
mov    %rax,-0x440(%rbp)
xor    %eax,%eax
cmpq   $0x0,-0x438(%rbp)
mov    %al,-0x44b(%rbp)
jne    1435 <test_cmps+0x325>
mov    -0x428(%rbp),%rcx
mov    -0x10(%rbp),%rdx
add    $0x1c,%rdx
xor    %eax,%eax
cmp    %rdx,%rcx
mov    %al,-0x44b(%rbp)
jne    1435 <test_cmps+0x325>
mov    -0x430(%rbp),%rax
lea    -0x420(%rbp),%rcx
add    $0x1c,%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x44b(%rbp)
mov    -0x44b(%rbp),%al
and    $0x1,%al
movzbl %al,%esi
lea    0xbd7(%rip),%rdi
mov    $0x0,%al
call   1030 <report@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x428(%rbp)
lea    -0x420(%rbp),%rax
mov    %rax,-0x430(%rbp)
movq   $0x4,-0x438(%rbp)
mov    -0x428(%rbp),%rsi
mov    -0x430(%rbp),%rdi
mov    -0x438(%rbp),%rcx
xor    %rax,%rax
repz cmpsq %es:(%rdi),%ds:(%rsi)
mov    %rsi,-0x428(%rbp)
mov    %rdi,-0x430(%rbp)
mov    %rcx,-0x438(%rbp)
mov    %rax,-0x440(%rbp)
xor    %eax,%eax
cmpq   $0x0,-0x438(%rbp)
mov    %al,-0x44c(%rbp)
jne    14fd <test_cmps+0x3ed>
mov    -0x428(%rbp),%rcx
mov    -0x10(%rbp),%rdx
add    $0x20,%rdx
xor    %eax,%eax
cmp    %rdx,%rcx
mov    %al,-0x44c(%rbp)
jne    14fd <test_cmps+0x3ed>
mov    -0x430(%rbp),%rax
lea    -0x420(%rbp),%rcx
add    $0x20,%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x44c(%rbp)
mov    -0x44c(%rbp),%al
and    $0x1,%al
movzbl %al,%esi
lea    0xb1e(%rip),%rdi
mov    $0x0,%al
call   1030 <report@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x428(%rbp)
lea    -0x420(%rbp),%rax
mov    %rax,-0x430(%rbp)
movq   $0x82,-0x438(%rbp)
mov    -0x428(%rbp),%rsi
mov    -0x430(%rbp),%rdi
mov    -0x438(%rbp),%rcx
xor    %rax,%rax
repz cmpsb %es:(%rdi),%ds:(%rsi)
mov    %rsi,-0x428(%rbp)
mov    %rdi,-0x430(%rbp)
mov    %rcx,-0x438(%rbp)
mov    %rax,-0x440(%rbp)
xor    %eax,%eax
cmpq   $0x1d,-0x438(%rbp)
1d
mov    %al,-0x44d(%rbp)
jne    15c4 <test_cmps+0x4b4>
mov    -0x428(%rbp),%rcx
mov    -0x10(%rbp),%rdx
add    $0x65,%rdx
xor    %eax,%eax
cmp    %rdx,%rcx
mov    %al,-0x44d(%rbp)
jne    15c4 <test_cmps+0x4b4>
mov    -0x430(%rbp),%rax
lea    -0x420(%rbp),%rcx
add    $0x65,%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x44d(%rbp)
mov    -0x44d(%rbp),%al
and    $0x1,%al
movzbl %al,%esi
lea    0xa66(%rip),%rdi
mov    $0x0,%al
call   1030 <report@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x428(%rbp)
lea    -0x420(%rbp),%rax
mov    %rax,-0x430(%rbp)
movq   $0x41,-0x438(%rbp)
mov    -0x428(%rbp),%rsi
mov    -0x430(%rbp),%rdi
mov    -0x438(%rbp),%rcx
xor    %rax,%rax
repz cmpsw %es:(%rdi),%ds:(%rsi)
mov    %rsi,-0x428(%rbp)
mov    %rdi,-0x430(%rbp)
mov    %rcx,-0x438(%rbp)
mov    %rax,-0x440(%rbp)
xor    %eax,%eax
cmpq   $0xe,-0x438(%rbp)
0e
mov    %al,-0x44e(%rbp)
jne    168c <test_cmps+0x57c>
mov    -0x428(%rbp),%rcx
mov    -0x10(%rbp),%rdx
add    $0x66,%rdx
xor    %eax,%eax
cmp    %rdx,%rcx
mov    %al,-0x44e(%rbp)
jne    168c <test_cmps+0x57c>
mov    -0x430(%rbp),%rax
lea    -0x420(%rbp),%rcx
add    $0x66,%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x44e(%rbp)
mov    -0x44e(%rbp),%al
and    $0x1,%al
movzbl %al,%esi
lea    0x9ad(%rip),%rdi
mov    $0x0,%al
call   1030 <report@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x428(%rbp)
lea    -0x420(%rbp),%rax
mov    %rax,-0x430(%rbp)
movq   $0x20,-0x438(%rbp)
mov    -0x428(%rbp),%rsi
mov    -0x430(%rbp),%rdi
mov    -0x438(%rbp),%rcx
xor    %rax,%rax
repz cmpsl %es:(%rdi),%ds:(%rsi)
mov    %rsi,-0x428(%rbp)
mov    %rdi,-0x430(%rbp)
mov    %rcx,-0x438(%rbp)
mov    %rax,-0x440(%rbp)
xor    %eax,%eax
cmpq   $0x6,-0x438(%rbp)
06
mov    %al,-0x44f(%rbp)
jne    1753 <test_cmps+0x643>
mov    -0x428(%rbp),%rcx
mov    -0x10(%rbp),%rdx
add    $0x68,%rdx
xor    %eax,%eax
cmp    %rdx,%rcx
mov    %al,-0x44f(%rbp)
jne    1753 <test_cmps+0x643>
mov    -0x430(%rbp),%rax
lea    -0x420(%rbp),%rcx
add    $0x68,%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x44f(%rbp)
mov    -0x44f(%rbp),%al
and    $0x1,%al
movzbl %al,%esi
lea    0x8f5(%rip),%rdi
mov    $0x0,%al
call   1030 <report@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x428(%rbp)
lea    -0x420(%rbp),%rax
mov    %rax,-0x430(%rbp)
movq   $0x10,-0x438(%rbp)
mov    -0x428(%rbp),%rsi
mov    -0x430(%rbp),%rdi
mov    -0x438(%rbp),%rcx
xor    %rax,%rax
repz cmpsq %es:(%rdi),%ds:(%rsi)
mov    %rsi,-0x428(%rbp)
mov    %rdi,-0x430(%rbp)
mov    %rcx,-0x438(%rbp)
mov    %rax,-0x440(%rbp)
xor    %eax,%eax
cmpq   $0x3,-0x438(%rbp)
03
mov    %al,-0x450(%rbp)
jne    181b <test_cmps+0x70b>
mov    -0x428(%rbp),%rcx
mov    -0x10(%rbp),%rdx
add    $0x68,%rdx
xor    %eax,%eax
cmp    %rdx,%rcx
mov    %al,-0x450(%rbp)
jne    181b <test_cmps+0x70b>
mov    -0x430(%rbp),%rax
lea    -0x420(%rbp),%rcx
add    $0x68,%rcx
cmp    %rcx,%rax
sete   %al
mov    %al,-0x450(%rbp)
mov    -0x450(%rbp),%al
and    $0x1,%al
movzbl %al,%esi
lea    0x83c(%rip),%rdi
mov    $0x0,%al
call   1030 <report@plt>
add    $0x450,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<test_cmps>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x408,%rsp
mov    %rdi,%rbx
movaps 0xed5(%rip),%xmm0
movaps %xmm0,(%rsp)
movups %xmm0,0x400(%rdi)
movups %xmm0,(%rdi)
movaps 0xed0(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
movups %xmm0,0x410(%rdi)
movups %xmm0,0x10(%rdi)
movaps 0xec9(%rip),%xmm0
movaps %xmm0,0x20(%rsp)
movups %xmm0,0x420(%rdi)
movups %xmm0,0x20(%rdi)
movaps 0xec2(%rip),%xmm0
movaps %xmm0,0x30(%rsp)
movups %xmm0,0x430(%rdi)
movups %xmm0,0x30(%rdi)
movaps 0xebb(%rip),%xmm0
movaps %xmm0,0x40(%rsp)
movups %xmm0,0x440(%rdi)
movups %xmm0,0x40(%rdi)
movaps 0xeb4(%rip),%xmm0
movaps %xmm0,0x50(%rsp)
movups %xmm0,0x450(%rdi)
movups %xmm0,0x50(%rdi)
movb   $0x60,0x60(%rsp)
movb   $0x60,0x460(%rdi)
movb   $0x60,0x60(%rdi)
movb   $0x61,0x61(%rsp)
movb   $0x61,0x461(%rdi)
movb   $0x61,0x61(%rdi)
movb   $0x62,0x62(%rsp)
movb   $0x62,0x462(%rdi)
movb   $0x62,0x62(%rdi)
movb   $0x63,0x63(%rsp)
movb   $0x63,0x463(%rdi)
movb   $0x63,0x63(%rdi)
movaps 0xe6d(%rip),%xmm0
movups %xmm0,0x464(%rdi)
movups %xmm0,0x64(%rsp)
movaps 0xe6a(%rip),%xmm0
movups %xmm0,0x64(%rdi)
movaps 0xe6f(%rip),%xmm0
movups %xmm0,0x474(%rdi)
movups %xmm0,0x74(%rsp)
movaps 0xe6c(%rip),%xmm0
movups %xmm0,0x74(%rdi)
movaps 0xe71(%rip),%xmm0
movups %xmm0,0x484(%rdi)
movups %xmm0,0x84(%rsp)
movaps 0xe6b(%rip),%xmm0
movups %xmm0,0x84(%rdi)
movaps 0xe6d(%rip),%xmm0
movups %xmm0,0x494(%rdi)
movups %xmm0,0x94(%rsp)
movaps 0xe67(%rip),%xmm0
movups %xmm0,0x94(%rdi)
movaps 0xe69(%rip),%xmm0
movups %xmm0,0x4a4(%rdi)
movups %xmm0,0xa4(%rsp)
movaps 0xe63(%rip),%xmm0
movups %xmm0,0xa4(%rdi)
movaps 0xe65(%rip),%xmm0
movups %xmm0,0x4b4(%rdi)
movups %xmm0,0xb4(%rsp)
movaps 0xe5f(%rip),%xmm0
movups %xmm0,0xb4(%rdi)
movb   $0xc4,0x4c4(%rdi)
movb   $0xc4,0xc4(%rsp)
c4
movb   $0xc5,0xc4(%rdi)
movb   $0xc5,0x4c5(%rdi)
movb   $0xc5,0xc5(%rsp)
c5
movb   $0xc6,0xc5(%rdi)
movb   $0xc6,0x4c6(%rdi)
movb   $0xc6,0xc6(%rsp)
c6
movb   $0xc7,0xc6(%rdi)
movb   $0xc7,0x4c7(%rdi)
movb   $0xc7,0xc7(%rsp)
c7
movb   $0xc8,0xc7(%rdi)
mov    %rsp,%r14
mov    $0x1e,%ecx
mov    %rdi,%rsi
mov    %r14,%rdi
xor    %rax,%rax
repz cmpsb %es:(%rdi),%ds:(%rsi)
lea    0x20(%rsp),%r15
lea    0x20(%rbx),%r12
lea    0x1e(%rbx),%r13
xor    %r13,%rsi
or     %rcx,%rsi
lea    0x1e(%rsp),%rbp
xor    %rbp,%rdi
xor    %eax,%eax
or     %rsi,%rdi
sete   %al
lea    0xdd3(%rip),%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1030 <report@plt>
mov    $0xf,%ecx
mov    %rbx,%rsi
mov    %r14,%rdi
xor    %rax,%rax
repz cmpsw %es:(%rdi),%ds:(%rsi)
xor    %r13,%rsi
or     %rcx,%rsi
xor    %rbp,%rdi
xor    %eax,%eax
or     %rsi,%rdi
sete   %al
lea    0xdb0(%rip),%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1030 <report@plt>
mov    $0x7,%ecx
mov    %rbx,%rsi
mov    %r14,%rdi
xor    %rax,%rax
repz cmpsl %es:(%rdi),%ds:(%rsi)
lea    0x1c(%rbx),%rax
xor    %rsi,%rax
or     %rcx,%rax
lea    0x1c(%rsp),%rcx
xor    %rdi,%rcx
xor    %esi,%esi
or     %rax,%rcx
sete   %sil
lea    0xd84(%rip),%rdi
xor    %eax,%eax
call   1030 <report@plt>
mov    $0x4,%ecx
mov    %rbx,%rsi
mov    %r14,%rdi
xor    %rax,%rax
repz cmpsq %es:(%rdi),%ds:(%rsi)
xor    %r12,%rsi
or     %rcx,%rsi
xor    %r15,%rdi
xor    %eax,%eax
or     %rsi,%rdi
sete   %al
lea    0xd63(%rip),%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1030 <report@plt>
mov    $0x82,%ecx
mov    %rbx,%rsi
mov    %r14,%rdi
xor    %rax,%rax
repz cmpsb %es:(%rdi),%ds:(%rsi)
xor    $0x1d,%rcx
lea    0x65(%rbx),%rax
xor    %rsi,%rax
or     %rcx,%rax
lea    0x65(%rsp),%rcx
xor    %rdi,%rcx
xor    %esi,%esi
or     %rax,%rcx
sete   %sil
lea    0xd33(%rip),%rdi
xor    %eax,%eax
call   1030 <report@plt>
mov    $0x41,%ecx
mov    %rbx,%rsi
mov    %r14,%rdi
xor    %rax,%rax
repz cmpsw %es:(%rdi),%ds:(%rsi)
xor    $0xe,%rcx
lea    0x66(%rbx),%rax
xor    %rsi,%rax
or     %rcx,%rax
lea    0x66(%rsp),%rcx
xor    %rdi,%rcx
xor    %esi,%esi
or     %rax,%rcx
sete   %sil
lea    0xd04(%rip),%rdi
xor    %eax,%eax
call   1030 <report@plt>
mov    $0x20,%ecx
mov    %rbx,%rsi
mov    %r14,%rdi
xor    %rax,%rax
repz cmpsl %es:(%rdi),%ds:(%rsi)
xor    $0x6,%rcx
mov    %rbx,%r15
add    $0x68,%r15
xor    %r15,%rsi
or     %rcx,%rsi
lea    0x68(%rsp),%rbp
xor    %rbp,%rdi
xor    %eax,%eax
or     %rsi,%rdi
sete   %al
lea    0xcd4(%rip),%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1030 <report@plt>
mov    $0x10,%ecx
mov    %rbx,%rsi
mov    %r14,%rdi
xor    %rax,%rax
repz cmpsq %es:(%rdi),%ds:(%rsi)
xor    $0x3,%rcx
xor    %r15,%rsi
or     %rcx,%rsi
xor    %rbp,%rdi
xor    %eax,%eax
or     %rsi,%rdi
sete   %al
lea    0xcad(%rip),%rdi
mov    %eax,%esi
xor    %eax,%eax
call   1030 <report@plt>
add    $0x408,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [15 x i8] c"repe/cmpsb (1)\00"
@.str.1 = [15 x i8] c"repe/cmpsw (1)\00"
@.str.2 = [15 x i8] c"repe/cmpll (1)\00"
@.str.3 = [15 x i8] c"repe/cmpsq (1)\00"
@.str.4 = [15 x i8] c"repe/cmpsb (2)\00"
@.str.5 = [15 x i8] c"repe/cmpsw (2)\00"
@.str.6 = [15 x i8] c"repe/cmpll (2)\00"
@.str.7 = [15 x i8] c"repe/cmpsq (2)\00"
define void @test_cmps(i8* %0) {
%2 = alloca i8*
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca [1024 x i8]
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i64
%9 = alloca i64
%10 = alloca i32
%11 = alloca i32
store i8* %0, i8** %2
%12 = load i8*, i8** %2
store i8* %12, i8** %3
%13 = load i8*, i8** %2
%14 = getelementptr i8, i8* %13, i64 1024
store i8* %14, i8** %4
store i32 0, i32* %10
br label %15
15: ; preds = %32, %1
%16 = load i32, i32* %10
%17 = icmp slt i32 %16, 100
br i1 %17, label %18, label %35
18: ; preds = %15
%19 = load i32, i32* %10
%20 = trunc i32 %19 to i8
%21 = load i32, i32* %10
%22 = sext i32 %21 to i64
%23 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 %22
store i8 %20, i8* %23
%24 = load i8*, i8** %4
%25 = load i32, i32* %10
%26 = sext i32 %25 to i64
%27 = getelementptr inbounds i8, i8* %24, i64 %26
store i8 %20, i8* %27
%28 = load i8*, i8** %3
%29 = load i32, i32* %10
%30 = sext i32 %29 to i64
%31 = getelementptr inbounds i8, i8* %28, i64 %30
store i8 %20, i8* %31
br label %32
32: ; preds = %18
%33 = load i32, i32* %10
%34 = add nsw i32 %33, 1
store i32 %34, i32* %10
br label %15
35: ; preds = %15
store i32 100, i32* %11
br label %36
36: ; preds = %56, %35
%37 = load i32, i32* %11
%38 = icmp slt i32 %37, 200
br i1 %38, label %39, label %59
39: ; preds = %36
%40 = load i32, i32* %11
%41 = trunc i32 %40 to i8
%42 = load i8*, i8** %4
%43 = load i32, i32* %11
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds i8, i8* %42, i64 %44
store i8 %41, i8* %45
%46 = load i32, i32* %11
%47 = sext i32 %46 to i64
%48 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 %47
store i8 %41, i8* %48
%49 = zext i8 %41 to i32
%50 = add nsw i32 %49, 1
%51 = trunc i32 %50 to i8
%52 = load i8*, i8** %3
%53 = load i32, i32* %11
%54 = sext i32 %53 to i64
%55 = getelementptr inbounds i8, i8* %52, i64 %54
store i8 %51, i8* %55
br label %56
56: ; preds = %39
%57 = load i32, i32* %11
%58 = add nsw i32 %57, 1
store i32 %58, i32* %11
br label %36
59: ; preds = %36
%60 = load i8*, i8** %3
store i8* %60, i8** %6
%61 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
store i8* %61, i8** %7
store i64 30, i64* %8
%62 = load i8*, i8** %6
%63 = load i8*, i8** %7
%64 = load i64, i64* %8
%65 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsb", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %62, i8* %63, i64 %64)
%66 = extractvalue { i8*, i8*, i64, i64 } %65, 0
%67 = extractvalue { i8*, i8*, i64, i64 } %65, 1
%68 = extractvalue { i8*, i8*, i64, i64 } %65, 2
%69 = extractvalue { i8*, i8*, i64, i64 } %65, 3
store i8* %66, i8** %6
store i8* %67, i8** %7
store i64 %68, i64* %8
store i64 %69, i64* %9
%70 = load i64, i64* %8
%71 = icmp eq i64 %70, 0
br i1 %71, label %72, label %82
72: ; preds = %59
%73 = load i8*, i8** %6
%74 = load i8*, i8** %3
%75 = getelementptr inbounds i8, i8* %74, i64 30
%76 = icmp eq i8* %73, %75
br i1 %76, label %77, label %82
77: ; preds = %72
%78 = load i8*, i8** %7
%79 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
%80 = getelementptr inbounds i8, i8* %79, i64 30
%81 = icmp eq i8* %78, %80
br label %82
82: ; preds = %77, %72, %59
%83 = phi i1 [ false, %72 ], [ false, %59 ], [ %81, %77 ]
%84 = zext i1 %83 to i32
%85 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i32 %84)
%86 = load i8*, i8** %3
store i8* %86, i8** %6
%87 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
store i8* %87, i8** %7
store i64 15, i64* %8
%88 = load i8*, i8** %6
%89 = load i8*, i8** %7
%90 = load i64, i64* %8
%91 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsw", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %88, i8* %89, i64 %90)
%92 = extractvalue { i8*, i8*, i64, i64 } %91, 0
%93 = extractvalue { i8*, i8*, i64, i64 } %91, 1
%94 = extractvalue { i8*, i8*, i64, i64 } %91, 2
%95 = extractvalue { i8*, i8*, i64, i64 } %91, 3
store i8* %92, i8** %6
store i8* %93, i8** %7
store i64 %94, i64* %8
store i64 %95, i64* %9
%96 = load i64, i64* %8
%97 = icmp eq i64 %96, 0
br i1 %97, label %98, label %108
98: ; preds = %82
%99 = load i8*, i8** %6
%100 = load i8*, i8** %3
%101 = getelementptr inbounds i8, i8* %100, i64 30
%102 = icmp eq i8* %99, %101
br i1 %102, label %103, label %108
103: ; preds = %98
%104 = load i8*, i8** %7
%105 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
%106 = getelementptr inbounds i8, i8* %105, i64 30
%107 = icmp eq i8* %104, %106
br label %108
108: ; preds = %103, %98, %82
%109 = phi i1 [ false, %98 ], [ false, %82 ], [ %107, %103 ]
%110 = zext i1 %109 to i32
%111 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.1, i64 0, i64 0), i32 %110)
%112 = load i8*, i8** %3
store i8* %112, i8** %6
%113 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
store i8* %113, i8** %7
store i64 7, i64* %8
%114 = load i8*, i8** %6
%115 = load i8*, i8** %7
%116 = load i64, i64* %8
%117 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsl", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %114, i8* %115, i64 %116)
%118 = extractvalue { i8*, i8*, i64, i64 } %117, 0
%119 = extractvalue { i8*, i8*, i64, i64 } %117, 1
%120 = extractvalue { i8*, i8*, i64, i64 } %117, 2
%121 = extractvalue { i8*, i8*, i64, i64 } %117, 3
store i8* %118, i8** %6
store i8* %119, i8** %7
store i64 %120, i64* %8
store i64 %121, i64* %9
%122 = load i64, i64* %8
%123 = icmp eq i64 %122, 0
br i1 %123, label %124, label %134
124: ; preds = %108
%125 = load i8*, i8** %6
%126 = load i8*, i8** %3
%127 = getelementptr inbounds i8, i8* %126, i64 28
%128 = icmp eq i8* %125, %127
br i1 %128, label %129, label %134
129: ; preds = %124
%130 = load i8*, i8** %7
%131 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
%132 = getelementptr inbounds i8, i8* %131, i64 28
%133 = icmp eq i8* %130, %132
br label %134
134: ; preds = %129, %124, %108
%135 = phi i1 [ false, %124 ], [ false, %108 ], [ %133, %129 ]
%136 = zext i1 %135 to i32
%137 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0), i32 %136)
%138 = load i8*, i8** %3
store i8* %138, i8** %6
%139 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
store i8* %139, i8** %7
store i64 4, i64* %8
%140 = load i8*, i8** %6
%141 = load i8*, i8** %7
%142 = load i64, i64* %8
%143 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsq", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %140, i8* %141, i64 %142)
%144 = extractvalue { i8*, i8*, i64, i64 } %143, 0
%145 = extractvalue { i8*, i8*, i64, i64 } %143, 1
%146 = extractvalue { i8*, i8*, i64, i64 } %143, 2
%147 = extractvalue { i8*, i8*, i64, i64 } %143, 3
store i8* %144, i8** %6
store i8* %145, i8** %7
store i64 %146, i64* %8
store i64 %147, i64* %9
%148 = load i64, i64* %8
%149 = icmp eq i64 %148, 0
br i1 %149, label %150, label %160
150: ; preds = %134
%151 = load i8*, i8** %6
%152 = load i8*, i8** %3
%153 = getelementptr inbounds i8, i8* %152, i64 32
%154 = icmp eq i8* %151, %153
br i1 %154, label %155, label %160
155: ; preds = %150
%156 = load i8*, i8** %7
%157 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
%158 = getelementptr inbounds i8, i8* %157, i64 32
%159 = icmp eq i8* %156, %158
br label %160
160: ; preds = %155, %150, %134
%161 = phi i1 [ false, %150 ], [ false, %134 ], [ %159, %155 ]
%162 = zext i1 %161 to i32
%163 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.3, i64 0, i64 0), i32 %162)
%164 = load i8*, i8** %3
store i8* %164, i8** %6
%165 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
store i8* %165, i8** %7
store i64 130, i64* %8
%166 = load i8*, i8** %6
%167 = load i8*, i8** %7
%168 = load i64, i64* %8
%169 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsb", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %166, i8* %167, i64 %168)
%170 = extractvalue { i8*, i8*, i64, i64 } %169, 0
%171 = extractvalue { i8*, i8*, i64, i64 } %169, 1
%172 = extractvalue { i8*, i8*, i64, i64 } %169, 2
%173 = extractvalue { i8*, i8*, i64, i64 } %169, 3
store i8* %170, i8** %6
store i8* %171, i8** %7
store i64 %172, i64* %8
store i64 %173, i64* %9
%174 = load i64, i64* %8
%175 = icmp eq i64 %174, 29
br i1 %175, label %176, label %186
176: ; preds = %160
%177 = load i8*, i8** %6
%178 = load i8*, i8** %3
%179 = getelementptr inbounds i8, i8* %178, i64 101
%180 = icmp eq i8* %177, %179
br i1 %180, label %181, label %186
181: ; preds = %176
%182 = load i8*, i8** %7
%183 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
%184 = getelementptr inbounds i8, i8* %183, i64 101
%185 = icmp eq i8* %182, %184
br label %186
186: ; preds = %181, %176, %160
%187 = phi i1 [ false, %176 ], [ false, %160 ], [ %185, %181 ]
%188 = zext i1 %187 to i32
%189 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.4, i64 0, i64 0), i32 %188)
%190 = load i8*, i8** %3
store i8* %190, i8** %6
%191 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
store i8* %191, i8** %7
store i64 65, i64* %8
%192 = load i8*, i8** %6
%193 = load i8*, i8** %7
%194 = load i64, i64* %8
%195 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsw", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %192, i8* %193, i64 %194)
%196 = extractvalue { i8*, i8*, i64, i64 } %195, 0
%197 = extractvalue { i8*, i8*, i64, i64 } %195, 1
%198 = extractvalue { i8*, i8*, i64, i64 } %195, 2
%199 = extractvalue { i8*, i8*, i64, i64 } %195, 3
store i8* %196, i8** %6
store i8* %197, i8** %7
store i64 %198, i64* %8
store i64 %199, i64* %9
%200 = load i64, i64* %8
%201 = icmp eq i64 %200, 14
br i1 %201, label %202, label %212
202: ; preds = %186
%203 = load i8*, i8** %6
%204 = load i8*, i8** %3
%205 = getelementptr inbounds i8, i8* %204, i64 102
%206 = icmp eq i8* %203, %205
br i1 %206, label %207, label %212
207: ; preds = %202
%208 = load i8*, i8** %7
%209 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
%210 = getelementptr inbounds i8, i8* %209, i64 102
%211 = icmp eq i8* %208, %210
br label %212
212: ; preds = %207, %202, %186
%213 = phi i1 [ false, %202 ], [ false, %186 ], [ %211, %207 ]
%214 = zext i1 %213 to i32
%215 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.5, i64 0, i64 0), i32 %214)
%216 = load i8*, i8** %3
store i8* %216, i8** %6
%217 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
store i8* %217, i8** %7
store i64 32, i64* %8
%218 = load i8*, i8** %6
%219 = load i8*, i8** %7
%220 = load i64, i64* %8
%221 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsl", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %218, i8* %219, i64 %220)
%222 = extractvalue { i8*, i8*, i64, i64 } %221, 0
%223 = extractvalue { i8*, i8*, i64, i64 } %221, 1
%224 = extractvalue { i8*, i8*, i64, i64 } %221, 2
%225 = extractvalue { i8*, i8*, i64, i64 } %221, 3
store i8* %222, i8** %6
store i8* %223, i8** %7
store i64 %224, i64* %8
store i64 %225, i64* %9
%226 = load i64, i64* %8
%227 = icmp eq i64 %226, 6
br i1 %227, label %228, label %238
228: ; preds = %212
%229 = load i8*, i8** %6
%230 = load i8*, i8** %3
%231 = getelementptr inbounds i8, i8* %230, i64 104
%232 = icmp eq i8* %229, %231
br i1 %232, label %233, label %238
233: ; preds = %228
%234 = load i8*, i8** %7
%235 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
%236 = getelementptr inbounds i8, i8* %235, i64 104
%237 = icmp eq i8* %234, %236
br label %238
238: ; preds = %233, %228, %212
%239 = phi i1 [ false, %228 ], [ false, %212 ], [ %237, %233 ]
%240 = zext i1 %239 to i32
%241 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.6, i64 0, i64 0), i32 %240)
%242 = load i8*, i8** %3
store i8* %242, i8** %6
%243 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
store i8* %243, i8** %7
store i64 16, i64* %8
%244 = load i8*, i8** %6
%245 = load i8*, i8** %7
%246 = load i64, i64* %8
%247 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsq", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %244, i8* %245, i64 %246)
%248 = extractvalue { i8*, i8*, i64, i64 } %247, 0
%249 = extractvalue { i8*, i8*, i64, i64 } %247, 1
%250 = extractvalue { i8*, i8*, i64, i64 } %247, 2
%251 = extractvalue { i8*, i8*, i64, i64 } %247, 3
store i8* %248, i8** %6
store i8* %249, i8** %7
store i64 %250, i64* %8
store i64 %251, i64* %9
%252 = load i64, i64* %8
%253 = icmp eq i64 %252, 3
br i1 %253, label %254, label %264
254: ; preds = %238
%255 = load i8*, i8** %6
%256 = load i8*, i8** %3
%257 = getelementptr inbounds i8, i8* %256, i64 104
%258 = icmp eq i8* %255, %257
br i1 %258, label %259, label %264
259: ; preds = %254
%260 = load i8*, i8** %7
%261 = getelementptr inbounds [1024 x i8], [1024 x i8]* %5, i64 0, i64 0
%262 = getelementptr inbounds i8, i8* %261, i64 104
%263 = icmp eq i8* %260, %262
br label %264
264: ; preds = %259, %254, %238
%265 = phi i1 [ false, %254 ], [ false, %238 ], [ %263, %259 ]
%266 = zext i1 %265 to i32
%267 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.7, i64 0, i64 0), i32 %266)
ret void
}

LLVM IR (-O2):
@.str = [15 x i8] c"repe/cmpsb (1)\00"
@.str.1 = [15 x i8] c"repe/cmpsw (1)\00"
@.str.2 = [15 x i8] c"repe/cmpll (1)\00"
@.str.3 = [15 x i8] c"repe/cmpsq (1)\00"
@.str.4 = [15 x i8] c"repe/cmpsb (2)\00"
@.str.5 = [15 x i8] c"repe/cmpsw (2)\00"
@.str.6 = [15 x i8] c"repe/cmpll (2)\00"
@.str.7 = [15 x i8] c"repe/cmpsq (2)\00"
define void @test_cmps(i8* %0) {
%2 = alloca [1024 x i8]
%3 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 0
%4 = getelementptr i8, i8* %0, i64 1024
%5 = bitcast [1024 x i8]* %2 to <16 x i8>*
store <16 x i8> <i8 0, i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15>, <16 x i8>* %5
%6 = bitcast i8* %4 to <16 x i8>*
store <16 x i8> <i8 0, i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15>, <16 x i8>* %6
%7 = bitcast i8* %0 to <16 x i8>*
store <16 x i8> <i8 0, i8 1, i8 2, i8 3, i8 4, i8 5, i8 6, i8 7, i8 8, i8 9, i8 10, i8 11, i8 12, i8 13, i8 14, i8 15>, <16 x i8>* %7
%8 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 16
%9 = bitcast i8* %8 to <16 x i8>*
store <16 x i8> <i8 16, i8 17, i8 18, i8 19, i8 20, i8 21, i8 22, i8 23, i8 24, i8 25, i8 26, i8 27, i8 28, i8 29, i8 30, i8 31>, <16 x i8>* %9
%10 = getelementptr i8, i8* %0, i64 1040
%11 = bitcast i8* %10 to <16 x i8>*
store <16 x i8> <i8 16, i8 17, i8 18, i8 19, i8 20, i8 21, i8 22, i8 23, i8 24, i8 25, i8 26, i8 27, i8 28, i8 29, i8 30, i8 31>, <16 x i8>* %11
%12 = getelementptr inbounds i8, i8* %0, i64 16
%13 = bitcast i8* %12 to <16 x i8>*
store <16 x i8> <i8 16, i8 17, i8 18, i8 19, i8 20, i8 21, i8 22, i8 23, i8 24, i8 25, i8 26, i8 27, i8 28, i8 29, i8 30, i8 31>, <16 x i8>* %13
%14 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 32
%15 = bitcast i8* %14 to <16 x i8>*
store <16 x i8> <i8 32, i8 33, i8 34, i8 35, i8 36, i8 37, i8 38, i8 39, i8 40, i8 41, i8 42, i8 43, i8 44, i8 45, i8 46, i8 47>, <16 x i8>* %15
%16 = getelementptr i8, i8* %0, i64 1056
%17 = bitcast i8* %16 to <16 x i8>*
store <16 x i8> <i8 32, i8 33, i8 34, i8 35, i8 36, i8 37, i8 38, i8 39, i8 40, i8 41, i8 42, i8 43, i8 44, i8 45, i8 46, i8 47>, <16 x i8>* %17
%18 = getelementptr inbounds i8, i8* %0, i64 32
%19 = bitcast i8* %18 to <16 x i8>*
store <16 x i8> <i8 32, i8 33, i8 34, i8 35, i8 36, i8 37, i8 38, i8 39, i8 40, i8 41, i8 42, i8 43, i8 44, i8 45, i8 46, i8 47>, <16 x i8>* %19
%20 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 48
%21 = bitcast i8* %20 to <16 x i8>*
store <16 x i8> <i8 48, i8 49, i8 50, i8 51, i8 52, i8 53, i8 54, i8 55, i8 56, i8 57, i8 58, i8 59, i8 60, i8 61, i8 62, i8 63>, <16 x i8>* %21
%22 = getelementptr i8, i8* %0, i64 1072
%23 = bitcast i8* %22 to <16 x i8>*
store <16 x i8> <i8 48, i8 49, i8 50, i8 51, i8 52, i8 53, i8 54, i8 55, i8 56, i8 57, i8 58, i8 59, i8 60, i8 61, i8 62, i8 63>, <16 x i8>* %23
%24 = getelementptr inbounds i8, i8* %0, i64 48
%25 = bitcast i8* %24 to <16 x i8>*
store <16 x i8> <i8 48, i8 49, i8 50, i8 51, i8 52, i8 53, i8 54, i8 55, i8 56, i8 57, i8 58, i8 59, i8 60, i8 61, i8 62, i8 63>, <16 x i8>* %25
%26 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 64
%27 = bitcast i8* %26 to <16 x i8>*
store <16 x i8> <i8 64, i8 65, i8 66, i8 67, i8 68, i8 69, i8 70, i8 71, i8 72, i8 73, i8 74, i8 75, i8 76, i8 77, i8 78, i8 79>, <16 x i8>* %27
%28 = getelementptr i8, i8* %0, i64 1088
%29 = bitcast i8* %28 to <16 x i8>*
store <16 x i8> <i8 64, i8 65, i8 66, i8 67, i8 68, i8 69, i8 70, i8 71, i8 72, i8 73, i8 74, i8 75, i8 76, i8 77, i8 78, i8 79>, <16 x i8>* %29
%30 = getelementptr inbounds i8, i8* %0, i64 64
%31 = bitcast i8* %30 to <16 x i8>*
store <16 x i8> <i8 64, i8 65, i8 66, i8 67, i8 68, i8 69, i8 70, i8 71, i8 72, i8 73, i8 74, i8 75, i8 76, i8 77, i8 78, i8 79>, <16 x i8>* %31
%32 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 80
%33 = bitcast i8* %32 to <16 x i8>*
store <16 x i8> <i8 80, i8 81, i8 82, i8 83, i8 84, i8 85, i8 86, i8 87, i8 88, i8 89, i8 90, i8 91, i8 92, i8 93, i8 94, i8 95>, <16 x i8>* %33
%34 = getelementptr i8, i8* %0, i64 1104
%35 = bitcast i8* %34 to <16 x i8>*
store <16 x i8> <i8 80, i8 81, i8 82, i8 83, i8 84, i8 85, i8 86, i8 87, i8 88, i8 89, i8 90, i8 91, i8 92, i8 93, i8 94, i8 95>, <16 x i8>* %35
%36 = getelementptr inbounds i8, i8* %0, i64 80
%37 = bitcast i8* %36 to <16 x i8>*
store <16 x i8> <i8 80, i8 81, i8 82, i8 83, i8 84, i8 85, i8 86, i8 87, i8 88, i8 89, i8 90, i8 91, i8 92, i8 93, i8 94, i8 95>, <16 x i8>* %37
%38 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 96
store i8 96, i8* %38
%39 = getelementptr i8, i8* %0, i64 1120
store i8 96, i8* %39
%40 = getelementptr inbounds i8, i8* %0, i64 96
store i8 96, i8* %40
%41 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 97
store i8 97, i8* %41
%42 = getelementptr i8, i8* %0, i64 1121
store i8 97, i8* %42
%43 = getelementptr inbounds i8, i8* %0, i64 97
store i8 97, i8* %43
%44 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 98
store i8 98, i8* %44
%45 = getelementptr i8, i8* %0, i64 1122
store i8 98, i8* %45
%46 = getelementptr inbounds i8, i8* %0, i64 98
store i8 98, i8* %46
%47 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 99
store i8 99, i8* %47
%48 = getelementptr i8, i8* %0, i64 1123
store i8 99, i8* %48
%49 = getelementptr inbounds i8, i8* %0, i64 99
store i8 99, i8* %49
%50 = getelementptr i8, i8* %0, i64 1124
%51 = bitcast i8* %50 to <16 x i8>*
store <16 x i8> <i8 100, i8 101, i8 102, i8 103, i8 104, i8 105, i8 106, i8 107, i8 108, i8 109, i8 110, i8 111, i8 112, i8 113, i8 114, i8 115>, <16 x i8>* %51
%52 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 100
%53 = bitcast i8* %52 to <16 x i8>*
store <16 x i8> <i8 100, i8 101, i8 102, i8 103, i8 104, i8 105, i8 106, i8 107, i8 108, i8 109, i8 110, i8 111, i8 112, i8 113, i8 114, i8 115>, <16 x i8>* %53
%54 = getelementptr inbounds i8, i8* %0, i64 100
%55 = bitcast i8* %54 to <16 x i8>*
store <16 x i8> <i8 101, i8 102, i8 103, i8 104, i8 105, i8 106, i8 107, i8 108, i8 109, i8 110, i8 111, i8 112, i8 113, i8 114, i8 115, i8 116>, <16 x i8>* %55
%56 = getelementptr i8, i8* %0, i64 1140
%57 = bitcast i8* %56 to <16 x i8>*
store <16 x i8> <i8 116, i8 117, i8 118, i8 119, i8 120, i8 121, i8 122, i8 123, i8 124, i8 125, i8 126, i8 127, i8 -128, i8 -127, i8 -126, i8 -125>, <16 x i8>* %57
%58 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 116
%59 = bitcast i8* %58 to <16 x i8>*
store <16 x i8> <i8 116, i8 117, i8 118, i8 119, i8 120, i8 121, i8 122, i8 123, i8 124, i8 125, i8 126, i8 127, i8 -128, i8 -127, i8 -126, i8 -125>, <16 x i8>* %59
%60 = getelementptr inbounds i8, i8* %0, i64 116
%61 = bitcast i8* %60 to <16 x i8>*
store <16 x i8> <i8 117, i8 118, i8 119, i8 120, i8 121, i8 122, i8 123, i8 124, i8 125, i8 126, i8 127, i8 -128, i8 -127, i8 -126, i8 -125, i8 -124>, <16 x i8>* %61
%62 = getelementptr i8, i8* %0, i64 1156
%63 = bitcast i8* %62 to <16 x i8>*
store <16 x i8> <i8 -124, i8 -123, i8 -122, i8 -121, i8 -120, i8 -119, i8 -118, i8 -117, i8 -116, i8 -115, i8 -114, i8 -113, i8 -112, i8 -111, i8 -110, i8 -109>, <16 x i8>* %63
%64 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 132
%65 = bitcast i8* %64 to <16 x i8>*
store <16 x i8> <i8 -124, i8 -123, i8 -122, i8 -121, i8 -120, i8 -119, i8 -118, i8 -117, i8 -116, i8 -115, i8 -114, i8 -113, i8 -112, i8 -111, i8 -110, i8 -109>, <16 x i8>* %65
%66 = getelementptr inbounds i8, i8* %0, i64 132
%67 = bitcast i8* %66 to <16 x i8>*
store <16 x i8> <i8 -123, i8 -122, i8 -121, i8 -120, i8 -119, i8 -118, i8 -117, i8 -116, i8 -115, i8 -114, i8 -113, i8 -112, i8 -111, i8 -110, i8 -109, i8 -108>, <16 x i8>* %67
%68 = getelementptr i8, i8* %0, i64 1172
%69 = bitcast i8* %68 to <16 x i8>*
store <16 x i8> <i8 -108, i8 -107, i8 -106, i8 -105, i8 -104, i8 -103, i8 -102, i8 -101, i8 -100, i8 -99, i8 -98, i8 -97, i8 -96, i8 -95, i8 -94, i8 -93>, <16 x i8>* %69
%70 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 148
%71 = bitcast i8* %70 to <16 x i8>*
store <16 x i8> <i8 -108, i8 -107, i8 -106, i8 -105, i8 -104, i8 -103, i8 -102, i8 -101, i8 -100, i8 -99, i8 -98, i8 -97, i8 -96, i8 -95, i8 -94, i8 -93>, <16 x i8>* %71
%72 = getelementptr inbounds i8, i8* %0, i64 148
%73 = bitcast i8* %72 to <16 x i8>*
store <16 x i8> <i8 -107, i8 -106, i8 -105, i8 -104, i8 -103, i8 -102, i8 -101, i8 -100, i8 -99, i8 -98, i8 -97, i8 -96, i8 -95, i8 -94, i8 -93, i8 -92>, <16 x i8>* %73
%74 = getelementptr i8, i8* %0, i64 1188
%75 = bitcast i8* %74 to <16 x i8>*
store <16 x i8> <i8 -92, i8 -91, i8 -90, i8 -89, i8 -88, i8 -87, i8 -86, i8 -85, i8 -84, i8 -83, i8 -82, i8 -81, i8 -80, i8 -79, i8 -78, i8 -77>, <16 x i8>* %75
%76 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 164
%77 = bitcast i8* %76 to <16 x i8>*
store <16 x i8> <i8 -92, i8 -91, i8 -90, i8 -89, i8 -88, i8 -87, i8 -86, i8 -85, i8 -84, i8 -83, i8 -82, i8 -81, i8 -80, i8 -79, i8 -78, i8 -77>, <16 x i8>* %77
%78 = getelementptr inbounds i8, i8* %0, i64 164
%79 = bitcast i8* %78 to <16 x i8>*
store <16 x i8> <i8 -91, i8 -90, i8 -89, i8 -88, i8 -87, i8 -86, i8 -85, i8 -84, i8 -83, i8 -82, i8 -81, i8 -80, i8 -79, i8 -78, i8 -77, i8 -76>, <16 x i8>* %79
%80 = getelementptr i8, i8* %0, i64 1204
%81 = bitcast i8* %80 to <16 x i8>*
store <16 x i8> <i8 -76, i8 -75, i8 -74, i8 -73, i8 -72, i8 -71, i8 -70, i8 -69, i8 -68, i8 -67, i8 -66, i8 -65, i8 -64, i8 -63, i8 -62, i8 -61>, <16 x i8>* %81
%82 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 180
%83 = bitcast i8* %82 to <16 x i8>*
store <16 x i8> <i8 -76, i8 -75, i8 -74, i8 -73, i8 -72, i8 -71, i8 -70, i8 -69, i8 -68, i8 -67, i8 -66, i8 -65, i8 -64, i8 -63, i8 -62, i8 -61>, <16 x i8>* %83
%84 = getelementptr inbounds i8, i8* %0, i64 180
%85 = bitcast i8* %84 to <16 x i8>*
store <16 x i8> <i8 -75, i8 -74, i8 -73, i8 -72, i8 -71, i8 -70, i8 -69, i8 -68, i8 -67, i8 -66, i8 -65, i8 -64, i8 -63, i8 -62, i8 -61, i8 -60>, <16 x i8>* %85
%86 = getelementptr i8, i8* %0, i64 1220
store i8 -60, i8* %86
%87 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 196
store i8 -60, i8* %87
%88 = getelementptr inbounds i8, i8* %0, i64 196
store i8 -59, i8* %88
%89 = getelementptr i8, i8* %0, i64 1221
store i8 -59, i8* %89
%90 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 197
store i8 -59, i8* %90
%91 = getelementptr inbounds i8, i8* %0, i64 197
store i8 -58, i8* %91
%92 = getelementptr i8, i8* %0, i64 1222
store i8 -58, i8* %92
%93 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 198
store i8 -58, i8* %93
%94 = getelementptr inbounds i8, i8* %0, i64 198
store i8 -57, i8* %94
%95 = getelementptr i8, i8* %0, i64 1223
store i8 -57, i8* %95
%96 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 199
store i8 -57, i8* %96
%97 = getelementptr inbounds i8, i8* %0, i64 199
store i8 -56, i8* %97
%98 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsb", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %0, i8* %3, i64 30)
%99 = extractvalue { i8*, i8*, i64, i64 } %98, 1
%100 = extractvalue { i8*, i8*, i64, i64 } %98, 2
%101 = icmp eq i64 %100, 0
%102 = extractvalue { i8*, i8*, i64, i64 } %98, 0
%103 = getelementptr inbounds i8, i8* %0, i64 30
%104 = icmp eq i8* %102, %103
%105 = select i1 %101, i1 %104, i1 false
%106 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 30
%107 = icmp eq i8* %99, %106
%108 = select i1 %105, i1 %107, i1 false
%109 = zext i1 %108 to i32
%110 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str, i64 0, i64 0), i32 %109)
%111 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsw", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %0, i8* %3, i64 15)
%112 = extractvalue { i8*, i8*, i64, i64 } %111, 1
%113 = extractvalue { i8*, i8*, i64, i64 } %111, 2
%114 = icmp eq i64 %113, 0
%115 = extractvalue { i8*, i8*, i64, i64 } %111, 0
%116 = icmp eq i8* %115, %103
%117 = select i1 %114, i1 %116, i1 false
%118 = icmp eq i8* %112, %106
%119 = select i1 %117, i1 %118, i1 false
%120 = zext i1 %119 to i32
%121 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.1, i64 0, i64 0), i32 %120)
%122 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsl", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %0, i8* %3, i64 7)
%123 = extractvalue { i8*, i8*, i64, i64 } %122, 1
%124 = extractvalue { i8*, i8*, i64, i64 } %122, 2
%125 = icmp eq i64 %124, 0
%126 = extractvalue { i8*, i8*, i64, i64 } %122, 0
%127 = getelementptr inbounds i8, i8* %0, i64 28
%128 = icmp eq i8* %126, %127
%129 = select i1 %125, i1 %128, i1 false
%130 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 28
%131 = icmp eq i8* %123, %130
%132 = select i1 %129, i1 %131, i1 false
%133 = zext i1 %132 to i32
%134 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.2, i64 0, i64 0), i32 %133)
%135 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsq", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %0, i8* %3, i64 4)
%136 = extractvalue { i8*, i8*, i64, i64 } %135, 1
%137 = extractvalue { i8*, i8*, i64, i64 } %135, 2
%138 = icmp eq i64 %137, 0
%139 = extractvalue { i8*, i8*, i64, i64 } %135, 0
%140 = getelementptr inbounds i8, i8* %0, i64 32
%141 = icmp eq i8* %139, %140
%142 = select i1 %138, i1 %141, i1 false
%143 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 32
%144 = icmp eq i8* %136, %143
%145 = select i1 %142, i1 %144, i1 false
%146 = zext i1 %145 to i32
%147 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.3, i64 0, i64 0), i32 %146)
%148 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsb", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %0, i8* %3, i64 130)
%149 = extractvalue { i8*, i8*, i64, i64 } %148, 1
%150 = extractvalue { i8*, i8*, i64, i64 } %148, 2
%151 = icmp eq i64 %150, 29
%152 = extractvalue { i8*, i8*, i64, i64 } %148, 0
%153 = getelementptr inbounds i8, i8* %0, i64 101
%154 = icmp eq i8* %152, %153
%155 = select i1 %151, i1 %154, i1 false
%156 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 101
%157 = icmp eq i8* %149, %156
%158 = select i1 %155, i1 %157, i1 false
%159 = zext i1 %158 to i32
%160 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.4, i64 0, i64 0), i32 %159)
%161 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsw", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %0, i8* %3, i64 65)
%162 = extractvalue { i8*, i8*, i64, i64 } %161, 1
%163 = extractvalue { i8*, i8*, i64, i64 } %161, 2
%164 = icmp eq i64 %163, 14
%165 = extractvalue { i8*, i8*, i64, i64 } %161, 0
%166 = getelementptr inbounds i8, i8* %0, i64 102
%167 = icmp eq i8* %165, %166
%168 = select i1 %164, i1 %167, i1 false
%169 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 102
%170 = icmp eq i8* %162, %169
%171 = select i1 %168, i1 %170, i1 false
%172 = zext i1 %171 to i32
%173 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.5, i64 0, i64 0), i32 %172)
%174 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsl", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %0, i8* %3, i64 32)
%175 = extractvalue { i8*, i8*, i64, i64 } %174, 1
%176 = extractvalue { i8*, i8*, i64, i64 } %174, 2
%177 = icmp eq i64 %176, 6
%178 = extractvalue { i8*, i8*, i64, i64 } %174, 0
%179 = getelementptr inbounds i8, i8* %0, i64 104
%180 = icmp eq i8* %178, %179
%181 = select i1 %177, i1 %180, i1 false
%182 = getelementptr inbounds [1024 x i8], [1024 x i8]* %2, i64 0, i64 104
%183 = icmp eq i8* %175, %182
%184 = select i1 %181, i1 %183, i1 false
%185 = zext i1 %184 to i32
%186 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.6, i64 0, i64 0), i32 %185)
%187 = call { i8*, i8*, i64, i64 } asm sideeffect "xor $3, $3 \0A\09repe/cmpsq", "={si},={di},={cx},=&r,0,1,2,~{cc},~{dirflag},~{fpsr},~{flags}"(i8* %0, i8* %3, i64 16)
%188 = extractvalue { i8*, i8*, i64, i64 } %187, 1
%189 = extractvalue { i8*, i8*, i64, i64 } %187, 2
%190 = icmp eq i64 %189, 3
%191 = extractvalue { i8*, i8*, i64, i64 } %187, 0
%192 = icmp eq i8* %191, %179
%193 = select i1 %190, i1 %192, i1 false
%194 = icmp eq i8* %188, %182
%195 = select i1 %193, i1 %194, i1 false
%196 = zext i1 %195 to i32
%197 = call i32 (i8*, i32, ...) bitcast (i32 (...)* @report to i32 (i8*, i32, ...)*)(i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.7, i64 0, i64 0), i32 %196)
ret void
}