Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include <stdio.h>

const int di[8] = {-1, -1, -1, 0, 0, 1, 1, 1};
const int dj[8] = {-1, 0, 1, -1, 1, -1, 0, 1};

int w, h;
int c[50][50];

void delete(int i, int j) {
	int k;

	c[i][j] = 0;

	for (k = 0; k < 8; k++) {
		int ni = i + di[k], nj = j + dj[k];
		if (ni >= 0 && ni < h && nj >= 0 && nj < w && c[ni][nj])
			delete(ni, nj);
	}
}

int main(void) {
	int i, j;

	while (scanf("%d %d", &w, &h), w) {
		int cnt;

		for (i = 0; i < h; i++)
			for (j = 0; j < w; j++)
				scanf("%d", c[i] + j);

		cnt = 0;
		for (i = 0; i < h; i++)
			for (j = 0; j < w; j++)
				if (c[i][j]) {
					delete(i, j);
					cnt++;
				}

		printf("%d\n", cnt);
	}

	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	di
	.section	.rodata
	.align 32
	.type	di, @object
	.size	di, 32
di:
	.long	-1
	.long	-1
	.long	-1
	.long	0
	.long	0
	.long	1
	.long	1
	.long	1
	.globl	dj
	.align 32
	.type	dj, @object
	.size	dj, 32
dj:
	.long	-1
	.long	0
	.long	1
	.long	-1
	.long	1
	.long	-1
	.long	0
	.long	1
	.globl	w
	.bss
	.align 4
	.type	w, @object
	.size	w, 4
w:
	.zero	4
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	c
	.align 32
	.type	c, @object
	.size	c, 10000
c:
	.zero	10000
	.text
	.globl	delete
	.type	delete, @function
delete:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$32, %rsp
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-20(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	$0, (%rdx,%rax)
	movl	$0, -12(%rbp)
	jmp	.L2
.L4:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	di(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-20(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -8(%rbp)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	dj(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -4(%rbp)
	cmpl	$0, -8(%rbp)
	js	.L3
	movl	h(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jge	.L3
	cmpl	$0, -4(%rbp)
	js	.L3
	movl	w(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jge	.L3
	movl	-4(%rbp), %eax
	movslq	%eax, %rcx
	movl	-8(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	je	.L3
	movl	-4(%rbp), %edx
	movl	-8(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	delete
.L3:
	addl	$1, -12(%rbp)
.L2:
	cmpl	$7, -12(%rbp)
	jle	.L4
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	delete, .-delete
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d %d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	jmp	.L6
.L16:
	movl	$0, -12(%rbp)
	jmp	.L7
.L10:
	movl	$0, -8(%rbp)
	jmp	.L8
.L9:
	movl	-12(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	c(%rip), %rdx
	addq	%rax, %rdx
	movl	-8(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -8(%rbp)
.L8:
	movl	w(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L9
	addl	$1, -12(%rbp)
.L7:
	movl	h(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L10
	movl	$0, -4(%rbp)
	movl	$0, -12(%rbp)
	jmp	.L11
.L15:
	movl	$0, -8(%rbp)
	jmp	.L12
.L14:
	movl	-8(%rbp), %eax
	movslq	%eax, %rcx
	movl	-12(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	je	.L13
	movl	-8(%rbp), %edx
	movl	-12(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	delete
	addl	$1, -4(%rbp)
.L13:
	addl	$1, -8(%rbp)
.L12:
	movl	w(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L14
	addl	$1, -12(%rbp)
.L11:
	movl	h(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L15
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L6:
	leaq	h(%rip), %rax
	movq	%rax, %rdx
	leaq	w(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	w(%rip), %eax
	testl	%eax, %eax
	jne	.L16
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
user
	.file	"temp.c"
	.text
	.p2align 4
	.globl	delete
	.type	delete, @function
delete:
.LFB23:
	.cfi_startproc
	endbr64
	movslq	%edi, %rax
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	movslq	%esi, %rsi
	leaq	c(%rip), %rcx
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	movq	%rsi, %rdx
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	movq	%rax, %r12
	leaq	(%rax,%rax,4), %rax
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	(%rax,%rax,4), %rax
	leaq	dj(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	(%rsi,%rax,2), %rax
	leaq	di(%rip), %rbx
	leaq	32(%rbx), %r15
	subq	$56, %rsp
	.cfi_def_cfa_offset 112
	movl	$0, (%rcx,%rax,4)
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L2:
	addq	$4, %rbx
	addq	$4, %rbp
	cmpq	%rbx, %r15
	je	.L35
.L12:
	movl	%r12d, %r13d
	addl	(%rbx), %r13d
	js	.L2
	movl	0(%rbp), %r14d
	movl	h(%rip), %eax
	addl	%edx, %r14d
	cmpl	%r13d, %eax
	jle	.L2
	testl	%r14d, %r14d
	js	.L2
	movl	w(%rip), %esi
	cmpl	%r14d, %esi
	jle	.L2
	movslq	%r13d, %r8
	movslq	%r14d, %r9
	leaq	(%r8,%r8,4), %rdi
	leaq	(%rdi,%rdi,4), %rdi
	leaq	(%r9,%rdi,2), %rdi
	movl	(%rcx,%rdi,4), %r10d
	testl	%r10d, %r10d
	je	.L2
	movl	$0, (%rcx,%rdi,4)
	leal	-1(%r14), %r10d
	leal	-1(%r13), %edi
	leal	1(%r14), %r11d
	testl	%r13d, %r13d
	je	.L3
	cmpl	%edi, %eax
	jle	.L4
	testl	%r10d, %r10d
	jns	.L36
.L4:
	cmpl	h(%rip), %edi
	jl	.L37
.L5:
	cmpl	h(%rip), %edi
	leal	1(%r14), %r11d
	jl	.L38
.L3:
	movl	%r10d, %eax
	notl	%eax
	shrl	$31, %eax
	cmpl	h(%rip), %r13d
	jge	.L6
	testb	%al, %al
	jne	.L39
.L6:
	cmpl	h(%rip), %r13d
	jl	.L13
.L8:
	addl	$1, %r13d
	cmpl	h(%rip), %r13d
	jge	.L9
	testb	%al, %al
	jne	.L40
.L9:
	cmpl	h(%rip), %r13d
	jl	.L41
.L10:
	cmpl	%r13d, h(%rip)
	jle	.L2
	cmpl	w(%rip), %r11d
	jge	.L2
	movslq	%r13d, %rsi
	movslq	%r11d, %rax
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rax,%rsi,2), %rax
	movl	(%rcx,%rax,4), %eax
	testl	%eax, %eax
	je	.L2
	movl	%r11d, %esi
	movl	%r13d, %edi
	movl	%edx, 8(%rsp)
	call	delete
	movl	8(%rsp), %edx
	leaq	c(%rip), %rcx
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L35:
	addq	$56, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
.L38:
	.cfi_restore_state
	cmpl	w(%rip), %r11d
	jge	.L3
	movslq	%edi, %rsi
	movslq	%r11d, %rax
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rax,%rsi,2), %rax
	movl	(%rcx,%rax,4), %eax
	testl	%eax, %eax
	je	.L3
	movl	%r11d, %esi
	movq	%r9, 32(%rsp)
	movq	%r8, 24(%rsp)
	movl	%r10d, 16(%rsp)
	movl	%edx, 12(%rsp)
	movl	%r11d, 8(%rsp)
	call	delete
	movq	32(%rsp), %r9
	movq	24(%rsp), %r8
	leaq	c(%rip), %rcx
	movl	16(%rsp), %r10d
	movl	12(%rsp), %edx
	movl	8(%rsp), %r11d
	jmp	.L3
.L36:
	cmpl	%r10d, %esi
	jle	.L4
	movslq	%edi, %rsi
	movslq	%r10d, %rax
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rax,%rsi,2), %rax
	movl	(%rcx,%rax,4), %eax
	testl	%eax, %eax
	je	.L4
	movl	%r10d, %esi
	movq	%r9, 32(%rsp)
	movq	%r8, 24(%rsp)
	movl	%edx, 16(%rsp)
	movl	%r10d, 12(%rsp)
	movl	%edi, 8(%rsp)
	call	delete
	movl	8(%rsp), %edi
	movl	12(%rsp), %r10d
	leaq	c(%rip), %rcx
	movl	16(%rsp), %edx
	movq	24(%rsp), %r8
	movq	32(%rsp), %r9
	jmp	.L4
.L37:
	cmpl	w(%rip), %r14d
	jge	.L5
	movslq	%edi, %rax
	leaq	(%rax,%rax,4), %rax
	leaq	(%rax,%rax,4), %rax
	leaq	(%r9,%rax,2), %rax
	movl	(%rcx,%rax,4), %eax
	testl	%eax, %eax
	je	.L5
	movl	%r14d, %esi
	movq	%r9, 32(%rsp)
	movq	%r8, 24(%rsp)
	movl	%r10d, 16(%rsp)
	movl	%edx, 12(%rsp)
	movl	%edi, 8(%rsp)
	call	delete
	movl	8(%rsp), %edi
	movl	12(%rsp), %edx
	leaq	c(%rip), %rcx
	movl	16(%rsp), %r10d
	movq	24(%rsp), %r8
	movq	32(%rsp), %r9
	jmp	.L5
.L13:
	cmpl	w(%rip), %r11d
	jge	.L8
	leaq	(%r8,%r8,4), %rdi
	movslq	%r11d, %rsi
	leaq	(%rdi,%rdi,4), %rdi
	leaq	(%rsi,%rdi,2), %rsi
	movl	(%rcx,%rsi,4), %r8d
	testl	%r8d, %r8d
	je	.L8
	movl	%r11d, %esi
	movl	%r13d, %edi
	movq	%r9, 32(%rsp)
	movl	%r10d, 24(%rsp)
	movl	%eax, 16(%rsp)
	movl	%edx, 12(%rsp)
	movl	%r11d, 8(%rsp)
	call	delete
	movq	32(%rsp), %r9
	movl	24(%rsp), %r10d
	leaq	c(%rip), %rcx
	movl	16(%rsp), %eax
	movl	12(%rsp), %edx
	movl	8(%rsp), %r11d
	jmp	.L8
.L41:
	cmpl	w(%rip), %r14d
	jge	.L10
	movslq	%r13d, %rax
	leaq	(%rax,%rax,4), %rax
	leaq	(%rax,%rax,4), %rax
	leaq	(%r9,%rax,2), %rax
	movl	(%rcx,%rax,4), %esi
	testl	%esi, %esi
	je	.L10
	movl	%r14d, %esi
	movl	%r13d, %edi
	movl	%r11d, 12(%rsp)
	movl	%edx, 8(%rsp)
	call	delete
	movl	12(%rsp), %r11d
	movl	8(%rsp), %edx
	leaq	c(%rip), %rcx
	jmp	.L10
.L39:
	cmpl	w(%rip), %r10d
	jge	.L13
	leaq	(%r8,%r8,4), %rdi
	movslq	%r10d, %rsi
	leaq	(%rdi,%rdi,4), %rdi
	leaq	(%rsi,%rdi,2), %rsi
	movl	(%rcx,%rsi,4), %esi
	testl	%esi, %esi
	je	.L13
	movl	%r10d, %esi
	movl	%r13d, %edi
	movq	%r9, 40(%rsp)
	movl	%r11d, 32(%rsp)
	movq	%r8, 24(%rsp)
	movl	%eax, 16(%rsp)
	movl	%edx, 12(%rsp)
	movl	%r10d, 8(%rsp)
	call	delete
	movq	40(%rsp), %r9
	movl	32(%rsp), %r11d
	leaq	c(%rip), %rcx
	movq	24(%rsp), %r8
	movl	16(%rsp), %eax
	movl	12(%rsp), %edx
	movl	8(%rsp), %r10d
	jmp	.L6
.L40:
	cmpl	w(%rip), %r10d
	jge	.L9
	movslq	%r13d, %rsi
	movslq	%r10d, %rax
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rax,%rsi,2), %rax
	movl	(%rcx,%rax,4), %edi
	testl	%edi, %edi
	je	.L9
	movl	%r10d, %esi
	movl	%r13d, %edi
	movq	%r9, 16(%rsp)
	movl	%r11d, 12(%rsp)
	movl	%edx, 8(%rsp)
	call	delete
	movq	16(%rsp), %r9
	movl	8(%rsp), %edx
	leaq	c(%rip), %rcx
	movl	12(%rsp), %r11d
	jmp	.L9
	.cfi_endproc
.LFE23:
	.size	delete, .-delete
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d %d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$152, %rsp
	.cfi_def_cfa_offset 208
.L43:
	leaq	h(%rip), %rdx
	leaq	w(%rip), %rsi
	xorl	%eax, %eax
	leaq	.LC2(%rip), %rdi
	call	__isoc99_scanf@PLT
	movl	w(%rip), %r11d
	testl	%r11d, %r11d
	je	.L95
	movl	h(%rip), %eax
	testl	%eax, %eax
	jle	.L50
	leaq	c(%rip), %rax
	xorl	%ebp, %ebp
	movq	%rax, 8(%rsp)
	movq	%rax, %r12
	testl	%r11d, %r11d
	jle	.L47
	.p2align 4,,10
	.p2align 3
.L84:
	movq	%r12, %r13
	xorl	%ebx, %ebx
	.p2align 4,,10
	.p2align 3
.L44:
	movq	%r13, %rsi
	leaq	.LC0(%rip), %rdi
	xorl	%eax, %eax
	addl	$1, %ebx
	call	__isoc99_scanf@PLT
	movl	w(%rip), %r11d
	addq	$4, %r13
	cmpl	%ebx, %r11d
	jg	.L44
	movl	h(%rip), %eax
	addl	$1, %ebp
	cmpl	%ebp, %eax
	jle	.L126
	addq	$200, %r12
	testl	%r11d, %r11d
	jg	.L84
.L47:
	movl	%r11d, %edi
	movl	$0, 16(%rsp)
	xorl	%r10d, %r10d
	leaq	32+di(%rip), %r9
	testl	%edi, %edi
	jle	.L75
	.p2align 4,,10
	.p2align 3
.L85:
	movq	8(%rsp), %r11
	movl	%r10d, %ecx
	xorl	%r8d, %r8d
	movl	%edi, %esi
	movq	%r11, %r10
	jmp	.L73
	.p2align 4,,10
	.p2align 3
.L51:
	addl	$1, %r8d
	addq	$4, %r10
	cmpl	%esi, %r8d
	jge	.L127
.L73:
	movl	(%r10), %ebp
	testl	%ebp, %ebp
	je	.L51
	leaq	dj(%rip), %r15
	movl	$0, (%r10)
	leaq	di(%rip), %r11
	movq	%r10, (%rsp)
	movl	%ecx, %r10d
	movq	%r15, %rcx
	jmp	.L72
	.p2align 4,,10
	.p2align 3
.L52:
	addq	$4, %r11
	addq	$4, %rcx
	cmpq	%r11, %r9
	je	.L128
.L72:
	movl	%r10d, %r12d
	addl	(%r11), %r12d
	js	.L52
	movl	(%rcx), %r15d
	addl	%r8d, %r15d
	cmpl	h(%rip), %r12d
	jge	.L52
	testl	%r15d, %r15d
	js	.L52
	cmpl	%esi, %r15d
	jge	.L52
	movslq	%r12d, %rdx
	movslq	%r15d, %rax
	leaq	c(%rip), %rdi
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rax,%rdx,2), %rax
	movl	(%rdi,%rax,4), %ebx
	testl	%ebx, %ebx
	je	.L52
	leaq	di(%rip), %r14
	leaq	dj(%rip), %r13
	movq	%rcx, 32(%rsp)
	movl	$0, (%rdi,%rax,4)
	movq	%r14, %rax
	movq	%r13, %rcx
	movl	%r12d, %r14d
	movl	%r8d, 20(%rsp)
	movl	%r15d, %r13d
	movq	%rax, %r12
	movq	%r11, 24(%rsp)
	movl	%r10d, 40(%rsp)
	jmp	.L71
	.p2align 4,,10
	.p2align 3
.L53:
	addq	$4, %r12
	addq	$4, %rcx
	cmpq	%r12, %r9
	je	.L129
.L71:
	movl	%r14d, %r11d
	addl	(%r12), %r11d
	js	.L53
	movl	(%rcx), %r15d
	addl	%r13d, %r15d
	cmpl	h(%rip), %r11d
	jge	.L53
	testl	%r15d, %r15d
	js	.L53
	cmpl	%esi, %r15d
	jge	.L53
	movslq	%r11d, %rdx
	movslq	%r15d, %rax
	leaq	c(%rip), %rdi
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rax,%rdx,2), %rax
	movl	(%rdi,%rax,4), %r10d
	testl	%r10d, %r10d
	je	.L53
	leaq	dj(%rip), %r10
	leaq	di(%rip), %r8
	movl	%r13d, 52(%rsp)
	movl	%r11d, %ebp
	movl	$0, (%rdi,%rax,4)
	movl	%r15d, %r13d
	movq	%r8, %rbx
	movq	%r10, %r15
	movl	%r14d, 48(%rsp)
	movl	%esi, %edi
	movq	%r12, 56(%rsp)
	movq	%rcx, 64(%rsp)
	jmp	.L70
	.p2align 4,,10
	.p2align 3
.L54:
	addq	$4, %rbx
	addq	$4, %r15
	cmpq	%rbx, %r9
	je	.L130
.L70:
	movl	%ebp, %r14d
	addl	(%rbx), %r14d
	js	.L54
	movl	(%r15), %r10d
	addl	%r13d, %r10d
	cmpl	h(%rip), %r14d
	jge	.L54
	testl	%r10d, %r10d
	js	.L54
	cmpl	%edi, %r10d
	jge	.L54
	movslq	%r14d, %rdx
	movslq	%r10d, %rax
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rax,%rdx,2), %rax
	leaq	c(%rip), %rdx
	movl	(%rdx,%rax,4), %r8d
	testl	%r8d, %r8d
	je	.L54
	leaq	dj(%rip), %r8
	movq	%r15, 104(%rsp)
	leaq	di(%rip), %r12
	movl	$0, (%rdx,%rax,4)
	movq	%r8, %r15
	movl	%ebp, 100(%rsp)
	movl	%r13d, 120(%rsp)
	movl	%r14d, 44(%rsp)
	movl	%r10d, 88(%rsp)
	movq	%rbx, 112(%rsp)
	jmp	.L69
	.p2align 4,,10
	.p2align 3
.L55:
	addq	$4, %r12
	addq	$4, %r15
	cmpq	%r12, %r9
	je	.L131
.L69:
	movl	44(%rsp), %r14d
	addl	(%r12), %r14d
	js	.L55
	movl	88(%rsp), %ebx
	addl	(%r15), %ebx
	cmpl	h(%rip), %r14d
	jge	.L55
	testl	%ebx, %ebx
	js	.L55
	cmpl	%edi, %ebx
	jge	.L55
	movslq	%r14d, %rdx
	movslq	%ebx, %rcx
	leaq	c(%rip), %rax
	leaq	(%rdx,%rdx,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rcx,%rsi,2), %rsi
	movl	(%rax,%rsi,4), %esi
	testl	%esi, %esi
	je	.L55
	imulq	$50, %rdx, %rdx
	movq	%r12, 128(%rsp)
	movl	%r14d, 92(%rsp)
	movl	%ebx, 124(%rsp)
	addq	%rcx, %rdx
	movq	%r15, 136(%rsp)
	movl	$0, (%rax,%rdx,4)
	leaq	dj(%rip), %rax
	movl	%edi, %edx
	movq	%rax, 72(%rsp)
	leaq	di(%rip), %rax
	movq	%rax, %r12
	jmp	.L57
.L59:
	addq	$4, %r12
	addq	$4, 72(%rsp)
	cmpq	%r9, %r12
	je	.L132
.L57:
	movl	92(%rsp), %r15d
	addl	(%r12), %r15d
	js	.L59
	movq	72(%rsp), %rax
	movl	h(%rip), %esi
	movl	124(%rsp), %ebx
	addl	(%rax), %ebx
	cmpl	%esi, %r15d
	jge	.L59
	testl	%ebx, %ebx
	js	.L59
	cmpl	%edx, %ebx
	jge	.L59
	movslq	%r15d, %rbp
	movslq	%ebx, %rax
	imulq	$50, %rbp, %rcx
	movq	%rax, 80(%rsp)
	addq	%rax, %rcx
	leaq	c(%rip), %rax
	cmpl	$0, (%rax,%rcx,4)
	je	.L59
	movl	$0, (%rax,%rcx,4)
	leal	-1(%r15), %edi
	leal	-1(%rbx), %r13d
	leal	1(%rbx), %r14d
	testl	%r15d, %r15d
	je	.L60
	movl	%ebx, %ecx
	negl	%ecx
	jns	.L61
	cmpl	%edi, %esi
	jle	.L61
	cmpl	%r13d, %edx
	jle	.L61
	movslq	%edi, %rdx
	movslq	%r13d, %rcx
	leaq	c(%rip), %rax
	imulq	$50, %rdx, %rdx
	addq	%rcx, %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L61
	movl	%r13d, %esi
	movl	%edi, 96(%rsp)
	call	delete
	movl	96(%rsp), %edi
	leaq	32+di(%rip), %r9
.L61:
	cmpl	%edi, h(%rip)
	jg	.L133
.L62:
	cmpl	%edi, h(%rip)
	leal	1(%rbx), %r14d
	jg	.L134
.L60:
	movl	%r13d, %edx
	notl	%edx
	shrl	$31, %edx
	cmpl	h(%rip), %r15d
	movl	%edx, 96(%rsp)
	jge	.L63
	testb	%dl, %dl
	jne	.L135
.L63:
	cmpl	h(%rip), %r15d
	jl	.L80
.L65:
	addl	$1, %r15d
	cmpl	%r15d, h(%rip)
	jle	.L66
	cmpb	$0, 96(%rsp)
	jne	.L136
.L66:
	cmpl	%r15d, h(%rip)
	jg	.L137
.L67:
	cmpl	%r15d, h(%rip)
	movl	w(%rip), %edx
	jle	.L59
	cmpl	%edx, %r14d
	jge	.L59
	movslq	%r15d, %rax
	movslq	%r14d, %rcx
	leaq	c(%rip), %rdi
	imulq	$50, %rax, %rax
	addq	%rcx, %rax
	cmpl	$0, (%rdi,%rax,4)
	je	.L59
	movl	%r14d, %esi
	movl	%r15d, %edi
	call	delete
	movl	w(%rip), %edx
	leaq	32+di(%rip), %r9
	jmp	.L59
	.p2align 4,,10
	.p2align 3
.L128:
	movl	%r10d, %ecx
	movq	(%rsp), %r10
	addl	$1, %r8d
	addl	$1, 16(%rsp)
	addq	$4, %r10
	cmpl	%esi, %r8d
	jl	.L73
.L127:
	movl	%ecx, %r10d
	movl	%esi, %edi
	addl	$1, %r10d
	cmpl	h(%rip), %r10d
	jge	.L75
	addq	$200, 8(%rsp)
	testl	%edi, %edi
	jg	.L85
.L75:
	movl	16(%rsp), %edx
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L43
	.p2align 4,,10
	.p2align 3
.L129:
	movl	20(%rsp), %r8d
	movq	24(%rsp), %r11
	movl	40(%rsp), %r10d
	movq	32(%rsp), %rcx
	jmp	.L52
.L130:
	movl	48(%rsp), %r14d
	movl	52(%rsp), %r13d
	movl	%edi, %esi
	movq	56(%rsp), %r12
	movq	64(%rsp), %rcx
	jmp	.L53
.L131:
	movl	100(%rsp), %ebp
	movl	120(%rsp), %r13d
	movq	104(%rsp), %r15
	movq	112(%rsp), %rbx
	jmp	.L54
.L126:
	testl	%eax, %eax
	jg	.L47
.L50:
	movl	$0, 16(%rsp)
	jmp	.L75
.L95:
	addq	$152, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
.L132:
	.cfi_restore_state
	movq	128(%rsp), %r12
	movq	136(%rsp), %r15
	movl	%edx, %edi
	jmp	.L55
.L134:
	cmpl	%r14d, w(%rip)
	jle	.L60
	movslq	%edi, %rdx
	movslq	%r14d, %rcx
	leaq	c(%rip), %rax
	imulq	$50, %rdx, %rdx
	addq	%rcx, %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L60
	movl	%r14d, %esi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L60
.L133:
	cmpl	w(%rip), %ebx
	jge	.L62
	movslq	%edi, %rdx
	leaq	c(%rip), %rax
	imulq	$50, %rdx, %rdx
	addq	80(%rsp), %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L62
	movl	%ebx, %esi
	movl	%edi, 96(%rsp)
	call	delete
	movl	96(%rsp), %edi
	leaq	32+di(%rip), %r9
	jmp	.L62
.L137:
	cmpl	w(%rip), %ebx
	jge	.L67
	movslq	%r15d, %rax
	leaq	c(%rip), %rdi
	imulq	$50, %rax, %rax
	addq	80(%rsp), %rax
	cmpl	$0, (%rdi,%rax,4)
	je	.L67
	movl	%ebx, %esi
	movl	%r15d, %edi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L67
.L136:
	cmpl	w(%rip), %r13d
	jge	.L66
	movslq	%r15d, %rax
	movslq	%r13d, %rdx
	leaq	c(%rip), %rdi
	imulq	$50, %rax, %rax
	addq	%rdx, %rax
	cmpl	$0, (%rdi,%rax,4)
	je	.L66
	movl	%r13d, %esi
	movl	%r15d, %edi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L66
.L80:
	cmpl	%r14d, w(%rip)
	jle	.L65
	imulq	$50, %rbp, %rdx
	movslq	%r14d, %rcx
	leaq	c(%rip), %rax
	addq	%rcx, %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L65
	movl	%r14d, %esi
	movl	%r15d, %edi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L65
.L135:
	cmpl	%r13d, w(%rip)
	jle	.L80
	imulq	$50, %rbp, %rdx
	movslq	%r13d, %rcx
	leaq	c(%rip), %rax
	addq	%rcx, %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L80
	movl	%r13d, %esi
	movl	%r15d, %edi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L63
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.globl	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 10000
c:
	.zero	10000
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	w
	.align 4
	.type	w, @object
	.size	w, 4
w:
	.zero	4
	.globl	dj
	.section	.rodata
	.align 32
	.type	dj, @object
	.size	dj, 32
dj:
	.long	-1
	.long	0
	.long	1
	.long	-1
	.long	1
	.long	-1
	.long	0
	.long	1
	.globl	di
	.align 32
	.type	di, @object
	.size	di, 32
di:
	.long	-1
	.long	-1
	.long	-1
	.long	0
	.long	0
	.long	1
	.long	1
	.long	1
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:

rule
	.file	"temp.c"
	.text
	.p2align 4
	.globl	delete
	.type	delete, @function
delete:
.LFB23:
	.cfi_startproc
	endbr64
	movslq	%edi, %rax
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	movslq	%esi, %rsi
	leaq	c(%rip), %rcx
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	movq	%rsi, %rdx
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	movq	%rax, %r12
	leaq	(%rax,%rax,4), %rax
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	(%rax,%rax,4), %rax
	leaq	dj(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	(%rsi,%rax,2), %rax
	leaq	di(%rip), %rbx
	leaq	32(%rbx), %r15
	subq	$56, %rsp
	.cfi_def_cfa_offset 112
	movl	$0, (%rcx,%rax,4)
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L2:
	addq	$4, %rbx
	addq	$4, %rbp
	cmpq	%rbx, %r15
	je	.L35
.L12:
	movl	%r12d, %r13d
	addl	(%rbx), %r13d
	js	.L2
	movl	0(%rbp), %r14d
	movl	h(%rip), %eax
	addl	%edx, %r14d
	cmpl	%r13d, %eax
	jle	.L2
	testl	%r14d, %r14d
	js	.L2
	movl	w(%rip), %esi
	cmpl	%r14d, %esi
	jle	.L2
	movslq	%r13d, %r8
	movslq	%r14d, %r9
	leaq	(%r8,%r8,4), %rdi
	leaq	(%rdi,%rdi,4), %rdi
	leaq	(%r9,%rdi,2), %rdi
	movl	(%rcx,%rdi,4), %r10d
	testl	%r10d, %r10d
	je	.L2
	movl	$0, (%rcx,%rdi,4)
	leal	-1(%r14), %r10d
	leal	-1(%r13), %edi
	leal	1(%r14), %r11d
	testl	%r13d, %r13d
	je	.L3
	cmpl	%edi, %eax
	jle	.L4
	testl	%r10d, %r10d
	jns	.L36
.L4:
	cmpl	h(%rip), %edi
	jl	.L37
.L5:
	cmpl	h(%rip), %edi
	leal	1(%r14), %r11d
	jl	.L38
.L3:
	movl	%r10d, %eax
	notl	%eax
	shrl	$31, %eax
	cmpl	h(%rip), %r13d
	jge	.L6
	testb	%al, %al
	jne	.L39
.L6:
	cmpl	h(%rip), %r13d
	jl	.L13
.L8:
	addl	$1, %r13d
	cmpl	h(%rip), %r13d
	jge	.L9
	testb	%al, %al
	jne	.L40
.L9:
	cmpl	h(%rip), %r13d
	jl	.L41
.L10:
	cmpl	%r13d, h(%rip)
	jle	.L2
	cmpl	w(%rip), %r11d
	jge	.L2
	movslq	%r13d, %rsi
	movslq	%r11d, %rax
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rax,%rsi,2), %rax
	movl	(%rcx,%rax,4), %eax
	testl	%eax, %eax
	je	.L2
	movl	%r11d, %esi
	movl	%r13d, %edi
	movl	%edx, 8(%rsp)
	call	delete
	movl	8(%rsp), %edx
	leaq	c(%rip), %rcx
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L35:
	addq	$56, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
.L38:
	.cfi_restore_state
	cmpl	w(%rip), %r11d
	jge	.L3
	movslq	%edi, %rsi
	movslq	%r11d, %rax
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rax,%rsi,2), %rax
	movl	(%rcx,%rax,4), %eax
	testl	%eax, %eax
	je	.L3
	movl	%r11d, %esi
	movq	%r9, 32(%rsp)
	movq	%r8, 24(%rsp)
	movl	%r10d, 16(%rsp)
	movl	%edx, 12(%rsp)
	movl	%r11d, 8(%rsp)
	call	delete
	movq	32(%rsp), %r9
	movq	24(%rsp), %r8
	leaq	c(%rip), %rcx
	movl	16(%rsp), %r10d
	movl	12(%rsp), %edx
	movl	8(%rsp), %r11d
	jmp	.L3
.L36:
	cmpl	%r10d, %esi
	jle	.L4
	movslq	%edi, %rsi
	movslq	%r10d, %rax
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rax,%rsi,2), %rax
	movl	(%rcx,%rax,4), %eax
	testl	%eax, %eax
	je	.L4
	movl	%r10d, %esi
	movq	%r9, 32(%rsp)
	movq	%r8, 24(%rsp)
	movl	%edx, 16(%rsp)
	movl	%r10d, 12(%rsp)
	movl	%edi, 8(%rsp)
	call	delete
	movl	8(%rsp), %edi
	movl	12(%rsp), %r10d
	leaq	c(%rip), %rcx
	movl	16(%rsp), %edx
	movq	24(%rsp), %r8
	movq	32(%rsp), %r9
	jmp	.L4
.L37:
	cmpl	w(%rip), %r14d
	jge	.L5
	movslq	%edi, %rax
	leaq	(%rax,%rax,4), %rax
	leaq	(%rax,%rax,4), %rax
	leaq	(%r9,%rax,2), %rax
	movl	(%rcx,%rax,4), %eax
	testl	%eax, %eax
	je	.L5
	movl	%r14d, %esi
	movq	%r9, 32(%rsp)
	movq	%r8, 24(%rsp)
	movl	%r10d, 16(%rsp)
	movl	%edx, 12(%rsp)
	movl	%edi, 8(%rsp)
	call	delete
	movl	8(%rsp), %edi
	movl	12(%rsp), %edx
	leaq	c(%rip), %rcx
	movl	16(%rsp), %r10d
	movq	24(%rsp), %r8
	movq	32(%rsp), %r9
	jmp	.L5
.L13:
	cmpl	w(%rip), %r11d
	jge	.L8
	leaq	(%r8,%r8,4), %rdi
	movslq	%r11d, %rsi
	leaq	(%rdi,%rdi,4), %rdi
	leaq	(%rsi,%rdi,2), %rsi
	movl	(%rcx,%rsi,4), %r8d
	testl	%r8d, %r8d
	je	.L8
	movl	%r11d, %esi
	movl	%r13d, %edi
	movq	%r9, 32(%rsp)
	movl	%r10d, 24(%rsp)
	movl	%eax, 16(%rsp)
	movl	%edx, 12(%rsp)
	movl	%r11d, 8(%rsp)
	call	delete
	movq	32(%rsp), %r9
	movl	24(%rsp), %r10d
	leaq	c(%rip), %rcx
	movl	16(%rsp), %eax
	movl	12(%rsp), %edx
	movl	8(%rsp), %r11d
	jmp	.L8
.L41:
	cmpl	w(%rip), %r14d
	jge	.L10
	movslq	%r13d, %rax
	leaq	(%rax,%rax,4), %rax
	leaq	(%rax,%rax,4), %rax
	leaq	(%r9,%rax,2), %rax
	movl	(%rcx,%rax,4), %esi
	testl	%esi, %esi
	je	.L10
	movl	%r14d, %esi
	movl	%r13d, %edi
	movl	%r11d, 12(%rsp)
	movl	%edx, 8(%rsp)
	call	delete
	movl	12(%rsp), %r11d
	movl	8(%rsp), %edx
	leaq	c(%rip), %rcx
	jmp	.L10
.L39:
	cmpl	w(%rip), %r10d
	jge	.L13
	leaq	(%r8,%r8,4), %rdi
	movslq	%r10d, %rsi
	leaq	(%rdi,%rdi,4), %rdi
	leaq	(%rsi,%rdi,2), %rsi
	movl	(%rcx,%rsi,4), %esi
	testl	%esi, %esi
	je	.L13
	movl	%r10d, %esi
	movl	%r13d, %edi
	movq	%r9, 40(%rsp)
	movl	%r11d, 32(%rsp)
	movq	%r8, 24(%rsp)
	movl	%eax, 16(%rsp)
	movl	%edx, 12(%rsp)
	movl	%r10d, 8(%rsp)
	call	delete
	movq	40(%rsp), %r9
	movl	32(%rsp), %r11d
	leaq	c(%rip), %rcx
	movq	24(%rsp), %r8
	movl	16(%rsp), %eax
	movl	12(%rsp), %edx
	movl	8(%rsp), %r10d
	jmp	.L6
.L40:
	cmpl	w(%rip), %r10d
	jge	.L9
	movslq	%r13d, %rsi
	movslq	%r10d, %rax
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rax,%rsi,2), %rax
	movl	(%rcx,%rax,4), %edi
	testl	%edi, %edi
	je	.L9
	movl	%r10d, %esi
	movl	%r13d, %edi
	movq	%r9, 16(%rsp)
	movl	%r11d, 12(%rsp)
	movl	%edx, 8(%rsp)
	call	delete
	movq	16(%rsp), %r9
	movl	8(%rsp), %edx
	leaq	c(%rip), %rcx
	movl	12(%rsp), %r11d
	jmp	.L9
	.cfi_endproc
.LFE23:
	.size	delete, .-delete
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d %d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$152, %rsp
	.cfi_def_cfa_offset 208
.L43:
	leaq	h(%rip), %rdx
	leaq	w(%rip), %rsi
	xorl	%eax, %eax
	leaq	.LC2(%rip), %rdi
	call	__isoc99_scanf@PLT
	movl	w(%rip), %r11d
	testl	%r11d, %r11d
	je	.L95
	movl	h(%rip), %eax
	testl	%eax, %eax
	jle	.L50
	leaq	c(%rip), %rax
	xorl	%ebp, %ebp
	movq	%rax, 8(%rsp)
	movq	%rax, %r12
	testl	%r11d, %r11d
	jle	.L47
	.p2align 4,,10
	.p2align 3
.L84:
	movq	%r12, %r13
	xorl	%ebx, %ebx
	.p2align 4,,10
	.p2align 3
.L44:
	movq	%r13, %rsi
	leaq	.LC0(%rip), %rdi
	xorl	%eax, %eax
	addl	$1, %ebx
	call	__isoc99_scanf@PLT
	movl	w(%rip), %r11d
	addq	$4, %r13
	cmpl	%ebx, %r11d
	jg	.L44
	movl	h(%rip), %eax
	addl	$1, %ebp
	cmpl	%ebp, %eax
	jle	.L126
	addq	$200, %r12
	testl	%r11d, %r11d
	jg	.L84
.L47:
	movl	%r11d, %edi
	movl	$0, 16(%rsp)
	xorl	%r10d, %r10d
	leaq	32+di(%rip), %r9
	testl	%edi, %edi
	jle	.L75
	.p2align 4,,10
	.p2align 3
.L85:
	movq	8(%rsp), %r11
	movl	%r10d, %ecx
	xorl	%r8d, %r8d
	movl	%edi, %esi
	movq	%r11, %r10
	jmp	.L73
	.p2align 4,,10
	.p2align 3
.L51:
	addl	$1, %r8d
	addq	$4, %r10
	cmpl	%esi, %r8d
	jge	.L127
.L73:
	movl	(%r10), %ebp
	testl	%ebp, %ebp
	je	.L51
	leaq	dj(%rip), %r15
	movl	$0, (%r10)
	leaq	di(%rip), %r11
	movq	%r10, (%rsp)
	movl	%ecx, %r10d
	movq	%r15, %rcx
	jmp	.L72
	.p2align 4,,10
	.p2align 3
.L52:
	addq	$4, %r11
	addq	$4, %rcx
	cmpq	%r11, %r9
	je	.L128
.L72:
	movl	%r10d, %r12d
	addl	(%r11), %r12d
	js	.L52
	movl	(%rcx), %r15d
	addl	%r8d, %r15d
	cmpl	h(%rip), %r12d
	jge	.L52
	testl	%r15d, %r15d
	js	.L52
	cmpl	%esi, %r15d
	jge	.L52
	movslq	%r12d, %rdx
	movslq	%r15d, %rax
	leaq	c(%rip), %rdi
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rax,%rdx,2), %rax
	movl	(%rdi,%rax,4), %ebx
	testl	%ebx, %ebx
	je	.L52
	leaq	di(%rip), %r14
	leaq	dj(%rip), %r13
	movq	%rcx, 32(%rsp)
	movl	$0, (%rdi,%rax,4)
	movq	%r14, %rax
	movq	%r13, %rcx
	movl	%r12d, %r14d
	movl	%r8d, 20(%rsp)
	movl	%r15d, %r13d
	movq	%rax, %r12
	movq	%r11, 24(%rsp)
	movl	%r10d, 40(%rsp)
	jmp	.L71
	.p2align 4,,10
	.p2align 3
.L53:
	addq	$4, %r12
	addq	$4, %rcx
	cmpq	%r12, %r9
	je	.L129
.L71:
	movl	%r14d, %r11d
	addl	(%r12), %r11d
	js	.L53
	movl	(%rcx), %r15d
	addl	%r13d, %r15d
	cmpl	h(%rip), %r11d
	jge	.L53
	testl	%r15d, %r15d
	js	.L53
	cmpl	%esi, %r15d
	jge	.L53
	movslq	%r11d, %rdx
	movslq	%r15d, %rax
	leaq	c(%rip), %rdi
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rax,%rdx,2), %rax
	movl	(%rdi,%rax,4), %r10d
	testl	%r10d, %r10d
	je	.L53
	leaq	dj(%rip), %r10
	leaq	di(%rip), %r8
	movl	%r13d, 52(%rsp)
	movl	%r11d, %ebp
	movl	$0, (%rdi,%rax,4)
	movl	%r15d, %r13d
	movq	%r8, %rbx
	movq	%r10, %r15
	movl	%r14d, 48(%rsp)
	movl	%esi, %edi
	movq	%r12, 56(%rsp)
	movq	%rcx, 64(%rsp)
	jmp	.L70
	.p2align 4,,10
	.p2align 3
.L54:
	addq	$4, %rbx
	addq	$4, %r15
	cmpq	%rbx, %r9
	je	.L130
.L70:
	movl	%ebp, %r14d
	addl	(%rbx), %r14d
	js	.L54
	movl	(%r15), %r10d
	addl	%r13d, %r10d
	cmpl	h(%rip), %r14d
	jge	.L54
	testl	%r10d, %r10d
	js	.L54
	cmpl	%edi, %r10d
	jge	.L54
	movslq	%r14d, %rdx
	movslq	%r10d, %rax
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rdx,%rdx,4), %rdx
	leaq	(%rax,%rdx,2), %rax
	leaq	c(%rip), %rdx
	movl	(%rdx,%rax,4), %r8d
	testl	%r8d, %r8d
	je	.L54
	leaq	dj(%rip), %r8
	movq	%r15, 104(%rsp)
	leaq	di(%rip), %r12
	movl	$0, (%rdx,%rax,4)
	movq	%r8, %r15
	movl	%ebp, 100(%rsp)
	movl	%r13d, 120(%rsp)
	movl	%r14d, 44(%rsp)
	movl	%r10d, 88(%rsp)
	movq	%rbx, 112(%rsp)
	jmp	.L69
	.p2align 4,,10
	.p2align 3
.L55:
	addq	$4, %r12
	addq	$4, %r15
	cmpq	%r12, %r9
	je	.L131
.L69:
	movl	44(%rsp), %r14d
	addl	(%r12), %r14d
	js	.L55
	movl	88(%rsp), %ebx
	addl	(%r15), %ebx
	cmpl	h(%rip), %r14d
	jge	.L55
	testl	%ebx, %ebx
	js	.L55
	cmpl	%edi, %ebx
	jge	.L55
	movslq	%r14d, %rdx
	movslq	%ebx, %rcx
	leaq	c(%rip), %rax
	leaq	(%rdx,%rdx,4), %rsi
	leaq	(%rsi,%rsi,4), %rsi
	leaq	(%rcx,%rsi,2), %rsi
	movl	(%rax,%rsi,4), %esi
	testl	%esi, %esi
	je	.L55
	imulq	$50, %rdx, %rdx
	movq	%r12, 128(%rsp)
	movl	%r14d, 92(%rsp)
	movl	%ebx, 124(%rsp)
	addq	%rcx, %rdx
	movq	%r15, 136(%rsp)
	movl	$0, (%rax,%rdx,4)
	leaq	dj(%rip), %rax
	movl	%edi, %edx
	movq	%rax, 72(%rsp)
	leaq	di(%rip), %rax
	movq	%rax, %r12
	jmp	.L57
.L59:
	addq	$4, %r12
	addq	$4, 72(%rsp)
	cmpq	%r9, %r12
	je	.L132
.L57:
	movl	92(%rsp), %r15d
	addl	(%r12), %r15d
	js	.L59
	movq	72(%rsp), %rax
	movl	h(%rip), %esi
	movl	124(%rsp), %ebx
	addl	(%rax), %ebx
	cmpl	%esi, %r15d
	jge	.L59
	testl	%ebx, %ebx
	js	.L59
	cmpl	%edx, %ebx
	jge	.L59
	movslq	%r15d, %rbp
	movslq	%ebx, %rax
	imulq	$50, %rbp, %rcx
	movq	%rax, 80(%rsp)
	addq	%rax, %rcx
	leaq	c(%rip), %rax
	cmpl	$0, (%rax,%rcx,4)
	je	.L59
	movl	$0, (%rax,%rcx,4)
	leal	-1(%r15), %edi
	leal	-1(%rbx), %r13d
	leal	1(%rbx), %r14d
	testl	%r15d, %r15d
	je	.L60
	movl	%ebx, %ecx
	negl	%ecx
	jns	.L61
	cmpl	%edi, %esi
	jle	.L61
	cmpl	%r13d, %edx
	jle	.L61
	movslq	%edi, %rdx
	movslq	%r13d, %rcx
	leaq	c(%rip), %rax
	imulq	$50, %rdx, %rdx
	addq	%rcx, %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L61
	movl	%r13d, %esi
	movl	%edi, 96(%rsp)
	call	delete
	movl	96(%rsp), %edi
	leaq	32+di(%rip), %r9
.L61:
	cmpl	%edi, h(%rip)
	jg	.L133
.L62:
	cmpl	%edi, h(%rip)
	leal	1(%rbx), %r14d
	jg	.L134
.L60:
	movl	%r13d, %edx
	notl	%edx
	shrl	$31, %edx
	cmpl	h(%rip), %r15d
	movl	%edx, 96(%rsp)
	jge	.L63
	testb	%dl, %dl
	jne	.L135
.L63:
	cmpl	h(%rip), %r15d
	jl	.L80
.L65:
	addl	$1, %r15d
	cmpl	%r15d, h(%rip)
	jle	.L66
	cmpb	$0, 96(%rsp)
	jne	.L136
.L66:
	cmpl	%r15d, h(%rip)
	jg	.L137
.L67:
	cmpl	%r15d, h(%rip)
	movl	w(%rip), %edx
	jle	.L59
	cmpl	%edx, %r14d
	jge	.L59
	movslq	%r15d, %rax
	movslq	%r14d, %rcx
	leaq	c(%rip), %rdi
	imulq	$50, %rax, %rax
	addq	%rcx, %rax
	cmpl	$0, (%rdi,%rax,4)
	je	.L59
	movl	%r14d, %esi
	movl	%r15d, %edi
	call	delete
	movl	w(%rip), %edx
	leaq	32+di(%rip), %r9
	jmp	.L59
	.p2align 4,,10
	.p2align 3
.L128:
	movl	%r10d, %ecx
	movq	(%rsp), %r10
	addl	$1, %r8d
	addl	$1, 16(%rsp)
	addq	$4, %r10
	cmpl	%esi, %r8d
	jl	.L73
.L127:
	movl	%ecx, %r10d
	movl	%esi, %edi
	addl	$1, %r10d
	cmpl	h(%rip), %r10d
	jge	.L75
	addq	$200, 8(%rsp)
	testl	%edi, %edi
	jg	.L85
.L75:
	movl	16(%rsp), %edx
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L43
	.p2align 4,,10
	.p2align 3
.L129:
	movl	20(%rsp), %r8d
	movq	24(%rsp), %r11
	movl	40(%rsp), %r10d
	movq	32(%rsp), %rcx
	jmp	.L52
.L130:
	movl	48(%rsp), %r14d
	movl	52(%rsp), %r13d
	movl	%edi, %esi
	movq	56(%rsp), %r12
	movq	64(%rsp), %rcx
	jmp	.L53
.L131:
	movl	100(%rsp), %ebp
	movl	120(%rsp), %r13d
	movq	104(%rsp), %r15
	movq	112(%rsp), %rbx
	jmp	.L54
.L126:
	testl	%eax, %eax
	jg	.L47
.L50:
	movl	$0, 16(%rsp)
	jmp	.L75
.L95:
	addq	$152, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
.L132:
	.cfi_restore_state
	movq	128(%rsp), %r12
	movq	136(%rsp), %r15
	movl	%edx, %edi
	jmp	.L55
.L134:
	cmpl	%r14d, w(%rip)
	jle	.L60
	movslq	%edi, %rdx
	movslq	%r14d, %rcx
	leaq	c(%rip), %rax
	imulq	$50, %rdx, %rdx
	addq	%rcx, %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L60
	movl	%r14d, %esi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L60
.L133:
	cmpl	w(%rip), %ebx
	jge	.L62
	movslq	%edi, %rdx
	leaq	c(%rip), %rax
	imulq	$50, %rdx, %rdx
	addq	80(%rsp), %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L62
	movl	%ebx, %esi
	movl	%edi, 96(%rsp)
	call	delete
	movl	96(%rsp), %edi
	leaq	32+di(%rip), %r9
	jmp	.L62
.L137:
	cmpl	w(%rip), %ebx
	jge	.L67
	movslq	%r15d, %rax
	leaq	c(%rip), %rdi
	imulq	$50, %rax, %rax
	addq	80(%rsp), %rax
	cmpl	$0, (%rdi,%rax,4)
	je	.L67
	movl	%ebx, %esi
	movl	%r15d, %edi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L67
.L136:
	cmpl	w(%rip), %r13d
	jge	.L66
	movslq	%r15d, %rax
	movslq	%r13d, %rdx
	leaq	c(%rip), %rdi
	imulq	$50, %rax, %rax
	addq	%rdx, %rax
	cmpl	$0, (%rdi,%rax,4)
	je	.L66
	movl	%r13d, %esi
	movl	%r15d, %edi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L66
.L80:
	cmpl	%r14d, w(%rip)
	jle	.L65
	imulq	$50, %rbp, %rdx
	movslq	%r14d, %rcx
	leaq	c(%rip), %rax
	addq	%rcx, %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L65
	movl	%r14d, %esi
	movl	%r15d, %edi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L65
.L135:
	cmpl	%r13d, w(%rip)
	jle	.L80
	imulq	$50, %rbp, %rdx
	movslq	%r13d, %rcx
	leaq	c(%rip), %rax
	addq	%rcx, %rdx
	cmpl	$0, (%rax,%rdx,4)
	je	.L80
	movl	%r13d, %esi
	movl	%r15d, %edi
	call	delete
	leaq	32+di(%rip), %r9
	jmp	.L63
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.globl	c
	.bss
	.align 32
	.type	c, @object
	.size	c, 10000
c:
	.zero	10000
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	w
	.align 4
	.type	w, @object
	.size	w, 4
w:
	.zero	4
	.globl	dj
	.section	.rodata
	.align 32
	.type	dj, @object
	.size	dj, 32
dj:
	.long	-1
	.long	0
	.long	1
	.long	-1
	.long	1
	.long	-1
	.long	0
	.long	1
	.globl	di
	.align 32
	.type	di, @object
	.size	di, 32
di:
	.long	-1
	.long	-1
	.long	-1
	.long	0
	.long	0
	.long	1
	.long	1
	.long	1
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:

#include <stdio.h>

const int di[8] = {-1, -1, -1, 0, 0, 1, 1, 1};
const int dj[8] = {-1, 0, 1, -1, 1, -1, 0, 1};

int w, h;
int c[50][50];

void delete(int i, int j) {
	int k;

	c[i][j] = 0;

	for (k = 0; k < 8; k++) {
		int ni = i + di[k], nj = j + dj[k];
		if (ni >= 0 && ni < h && nj >= 0 && nj < w && c[ni][nj])
			delete(ni, nj);
	}
}

int main(void) {
	int i, j;

	while (scanf("%d %d", &w, &h), w) {
		int cnt;

		for (i = 0; i < h; i++)
			for (j = 0; j < w; j++)
				scanf("%d", c[i] + j);

		cnt = 0;
		for (i = 0; i < h; i++)
			for (j = 0; j < w; j++)
				if (c[i][j]) {
					delete(i, j);
					cnt++;
				}

		printf("%d\n", cnt);
	}

	return 0;
}
1 1
0
2 2
0 1
1 0
3 2
1 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 0
1 0 1 0 1
1 0 0 1 0
5 4
1 1 1 0 1
1 0 1 0 1
1 0 1 0 1
1 0 1 1 1
5 5
1 0 1 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 0 0
1 0 1 0 1
0 0
 1 1
0
2 2
0 1
1 0
3 2
1 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 1
1 0 1 0 1
1 0 0 1 0
5 4
1 1 1 0 1
1 1 1 0 1
1 0 1 0 1
2 0 1 1 1
5 5
0 0 1 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 0 0
1 0 1 0 1
0 0
 1 1
0
2 2
0 1
2 0
3 2
1 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 2
1 0 1 0 1
1 0 0 1 0
5 4
1 1 1 0 1
1 1 1 0 1
1 0 1 0 1
2 0 1 1 1
5 5
0 0 1 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 1 0
1 0 1 0 1
0 0
 1 1
0
2 2
0 1
1 0
3 2
1 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 0
1 1 1 0 1
1 0 0 1 0
5 4
1 1 1 0 1
1 0 1 0 1
1 0 1 0 1
2 0 1 1 1
5 5
1 0 1 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 0 0
1 0 1 0 1
0 0
 1 1
0
2 2
0 1
1 0
3 2
1 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 1
1 0 1 0 1
1 0 0 1 0
5 4
1 1 1 0 1
1 1 1 0 1
1 0 1 0 1
2 0 1 1 1
5 5
0 0 1 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 0 0
1 0 1 0 0
0 0
 1 1
0
2 2
0 1
2 0
3 2
1 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 2
1 0 1 0 0
1 0 0 1 0
5 4
1 1 1 0 1
1 1 1 0 1
1 0 1 0 1
2 0 1 1 1
5 5
0 0 0 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 1 0
1 0 1 0 1
0 0
 1 1
0
2 1
0 1
1 0
3 2
1 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 0
1 1 1 0 1
1 0 0 1 0
5 4
1 1 1 0 1
1 0 1 0 1
0 0 1 0 1
2 0 1 1 1
5 5
1 0 1 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 0 0
1 0 1 0 1
0 0
 1 1
0
2 1
0 1
1 0
3 2
1 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 0
1 1 1 0 1
1 0 0 1 0
5 4
1 1 1 0 1
1 0 1 0 1
0 0 1 0 1
2 0 1 1 1
5 5
1 0 1 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 0 0
1 0 1 1 1
0 0
 1 1
0
2 2
0 1
2 0
3 2
0 1 1
1 1 1
5 4
1 0 1 0 0
1 0 0 0 2
1 1 1 0 0
1 0 0 1 0
5 4
1 1 1 0 1
1 1 1 0 1
1 0 1 0 1
2 0 1 1 1
5 5
0 0 0 0 1
0 0 0 0 0
1 0 1 0 1
0 0 1 1 0
1 0 1 0 1
0 0
 1 1
0
2 2
0 1
1 0
3 2
1 1 1
1 1 1
5 4
2 0 1 0 0
1 0 1 0 0
1 0 1 0 2
1 0 0 1 0
5 4
1 1 1 0 1
1 0 1 0 1
1 0 1 0 1
1 0 1 1 1
5 5
1 0 1 0 1
0 0 0 0 1
1 0 1 0 1
0 0 1 0 0
1 0 1 0 1
0 0

0
1
1
3
1
8
 0
1
1
3
1
7
 0
1
1
3
1
5
 0
1
1
2
1
8
 0
1
1
3
1
6
 0
1
1
4
1
4
 0
1
0
1
2
2
8
 0
1
0
1
2
2
7
 0
1
1
3
1
4
 0
1
1
2
1
7

Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include <stdio.h>

const int di[8] = {-1, -1, -1, 0, 0, 1, 1, 1};
const int dj[8] = {-1, 0, 1, -1, 1, -1, 0, 1};

int w, h;
int c[50][50];

void delete(int i, int j) {
	int k;

	c[i][j] = 0;

	for (k = 0; k < 8; k++) {
		int ni = i + di[k], nj = j + dj[k];
		if (ni >= 0 && ni < h && nj >= 0 && nj < w && c[ni][nj])
			delete(ni, nj);
	}
}

int main(void) {
	int i, j;

	while (scanf("%d %d", &w, &h), w) {
		int cnt;

		for (i = 0; i < h; i++)
			for (j = 0; j < w; j++)
				scanf("%d", c[i] + j);

		cnt = 0;
		for (i = 0; i < h; i++)
			for (j = 0; j < w; j++)
				if (c[i][j]) {
					delete(i, j);
					cnt++;
				}

		printf("%d\n", cnt);
	}

	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	di
	.section	.rodata
	.align 32
	.type	di, @object
	.size	di, 32
di:
	.long	-1
	.long	-1
	.long	-1
	.long	0
	.long	0
	.long	1
	.long	1
	.long	1
	.globl	dj
	.align 32
	.type	dj, @object
	.size	dj, 32
dj:
	.long	-1
	.long	0
	.long	1
	.long	-1
	.long	1
	.long	-1
	.long	0
	.long	1
	.globl	w
	.bss
	.align 4
	.type	w, @object
	.size	w, 4
w:
	.zero	4
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	c
	.align 32
	.type	c, @object
	.size	c, 10000
c:
	.zero	10000
	.text
	.globl	delete
	.type	delete, @function
delete:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$32, %rsp
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-20(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	$0, (%rdx,%rax)
	movl	$0, -12(%rbp)
	jmp	.L2
.L4:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	di(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-20(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -8(%rbp)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	dj(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -4(%rbp)
	cmpl	$0, -8(%rbp)
	js	.L3
	movl	h(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jge	.L3
	cmpl	$0, -4(%rbp)
	js	.L3
	movl	w(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jge	.L3
	movl	-4(%rbp), %eax
	movslq	%eax, %rcx
	movl	-8(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	je	.L3
	movl	-4(%rbp), %edx
	movl	-8(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	delete
.L3:
	addl	$1, -12(%rbp)
.L2:
	cmpl	$7, -12(%rbp)
	jle	.L4
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	delete, .-delete
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d %d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	jmp	.L6
.L16:
	movl	$0, -12(%rbp)
	jmp	.L7
.L10:
	movl	$0, -8(%rbp)
	jmp	.L8
.L9:
	movl	-12(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	c(%rip), %rdx
	addq	%rax, %rdx
	movl	-8(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -8(%rbp)
.L8:
	movl	w(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L9
	addl	$1, -12(%rbp)
.L7:
	movl	h(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L10
	movl	$0, -4(%rbp)
	movl	$0, -12(%rbp)
	jmp	.L11
.L15:
	movl	$0, -8(%rbp)
	jmp	.L12
.L14:
	movl	-8(%rbp), %eax
	movslq	%eax, %rcx
	movl	-12(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	je	.L13
	movl	-8(%rbp), %edx
	movl	-12(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	delete
	addl	$1, -4(%rbp)
.L13:
	addl	$1, -8(%rbp)
.L12:
	movl	w(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L14
	addl	$1, -12(%rbp)
.L11:
	movl	h(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L15
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L6:
	leaq	h(%rip), %rax
	movq	%rax, %rdx
	leaq	w(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	w(%rip), %eax
	testl	%eax, %eax
	jne	.L16
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
```

Only output the optimized assembly code. Do not include any other text. Do not write any comments in the assembly code. Wrap the assembly code in ```assembly``` tags.
train
	.file	"temp.c"
	.text
	.globl	di
	.section	.rodata
	.align 32
	.type	di, @object
	.size	di, 32
di:
	.long	-1
	.long	-1
	.long	-1
	.long	0
	.long	0
	.long	1
	.long	1
	.long	1
	.globl	dj
	.align 32
	.type	dj, @object
	.size	dj, 32
dj:
	.long	-1
	.long	0
	.long	1
	.long	-1
	.long	1
	.long	-1
	.long	0
	.long	1
	.globl	w
	.bss
	.align 4
	.type	w, @object
	.size	w, 4
w:
	.zero	4
	.globl	h
	.align 4
	.type	h, @object
	.size	h, 4
h:
	.zero	4
	.globl	c
	.align 32
	.type	c, @object
	.size	c, 10000
c:
	.zero	10000
	.text
	.globl	delete
	.type	delete, @function
delete:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$32, %rsp
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movl	-24(%rbp), %eax
	movslq	%eax, %rcx
	movl	-20(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	$0, (%rdx,%rax)
	movl	$0, -12(%rbp)
	jmp	.L2
.L4:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	di(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-20(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -8(%rbp)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	dj(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, -4(%rbp)
	cmpl	$0, -8(%rbp)
	js	.L3
	movl	h(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jge	.L3
	cmpl	$0, -4(%rbp)
	js	.L3
	movl	w(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jge	.L3
	movl	-4(%rbp), %eax
	movslq	%eax, %rcx
	movl	-8(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	je	.L3
	movl	-4(%rbp), %edx
	movl	-8(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	delete
.L3:
	addl	$1, -12(%rbp)
.L2:
	cmpl	$7, -12(%rbp)
	jle	.L4
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	delete, .-delete
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d %d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	jmp	.L6
.L16:
	movl	$0, -12(%rbp)
	jmp	.L7
.L10:
	movl	$0, -8(%rbp)
	jmp	.L8
.L9:
	movl	-12(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	c(%rip), %rdx
	addq	%rax, %rdx
	movl	-8(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -8(%rbp)
.L8:
	movl	w(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L9
	addl	$1, -12(%rbp)
.L7:
	movl	h(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L10
	movl	$0, -4(%rbp)
	movl	$0, -12(%rbp)
	jmp	.L11
.L15:
	movl	$0, -8(%rbp)
	jmp	.L12
.L14:
	movl	-8(%rbp), %eax
	movslq	%eax, %rcx
	movl	-12(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,4), %rdx
	addq	%rdx, %rax
	addq	%rax, %rax
	addq	%rcx, %rax
	leaq	0(,%rax,4), %rdx
	leaq	c(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	je	.L13
	movl	-8(%rbp), %edx
	movl	-12(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	delete
	addl	$1, -4(%rbp)
.L13:
	addl	$1, -8(%rbp)
.L12:
	movl	w(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L14
	addl	$1, -12(%rbp)
.L11:
	movl	h(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L15
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L6:
	leaq	h(%rip), %rax
	movq	%rax, %rdx
	leaq	w(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	w(%rip), %eax
	testl	%eax, %eax
	jne	.L16
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	1f - 0f
	.long	4f - 1f
	.long	5
0:
	.string	"GNU"
1:
	.align 8
	.long	0xc0000002
	.long	3f - 2f
2:
	.long	0x3
3:
	.align 8
4:
