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 <math.h>
short v[10240][333],a[10],i,j,n,s;
short summing(short n,short s){
	short ans=0,i,max=0,min=0,m,k;
	if(s>332)return 0;
	if(n==1){if(s<10 && a[s]==1)return 1; else return 0;}
	else{
		k=(a[0]+a[1]*2+a[2]*4+a[3]*8+a[4]*16+a[5]*32+a[6]*64+a[7]*128+a[8]*256+a[9]*512)*10+(n-1);
		if(v[k][s]>=0)return v[k][s];
		for(i=0,m=n;m>0 && i<10;i++){if(a[i]==1){min+=m*i;m--;if(s<min)goto answer;}}
		for(i=9,m=n;m>0 && i>=0;i--){if(a[i]==1){max+=m*i;m--;if(s<=max)break;}}if(s>max)goto answer;
		for(i=0;i<10;i++){
			if(a[i]==1 && n*i<=s){
				a[i]=0;
				ans+=summing(n-1,s-n*i);
				a[i]=1;
			}
		}
		answer:
		v[k][s]=ans;
		return ans;
	}
}
int main(void){
	for(i=0;i<10;i++)a[i]=1;
	for(i=0;i<10240;i++){{for(j=0;j<333;j++)v[i][j]=-1;}}
	while(scanf("%d %d",&n,&s)!=EOF){printf("%d\n",summing(n,s));}
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	v
	.bss
	.align 32
	.type	v, @object
	.size	v, 6819840
v:
	.zero	6819840
	.globl	a
	.align 16
	.type	a, @object
	.size	a, 20
a:
	.zero	20
	.globl	i
	.align 2
	.type	i, @object
	.size	i, 2
i:
	.zero	2
	.globl	j
	.align 2
	.type	j, @object
	.size	j, 2
j:
	.zero	2
	.globl	n
	.align 2
	.type	n, @object
	.size	n, 2
n:
	.zero	2
	.globl	s
	.align 2
	.type	s, @object
	.size	s, 2
s:
	.zero	2
	.text
	.globl	summing
	.type	summing, @function
summing:
.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, %edx
	movl	%esi, %eax
	movw	%dx, -20(%rbp)
	movw	%ax, -24(%rbp)
	movw	$0, -12(%rbp)
	movw	$0, -8(%rbp)
	movw	$0, -6(%rbp)
	cmpw	$332, -24(%rbp)
	jle	.L2
	movl	$0, %eax
	jmp	.L3
.L2:
	cmpw	$1, -20(%rbp)
	jne	.L4
	cmpw	$9, -24(%rbp)
	jg	.L5
	movswl	-24(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L5
	movl	$1, %eax
	jmp	.L3
.L5:
	movl	$0, %eax
	jmp	.L3
.L4:
	movzwl	a(%rip), %eax
	movswl	%ax, %edx
	movzwl	2+a(%rip), %eax
	cwtl
	addl	%eax, %eax
	addl	%eax, %edx
	movzwl	4+a(%rip), %eax
	cwtl
	sall	$2, %eax
	addl	%eax, %edx
	movzwl	6+a(%rip), %eax
	cwtl
	sall	$3, %eax
	addl	%eax, %edx
	movzwl	8+a(%rip), %eax
	cwtl
	sall	$4, %eax
	addl	%eax, %edx
	movzwl	10+a(%rip), %eax
	cwtl
	sall	$5, %eax
	addl	%eax, %edx
	movzwl	12+a(%rip), %eax
	cwtl
	sall	$6, %eax
	addl	%eax, %edx
	movzwl	14+a(%rip), %eax
	cwtl
	sall	$7, %eax
	addl	%eax, %edx
	movzwl	16+a(%rip), %eax
	cwtl
	sall	$8, %eax
	addl	%eax, %edx
	movzwl	18+a(%rip), %eax
	cwtl
	sall	$9, %eax
	addl	%edx, %eax
	movl	%eax, %edx
	movl	%edx, %eax
	sall	$2, %eax
	addl	%edx, %eax
	addl	%eax, %eax
	movl	%eax, %edx
	movzwl	-20(%rbp), %eax
	addl	%edx, %eax
	subl	$1, %eax
	movw	%ax, -2(%rbp)
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	testw	%ax, %ax
	js	.L6
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	jmp	.L3
.L6:
	movw	$0, -10(%rbp)
	movzwl	-20(%rbp), %eax
	movw	%ax, -4(%rbp)
	jmp	.L7
.L11:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L8
	movzwl	-4(%rbp), %edx
	movzwl	-10(%rbp), %eax
	imull	%eax, %edx
	movzwl	-6(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -6(%rbp)
	movzwl	-4(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -4(%rbp)
	movzwl	-24(%rbp), %eax
	cmpw	-6(%rbp), %ax
	jl	.L20
.L8:
	movzwl	-10(%rbp), %eax
	addl	$1, %eax
	movw	%ax, -10(%rbp)
.L7:
	cmpw	$0, -4(%rbp)
	jle	.L10
	cmpw	$9, -10(%rbp)
	jle	.L11
.L10:
	movw	$9, -10(%rbp)
	movzwl	-20(%rbp), %eax
	movw	%ax, -4(%rbp)
	jmp	.L12
.L15:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L13
	movzwl	-4(%rbp), %edx
	movzwl	-10(%rbp), %eax
	imull	%eax, %edx
	movzwl	-8(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -8(%rbp)
	movzwl	-4(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -4(%rbp)
	movzwl	-24(%rbp), %eax
	cmpw	-8(%rbp), %ax
	jle	.L21
.L13:
	movzwl	-10(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -10(%rbp)
.L12:
	cmpw	$0, -4(%rbp)
	jle	.L14
	cmpw	$0, -10(%rbp)
	jns	.L15
	jmp	.L14
.L21:
	nop
.L14:
	movzwl	-24(%rbp), %eax
	cmpw	-8(%rbp), %ax
	jg	.L22
	movw	$0, -10(%rbp)
	jmp	.L17
.L19:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L18
	movswl	-20(%rbp), %edx
	movswl	-10(%rbp), %eax
	imull	%eax, %edx
	movswl	-24(%rbp), %eax
	cmpl	%eax, %edx
	jg	.L18
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$0, (%rdx,%rax)
	movzwl	-24(%rbp), %eax
	movzwl	-20(%rbp), %ecx
	movzwl	-10(%rbp), %edx
	imull	%ecx, %edx
	subl	%edx, %eax
	movswl	%ax, %edx
	movzwl	-20(%rbp), %eax
	subl	$1, %eax
	cwtl
	movl	%edx, %esi
	movl	%eax, %edi
	call	summing
	movl	%eax, %edx
	movzwl	-12(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -12(%rbp)
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$1, (%rdx,%rax)
.L18:
	movzwl	-10(%rbp), %eax
	addl	$1, %eax
	movw	%ax, -10(%rbp)
.L17:
	cmpw	$9, -10(%rbp)
	jle	.L19
	jmp	.L9
.L20:
	nop
	jmp	.L9
.L22:
	nop
.L9:
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rcx
	leaq	v(%rip), %rdx
	movzwl	-12(%rbp), %eax
	movw	%ax, (%rcx,%rdx)
	movzwl	-12(%rbp), %eax
.L3:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	summing, .-summing
	.section	.rodata
.LC0:
	.string	"%d\n"
.LC1:
	.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
	movw	$0, i(%rip)
	jmp	.L24
.L25:
	movzwl	i(%rip), %eax
	cwtl
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$1, (%rdx,%rax)
	movzwl	i(%rip), %eax
	addl	$1, %eax
	movw	%ax, i(%rip)
.L24:
	movzwl	i(%rip), %eax
	cmpw	$9, %ax
	jle	.L25
	movw	$0, i(%rip)
	jmp	.L26
.L29:
	movw	$0, j(%rip)
	jmp	.L27
.L28:
	movzwl	i(%rip), %eax
	cwtl
	movzwl	j(%rip), %edx
	movswl	%dx, %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movw	$-1, (%rdx,%rax)
	movzwl	j(%rip), %eax
	addl	$1, %eax
	movw	%ax, j(%rip)
.L27:
	movzwl	j(%rip), %eax
	cmpw	$332, %ax
	jle	.L28
	movzwl	i(%rip), %eax
	addl	$1, %eax
	movw	%ax, i(%rip)
.L26:
	movzwl	i(%rip), %eax
	cmpw	$10239, %ax
	jle	.L29
	jmp	.L30
.L31:
	movzwl	s(%rip), %eax
	movswl	%ax, %edx
	movzwl	n(%rip), %eax
	cwtl
	movl	%edx, %esi
	movl	%eax, %edi
	call	summing
	cwtl
	movl	%eax, %esi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L30:
	leaq	s(%rip), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	cmpl	$-1, %eax
	jne	.L31
	movl	$0, %eax
	popq	%rbp
	.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
	.type	summing.part.0, @function
summing.part.0:
.LFB25:
	.cfi_startproc
	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
	movl	%edi, %r12d
	movl	%esi, %edi
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	movl	%esi, %ebp
	leal	-1(%r12), %r15d
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movzwl	16+a(%rip), %eax
	movzwl	a(%rip), %r8d
	movswl	2+a(%rip), %edx
	movzwl	4+a(%rip), %esi
	movzwl	6+a(%rip), %ebx
	movw	%ax, 12(%rsp)
	movswl	%r8w, %eax
	movzwl	8+a(%rip), %ecx
	leal	(%rax,%rdx,2), %eax
	movl	%edx, %r10d
	movswl	%si, %edx
	leal	(%rax,%rdx,4), %eax
	movswl	%bx, %edx
	movzwl	10+a(%rip), %r14d
	movw	%bx, 22(%rsp)
	leal	(%rax,%rdx,8), %ebx
	movswl	%cx, %eax
	movzwl	12+a(%rip), %r11d
	movzwl	14+a(%rip), %r13d
	sall	$4, %eax
	movzwl	18+a(%rip), %r9d
	movw	%r14w, 26(%rsp)
	addl	%eax, %ebx
	movswl	%r14w, %eax
	movw	%r13w, 30(%rsp)
	leaq	v(%rip), %r14
	sall	$5, %eax
	movw	%r11w, 28(%rsp)
	addl	%eax, %ebx
	movswl	%r11w, %eax
	movw	%si, 20(%rsp)
	sall	$6, %eax
	movw	%cx, 24(%rsp)
	addl	%eax, %ebx
	movswl	%r13w, %eax
	movswq	%bp, %r13
	sall	$7, %eax
	addl	%eax, %ebx
	movswl	12(%rsp), %eax
	sall	$8, %eax
	addl	%eax, %ebx
	movswl	%r9w, %eax
	sall	$9, %eax
	addl	%eax, %ebx
	movswl	%bp, %eax
	leal	(%rbx,%rbx,4), %ebx
	movl	%eax, 16(%rsp)
	leal	(%r15,%rbx,2), %ebx
	movswq	%bx, %rbx
	leaq	(%rbx,%rbx,8), %rax
	leaq	(%rbx,%rax,4), %rax
	leaq	(%rax,%rax,8), %rax
	addq	%r13, %rax
	movzwl	(%r14,%rax,2), %r11d
	testw	%r11w, %r11w
	js	.L94
.L1:
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	movl	%r11d, %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
	.p2align 4,,10
	.p2align 3
.L94:
	.cfi_restore_state
	testw	%r12w, %r12w
	jle	.L63
	movl	%r8d, %ecx
	movl	%r12d, %edx
	xorl	%esi, %esi
	xorl	%eax, %eax
	leaq	a(%rip), %r11
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L4:
	addl	$1, %eax
	testw	%dx, %dx
	jle	.L65
	cmpw	$9, %ax
	jg	.L65
	movswq	%ax, %rcx
	movzwl	(%r11,%rcx,2), %ecx
.L7:
	cmpw	$1, %cx
	jne	.L4
	movl	%edx, %ecx
	subl	$1, %edx
	imull	%eax, %ecx
	addl	%ecx, %esi
	cmpw	%si, %di
	jge	.L4
	xorl	%r11d, %r11d
.L5:
	leaq	(%rbx,%rbx,8), %rax
	leaq	(%rbx,%rax,4), %rax
	leaq	(%rax,%rax,8), %rax
	addq	%r13, %rax
	movw	%r11w, (%r14,%rax,2)
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L65:
	movl	%r9d, %ecx
	movl	%r12d, %edx
	xorl	%esi, %esi
	movl	$9, %eax
	leaq	a(%rip), %r11
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L8:
	subl	$1, %eax
	testw	%dx, %dx
	jle	.L3
	testw	%ax, %ax
	js	.L3
	movswq	%ax, %rcx
	movzwl	(%r11,%rcx,2), %ecx
.L6:
	cmpw	$1, %cx
	jne	.L8
	movl	%edx, %ecx
	subl	$1, %edx
	imull	%eax, %ecx
	addl	%ecx, %esi
	cmpw	%si, %di
	jg	.L8
	xorl	%r11d, %r11d
	cmpw	$1, %r15w
	je	.L12
.L105:
	cmpw	$1, %r8w
	je	.L95
.L13:
	cmpw	$1, 2+a(%rip)
	je	.L96
.L15:
	cmpw	$1, 4+a(%rip)
	je	.L97
.L17:
	cmpw	$1, 6+a(%rip)
	je	.L98
.L19:
	cmpw	$1, 8+a(%rip)
	je	.L99
.L21:
	cmpw	$1, 10+a(%rip)
	je	.L100
.L23:
	cmpw	$1, 12+a(%rip)
	je	.L101
.L25:
	cmpw	$1, 14+a(%rip)
	je	.L102
.L27:
	cmpw	$1, 16+a(%rip)
	je	.L103
.L29:
	cmpw	$1, 18+a(%rip)
	jne	.L5
	movswl	%r12w, %eax
	leal	(%rax,%rax,8), %eax
	cmpl	%eax, 16(%rsp)
	jl	.L5
	leal	(%r12,%r12,8), %r12d
	xorl	%eax, %eax
	subl	%r12d, %ebp
	movw	%ax, 18+a(%rip)
	cmpw	$332, %bp
	jg	.L104
	movswl	%bp, %esi
	movswl	%r15w, %edi
	movl	%r11d, 12(%rsp)
	call	summing.part.0
	movl	12(%rsp), %r11d
.L33:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 18+a(%rip)
	jmp	.L5
.L63:
	xorl	%esi, %esi
	.p2align 4,,10
	.p2align 3
.L3:
	xorl	%r11d, %r11d
	cmpw	%si, %bp
	jg	.L5
	xorl	%r11d, %r11d
	cmpw	$1, %r15w
	jne	.L105
.L12:
	cmpw	$1, %r8w
	je	.L106
.L34:
	cmpw	$1, %r10w
	je	.L107
.L37:
	cmpw	$1, 20(%rsp)
	je	.L108
.L40:
	cmpw	$1, 22(%rsp)
	je	.L109
.L43:
	cmpw	$1, 24(%rsp)
	je	.L110
.L46:
	cmpw	$1, 26(%rsp)
	je	.L111
.L49:
	cmpw	$1, 28(%rsp)
	je	.L112
.L52:
	cmpw	$1, 30(%rsp)
	je	.L113
.L55:
	cmpw	$1, 12(%rsp)
	je	.L114
.L58:
	cmpw	$1, %r9w
	jne	.L5
	cmpl	$17, 16(%rsp)
	jle	.L5
	xorl	%edx, %edx
	subl	$18, %ebp
	movw	%dx, 18+a(%rip)
	movswq	%bp, %rax
	xorl	%edx, %edx
	cmpw	$9, %bp
	jg	.L62
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%dl
	movzbl	%dl, %edx
.L62:
	movl	$1, %eax
	addl	%edx, %r11d
	movw	%ax, 18+a(%rip)
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L103:
	movswl	%r12w, %eax
	sall	$3, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L29
	xorl	%eax, %eax
	movl	%ebp, %edx
	movw	%ax, 16+a(%rip)
	leal	0(,%r12,8), %eax
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L30
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L30:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 16+a(%rip)
	jmp	.L29
.L102:
	movswl	%r12w, %edx
	leal	0(,%rdx,8), %eax
	subl	%edx, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L27
	xorl	%edx, %edx
	leal	0(,%r12,8), %eax
	subl	%r12d, %eax
	movw	%dx, 14+a(%rip)
	movl	%ebp, %edx
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L28
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L28:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 14+a(%rip)
	jmp	.L27
.L101:
	movswl	%r12w, %eax
	leal	(%rax,%rax,2), %eax
	addl	%eax, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L25
	leal	(%r12,%r12,2), %eax
	movl	%ebp, %edx
	xorl	%esi, %esi
	addl	%eax, %eax
	movw	%si, 12+a(%rip)
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L26
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L26:
	movl	$1, %ecx
	addl	%eax, %r11d
	movw	%cx, 12+a(%rip)
	jmp	.L25
.L100:
	movswl	%r12w, %eax
	leal	(%rax,%rax,4), %eax
	cmpl	%eax, 16(%rsp)
	jl	.L23
	leal	(%r12,%r12,4), %eax
	movl	%ebp, %edx
	xorl	%r8d, %r8d
	subl	%eax, %edx
	movw	%r8w, 10+a(%rip)
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L24
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L24:
	movl	$1, %edi
	addl	%eax, %r11d
	movw	%di, 10+a(%rip)
	jmp	.L23
.L99:
	movswl	%r12w, %eax
	sall	$2, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L21
	leal	0(,%r12,4), %eax
	movl	%ebp, %edx
	xorl	%r10d, %r10d
	subl	%eax, %edx
	movw	%r10w, 8+a(%rip)
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L22
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L22:
	movl	$1, %r9d
	addl	%eax, %r11d
	movw	%r9w, 8+a(%rip)
	jmp	.L21
.L98:
	movswl	%r12w, %eax
	leal	(%rax,%rax,2), %eax
	cmpl	%eax, 16(%rsp)
	jl	.L19
	xorl	%eax, %eax
	movl	%ebp, %edx
	movw	%ax, 6+a(%rip)
	leal	(%r12,%r12,2), %eax
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L20
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L20:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 6+a(%rip)
	jmp	.L19
.L97:
	movswl	%r12w, %eax
	addl	%eax, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L17
	xorl	%eax, %eax
	movl	%ebp, %edx
	movw	%ax, 4+a(%rip)
	leal	(%r12,%r12), %eax
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L18
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L18:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 4+a(%rip)
	jmp	.L17
.L96:
	movswl	%r12w, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L15
	xorl	%edx, %edx
	xorl	%eax, %eax
	movw	%dx, 2+a(%rip)
	movl	%ebp, %edx
	subl	%r12d, %edx
	cmpw	$332, %dx
	jg	.L16
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L16:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 2+a(%rip)
	jmp	.L15
.L95:
	movl	16(%rsp), %edi
	testl	%edi, %edi
	js	.L13
	xorl	%esi, %esi
	movw	%si, a(%rip)
	cmpw	$332, %bp
	jg	.L14
	movl	16(%rsp), %esi
	movswl	%r15w, %edi
	call	summing.part.0
	movl	%eax, %r11d
.L14:
	movl	$1, %ecx
	movw	%cx, a(%rip)
	jmp	.L13
.L104:
	xorl	%eax, %eax
	jmp	.L33
.L106:
	movl	16(%rsp), %r15d
	testl	%r15d, %r15d
	js	.L34
	xorl	%r12d, %r12d
	movw	%r12w, a(%rip)
	cmpw	$9, %bp
	jg	.L36
	leaq	a(%rip), %rax
	xorl	%r11d, %r11d
	cmpw	$1, (%rax,%r13,2)
	sete	%r11b
.L36:
	movl	$1, %r8d
	movw	%r8w, a(%rip)
	jmp	.L34
.L114:
	cmpl	$15, 16(%rsp)
	jle	.L58
	xorl	%esi, %esi
	leal	-16(%rbp), %edx
	movw	%si, 16+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L115
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L60:
	movl	$1, %ecx
	addl	%eax, %r11d
	movw	%cx, 16+a(%rip)
	jmp	.L58
.L113:
	cmpl	$13, 16(%rsp)
	jle	.L55
	xorl	%r8d, %r8d
	leal	-14(%rbp), %edx
	movw	%r8w, 14+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L116
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L57:
	movl	$1, %edi
	addl	%eax, %r11d
	movw	%di, 14+a(%rip)
	jmp	.L55
.L112:
	cmpl	$11, 16(%rsp)
	jle	.L52
	xorl	%r12d, %r12d
	leal	-12(%rbp), %edx
	movw	%r12w, 12+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L117
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L54:
	movl	$1, %r10d
	addl	%eax, %r11d
	movw	%r10w, 12+a(%rip)
	jmp	.L52
.L111:
	cmpl	$9, 16(%rsp)
	jle	.L49
	xorl	%eax, %eax
	leal	-10(%rbp), %edx
	movw	%ax, 10+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L118
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L51:
	movl	$1, %r15d
	addl	%eax, %r11d
	movw	%r15w, 10+a(%rip)
	jmp	.L49
.L110:
	cmpl	$7, 16(%rsp)
	jle	.L46
	xorl	%eax, %eax
	leal	-8(%rbp), %edx
	movw	%ax, 8+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L119
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L48:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 8+a(%rip)
	jmp	.L46
.L108:
	cmpl	$3, 16(%rsp)
	jle	.L40
	xorl	%ecx, %ecx
	leal	-4(%rbp), %edx
	movw	%cx, 4+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L120
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L42:
	movl	$1, %edx
	addl	%eax, %r11d
	movw	%dx, 4+a(%rip)
	jmp	.L40
.L109:
	cmpl	$5, 16(%rsp)
	jle	.L43
	xorl	%eax, %eax
	leal	-6(%rbp), %edx
	movw	%ax, 6+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L121
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L45:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 6+a(%rip)
	jmp	.L43
.L107:
	cmpl	$1, 16(%rsp)
	jle	.L37
	xorl	%edi, %edi
	leal	-2(%rbp), %edx
	movw	%di, 2+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L122
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L39:
	movl	$1, %esi
	addl	%eax, %r11d
	movw	%si, 2+a(%rip)
	jmp	.L37
.L115:
	xorl	%eax, %eax
	jmp	.L60
.L122:
	xorl	%eax, %eax
	jmp	.L39
.L116:
	xorl	%eax, %eax
	jmp	.L57
.L117:
	xorl	%eax, %eax
	jmp	.L54
.L118:
	xorl	%eax, %eax
	jmp	.L51
.L120:
	xorl	%eax, %eax
	jmp	.L42
.L119:
	xorl	%eax, %eax
	jmp	.L48
.L121:
	xorl	%eax, %eax
	jmp	.L45
	.cfi_endproc
.LFE25:
	.size	summing.part.0, .-summing.part.0
	.p2align 4
	.globl	summing
	.type	summing, @function
summing:
.LFB23:
	.cfi_startproc
	endbr64
	cmpw	$332, %si
	jg	.L126
	cmpw	$1, %di
	je	.L128
	movswl	%si, %esi
	movswl	%di, %edi
	jmp	summing.part.0
	.p2align 4,,10
	.p2align 3
.L128:
	xorl	%eax, %eax
	cmpw	$9, %si
	jg	.L123
	movswq	%si, %rsi
	leaq	a(%rip), %rax
	cmpw	$1, (%rax,%rsi,2)
	sete	%al
	movzbl	%al, %eax
	ret
	.p2align 4,,10
	.p2align 3
.L126:
	xorl	%eax, %eax
.L123:
	ret
	.cfi_endproc
.LFE23:
	.size	summing, .-summing
	.section	.rodata.str1.1,"aMS",@progbits,1
.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	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	movl	$6819840, %edx
	movdqa	.LC0(%rip), %xmm0
	movl	$255, %esi
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	leaq	v(%rip), %rdi
	leaq	a(%rip), %r14
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	leaq	.LC1(%rip), %r13
	leaq	s(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	leaq	n(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	leaq	.LC2(%rip), %rbx
	movl	$65537, 16+a(%rip)
	movaps	%xmm0, a(%rip)
	call	memset@PLT
	movl	$333, %eax
	movl	$10240, %edx
	movw	%ax, j(%rip)
	movw	%dx, i(%rip)
	jmp	.L130
	.p2align 4,,10
	.p2align 3
.L132:
	call	summing.part.0
	movswl	%ax, %edx
.L131:
	movq	%r13, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
.L130:
	xorl	%eax, %eax
	movq	%r12, %rdx
	movq	%rbp, %rsi
	movq	%rbx, %rdi
	call	__isoc99_scanf@PLT
	cmpl	$-1, %eax
	je	.L137
	movzwl	s(%rip), %eax
	xorl	%edx, %edx
	cmpw	$332, %ax
	jg	.L131
	movswl	n(%rip), %edi
	movswq	%ax, %rsi
	cmpw	$1, %di
	jne	.L132
	cmpw	$9, %ax
	jg	.L131
	xorl	%edx, %edx
	cmpw	$1, (%r14,%rsi,2)
	sete	%dl
	jmp	.L131
	.p2align 4,,10
	.p2align 3
.L137:
	popq	%rbx
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.globl	s
	.bss
	.align 2
	.type	s, @object
	.size	s, 2
s:
	.zero	2
	.globl	n
	.align 2
	.type	n, @object
	.size	n, 2
n:
	.zero	2
	.globl	j
	.align 2
	.type	j, @object
	.size	j, 2
j:
	.zero	2
	.globl	i
	.align 2
	.type	i, @object
	.size	i, 2
i:
	.zero	2
	.globl	a
	.align 16
	.type	a, @object
	.size	a, 20
a:
	.zero	20
	.globl	v
	.align 32
	.type	v, @object
	.size	v, 6819840
v:
	.zero	6819840
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC0:
	.value	1
	.value	1
	.value	1
	.value	1
	.value	1
	.value	1
	.value	1
	.value	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
	.type	summing.part.0, @function
summing.part.0:
.LFB25:
	.cfi_startproc
	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
	movl	%edi, %r12d
	movl	%esi, %edi
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	movl	%esi, %ebp
	leal	-1(%r12), %r15d
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movzwl	16+a(%rip), %eax
	movzwl	a(%rip), %r8d
	movswl	2+a(%rip), %edx
	movzwl	4+a(%rip), %esi
	movzwl	6+a(%rip), %ebx
	movw	%ax, 12(%rsp)
	movswl	%r8w, %eax
	movzwl	8+a(%rip), %ecx
	leal	(%rax,%rdx,2), %eax
	movl	%edx, %r10d
	movswl	%si, %edx
	leal	(%rax,%rdx,4), %eax
	movswl	%bx, %edx
	movzwl	10+a(%rip), %r14d
	movw	%bx, 22(%rsp)
	leal	(%rax,%rdx,8), %ebx
	movswl	%cx, %eax
	movzwl	12+a(%rip), %r11d
	movzwl	14+a(%rip), %r13d
	sall	$4, %eax
	movzwl	18+a(%rip), %r9d
	movw	%r14w, 26(%rsp)
	addl	%eax, %ebx
	movswl	%r14w, %eax
	movw	%r13w, 30(%rsp)
	leaq	v(%rip), %r14
	sall	$5, %eax
	movw	%r11w, 28(%rsp)
	addl	%eax, %ebx
	movswl	%r11w, %eax
	movw	%si, 20(%rsp)
	sall	$6, %eax
	movw	%cx, 24(%rsp)
	addl	%eax, %ebx
	movswl	%r13w, %eax
	movswq	%bp, %r13
	sall	$7, %eax
	addl	%eax, %ebx
	movswl	12(%rsp), %eax
	sall	$8, %eax
	addl	%eax, %ebx
	movswl	%r9w, %eax
	sall	$9, %eax
	addl	%eax, %ebx
	movswl	%bp, %eax
	leal	(%rbx,%rbx,4), %ebx
	movl	%eax, 16(%rsp)
	leal	(%r15,%rbx,2), %ebx
	movswq	%bx, %rbx
	leaq	(%rbx,%rbx,8), %rax
	leaq	(%rbx,%rax,4), %rax
	leaq	(%rax,%rax,8), %rax
	addq	%r13, %rax
	movzwl	(%r14,%rax,2), %r11d
	testw	%r11w, %r11w
	js	.L94
.L1:
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	movl	%r11d, %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
	.p2align 4,,10
	.p2align 3
.L94:
	.cfi_restore_state
	testw	%r12w, %r12w
	jle	.L63
	movl	%r8d, %ecx
	movl	%r12d, %edx
	xorl	%esi, %esi
	xorl	%eax, %eax
	leaq	a(%rip), %r11
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L4:
	addl	$1, %eax
	testw	%dx, %dx
	jle	.L65
	cmpw	$9, %ax
	jg	.L65
	movswq	%ax, %rcx
	movzwl	(%r11,%rcx,2), %ecx
.L7:
	cmpw	$1, %cx
	jne	.L4
	movl	%edx, %ecx
	subl	$1, %edx
	imull	%eax, %ecx
	addl	%ecx, %esi
	cmpw	%si, %di
	jge	.L4
	xorl	%r11d, %r11d
.L5:
	leaq	(%rbx,%rbx,8), %rax
	leaq	(%rbx,%rax,4), %rax
	leaq	(%rax,%rax,8), %rax
	addq	%r13, %rax
	movw	%r11w, (%r14,%rax,2)
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L65:
	movl	%r9d, %ecx
	movl	%r12d, %edx
	xorl	%esi, %esi
	movl	$9, %eax
	leaq	a(%rip), %r11
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L8:
	subl	$1, %eax
	testw	%dx, %dx
	jle	.L3
	testw	%ax, %ax
	js	.L3
	movswq	%ax, %rcx
	movzwl	(%r11,%rcx,2), %ecx
.L6:
	cmpw	$1, %cx
	jne	.L8
	movl	%edx, %ecx
	subl	$1, %edx
	imull	%eax, %ecx
	addl	%ecx, %esi
	cmpw	%si, %di
	jg	.L8
	xorl	%r11d, %r11d
	cmpw	$1, %r15w
	je	.L12
.L105:
	cmpw	$1, %r8w
	je	.L95
.L13:
	cmpw	$1, 2+a(%rip)
	je	.L96
.L15:
	cmpw	$1, 4+a(%rip)
	je	.L97
.L17:
	cmpw	$1, 6+a(%rip)
	je	.L98
.L19:
	cmpw	$1, 8+a(%rip)
	je	.L99
.L21:
	cmpw	$1, 10+a(%rip)
	je	.L100
.L23:
	cmpw	$1, 12+a(%rip)
	je	.L101
.L25:
	cmpw	$1, 14+a(%rip)
	je	.L102
.L27:
	cmpw	$1, 16+a(%rip)
	je	.L103
.L29:
	cmpw	$1, 18+a(%rip)
	jne	.L5
	movswl	%r12w, %eax
	leal	(%rax,%rax,8), %eax
	cmpl	%eax, 16(%rsp)
	jl	.L5
	leal	(%r12,%r12,8), %r12d
	xorl	%eax, %eax
	subl	%r12d, %ebp
	movw	%ax, 18+a(%rip)
	cmpw	$332, %bp
	jg	.L104
	movswl	%bp, %esi
	movswl	%r15w, %edi
	movl	%r11d, 12(%rsp)
	call	summing.part.0
	movl	12(%rsp), %r11d
.L33:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 18+a(%rip)
	jmp	.L5
.L63:
	xorl	%esi, %esi
	.p2align 4,,10
	.p2align 3
.L3:
	xorl	%r11d, %r11d
	cmpw	%si, %bp
	jg	.L5
	xorl	%r11d, %r11d
	cmpw	$1, %r15w
	jne	.L105
.L12:
	cmpw	$1, %r8w
	je	.L106
.L34:
	cmpw	$1, %r10w
	je	.L107
.L37:
	cmpw	$1, 20(%rsp)
	je	.L108
.L40:
	cmpw	$1, 22(%rsp)
	je	.L109
.L43:
	cmpw	$1, 24(%rsp)
	je	.L110
.L46:
	cmpw	$1, 26(%rsp)
	je	.L111
.L49:
	cmpw	$1, 28(%rsp)
	je	.L112
.L52:
	cmpw	$1, 30(%rsp)
	je	.L113
.L55:
	cmpw	$1, 12(%rsp)
	je	.L114
.L58:
	cmpw	$1, %r9w
	jne	.L5
	cmpl	$17, 16(%rsp)
	jle	.L5
	xorl	%edx, %edx
	subl	$18, %ebp
	movw	%dx, 18+a(%rip)
	movswq	%bp, %rax
	xorl	%edx, %edx
	cmpw	$9, %bp
	jg	.L62
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%dl
	movzbl	%dl, %edx
.L62:
	movl	$1, %eax
	addl	%edx, %r11d
	movw	%ax, 18+a(%rip)
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L103:
	movswl	%r12w, %eax
	sall	$3, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L29
	xorl	%eax, %eax
	movl	%ebp, %edx
	movw	%ax, 16+a(%rip)
	leal	0(,%r12,8), %eax
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L30
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L30:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 16+a(%rip)
	jmp	.L29
.L102:
	movswl	%r12w, %edx
	leal	0(,%rdx,8), %eax
	subl	%edx, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L27
	xorl	%edx, %edx
	leal	0(,%r12,8), %eax
	subl	%r12d, %eax
	movw	%dx, 14+a(%rip)
	movl	%ebp, %edx
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L28
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L28:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 14+a(%rip)
	jmp	.L27
.L101:
	movswl	%r12w, %eax
	leal	(%rax,%rax,2), %eax
	addl	%eax, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L25
	leal	(%r12,%r12,2), %eax
	movl	%ebp, %edx
	xorl	%esi, %esi
	addl	%eax, %eax
	movw	%si, 12+a(%rip)
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L26
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L26:
	movl	$1, %ecx
	addl	%eax, %r11d
	movw	%cx, 12+a(%rip)
	jmp	.L25
.L100:
	movswl	%r12w, %eax
	leal	(%rax,%rax,4), %eax
	cmpl	%eax, 16(%rsp)
	jl	.L23
	leal	(%r12,%r12,4), %eax
	movl	%ebp, %edx
	xorl	%r8d, %r8d
	subl	%eax, %edx
	movw	%r8w, 10+a(%rip)
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L24
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L24:
	movl	$1, %edi
	addl	%eax, %r11d
	movw	%di, 10+a(%rip)
	jmp	.L23
.L99:
	movswl	%r12w, %eax
	sall	$2, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L21
	leal	0(,%r12,4), %eax
	movl	%ebp, %edx
	xorl	%r10d, %r10d
	subl	%eax, %edx
	movw	%r10w, 8+a(%rip)
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L22
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L22:
	movl	$1, %r9d
	addl	%eax, %r11d
	movw	%r9w, 8+a(%rip)
	jmp	.L21
.L98:
	movswl	%r12w, %eax
	leal	(%rax,%rax,2), %eax
	cmpl	%eax, 16(%rsp)
	jl	.L19
	xorl	%eax, %eax
	movl	%ebp, %edx
	movw	%ax, 6+a(%rip)
	leal	(%r12,%r12,2), %eax
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L20
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L20:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 6+a(%rip)
	jmp	.L19
.L97:
	movswl	%r12w, %eax
	addl	%eax, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L17
	xorl	%eax, %eax
	movl	%ebp, %edx
	movw	%ax, 4+a(%rip)
	leal	(%r12,%r12), %eax
	subl	%eax, %edx
	xorl	%eax, %eax
	cmpw	$332, %dx
	jg	.L18
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L18:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 4+a(%rip)
	jmp	.L17
.L96:
	movswl	%r12w, %eax
	cmpl	%eax, 16(%rsp)
	jl	.L15
	xorl	%edx, %edx
	xorl	%eax, %eax
	movw	%dx, 2+a(%rip)
	movl	%ebp, %edx
	subl	%r12d, %edx
	cmpw	$332, %dx
	jg	.L16
	movswl	%r15w, %eax
	movswl	%dx, %esi
	movl	%r11d, 12(%rsp)
	movl	%eax, %edi
	call	summing.part.0
	movl	12(%rsp), %r11d
.L16:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 2+a(%rip)
	jmp	.L15
.L95:
	movl	16(%rsp), %edi
	testl	%edi, %edi
	js	.L13
	xorl	%esi, %esi
	movw	%si, a(%rip)
	cmpw	$332, %bp
	jg	.L14
	movl	16(%rsp), %esi
	movswl	%r15w, %edi
	call	summing.part.0
	movl	%eax, %r11d
.L14:
	movl	$1, %ecx
	movw	%cx, a(%rip)
	jmp	.L13
.L104:
	xorl	%eax, %eax
	jmp	.L33
.L106:
	movl	16(%rsp), %r15d
	testl	%r15d, %r15d
	js	.L34
	xorl	%r12d, %r12d
	movw	%r12w, a(%rip)
	cmpw	$9, %bp
	jg	.L36
	leaq	a(%rip), %rax
	xorl	%r11d, %r11d
	cmpw	$1, (%rax,%r13,2)
	sete	%r11b
.L36:
	movl	$1, %r8d
	movw	%r8w, a(%rip)
	jmp	.L34
.L114:
	cmpl	$15, 16(%rsp)
	jle	.L58
	xorl	%esi, %esi
	leal	-16(%rbp), %edx
	movw	%si, 16+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L115
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L60:
	movl	$1, %ecx
	addl	%eax, %r11d
	movw	%cx, 16+a(%rip)
	jmp	.L58
.L113:
	cmpl	$13, 16(%rsp)
	jle	.L55
	xorl	%r8d, %r8d
	leal	-14(%rbp), %edx
	movw	%r8w, 14+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L116
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L57:
	movl	$1, %edi
	addl	%eax, %r11d
	movw	%di, 14+a(%rip)
	jmp	.L55
.L112:
	cmpl	$11, 16(%rsp)
	jle	.L52
	xorl	%r12d, %r12d
	leal	-12(%rbp), %edx
	movw	%r12w, 12+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L117
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L54:
	movl	$1, %r10d
	addl	%eax, %r11d
	movw	%r10w, 12+a(%rip)
	jmp	.L52
.L111:
	cmpl	$9, 16(%rsp)
	jle	.L49
	xorl	%eax, %eax
	leal	-10(%rbp), %edx
	movw	%ax, 10+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L118
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L51:
	movl	$1, %r15d
	addl	%eax, %r11d
	movw	%r15w, 10+a(%rip)
	jmp	.L49
.L110:
	cmpl	$7, 16(%rsp)
	jle	.L46
	xorl	%eax, %eax
	leal	-8(%rbp), %edx
	movw	%ax, 8+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L119
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L48:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 8+a(%rip)
	jmp	.L46
.L108:
	cmpl	$3, 16(%rsp)
	jle	.L40
	xorl	%ecx, %ecx
	leal	-4(%rbp), %edx
	movw	%cx, 4+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L120
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L42:
	movl	$1, %edx
	addl	%eax, %r11d
	movw	%dx, 4+a(%rip)
	jmp	.L40
.L109:
	cmpl	$5, 16(%rsp)
	jle	.L43
	xorl	%eax, %eax
	leal	-6(%rbp), %edx
	movw	%ax, 6+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L121
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L45:
	addl	%eax, %r11d
	movl	$1, %eax
	movw	%ax, 6+a(%rip)
	jmp	.L43
.L107:
	cmpl	$1, 16(%rsp)
	jle	.L37
	xorl	%edi, %edi
	leal	-2(%rbp), %edx
	movw	%di, 2+a(%rip)
	movswq	%dx, %rax
	cmpw	$9, %dx
	jg	.L122
	leaq	a(%rip), %rdx
	cmpw	$1, (%rdx,%rax,2)
	sete	%al
	movzbl	%al, %eax
.L39:
	movl	$1, %esi
	addl	%eax, %r11d
	movw	%si, 2+a(%rip)
	jmp	.L37
.L115:
	xorl	%eax, %eax
	jmp	.L60
.L122:
	xorl	%eax, %eax
	jmp	.L39
.L116:
	xorl	%eax, %eax
	jmp	.L57
.L117:
	xorl	%eax, %eax
	jmp	.L54
.L118:
	xorl	%eax, %eax
	jmp	.L51
.L120:
	xorl	%eax, %eax
	jmp	.L42
.L119:
	xorl	%eax, %eax
	jmp	.L48
.L121:
	xorl	%eax, %eax
	jmp	.L45
	.cfi_endproc
.LFE25:
	.size	summing.part.0, .-summing.part.0
	.p2align 4
	.globl	summing
	.type	summing, @function
summing:
.LFB23:
	.cfi_startproc
	endbr64
	cmpw	$332, %si
	jg	.L126
	cmpw	$1, %di
	je	.L128
	movswl	%si, %esi
	movswl	%di, %edi
	jmp	summing.part.0
	.p2align 4,,10
	.p2align 3
.L128:
	xorl	%eax, %eax
	cmpw	$9, %si
	jg	.L123
	movswq	%si, %rsi
	leaq	a(%rip), %rax
	cmpw	$1, (%rax,%rsi,2)
	sete	%al
	movzbl	%al, %eax
	ret
	.p2align 4,,10
	.p2align 3
.L126:
	xorl	%eax, %eax
.L123:
	ret
	.cfi_endproc
.LFE23:
	.size	summing, .-summing
	.section	.rodata.str1.1,"aMS",@progbits,1
.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	%r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	movl	$6819840, %edx
	movdqa	.LC0(%rip), %xmm0
	movl	$255, %esi
	pushq	%r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	leaq	v(%rip), %rdi
	leaq	a(%rip), %r14
	pushq	%r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	leaq	.LC1(%rip), %r13
	leaq	s(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	leaq	n(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	leaq	.LC2(%rip), %rbx
	movl	$65537, 16+a(%rip)
	movaps	%xmm0, a(%rip)
	call	memset@PLT
	movl	$333, %eax
	movl	$10240, %edx
	movw	%ax, j(%rip)
	movw	%dx, i(%rip)
	jmp	.L130
	.p2align 4,,10
	.p2align 3
.L132:
	call	summing.part.0
	movswl	%ax, %edx
.L131:
	movq	%r13, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
.L130:
	xorl	%eax, %eax
	movq	%r12, %rdx
	movq	%rbp, %rsi
	movq	%rbx, %rdi
	call	__isoc99_scanf@PLT
	cmpl	$-1, %eax
	je	.L137
	movzwl	s(%rip), %eax
	xorl	%edx, %edx
	cmpw	$332, %ax
	jg	.L131
	movswl	n(%rip), %edi
	movswq	%ax, %rsi
	cmpw	$1, %di
	jne	.L132
	cmpw	$9, %ax
	jg	.L131
	xorl	%edx, %edx
	cmpw	$1, (%r14,%rsi,2)
	sete	%dl
	jmp	.L131
	.p2align 4,,10
	.p2align 3
.L137:
	popq	%rbx
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbp
	.cfi_def_cfa_offset 32
	popq	%r12
	.cfi_def_cfa_offset 24
	popq	%r13
	.cfi_def_cfa_offset 16
	popq	%r14
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.globl	s
	.bss
	.align 2
	.type	s, @object
	.size	s, 2
s:
	.zero	2
	.globl	n
	.align 2
	.type	n, @object
	.size	n, 2
n:
	.zero	2
	.globl	j
	.align 2
	.type	j, @object
	.size	j, 2
j:
	.zero	2
	.globl	i
	.align 2
	.type	i, @object
	.size	i, 2
i:
	.zero	2
	.globl	a
	.align 16
	.type	a, @object
	.size	a, 20
a:
	.zero	20
	.globl	v
	.align 32
	.type	v, @object
	.size	v, 6819840
v:
	.zero	6819840
	.section	.rodata.cst16,"aM",@progbits,16
	.align 16
.LC0:
	.value	1
	.value	1
	.value	1
	.value	1
	.value	1
	.value	1
	.value	1
	.value	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 <math.h>
short v[10240][333],a[10],i,j,n,s;
short summing(short n,short s){
	short ans=0,i,max=0,min=0,m,k;
	if(s>332)return 0;
	if(n==1){if(s<10 && a[s]==1)return 1; else return 0;}
	else{
		k=(a[0]+a[1]*2+a[2]*4+a[3]*8+a[4]*16+a[5]*32+a[6]*64+a[7]*128+a[8]*256+a[9]*512)*10+(n-1);
		if(v[k][s]>=0)return v[k][s];
		for(i=0,m=n;m>0 && i<10;i++){if(a[i]==1){min+=m*i;m--;if(s<min)goto answer;}}
		for(i=9,m=n;m>0 && i>=0;i--){if(a[i]==1){max+=m*i;m--;if(s<=max)break;}}if(s>max)goto answer;
		for(i=0;i<10;i++){
			if(a[i]==1 && n*i<=s){
				a[i]=0;
				ans+=summing(n-1,s-n*i);
				a[i]=1;
			}
		}
		answer:
		v[k][s]=ans;
		return ans;
	}
}
int main(void){
	for(i=0;i<10;i++)a[i]=1;
	for(i=0;i<10240;i++){{for(j=0;j<333;j++)v[i][j]=-1;}}
	while(scanf("%d %d",&n,&s)!=EOF){printf("%d\n",summing(n,s));}
	return 0;
}
4 10
3 1
 6 10
3 1
 2 14
3 1
 2 25
10 0
 2 4
10 0
 3 10
0 1
 3 14
10 3
 3 10
2 1
 2 9
3 1
 2 14
2 1

1
0
 0
0
 5
0
 2
0
 3
0
 8
0
 14
0
 8
1
 4
0
 5
1

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 <math.h>
short v[10240][333],a[10],i,j,n,s;
short summing(short n,short s){
	short ans=0,i,max=0,min=0,m,k;
	if(s>332)return 0;
	if(n==1){if(s<10 && a[s]==1)return 1; else return 0;}
	else{
		k=(a[0]+a[1]*2+a[2]*4+a[3]*8+a[4]*16+a[5]*32+a[6]*64+a[7]*128+a[8]*256+a[9]*512)*10+(n-1);
		if(v[k][s]>=0)return v[k][s];
		for(i=0,m=n;m>0 && i<10;i++){if(a[i]==1){min+=m*i;m--;if(s<min)goto answer;}}
		for(i=9,m=n;m>0 && i>=0;i--){if(a[i]==1){max+=m*i;m--;if(s<=max)break;}}if(s>max)goto answer;
		for(i=0;i<10;i++){
			if(a[i]==1 && n*i<=s){
				a[i]=0;
				ans+=summing(n-1,s-n*i);
				a[i]=1;
			}
		}
		answer:
		v[k][s]=ans;
		return ans;
	}
}
int main(void){
	for(i=0;i<10;i++)a[i]=1;
	for(i=0;i<10240;i++){{for(j=0;j<333;j++)v[i][j]=-1;}}
	while(scanf("%d %d",&n,&s)!=EOF){printf("%d\n",summing(n,s));}
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	v
	.bss
	.align 32
	.type	v, @object
	.size	v, 6819840
v:
	.zero	6819840
	.globl	a
	.align 16
	.type	a, @object
	.size	a, 20
a:
	.zero	20
	.globl	i
	.align 2
	.type	i, @object
	.size	i, 2
i:
	.zero	2
	.globl	j
	.align 2
	.type	j, @object
	.size	j, 2
j:
	.zero	2
	.globl	n
	.align 2
	.type	n, @object
	.size	n, 2
n:
	.zero	2
	.globl	s
	.align 2
	.type	s, @object
	.size	s, 2
s:
	.zero	2
	.text
	.globl	summing
	.type	summing, @function
summing:
.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, %edx
	movl	%esi, %eax
	movw	%dx, -20(%rbp)
	movw	%ax, -24(%rbp)
	movw	$0, -12(%rbp)
	movw	$0, -8(%rbp)
	movw	$0, -6(%rbp)
	cmpw	$332, -24(%rbp)
	jle	.L2
	movl	$0, %eax
	jmp	.L3
.L2:
	cmpw	$1, -20(%rbp)
	jne	.L4
	cmpw	$9, -24(%rbp)
	jg	.L5
	movswl	-24(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L5
	movl	$1, %eax
	jmp	.L3
.L5:
	movl	$0, %eax
	jmp	.L3
.L4:
	movzwl	a(%rip), %eax
	movswl	%ax, %edx
	movzwl	2+a(%rip), %eax
	cwtl
	addl	%eax, %eax
	addl	%eax, %edx
	movzwl	4+a(%rip), %eax
	cwtl
	sall	$2, %eax
	addl	%eax, %edx
	movzwl	6+a(%rip), %eax
	cwtl
	sall	$3, %eax
	addl	%eax, %edx
	movzwl	8+a(%rip), %eax
	cwtl
	sall	$4, %eax
	addl	%eax, %edx
	movzwl	10+a(%rip), %eax
	cwtl
	sall	$5, %eax
	addl	%eax, %edx
	movzwl	12+a(%rip), %eax
	cwtl
	sall	$6, %eax
	addl	%eax, %edx
	movzwl	14+a(%rip), %eax
	cwtl
	sall	$7, %eax
	addl	%eax, %edx
	movzwl	16+a(%rip), %eax
	cwtl
	sall	$8, %eax
	addl	%eax, %edx
	movzwl	18+a(%rip), %eax
	cwtl
	sall	$9, %eax
	addl	%edx, %eax
	movl	%eax, %edx
	movl	%edx, %eax
	sall	$2, %eax
	addl	%edx, %eax
	addl	%eax, %eax
	movl	%eax, %edx
	movzwl	-20(%rbp), %eax
	addl	%edx, %eax
	subl	$1, %eax
	movw	%ax, -2(%rbp)
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	testw	%ax, %ax
	js	.L6
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	jmp	.L3
.L6:
	movw	$0, -10(%rbp)
	movzwl	-20(%rbp), %eax
	movw	%ax, -4(%rbp)
	jmp	.L7
.L11:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L8
	movzwl	-4(%rbp), %edx
	movzwl	-10(%rbp), %eax
	imull	%eax, %edx
	movzwl	-6(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -6(%rbp)
	movzwl	-4(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -4(%rbp)
	movzwl	-24(%rbp), %eax
	cmpw	-6(%rbp), %ax
	jl	.L20
.L8:
	movzwl	-10(%rbp), %eax
	addl	$1, %eax
	movw	%ax, -10(%rbp)
.L7:
	cmpw	$0, -4(%rbp)
	jle	.L10
	cmpw	$9, -10(%rbp)
	jle	.L11
.L10:
	movw	$9, -10(%rbp)
	movzwl	-20(%rbp), %eax
	movw	%ax, -4(%rbp)
	jmp	.L12
.L15:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L13
	movzwl	-4(%rbp), %edx
	movzwl	-10(%rbp), %eax
	imull	%eax, %edx
	movzwl	-8(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -8(%rbp)
	movzwl	-4(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -4(%rbp)
	movzwl	-24(%rbp), %eax
	cmpw	-8(%rbp), %ax
	jle	.L21
.L13:
	movzwl	-10(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -10(%rbp)
.L12:
	cmpw	$0, -4(%rbp)
	jle	.L14
	cmpw	$0, -10(%rbp)
	jns	.L15
	jmp	.L14
.L21:
	nop
.L14:
	movzwl	-24(%rbp), %eax
	cmpw	-8(%rbp), %ax
	jg	.L22
	movw	$0, -10(%rbp)
	jmp	.L17
.L19:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L18
	movswl	-20(%rbp), %edx
	movswl	-10(%rbp), %eax
	imull	%eax, %edx
	movswl	-24(%rbp), %eax
	cmpl	%eax, %edx
	jg	.L18
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$0, (%rdx,%rax)
	movzwl	-24(%rbp), %eax
	movzwl	-20(%rbp), %ecx
	movzwl	-10(%rbp), %edx
	imull	%ecx, %edx
	subl	%edx, %eax
	movswl	%ax, %edx
	movzwl	-20(%rbp), %eax
	subl	$1, %eax
	cwtl
	movl	%edx, %esi
	movl	%eax, %edi
	call	summing
	movl	%eax, %edx
	movzwl	-12(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -12(%rbp)
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$1, (%rdx,%rax)
.L18:
	movzwl	-10(%rbp), %eax
	addl	$1, %eax
	movw	%ax, -10(%rbp)
.L17:
	cmpw	$9, -10(%rbp)
	jle	.L19
	jmp	.L9
.L20:
	nop
	jmp	.L9
.L22:
	nop
.L9:
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rcx
	leaq	v(%rip), %rdx
	movzwl	-12(%rbp), %eax
	movw	%ax, (%rcx,%rdx)
	movzwl	-12(%rbp), %eax
.L3:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	summing, .-summing
	.section	.rodata
.LC0:
	.string	"%d\n"
.LC1:
	.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
	movw	$0, i(%rip)
	jmp	.L24
.L25:
	movzwl	i(%rip), %eax
	cwtl
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$1, (%rdx,%rax)
	movzwl	i(%rip), %eax
	addl	$1, %eax
	movw	%ax, i(%rip)
.L24:
	movzwl	i(%rip), %eax
	cmpw	$9, %ax
	jle	.L25
	movw	$0, i(%rip)
	jmp	.L26
.L29:
	movw	$0, j(%rip)
	jmp	.L27
.L28:
	movzwl	i(%rip), %eax
	cwtl
	movzwl	j(%rip), %edx
	movswl	%dx, %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movw	$-1, (%rdx,%rax)
	movzwl	j(%rip), %eax
	addl	$1, %eax
	movw	%ax, j(%rip)
.L27:
	movzwl	j(%rip), %eax
	cmpw	$332, %ax
	jle	.L28
	movzwl	i(%rip), %eax
	addl	$1, %eax
	movw	%ax, i(%rip)
.L26:
	movzwl	i(%rip), %eax
	cmpw	$10239, %ax
	jle	.L29
	jmp	.L30
.L31:
	movzwl	s(%rip), %eax
	movswl	%ax, %edx
	movzwl	n(%rip), %eax
	cwtl
	movl	%edx, %esi
	movl	%eax, %edi
	call	summing
	cwtl
	movl	%eax, %esi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L30:
	leaq	s(%rip), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	cmpl	$-1, %eax
	jne	.L31
	movl	$0, %eax
	popq	%rbp
	.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	v
	.bss
	.align 32
	.type	v, @object
	.size	v, 6819840
v:
	.zero	6819840
	.globl	a
	.align 16
	.type	a, @object
	.size	a, 20
a:
	.zero	20
	.globl	i
	.align 2
	.type	i, @object
	.size	i, 2
i:
	.zero	2
	.globl	j
	.align 2
	.type	j, @object
	.size	j, 2
j:
	.zero	2
	.globl	n
	.align 2
	.type	n, @object
	.size	n, 2
n:
	.zero	2
	.globl	s
	.align 2
	.type	s, @object
	.size	s, 2
s:
	.zero	2
	.text
	.globl	summing
	.type	summing, @function
summing:
.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, %edx
	movl	%esi, %eax
	movw	%dx, -20(%rbp)
	movw	%ax, -24(%rbp)
	movw	$0, -12(%rbp)
	movw	$0, -8(%rbp)
	movw	$0, -6(%rbp)
	cmpw	$332, -24(%rbp)
	jle	.L2
	movl	$0, %eax
	jmp	.L3
.L2:
	cmpw	$1, -20(%rbp)
	jne	.L4
	cmpw	$9, -24(%rbp)
	jg	.L5
	movswl	-24(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L5
	movl	$1, %eax
	jmp	.L3
.L5:
	movl	$0, %eax
	jmp	.L3
.L4:
	movzwl	a(%rip), %eax
	movswl	%ax, %edx
	movzwl	2+a(%rip), %eax
	cwtl
	addl	%eax, %eax
	addl	%eax, %edx
	movzwl	4+a(%rip), %eax
	cwtl
	sall	$2, %eax
	addl	%eax, %edx
	movzwl	6+a(%rip), %eax
	cwtl
	sall	$3, %eax
	addl	%eax, %edx
	movzwl	8+a(%rip), %eax
	cwtl
	sall	$4, %eax
	addl	%eax, %edx
	movzwl	10+a(%rip), %eax
	cwtl
	sall	$5, %eax
	addl	%eax, %edx
	movzwl	12+a(%rip), %eax
	cwtl
	sall	$6, %eax
	addl	%eax, %edx
	movzwl	14+a(%rip), %eax
	cwtl
	sall	$7, %eax
	addl	%eax, %edx
	movzwl	16+a(%rip), %eax
	cwtl
	sall	$8, %eax
	addl	%eax, %edx
	movzwl	18+a(%rip), %eax
	cwtl
	sall	$9, %eax
	addl	%edx, %eax
	movl	%eax, %edx
	movl	%edx, %eax
	sall	$2, %eax
	addl	%edx, %eax
	addl	%eax, %eax
	movl	%eax, %edx
	movzwl	-20(%rbp), %eax
	addl	%edx, %eax
	subl	$1, %eax
	movw	%ax, -2(%rbp)
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	testw	%ax, %ax
	js	.L6
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	jmp	.L3
.L6:
	movw	$0, -10(%rbp)
	movzwl	-20(%rbp), %eax
	movw	%ax, -4(%rbp)
	jmp	.L7
.L11:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L8
	movzwl	-4(%rbp), %edx
	movzwl	-10(%rbp), %eax
	imull	%eax, %edx
	movzwl	-6(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -6(%rbp)
	movzwl	-4(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -4(%rbp)
	movzwl	-24(%rbp), %eax
	cmpw	-6(%rbp), %ax
	jl	.L20
.L8:
	movzwl	-10(%rbp), %eax
	addl	$1, %eax
	movw	%ax, -10(%rbp)
.L7:
	cmpw	$0, -4(%rbp)
	jle	.L10
	cmpw	$9, -10(%rbp)
	jle	.L11
.L10:
	movw	$9, -10(%rbp)
	movzwl	-20(%rbp), %eax
	movw	%ax, -4(%rbp)
	jmp	.L12
.L15:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L13
	movzwl	-4(%rbp), %edx
	movzwl	-10(%rbp), %eax
	imull	%eax, %edx
	movzwl	-8(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -8(%rbp)
	movzwl	-4(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -4(%rbp)
	movzwl	-24(%rbp), %eax
	cmpw	-8(%rbp), %ax
	jle	.L21
.L13:
	movzwl	-10(%rbp), %eax
	subl	$1, %eax
	movw	%ax, -10(%rbp)
.L12:
	cmpw	$0, -4(%rbp)
	jle	.L14
	cmpw	$0, -10(%rbp)
	jns	.L15
	jmp	.L14
.L21:
	nop
.L14:
	movzwl	-24(%rbp), %eax
	cmpw	-8(%rbp), %ax
	jg	.L22
	movw	$0, -10(%rbp)
	jmp	.L17
.L19:
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movzwl	(%rdx,%rax), %eax
	cmpw	$1, %ax
	jne	.L18
	movswl	-20(%rbp), %edx
	movswl	-10(%rbp), %eax
	imull	%eax, %edx
	movswl	-24(%rbp), %eax
	cmpl	%eax, %edx
	jg	.L18
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$0, (%rdx,%rax)
	movzwl	-24(%rbp), %eax
	movzwl	-20(%rbp), %ecx
	movzwl	-10(%rbp), %edx
	imull	%ecx, %edx
	subl	%edx, %eax
	movswl	%ax, %edx
	movzwl	-20(%rbp), %eax
	subl	$1, %eax
	cwtl
	movl	%edx, %esi
	movl	%eax, %edi
	call	summing
	movl	%eax, %edx
	movzwl	-12(%rbp), %eax
	addl	%edx, %eax
	movw	%ax, -12(%rbp)
	movswl	-10(%rbp), %eax
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$1, (%rdx,%rax)
.L18:
	movzwl	-10(%rbp), %eax
	addl	$1, %eax
	movw	%ax, -10(%rbp)
.L17:
	cmpw	$9, -10(%rbp)
	jle	.L19
	jmp	.L9
.L20:
	nop
	jmp	.L9
.L22:
	nop
.L9:
	movswl	-2(%rbp), %eax
	movswl	-24(%rbp), %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rcx
	leaq	v(%rip), %rdx
	movzwl	-12(%rbp), %eax
	movw	%ax, (%rcx,%rdx)
	movzwl	-12(%rbp), %eax
.L3:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	summing, .-summing
	.section	.rodata
.LC0:
	.string	"%d\n"
.LC1:
	.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
	movw	$0, i(%rip)
	jmp	.L24
.L25:
	movzwl	i(%rip), %eax
	cwtl
	cltq
	leaq	(%rax,%rax), %rdx
	leaq	a(%rip), %rax
	movw	$1, (%rdx,%rax)
	movzwl	i(%rip), %eax
	addl	$1, %eax
	movw	%ax, i(%rip)
.L24:
	movzwl	i(%rip), %eax
	cmpw	$9, %ax
	jle	.L25
	movw	$0, i(%rip)
	jmp	.L26
.L29:
	movw	$0, j(%rip)
	jmp	.L27
.L28:
	movzwl	i(%rip), %eax
	cwtl
	movzwl	j(%rip), %edx
	movswl	%dx, %edx
	movslq	%edx, %rcx
	movslq	%eax, %rdx
	movq	%rdx, %rax
	salq	$3, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	leaq	0(,%rax,8), %rdx
	addq	%rdx, %rax
	addq	%rcx, %rax
	leaq	(%rax,%rax), %rdx
	leaq	v(%rip), %rax
	movw	$-1, (%rdx,%rax)
	movzwl	j(%rip), %eax
	addl	$1, %eax
	movw	%ax, j(%rip)
.L27:
	movzwl	j(%rip), %eax
	cmpw	$332, %ax
	jle	.L28
	movzwl	i(%rip), %eax
	addl	$1, %eax
	movw	%ax, i(%rip)
.L26:
	movzwl	i(%rip), %eax
	cmpw	$10239, %ax
	jle	.L29
	jmp	.L30
.L31:
	movzwl	s(%rip), %eax
	movswl	%ax, %edx
	movzwl	n(%rip), %eax
	cwtl
	movl	%edx, %esi
	movl	%eax, %edi
	call	summing
	cwtl
	movl	%eax, %esi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L30:
	leaq	s(%rip), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	cmpl	$-1, %eax
	jne	.L31
	movl	$0, %eax
	popq	%rbp
	.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:
