#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*/ printf(char *, ...);
int /*<<< orphan*/ scanf(char *, ...);
int main(void) {
  int num, area[8][8], i, j, k, bomb[64][2], sp, bx, by;
  char str[8];
  scanf("%d\n", &num);
  for (i = 0; i < num; i++) {
    sp = 0;
    for (j = 0; j < 8; j++) {
      scanf("%s\n", str);
      for (k = 0; k < 8; k++) {
        if (str[k] == '0') {
          area[j][k] = 0;
        } else {
          area[j][k] = 1;
        }
      }
    }
    scanf("%d %d", &bx, &by);
    bomb[0][0] = bx - 1;
    bomb[0][1] = by - 1;
    sp++;
    while (1) {
      sp--;
      bx = bomb[sp][0];
      by = bomb[sp][1];
      area[by][bx] = 0;
      for (j = bx - 1; bx - 3 <= j && j >= 0; j--) {
        if (area[by][j] == 1) {
          area[by][j] = 0;
          bomb[sp][0] = j;
          bomb[sp][1] = by;
          sp++;
        }
      }
      for (j = bx + 1; bx + 3 >= j && j <= 7; j++) {
        if (area[by][j] == 1) {
          area[by][j] = 0;
          bomb[sp][0] = j;
          bomb[sp][1] = by;
          sp++;
        }
      }
      for (j = by - 1; by - 3 <= j && j >= 0; j--) {
        if (area[j][bx] == 1) {
          area[j][bx] = 0;
          bomb[sp][0] = bx;
          bomb[sp][1] = j;
          sp++;
        }
      }
      for (j = by + 1; by + 3 >= j && j <= 7; j++) {
        if (area[j][bx] == 1) {
          area[j][bx] = 0;
          bomb[sp][0] = bx;
          bomb[sp][1] = j;
          sp++;
        }
      }
      if (sp == 0)
        break;
    }
    printf("Data %d:\n", i + 1);
    for (j = 0; j < 8; j++) {
      for (k = 0; k < 8; k++)
        printf("%d", area[j][k]);
      printf("\n");
    }
  }
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x340,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xec7(%rip),%rdi
lea    -0x8(%rbp),%rsi
mov    $0x0,%al
call   1040 <scanf@plt>
movl   $0x0,-0x114(%rbp)
mov    -0x114(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    175a <main+0x63a>
movl   $0x0,-0x324(%rbp)
movl   $0x0,-0x118(%rbp)
cmpl   $0x8,-0x118(%rbp)
jge    123f <main+0x11f>
lea    -0x334(%rbp),%rsi
lea    0xe78(%rip),%rdi
mov    $0x0,%al
call   1040 <scanf@plt>
movl   $0x0,-0x11c(%rbp)
cmpl   $0x8,-0x11c(%rbp)
jge    1226 <main+0x106>
movslq -0x11c(%rbp),%rax
movsbl -0x334(%rbp,%rax,1),%eax
ff
cmp    $0x30,%eax
jne    11ea <main+0xca>
movslq -0x118(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x11c(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
jmp    120d <main+0xed>
movslq -0x118(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x11c(%rbp),%rcx
movl   $0x1,(%rax,%rcx,4)
jmp    1212 <main+0xf2>
mov    -0x11c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x11c(%rbp)
jmp    119d <main+0x7d>
jmp    122b <main+0x10b>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1171 <main+0x51>
lea    0xdc2(%rip),%rdi
lea    -0x328(%rbp),%rsi
lea    -0x32c(%rbp),%rdx
mov    $0x0,%al
call   1040 <scanf@plt>
mov    -0x328(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x320(%rbp)
mov    -0x32c(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x31c(%rbp)
mov    -0x324(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x324(%rbp)
mov    -0x324(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x324(%rbp)
movslq -0x324(%rbp),%rax
mov    -0x320(%rbp,%rax,8),%eax
mov    %eax,-0x328(%rbp)
movslq -0x324(%rbp),%rax
mov    -0x31c(%rbp,%rax,8),%eax
mov    %eax,-0x32c(%rbp)
movslq -0x32c(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x328(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x328(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x118(%rbp)
mov    -0x328(%rbp),%ecx
sub    $0x3,%ecx
xor    %eax,%eax
cmp    -0x118(%rbp),%ecx
mov    %al,-0x335(%rbp)
jg     131e <main+0x1fe>
cmpl   $0x0,-0x118(%rbp)
setge  %al
mov    %al,-0x335(%rbp)
mov    -0x335(%rbp),%al
test   $0x1,%al
jne    1331 <main+0x211>
jmp    13ca <main+0x2aa>
movslq -0x32c(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x118(%rbp),%rcx
cmpl   $0x1,(%rax,%rcx,4)
jne    13b1 <main+0x291>
movslq -0x32c(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x118(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x118(%rbp),%ecx
movslq -0x324(%rbp),%rax
mov    %ecx,-0x320(%rbp,%rax,8)
mov    -0x32c(%rbp),%ecx
movslq -0x324(%rbp),%rax
mov    %ecx,-0x31c(%rbp,%rax,8)
mov    -0x324(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x324(%rbp)
jmp    13b6 <main+0x296>
mov    -0x118(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x118(%rbp)
jmp    12f1 <main+0x1d1>
mov    -0x328(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
mov    -0x328(%rbp),%ecx
add    $0x3,%ecx
xor    %eax,%eax
cmp    -0x118(%rbp),%ecx
mov    %al,-0x336(%rbp)
jl     1406 <main+0x2e6>
cmpl   $0x7,-0x118(%rbp)
setle  %al
mov    %al,-0x336(%rbp)
mov    -0x336(%rbp),%al
test   $0x1,%al
jne    1419 <main+0x2f9>
jmp    14b2 <main+0x392>
movslq -0x32c(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x118(%rbp),%rcx
cmpl   $0x1,(%rax,%rcx,4)
jne    1499 <main+0x379>
movslq -0x32c(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x118(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x118(%rbp),%ecx
movslq -0x324(%rbp),%rax
mov    %ecx,-0x320(%rbp,%rax,8)
mov    -0x32c(%rbp),%ecx
movslq -0x324(%rbp),%rax
mov    %ecx,-0x31c(%rbp,%rax,8)
mov    -0x324(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x324(%rbp)
jmp    149e <main+0x37e>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    13d9 <main+0x2b9>
mov    -0x32c(%rbp),%eax
sub    $0x1,%eax
mov    %eax,-0x118(%rbp)
mov    -0x32c(%rbp),%ecx
sub    $0x3,%ecx
xor    %eax,%eax
cmp    -0x118(%rbp),%ecx
mov    %al,-0x337(%rbp)
jg     14ee <main+0x3ce>
cmpl   $0x0,-0x118(%rbp)
setge  %al
mov    %al,-0x337(%rbp)
mov    -0x337(%rbp),%al
test   $0x1,%al
jne    1501 <main+0x3e1>
jmp    159a <main+0x47a>
movslq -0x118(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x328(%rbp),%rcx
cmpl   $0x1,(%rax,%rcx,4)
jne    1581 <main+0x461>
movslq -0x118(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x328(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x328(%rbp),%ecx
movslq -0x324(%rbp),%rax
mov    %ecx,-0x320(%rbp,%rax,8)
mov    -0x118(%rbp),%ecx
movslq -0x324(%rbp),%rax
mov    %ecx,-0x31c(%rbp,%rax,8)
mov    -0x324(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x324(%rbp)
jmp    1586 <main+0x466>
mov    -0x118(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x118(%rbp)
jmp    14c1 <main+0x3a1>
mov    -0x32c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
mov    -0x32c(%rbp),%ecx
add    $0x3,%ecx
xor    %eax,%eax
cmp    -0x118(%rbp),%ecx
mov    %al,-0x338(%rbp)
jl     15d6 <main+0x4b6>
cmpl   $0x7,-0x118(%rbp)
setle  %al
mov    %al,-0x338(%rbp)
mov    -0x338(%rbp),%al
test   $0x1,%al
jne    15e9 <main+0x4c9>
jmp    1682 <main+0x562>
movslq -0x118(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x328(%rbp),%rcx
cmpl   $0x1,(%rax,%rcx,4)
jne    1669 <main+0x549>
movslq -0x118(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x328(%rbp),%rcx
movl   $0x0,(%rax,%rcx,4)
mov    -0x328(%rbp),%ecx
movslq -0x324(%rbp),%rax
mov    %ecx,-0x320(%rbp,%rax,8)
mov    -0x118(%rbp),%ecx
movslq -0x324(%rbp),%rax
mov    %ecx,-0x31c(%rbp,%rax,8)
mov    -0x324(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x324(%rbp)
jmp    166e <main+0x54e>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    15a9 <main+0x489>
cmpl   $0x0,-0x324(%rbp)
jne    1694 <main+0x574>
jmp    1699 <main+0x579>
jmp    1288 <main+0x168>
mov    -0x114(%rbp),%esi
add    $0x1,%esi
lea    0x965(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
movl   $0x0,-0x118(%rbp)
cmpl   $0x8,-0x118(%rbp)
jge    1741 <main+0x621>
movl   $0x0,-0x11c(%rbp)
cmpl   $0x8,-0x11c(%rbp)
jge    171f <main+0x5ff>
movslq -0x118(%rbp),%rcx
lea    -0x110(%rbp),%rax
shl    $0x5,%rcx
add    %rcx,%rax
movslq -0x11c(%rbp),%rcx
mov    (%rax,%rcx,4),%esi
lea    0x907(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x11c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x11c(%rbp)
jmp    16d1 <main+0x5b1>
lea    0x8f0(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    16ba <main+0x59a>
jmp    1746 <main+0x626>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    114e <main+0x2e>
xor    %eax,%eax
add    $0x340,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x328,%rsp
lea    0xed8(%rip),%rdi
lea    0x1c(%rsp),%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
cmpl   $0x0,0x1c(%rsp)
jle    1776 <main+0x646>
lea    0x24(%rsp),%r13
lea    0xc(%rsp),%r14
lea    0xebb(%rip),%r15
xor    %r12d,%r12d
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
lea    0xe9d(%rip),%rbx
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movd   0xc(%rsp),%xmm0
movdqa 0xe5e(%rip),%xmm1
pcmpeqb %xmm1,%xmm0
movdqa %xmm1,%xmm3
pcmpeqd %xmm1,%xmm1
pxor   %xmm1,%xmm0
pcmpeqd %xmm2,%xmm2
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
movdqa 0xe4a(%rip),%xmm1
pand   %xmm1,%xmm0
movdqa %xmm0,0x20(%rsp)
movd   0x10(%rsp),%xmm0
pcmpeqb %xmm3,%xmm0
pxor   %xmm2,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
pand   %xmm1,%xmm0
movdqa %xmm0,0x30(%rsp)
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movd   0xc(%rsp),%xmm0
movdqa 0xdf5(%rip),%xmm1
pcmpeqb %xmm1,%xmm0
pcmpeqd %xmm3,%xmm3
pxor   %xmm3,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
movdqa 0xde9(%rip),%xmm2
pand   %xmm2,%xmm0
movdqa %xmm0,0x40(%rsp)
movd   0x10(%rsp),%xmm0
pcmpeqb %xmm1,%xmm0
pxor   %xmm3,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
pand   %xmm2,%xmm0
movdqa %xmm0,0x50(%rsp)
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movd   0xc(%rsp),%xmm0
movdqa 0xd94(%rip),%xmm2
pcmpeqb %xmm2,%xmm0
pcmpeqd %xmm1,%xmm1
pxor   %xmm1,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
movdqa 0xd88(%rip),%xmm3
pand   %xmm3,%xmm0
movdqa %xmm0,0x60(%rsp)
movd   0x10(%rsp),%xmm0
pcmpeqb %xmm2,%xmm0
pxor   %xmm1,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
pand   %xmm3,%xmm0
movdqa %xmm0,0x70(%rsp)
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movd   0xc(%rsp),%xmm0
movdqa 0xd33(%rip),%xmm1
pcmpeqb %xmm1,%xmm0
pcmpeqd %xmm3,%xmm3
pxor   %xmm3,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
movdqa 0xd27(%rip),%xmm2
pand   %xmm2,%xmm0
movdqa %xmm0,0x80(%rsp)
movd   0x10(%rsp),%xmm0
pcmpeqb %xmm1,%xmm0
pxor   %xmm3,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
pand   %xmm2,%xmm0
movdqa %xmm0,0x90(%rsp)
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movd   0xc(%rsp),%xmm0
movdqa 0xccc(%rip),%xmm2
pcmpeqb %xmm2,%xmm0
pcmpeqd %xmm1,%xmm1
pxor   %xmm1,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
movdqa 0xcc0(%rip),%xmm3
pand   %xmm3,%xmm0
movdqa %xmm0,0xa0(%rsp)
movd   0x10(%rsp),%xmm0
pcmpeqb %xmm2,%xmm0
pxor   %xmm1,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
pand   %xmm3,%xmm0
movdqa %xmm0,0xb0(%rsp)
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movd   0xc(%rsp),%xmm0
movdqa 0xc65(%rip),%xmm1
pcmpeqb %xmm1,%xmm0
pcmpeqd %xmm3,%xmm3
pxor   %xmm3,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
movdqa 0xc59(%rip),%xmm2
pand   %xmm2,%xmm0
movdqa %xmm0,0xc0(%rsp)
movd   0x10(%rsp),%xmm0
pcmpeqb %xmm1,%xmm0
pxor   %xmm3,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
pand   %xmm2,%xmm0
movdqa %xmm0,0xd0(%rsp)
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movd   0xc(%rsp),%xmm0
movdqa 0xbfe(%rip),%xmm1
pcmpeqb %xmm1,%xmm0
pcmpeqd %xmm2,%xmm2
pxor   %xmm2,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
movdqa 0xbf2(%rip),%xmm3
pand   %xmm3,%xmm0
movdqa %xmm0,0xe0(%rsp)
movd   0x10(%rsp),%xmm0
pcmpeqb %xmm1,%xmm0
pxor   %xmm2,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
pand   %xmm3,%xmm0
movdqa %xmm0,0xf0(%rsp)
mov    %rbx,%rdi
mov    %r14,%rsi
xor    %eax,%eax
call   1050 <scanf@plt>
movd   0xc(%rsp),%xmm0
movdqa 0xb97(%rip),%xmm1
pcmpeqb %xmm1,%xmm0
pcmpeqd %xmm2,%xmm2
pxor   %xmm2,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
movdqa 0xb8b(%rip),%xmm3
pand   %xmm3,%xmm0
movdqa %xmm0,0x100(%rsp)
movd   0x10(%rsp),%xmm0
pcmpeqb %xmm1,%xmm0
pxor   %xmm2,%xmm0
punpcklbw %xmm0,%xmm0
punpcklwd %xmm0,%xmm0
pand   %xmm3,%xmm0
movdqa %xmm0,0x110(%rsp)
lea    0xb6c(%rip),%rdi
lea    0x18(%rsp),%rsi
lea    0x14(%rsp),%rdx
xor    %eax,%eax
call   1050 <scanf@plt>
mov    0x18(%rsp),%eax
add    $0xffffffff,%eax
mov    %eax,0x120(%rsp)
mov    0x14(%rsp),%eax
add    $0xffffffff,%eax
mov    %eax,0x124(%rsp)
mov    $0x1,%eax
jmp    14f8 <main+0x3c8>
test   %eax,%eax
je     16b0 <main+0x580>
movslq %eax,%rcx
add    $0xffffffff,%eax
movslq 0x118(%rsp,%rcx,8),%r9
mov    0x11c(%rsp,%rcx,8),%r8d
movslq %r8d,%rsi
mov    %rsi,%r10
shl    $0x5,%r10
lea    (%rsp,%r10,1),%rbp
add    $0x20,%rbp
movl   $0x0,0x0(%rbp,%r9,4)
test   %r9,%r9
jle    158a <main+0x45a>
mov    %r9d,%ebx
lea    -0x2(%r9),%rdx
cs nopw 0x0(%rax,%rax,1)
nop
lea    -0x1(%rbx),%ecx
cmpl   $0x1,0x0(%rbp,%rcx,4)
jne    1572 <main+0x442>
lea    0x0(,%rcx,4),%rcx
add    %rbp,%rcx
lea    -0x1(%rbx),%edi
movl   $0x0,(%rcx)
cltq
mov    %edi,0x120(%rsp,%rax,8)
mov    %r8d,0x124(%rsp,%rax,8)
add    $0x1,%eax
cmp    %rdx,%rbx
jle    1584 <main+0x454>
lea    -0x1(%rbx),%rcx
cmp    $0x1,%rbx
mov    %rcx,%rbx
ja     1540 <main+0x410>
cmp    $0x6,%r9d
jg     15d8 <main+0x4a8>
lea    0x2(%r9),%rbp
lea    0x1(%r9),%edx
add    %r13,%r10
mov    %r9,%rcx
nopl   0x0(%rax,%rax,1)
cmpl   $0x1,(%r10,%rcx,4)
jne    15c3 <main+0x493>
movl   $0x0,(%r10,%rcx,4)
cltq
mov    %edx,0x120(%rsp,%rax,8)
mov    %r8d,0x124(%rsp,%rax,8)
add    $0x1,%eax
cmp    %rbp,%rcx
jge    15d8 <main+0x4a8>
add    $0x1,%edx
lea    0x1(%rcx),%rdi
cmp    $0x6,%rcx
mov    %rdi,%rcx
jl     15a0 <main+0x470>
test   %r8d,%r8d
jle    1642 <main+0x512>
lea    -0x2(%rsi),%rdi
mov    %r8,%rdx
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
lea    -0x1(%rdx),%ecx
shl    $0x5,%rcx
add    %rsp,%rcx
add    $0x20,%rcx
cmpl   $0x1,(%rcx,%r9,4)
jne    1626 <main+0x4f6>
lea    (%rcx,%r9,4),%rcx
lea    -0x1(%rdx),%ebp
movl   $0x0,(%rcx)
cltq
mov    %r9d,0x120(%rsp,%rax,8)
mov    %ebp,0x124(%rsp,%rax,8)
add    $0x1,%eax
cmp    %rdi,%rdx
jle    1638 <main+0x508>
lea    -0x1(%rdx),%rcx
cmp    $0x1,%rdx
mov    %rcx,%rdx
ja     15f0 <main+0x4c0>
cmp    $0x6,%r8d
jg     14f0 <main+0x3c0>
lea    0x2(%rsi),%rdi
lea    0x1(%r8),%ebp
lea    (%r9,%rsi,8),%rcx
lea    0x1c(,%rcx,4),%rbx
add    %r13,%rbx
nopl   0x0(%rax)
cmpl   $0x1,(%rbx)
jne    167f <main+0x54f>
movl   $0x0,(%rbx)
cltq
mov    %r9d,0x120(%rsp,%rax,8)
mov    %ebp,0x124(%rsp,%rax,8)
add    $0x1,%eax
cmp    %rdi,%rsi
jge    14f0 <main+0x3c0>
add    $0x1,%ebp
add    $0x20,%rbx
lea    0x1(%rsi),%rcx
cmp    $0x6,%rsi
mov    %rcx,%rsi
jl     1660 <main+0x530>
jmp    14f0 <main+0x3c0>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    %r9d,0x18(%rsp)
mov    %r8d,0x14(%rsp)
add    $0x1,%r12d
lea    0x969(%rip),%rdi
mov    %r12d,%esi
xor    %eax,%eax
call   1040 <printf@plt>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
mov    0x20(%rsp,%rbp,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x24(%rsp,%rbp,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x28(%rsp,%rbp,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x2c(%rsp,%rbp,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x30(%rsp,%rbp,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x34(%rsp,%rbp,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x38(%rsp,%rbp,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    0x3c(%rsp,%rbp,1),%esi
mov    %r15,%rdi
xor    %eax,%eax
call   1040 <printf@plt>
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x20,%rbp
cmp    $0x100,%rbp
jne    16e0 <main+0x5b0>
cmp    0x1c(%rsp),%r12d
jl     1180 <main+0x50>
xor    %eax,%eax
add    $0x328,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

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

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