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>
#include <string.h>

char outFile[128][128];
int patSize; 
int logx, logy;

void makeSpin(int dir, int ty, int tx)
{
	int i, j;
	int dy[] = {-1, 0, 1, 0};
	int dx[] = {0, 1, 0, -1};
	logy = ty;
	logx = tx;
	outFile[ty][tx] = '#';

	for (i = dir; i < dir + 4; i++){
		j = i % 4;
		if (ty + dy[j] > 0 && ty + dy[j] < patSize + 1 && tx + dx[j] > 0 && tx + dx[j] < patSize + 1 && 
				outFile[ty + dy[j]][tx + dx[j]] != '#' && outFile[ty + 2 * dy[j]][tx + 2 * dx[j]] != '#'){
			makeSpin(j, ty + dy[j], tx + dx[j]);
			return;
		}
	}
}	

int main(void)
{
	int testNum;
	int i, j;
	int flag;
	
	scanf("%d", &testNum);
	
	flag = 0;
	while (testNum--){
		scanf("%d", &patSize);
		
		memset(outFile, ' ', sizeof(outFile));
		
		makeSpin(0, patSize, 1);

		if (patSize % 2 == 0){
			outFile[logy][logx] = ' ';
		}

		if (flag++){
			puts("");
		}

		for (i = 1; i <= patSize; i++){
			for (j = 1; j <= patSize; j++){
				printf("%c", outFile[i][j]);
			}
			puts("");
		}
	}
	
	return (0);
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	outFile
	.bss
	.align 32
	.type	outFile, @object
	.size	outFile, 16384
outFile:
	.zero	16384
	.globl	patSize
	.align 4
	.type	patSize, @object
	.size	patSize, 4
patSize:
	.zero	4
	.globl	logx
	.align 4
	.type	logx, @object
	.size	logx, 4
logx:
	.zero	4
	.globl	logy
	.align 4
	.type	logy, @object
	.size	logy, 4
logy:
	.zero	4
	.text
	.globl	makeSpin
	.type	makeSpin, @function
makeSpin:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$80, %rsp
	movl	%edi, -68(%rbp)
	movl	%esi, -72(%rbp)
	movl	%edx, -76(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$-1, -48(%rbp)
	movl	$0, -44(%rbp)
	movl	$1, -40(%rbp)
	movl	$0, -36(%rbp)
	movl	$0, -32(%rbp)
	movl	$1, -28(%rbp)
	movl	$0, -24(%rbp)
	movl	$-1, -20(%rbp)
	movl	-72(%rbp), %eax
	movl	%eax, logy(%rip)
	movl	-76(%rbp), %eax
	movl	%eax, logx(%rip)
	movl	-76(%rbp), %eax
	movslq	%eax, %rdx
	movl	-72(%rbp), %eax
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movb	$35, (%rax)
	movl	-68(%rbp), %eax
	movl	%eax, -56(%rbp)
	jmp	.L2
.L5:
	movl	-56(%rbp), %eax
	cltd
	shrl	$30, %edx
	addl	%edx, %eax
	andl	$3, %eax
	subl	%edx, %eax
	movl	%eax, -52(%rbp)
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%edx, %eax
	testl	%eax, %eax
	jle	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	patSize(%rip), %eax
	cmpl	%eax, %edx
	jg	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%edx, %eax
	testl	%eax, %eax
	jle	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%eax, %edx
	movl	patSize(%rip), %eax
	cmpl	%eax, %edx
	jg	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %ecx
	movl	-76(%rbp), %eax
	addl	%ecx, %eax
	movslq	%eax, %rcx
	movslq	%edx, %rax
	salq	$7, %rax
	leaq	(%rax,%rcx), %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	je	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %eax
	leal	(%rax,%rax), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %eax
	leal	(%rax,%rax), %ecx
	movl	-76(%rbp), %eax
	addl	%ecx, %eax
	movslq	%eax, %rcx
	movslq	%edx, %rax
	salq	$7, %rax
	leaq	(%rax,%rcx), %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	je	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %ecx
	movl	-72(%rbp), %eax
	addl	%eax, %ecx
	movl	-52(%rbp), %eax
	movl	%ecx, %esi
	movl	%eax, %edi
	call	makeSpin
	jmp	.L1
.L3:
	addl	$1, -56(%rbp)
.L2:
	movl	-68(%rbp), %eax
	addl	$3, %eax
	cmpl	%eax, -56(%rbp)
	jle	.L5
.L1:
	movq	-8(%rbp), %rax
	subq	%fs:40, %rax
	je	.L6
	call	__stack_chk_fail@PLT
.L6:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	makeSpin, .-makeSpin
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	""
	.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	$32, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-24(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -12(%rbp)
	jmp	.L8
.L15:
	leaq	patSize(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$16384, %edx
	movl	$32, %esi
	leaq	outFile(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	movl	patSize(%rip), %eax
	movl	$1, %edx
	movl	%eax, %esi
	movl	$0, %edi
	call	makeSpin
	movl	patSize(%rip), %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L9
	movl	logy(%rip), %eax
	movl	logx(%rip), %edx
	movslq	%edx, %rdx
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movb	$32, (%rax)
.L9:
	movl	-12(%rbp), %eax
	leal	1(%rax), %edx
	movl	%edx, -12(%rbp)
	testl	%eax, %eax
	je	.L10
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L10:
	movl	$1, -20(%rbp)
	jmp	.L11
.L14:
	movl	$1, -16(%rbp)
	jmp	.L12
.L13:
	movl	-16(%rbp), %eax
	movslq	%eax, %rdx
	movl	-20(%rbp), %eax
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	movsbl	%al, %eax
	movl	%eax, %edi
	call	putchar@PLT
	addl	$1, -16(%rbp)
.L12:
	movl	patSize(%rip), %eax
	cmpl	%eax, -16(%rbp)
	jle	.L13
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	addl	$1, -20(%rbp)
.L11:
	movl	patSize(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L14
.L8:
	movl	-24(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -24(%rbp)
	testl	%eax, %eax
	jne	.L15
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L17
	call	__stack_chk_fail@PLT
.L17:
	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	makeSpin
	.type	makeSpin, @function
makeSpin:
.LFB35:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	movl	%edi, %ecx
	movl	%edx, %r10d
	movl	%esi, %edi
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	leaq	outFile(%rip), %r11
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	subq	$56, %rsp
	.cfi_def_cfa_offset 96
	movl	patSize(%rip), %r9d
	movdqa	.LC0(%rip), %xmm1
	movq	%fs:40, %rax
	movq	%rax, 40(%rsp)
	xorl	%eax, %eax
	movdqa	.LC1(%rip), %xmm0
.L3:
	movslq	%edi, %rax
	movslq	%r10d, %rdx
	movaps	%xmm1, (%rsp)
	leal	3(%rcx), %r8d
	salq	$7, %rax
	movaps	%xmm0, 16(%rsp)
	addq	%r11, %rax
	movb	$35, (%rax,%rdx)
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L2:
	addl	$1, %ecx
	cmpl	%r8d, %ecx
	jg	.L16
.L4:
	movl	%ecx, %edx
	sarl	$31, %edx
	shrl	$30, %edx
	leal	(%rcx,%rdx), %eax
	andl	$3, %eax
	subl	%edx, %eax
	movslq	%eax, %rbx
	movl	(%rsp,%rbx,4), %esi
	leal	(%rsi,%rdi), %edx
	testl	%edx, %edx
	jle	.L2
	cmpl	%r9d, %edx
	jg	.L2
	movl	16(%rsp,%rbx,4), %ebp
	leal	0(%rbp,%r10), %ebx
	cmpl	%ebx, %r9d
	jl	.L2
	testl	%ebx, %ebx
	jle	.L2
	movslq	%edx, %r12
	movslq	%ebx, %r13
	salq	$7, %r12
	addq	%r11, %r12
	cmpb	$35, (%r12,%r13)
	je	.L2
	addl	%edx, %esi
	addl	%ebx, %ebp
	movslq	%esi, %rsi
	movslq	%ebp, %rbp
	salq	$7, %rsi
	addq	%r11, %rsi
	cmpb	$35, (%rsi,%rbp)
	je	.L2
	movl	%ebx, %r10d
	movl	%edx, %edi
	movl	%eax, %ecx
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L16:
	movl	%r10d, logx(%rip)
	movl	%edi, logy(%rip)
	movq	40(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L17
	addq	$56, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
.L17:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE35:
	.size	makeSpin, .-makeSpin
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC2:
	.string	"%d"
.LC3:
	.string	""
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB36:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	.LC2(%rip), %rdi
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	outFile(%rip), %r14
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	xorl	%r13d, %r13d
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	leaq	.LC3(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 4(%rsp)
	testl	%eax, %eax
	je	.L25
	.p2align 4,,10
	.p2align 3
.L19:
	leaq	patSize(%rip), %rsi
	leaq	.LC2(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	$16384, %edx
	movl	$32, %esi
	movq	%r14, %rdi
	call	memset@PLT
	movl	patSize(%rip), %esi
	movl	$1, %edx
	xorl	%edi, %edi
	call	makeSpin
	movl	patSize(%rip), %eax
	testb	$1, %al
	jne	.L20
	movslq	logy(%rip), %rdx
	movslq	logx(%rip), %rcx
	salq	$7, %rdx
	addq	%r14, %rdx
	movb	$32, (%rdx,%rcx)
.L20:
	testl	%r13d, %r13d
	jne	.L37
.L21:
	testl	%eax, %eax
	jle	.L22
	leaq	128+outFile(%rip), %rbx
	movl	$1, %ebp
	.p2align 4,,10
	.p2align 3
.L23:
	movl	$1, %r15d
	.p2align 4,,10
	.p2align 3
.L24:
	movsbl	(%rbx,%r15), %edi
	addq	$1, %r15
	call	putchar@PLT
	cmpl	%r15d, patSize(%rip)
	jge	.L24
	movq	%r12, %rdi
	addl	$1, %ebp
	subq	$-128, %rbx
	call	puts@PLT
	cmpl	%ebp, patSize(%rip)
	jge	.L23
.L22:
	movl	4(%rsp), %eax
	addl	$1, %r13d
	leal	-1(%rax), %edx
	movl	%edx, 4(%rsp)
	testl	%eax, %eax
	jne	.L19
.L25:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L38
	addq	$24, %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
.L37:
	.cfi_restore_state
	movq	%r12, %rdi
	call	puts@PLT
	movl	patSize(%rip), %eax
	jmp	.L21
.L38:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE36:
	.size	main, .-main
	.globl	logy
	.bss
	.align 4
	.type	logy, @object
	.size	logy, 4
logy:
	.zero	4
	.globl	logx
	.align 4
	.type	logx, @object
	.size	logx, 4
logx:
	.zero	4
	.globl	patSize
	.align 4
	.type	patSize, @object
	.size	patSize, 4
patSize:
	.zero	4
	.globl	outFile
	.align 32
	.type	outFile, @object
	.size	outFile, 16384
outFile:
	.zero	16384
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC0:
	.long	-1
	.long	0
	.long	1
	.long	0
	.align 16
.LC1:
	.long	0
	.long	1
	.long	0
	.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	makeSpin
	.type	makeSpin, @function
makeSpin:
.LFB35:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	movl	%edi, %ecx
	movl	%edx, %r10d
	movl	%esi, %edi
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	leaq	outFile(%rip), %r11
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	subq	$56, %rsp
	.cfi_def_cfa_offset 96
	movl	patSize(%rip), %r9d
	movdqa	.LC0(%rip), %xmm1
	movq	%fs:40, %rax
	movq	%rax, 40(%rsp)
	xorl	%eax, %eax
	movdqa	.LC1(%rip), %xmm0
.L3:
	movslq	%edi, %rax
	movslq	%r10d, %rdx
	movaps	%xmm1, (%rsp)
	leal	3(%rcx), %r8d
	salq	$7, %rax
	movaps	%xmm0, 16(%rsp)
	addq	%r11, %rax
	movb	$35, (%rax,%rdx)
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L2:
	addl	$1, %ecx
	cmpl	%r8d, %ecx
	jg	.L16
.L4:
	movl	%ecx, %edx
	sarl	$31, %edx
	shrl	$30, %edx
	leal	(%rcx,%rdx), %eax
	andl	$3, %eax
	subl	%edx, %eax
	movslq	%eax, %rbx
	movl	(%rsp,%rbx,4), %esi
	leal	(%rsi,%rdi), %edx
	testl	%edx, %edx
	jle	.L2
	cmpl	%r9d, %edx
	jg	.L2
	movl	16(%rsp,%rbx,4), %ebp
	leal	0(%rbp,%r10), %ebx
	cmpl	%ebx, %r9d
	jl	.L2
	testl	%ebx, %ebx
	jle	.L2
	movslq	%edx, %r12
	movslq	%ebx, %r13
	salq	$7, %r12
	addq	%r11, %r12
	cmpb	$35, (%r12,%r13)
	je	.L2
	addl	%edx, %esi
	addl	%ebx, %ebp
	movslq	%esi, %rsi
	movslq	%ebp, %rbp
	salq	$7, %rsi
	addq	%r11, %rsi
	cmpb	$35, (%rsi,%rbp)
	je	.L2
	movl	%ebx, %r10d
	movl	%edx, %edi
	movl	%eax, %ecx
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L16:
	movl	%r10d, logx(%rip)
	movl	%edi, logy(%rip)
	movq	40(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L17
	addq	$56, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
.L17:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE35:
	.size	makeSpin, .-makeSpin
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC2:
	.string	"%d"
.LC3:
	.string	""
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB36:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	.LC2(%rip), %rdi
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	leaq	outFile(%rip), %r14
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	xorl	%r13d, %r13d
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	leaq	.LC3(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 4(%rsp)
	testl	%eax, %eax
	je	.L25
	.p2align 4,,10
	.p2align 3
.L19:
	leaq	patSize(%rip), %rsi
	leaq	.LC2(%rip), %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	$16384, %edx
	movl	$32, %esi
	movq	%r14, %rdi
	call	memset@PLT
	movl	patSize(%rip), %esi
	movl	$1, %edx
	xorl	%edi, %edi
	call	makeSpin
	movl	patSize(%rip), %eax
	testb	$1, %al
	jne	.L20
	movslq	logy(%rip), %rdx
	movslq	logx(%rip), %rcx
	salq	$7, %rdx
	addq	%r14, %rdx
	movb	$32, (%rdx,%rcx)
.L20:
	testl	%r13d, %r13d
	jne	.L37
.L21:
	testl	%eax, %eax
	jle	.L22
	leaq	128+outFile(%rip), %rbx
	movl	$1, %ebp
	.p2align 4,,10
	.p2align 3
.L23:
	movl	$1, %r15d
	.p2align 4,,10
	.p2align 3
.L24:
	movsbl	(%rbx,%r15), %edi
	addq	$1, %r15
	call	putchar@PLT
	cmpl	%r15d, patSize(%rip)
	jge	.L24
	movq	%r12, %rdi
	addl	$1, %ebp
	subq	$-128, %rbx
	call	puts@PLT
	cmpl	%ebp, patSize(%rip)
	jge	.L23
.L22:
	movl	4(%rsp), %eax
	addl	$1, %r13d
	leal	-1(%rax), %edx
	movl	%edx, 4(%rsp)
	testl	%eax, %eax
	jne	.L19
.L25:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L38
	addq	$24, %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
.L37:
	.cfi_restore_state
	movq	%r12, %rdi
	call	puts@PLT
	movl	patSize(%rip), %eax
	jmp	.L21
.L38:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE36:
	.size	main, .-main
	.globl	logy
	.bss
	.align 4
	.type	logy, @object
	.size	logy, 4
logy:
	.zero	4
	.globl	logx
	.align 4
	.type	logx, @object
	.size	logx, 4
logx:
	.zero	4
	.globl	patSize
	.align 4
	.type	patSize, @object
	.size	patSize, 4
patSize:
	.zero	4
	.globl	outFile
	.align 32
	.type	outFile, @object
	.size	outFile, 16384
outFile:
	.zero	16384
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC0:
	.long	-1
	.long	0
	.long	1
	.long	0
	.align 16
.LC1:
	.long	0
	.long	1
	.long	0
	.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>
#include <string.h>

char outFile[128][128];
int patSize; 
int logx, logy;

void makeSpin(int dir, int ty, int tx)
{
	int i, j;
	int dy[] = {-1, 0, 1, 0};
	int dx[] = {0, 1, 0, -1};
	logy = ty;
	logx = tx;
	outFile[ty][tx] = '#';

	for (i = dir; i < dir + 4; i++){
		j = i % 4;
		if (ty + dy[j] > 0 && ty + dy[j] < patSize + 1 && tx + dx[j] > 0 && tx + dx[j] < patSize + 1 && 
				outFile[ty + dy[j]][tx + dx[j]] != '#' && outFile[ty + 2 * dy[j]][tx + 2 * dx[j]] != '#'){
			makeSpin(j, ty + dy[j], tx + dx[j]);
			return;
		}
	}
}	

int main(void)
{
	int testNum;
	int i, j;
	int flag;
	
	scanf("%d", &testNum);
	
	flag = 0;
	while (testNum--){
		scanf("%d", &patSize);
		
		memset(outFile, ' ', sizeof(outFile));
		
		makeSpin(0, patSize, 1);

		if (patSize % 2 == 0){
			outFile[logy][logx] = ' ';
		}

		if (flag++){
			puts("");
		}

		for (i = 1; i <= patSize; i++){
			for (j = 1; j <= patSize; j++){
				printf("%c", outFile[i][j]);
			}
			puts("");
		}
	}
	
	return (0);
}
2
5
5
 2
8
5
 2
12
5
 2
12
3
 2
5
9
 2
5
7
 2
8
9
 2
16
3
 2
9
9
 2
10
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>
#include <string.h>

char outFile[128][128];
int patSize; 
int logx, logy;

void makeSpin(int dir, int ty, int tx)
{
	int i, j;
	int dy[] = {-1, 0, 1, 0};
	int dx[] = {0, 1, 0, -1};
	logy = ty;
	logx = tx;
	outFile[ty][tx] = '#';

	for (i = dir; i < dir + 4; i++){
		j = i % 4;
		if (ty + dy[j] > 0 && ty + dy[j] < patSize + 1 && tx + dx[j] > 0 && tx + dx[j] < patSize + 1 && 
				outFile[ty + dy[j]][tx + dx[j]] != '#' && outFile[ty + 2 * dy[j]][tx + 2 * dx[j]] != '#'){
			makeSpin(j, ty + dy[j], tx + dx[j]);
			return;
		}
	}
}	

int main(void)
{
	int testNum;
	int i, j;
	int flag;
	
	scanf("%d", &testNum);
	
	flag = 0;
	while (testNum--){
		scanf("%d", &patSize);
		
		memset(outFile, ' ', sizeof(outFile));
		
		makeSpin(0, patSize, 1);

		if (patSize % 2 == 0){
			outFile[logy][logx] = ' ';
		}

		if (flag++){
			puts("");
		}

		for (i = 1; i <= patSize; i++){
			for (j = 1; j <= patSize; j++){
				printf("%c", outFile[i][j]);
			}
			puts("");
		}
	}
	
	return (0);
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	outFile
	.bss
	.align 32
	.type	outFile, @object
	.size	outFile, 16384
outFile:
	.zero	16384
	.globl	patSize
	.align 4
	.type	patSize, @object
	.size	patSize, 4
patSize:
	.zero	4
	.globl	logx
	.align 4
	.type	logx, @object
	.size	logx, 4
logx:
	.zero	4
	.globl	logy
	.align 4
	.type	logy, @object
	.size	logy, 4
logy:
	.zero	4
	.text
	.globl	makeSpin
	.type	makeSpin, @function
makeSpin:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$80, %rsp
	movl	%edi, -68(%rbp)
	movl	%esi, -72(%rbp)
	movl	%edx, -76(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$-1, -48(%rbp)
	movl	$0, -44(%rbp)
	movl	$1, -40(%rbp)
	movl	$0, -36(%rbp)
	movl	$0, -32(%rbp)
	movl	$1, -28(%rbp)
	movl	$0, -24(%rbp)
	movl	$-1, -20(%rbp)
	movl	-72(%rbp), %eax
	movl	%eax, logy(%rip)
	movl	-76(%rbp), %eax
	movl	%eax, logx(%rip)
	movl	-76(%rbp), %eax
	movslq	%eax, %rdx
	movl	-72(%rbp), %eax
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movb	$35, (%rax)
	movl	-68(%rbp), %eax
	movl	%eax, -56(%rbp)
	jmp	.L2
.L5:
	movl	-56(%rbp), %eax
	cltd
	shrl	$30, %edx
	addl	%edx, %eax
	andl	$3, %eax
	subl	%edx, %eax
	movl	%eax, -52(%rbp)
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%edx, %eax
	testl	%eax, %eax
	jle	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	patSize(%rip), %eax
	cmpl	%eax, %edx
	jg	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%edx, %eax
	testl	%eax, %eax
	jle	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%eax, %edx
	movl	patSize(%rip), %eax
	cmpl	%eax, %edx
	jg	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %ecx
	movl	-76(%rbp), %eax
	addl	%ecx, %eax
	movslq	%eax, %rcx
	movslq	%edx, %rax
	salq	$7, %rax
	leaq	(%rax,%rcx), %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	je	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %eax
	leal	(%rax,%rax), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %eax
	leal	(%rax,%rax), %ecx
	movl	-76(%rbp), %eax
	addl	%ecx, %eax
	movslq	%eax, %rcx
	movslq	%edx, %rax
	salq	$7, %rax
	leaq	(%rax,%rcx), %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	je	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %ecx
	movl	-72(%rbp), %eax
	addl	%eax, %ecx
	movl	-52(%rbp), %eax
	movl	%ecx, %esi
	movl	%eax, %edi
	call	makeSpin
	jmp	.L1
.L3:
	addl	$1, -56(%rbp)
.L2:
	movl	-68(%rbp), %eax
	addl	$3, %eax
	cmpl	%eax, -56(%rbp)
	jle	.L5
.L1:
	movq	-8(%rbp), %rax
	subq	%fs:40, %rax
	je	.L6
	call	__stack_chk_fail@PLT
.L6:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	makeSpin, .-makeSpin
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	""
	.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	$32, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-24(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -12(%rbp)
	jmp	.L8
.L15:
	leaq	patSize(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$16384, %edx
	movl	$32, %esi
	leaq	outFile(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	movl	patSize(%rip), %eax
	movl	$1, %edx
	movl	%eax, %esi
	movl	$0, %edi
	call	makeSpin
	movl	patSize(%rip), %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L9
	movl	logy(%rip), %eax
	movl	logx(%rip), %edx
	movslq	%edx, %rdx
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movb	$32, (%rax)
.L9:
	movl	-12(%rbp), %eax
	leal	1(%rax), %edx
	movl	%edx, -12(%rbp)
	testl	%eax, %eax
	je	.L10
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L10:
	movl	$1, -20(%rbp)
	jmp	.L11
.L14:
	movl	$1, -16(%rbp)
	jmp	.L12
.L13:
	movl	-16(%rbp), %eax
	movslq	%eax, %rdx
	movl	-20(%rbp), %eax
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	movsbl	%al, %eax
	movl	%eax, %edi
	call	putchar@PLT
	addl	$1, -16(%rbp)
.L12:
	movl	patSize(%rip), %eax
	cmpl	%eax, -16(%rbp)
	jle	.L13
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	addl	$1, -20(%rbp)
.L11:
	movl	patSize(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L14
.L8:
	movl	-24(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -24(%rbp)
	testl	%eax, %eax
	jne	.L15
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L17
	call	__stack_chk_fail@PLT
.L17:
	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	outFile
	.bss
	.align 32
	.type	outFile, @object
	.size	outFile, 16384
outFile:
	.zero	16384
	.globl	patSize
	.align 4
	.type	patSize, @object
	.size	patSize, 4
patSize:
	.zero	4
	.globl	logx
	.align 4
	.type	logx, @object
	.size	logx, 4
logx:
	.zero	4
	.globl	logy
	.align 4
	.type	logy, @object
	.size	logy, 4
logy:
	.zero	4
	.text
	.globl	makeSpin
	.type	makeSpin, @function
makeSpin:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$80, %rsp
	movl	%edi, -68(%rbp)
	movl	%esi, -72(%rbp)
	movl	%edx, -76(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$-1, -48(%rbp)
	movl	$0, -44(%rbp)
	movl	$1, -40(%rbp)
	movl	$0, -36(%rbp)
	movl	$0, -32(%rbp)
	movl	$1, -28(%rbp)
	movl	$0, -24(%rbp)
	movl	$-1, -20(%rbp)
	movl	-72(%rbp), %eax
	movl	%eax, logy(%rip)
	movl	-76(%rbp), %eax
	movl	%eax, logx(%rip)
	movl	-76(%rbp), %eax
	movslq	%eax, %rdx
	movl	-72(%rbp), %eax
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movb	$35, (%rax)
	movl	-68(%rbp), %eax
	movl	%eax, -56(%rbp)
	jmp	.L2
.L5:
	movl	-56(%rbp), %eax
	cltd
	shrl	$30, %edx
	addl	%edx, %eax
	andl	$3, %eax
	subl	%edx, %eax
	movl	%eax, -52(%rbp)
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%edx, %eax
	testl	%eax, %eax
	jle	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	patSize(%rip), %eax
	cmpl	%eax, %edx
	jg	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%edx, %eax
	testl	%eax, %eax
	jle	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%eax, %edx
	movl	patSize(%rip), %eax
	cmpl	%eax, %edx
	jg	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %ecx
	movl	-76(%rbp), %eax
	addl	%ecx, %eax
	movslq	%eax, %rcx
	movslq	%edx, %rax
	salq	$7, %rax
	leaq	(%rax,%rcx), %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	je	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %eax
	leal	(%rax,%rax), %edx
	movl	-72(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %eax
	leal	(%rax,%rax), %ecx
	movl	-76(%rbp), %eax
	addl	%ecx, %eax
	movslq	%eax, %rcx
	movslq	%edx, %rax
	salq	$7, %rax
	leaq	(%rax,%rcx), %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	cmpb	$35, %al
	je	.L3
	movl	-52(%rbp), %eax
	cltq
	movl	-32(%rbp,%rax,4), %edx
	movl	-76(%rbp), %eax
	addl	%eax, %edx
	movl	-52(%rbp), %eax
	cltq
	movl	-48(%rbp,%rax,4), %ecx
	movl	-72(%rbp), %eax
	addl	%eax, %ecx
	movl	-52(%rbp), %eax
	movl	%ecx, %esi
	movl	%eax, %edi
	call	makeSpin
	jmp	.L1
.L3:
	addl	$1, -56(%rbp)
.L2:
	movl	-68(%rbp), %eax
	addl	$3, %eax
	cmpl	%eax, -56(%rbp)
	jle	.L5
.L1:
	movq	-8(%rbp), %rax
	subq	%fs:40, %rax
	je	.L6
	call	__stack_chk_fail@PLT
.L6:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	makeSpin, .-makeSpin
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	""
	.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	$32, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-24(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$0, -12(%rbp)
	jmp	.L8
.L15:
	leaq	patSize(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$16384, %edx
	movl	$32, %esi
	leaq	outFile(%rip), %rax
	movq	%rax, %rdi
	call	memset@PLT
	movl	patSize(%rip), %eax
	movl	$1, %edx
	movl	%eax, %esi
	movl	$0, %edi
	call	makeSpin
	movl	patSize(%rip), %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L9
	movl	logy(%rip), %eax
	movl	logx(%rip), %edx
	movslq	%edx, %rdx
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movb	$32, (%rax)
.L9:
	movl	-12(%rbp), %eax
	leal	1(%rax), %edx
	movl	%edx, -12(%rbp)
	testl	%eax, %eax
	je	.L10
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
.L10:
	movl	$1, -20(%rbp)
	jmp	.L11
.L14:
	movl	$1, -16(%rbp)
	jmp	.L12
.L13:
	movl	-16(%rbp), %eax
	movslq	%eax, %rdx
	movl	-20(%rbp), %eax
	cltq
	salq	$7, %rax
	addq	%rax, %rdx
	leaq	outFile(%rip), %rax
	addq	%rdx, %rax
	movzbl	(%rax), %eax
	movsbl	%al, %eax
	movl	%eax, %edi
	call	putchar@PLT
	addl	$1, -16(%rbp)
.L12:
	movl	patSize(%rip), %eax
	cmpl	%eax, -16(%rbp)
	jle	.L13
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	addl	$1, -20(%rbp)
.L11:
	movl	patSize(%rip), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L14
.L8:
	movl	-24(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -24(%rbp)
	testl	%eax, %eax
	jne	.L15
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L17
	call	__stack_chk_fail@PLT
.L17:
	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:
