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

```c
#include<stdio.h>
#include<math.h>
 
int n[100010];
int main()
{
  int N;
  scanf("%d",&N);
  int temp;
 
  for(int x=1;x<104;x++){
    for(int y=1;y<104;y++){
      for(int z=1;z<104;z++){
        temp = x*x + y*y + z*z + x*y + y*z + z*x;
        n[temp]++;
      }
    }
  }
  
  for(int i=1;i<=N;i++){printf("%d\n",n[i]);}
}```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	.LC0(%rip), %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	leaq	n(%rip), %rbx
	subq	$16, %rsp
	.cfi_def_cfa_offset 48
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	$1, %r9d
.L2:
	movl	%r9d, %r11d
	movl	%r9d, %r10d
	movl	$1, %edi
	imull	%r9d, %r11d
.L7:
	movl	%edi, %r8d
	movl	%r9d, %esi
	movl	%edi, %ecx
	movl	$1, %edx
	imull	%edi, %r8d
	addl	%r11d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%edx, %eax
	imull	%edx, %eax
	addl	$1, %edx
	addl	%r8d, %eax
	addl	%r10d, %eax
	addl	%ecx, %eax
	addl	%edi, %ecx
	addl	%esi, %eax
	addl	%r9d, %esi
	cltq
	addl	$1, (%rbx,%rax,4)
	cmpl	$104, %edx
	jne	.L3
	addl	$1, %edi
	addl	%r9d, %r10d
	cmpl	$104, %edi
	jne	.L7
	addl	$1, %r9d
	cmpl	$104, %r9d
	jne	.L2
	movl	4(%rsp), %eax
	movl	$1, %ebp
	leaq	.LC1(%rip), %r12
	testl	%eax, %eax
	jle	.L6
.L5:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 4(%rsp)
	jge	.L5
.L6:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L16
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
.L16:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	n
	.bss
	.align 32
	.type	n, @object
	.size	n, 400040
n:
	.zero	400040
	.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.
Optimized Assembly Code:

user
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	.LC0(%rip), %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	leaq	n(%rip), %rbx
	subq	$16, %rsp
	.cfi_def_cfa_offset 48
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	$1, %r9d
.L2:
	movl	%r9d, %r11d
	movl	%r9d, %r10d
	movl	$1, %edi
	imull	%r9d, %r11d
.L7:
	movl	%edi, %r8d
	movl	%r9d, %esi
	movl	%edi, %ecx
	movl	$1, %edx
	imull	%edi, %r8d
	addl	%r11d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%edx, %eax
	imull	%edx, %eax
	addl	$1, %edx
	addl	%r8d, %eax
	addl	%r10d, %eax
	addl	%ecx, %eax
	addl	%edi, %ecx
	addl	%esi, %eax
	addl	%r9d, %esi
	cltq
	addl	$1, (%rbx,%rax,4)
	cmpl	$104, %edx
	jne	.L3
	addl	$1, %edi
	addl	%r9d, %r10d
	cmpl	$104, %edi
	jne	.L7
	addl	$1, %r9d
	cmpl	$104, %r9d
	jne	.L2
	movl	4(%rsp), %eax
	movl	$1, %ebp
	leaq	.LC1(%rip), %r12
	testl	%eax, %eax
	jle	.L6
.L5:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 4(%rsp)
	jge	.L5
.L6:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L16
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
.L16:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	n
	.bss
	.align 32
	.type	n, @object
	.size	n, 400040
n:
	.zero	400040
	.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
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	.LC0(%rip), %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	leaq	n(%rip), %rbx
	subq	$16, %rsp
	.cfi_def_cfa_offset 48
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	$1, %r9d
.L2:
	movl	%r9d, %r11d
	movl	%r9d, %r10d
	movl	$1, %edi
	imull	%r9d, %r11d
.L7:
	movl	%edi, %r8d
	movl	%r9d, %esi
	movl	%edi, %ecx
	movl	$1, %edx
	imull	%edi, %r8d
	addl	%r11d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%edx, %eax
	imull	%edx, %eax
	addl	$1, %edx
	addl	%r8d, %eax
	addl	%r10d, %eax
	addl	%ecx, %eax
	addl	%edi, %ecx
	addl	%esi, %eax
	addl	%r9d, %esi
	cltq
	addl	$1, (%rbx,%rax,4)
	cmpl	$104, %edx
	jne	.L3
	addl	$1, %edi
	addl	%r9d, %r10d
	cmpl	$104, %edi
	jne	.L7
	addl	$1, %r9d
	cmpl	$104, %r9d
	jne	.L2
	movl	4(%rsp), %eax
	movl	$1, %ebp
	leaq	.LC1(%rip), %r12
	testl	%eax, %eax
	jle	.L6
.L5:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 4(%rsp)
	jge	.L5
.L6:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L16
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
.L16:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	n
	.bss
	.align 32
	.type	n, @object
	.size	n, 400040
n:
	.zero	400040
	.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:
```
```c
#include<stdio.h>
#include<math.h>
 
int n[100010];
int main()
{
  int N;
  scanf("%d",&N);
  int temp;
 
  for(int x=1;x<104;x++){
    for(int y=1;y<104;y++){
      for(int z=1;z<104;z++){
        temp = x*x + y*y + z*z + x*y + y*z + z*x;
        n[temp]++;
      }
    }
  }
  
  for(int i=1;i<=N;i++){printf("%d\n",n[i]);}
}```
Given the following C code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
#include<stdio.h>
#include<math.h>
 
int n[100010];
int main()
{
  int N;
  scanf("%d",&N);
  int temp;
 
  for(int x=1;x<104;x++){
    for(int y=1;y<104;y++){
      for(int z=1;z<104;z++){
        temp = x*x + y*y + z*z + x*y + y*z + z*x;
        n[temp]++;
      }
    }
  }
  
  for(int i=1;i<=N;i++){printf("%d\n",n[i]);}
}```

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.
Optimized Assembly Code:

27
 13
 3
 2
 4
 8
 14
 1
 31
 53

0
0
0
0
0
1
0
0
0
0
3
0
0
0
0
0
3
3
0
0
0
0
0
1
6
0
3
 0
0
0
0
0
1
0
0
0
0
3
0
0
 0
0
0
 0
0
 0
0
0
0
 0
0
0
0
0
1
0
0
 0
0
0
0
0
1
0
0
0
0
3
0
0
0
 0
 0
0
0
0
0
1
0
0
0
0
3
0
0
0
0
0
3
3
0
0
0
0
0
1
6
0
3
0
0
0
0
 0
0
0
0
0
1
0
0
0
0
3
0
0
0
0
0
3
3
0
0
0
0
0
1
6
0
3
0
0
0
0
0
3
3
6
0
0
3
0
0
0
0
3
3
6
0
6
0
0
0
3
0
0

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

```c
#include<stdio.h>
#include<math.h>
 
int n[100010];
int main()
{
  int N;
  scanf("%d",&N);
  int temp;
 
  for(int x=1;x<104;x++){
    for(int y=1;y<104;y++){
      for(int z=1;z<104;z++){
        temp = x*x + y*y + z*z + x*y + y*z + z*x;
        n[temp]++;
      }
    }
  }
  
  for(int i=1;i<=N;i++){printf("%d\n",n[i]);}
}```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	.LC0(%rip), %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	leaq	n(%rip), %rbx
	subq	$16, %rsp
	.cfi_def_cfa_offset 48
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	$1, %r9d
.L2:
	movl	%r9d, %r11d
	movl	%r9d, %r10d
	movl	$1, %edi
	imull	%r9d, %r11d
.L7:
	movl	%edi, %r8d
	movl	%r9d, %esi
	movl	%edi, %ecx
	movl	$1, %edx
	imull	%edi, %r8d
	addl	%r11d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%edx, %eax
	imull	%edx, %eax
	addl	$1, %edx
	addl	%r8d, %eax
	addl	%r10d, %eax
	addl	%ecx, %eax
	addl	%edi, %ecx
	addl	%esi, %eax
	addl	%r9d, %esi
	cltq
	addl	$1, (%rbx,%rax,4)
	cmpl	$104, %edx
	jne	.L3
	addl	$1, %edi
	addl	%r9d, %r10d
	cmpl	$104, %edi
	jne	.L7
	addl	$1, %r9d
	cmpl	$104, %r9d
	jne	.L2
	movl	4(%rsp), %eax
	movl	$1, %ebp
	leaq	.LC1(%rip), %r12
	testl	%eax, %eax
	jle	.L6
.L5:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 4(%rsp)
	jge	.L5
.L6:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L16
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
.L16:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	n
	.bss
	.align 32
	.type	n, @object
	.size	n, 400040
n:
	.zero	400040
	.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.
Optimized Assembly Code:

train
```assembly
	.file	"temp.c"
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB23:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	.LC0(%rip), %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	leaq	n(%rip), %rbx
	subq	$16, %rsp
	.cfi_def_cfa_offset 48
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	$1, %r9d
.L2:
	movl	%r9d, %r11d
	movl	%r9d, %r10d
	movl	$1, %edi
	imull	%r9d, %r11d
.L7:
	movl	%edi, %r8d
	movl	%r9d, %esi
	movl	%edi, %ecx
	movl	$1, %edx
	imull	%edi, %r8d
	addl	%r11d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movl	%edx, %eax
	imull	%edx, %eax
	addl	$1, %edx
	addl	%r8d, %eax
	addl	%r10d, %eax
	addl	%ecx, %eax
	addl	%edi, %ecx
	addl	%esi, %eax
	addl	%r9d, %esi
	cltq
	addl	$1, (%rbx,%rax,4)
	cmpl	$104, %edx
	jne	.L3
	addl	$1, %edi
	addl	%r9d, %r10d
	cmpl	$104, %edi
	jne	.L7
	addl	$1, %r9d
	cmpl	$104, %r9d
	jne	.L2
	movl	4(%rsp), %eax
	movl	$1, %ebp
	leaq	.LC1(%rip), %r12
	testl	%eax, %eax
	jle	.L6
.L5:
	movl	(%rbx,%rbp,4), %edx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	addq	$1, %rbp
	call	__printf_chk@PLT
	cmpl	%ebp, 4(%rsp)
	jge	.L5
.L6:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L16
	addq	$16, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
.L16:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE23:
	.size	main, .-main
	.globl	n
	.bss
	.align 32
	.type	n, @object
	.size	n, 400040
n:
	.zero	400040
	.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:
```