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

typedef unsigned long long u64;

#define N (62500)

u64 dp[N + 1000];

int main(void) {
  int n;
  scanf("%d", &n);
  
  dp[0] = 1;

  int s = 0;
  while (n--) {
    int a;
    scanf("%d", &a);

    s += a;

    int H = a / 64;
    int L = a % 64;

    if (L == 0) {
      for (int i = N; i >= 0; i--) {
        dp[i + H] |= dp[i];
      }
    } else {
      for (int i = N; i >= 0; i--) {
        dp[i + H + 1] |= dp[i] >> (64 - L);
        dp[i + H] |= dp[i] << L;
      }
    }
  }

  s = (s + 1) / 2;
  while (~dp[s / 64] >> s % 64 & 1) s++;

  printf("%d\n", s);

  return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	dp
	.bss
	.align 32
	.type	dp, @object
	.size	dp, 508000
dp:
	.zero	508000
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-36(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$1, dp(%rip)
	movl	$0, -28(%rbp)
	jmp	.L2
.L9:
	leaq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-32(%rbp), %eax
	addl	%eax, -28(%rbp)
	movl	-32(%rbp), %eax
	leal	63(%rax), %edx
	testl	%eax, %eax
	cmovs	%edx, %eax
	sarl	$6, %eax
	movl	%eax, -16(%rbp)
	movl	-32(%rbp), %eax
	cltd
	shrl	$26, %edx
	addl	%edx, %eax
	andl	$63, %eax
	subl	%edx, %eax
	movl	%eax, -12(%rbp)
	cmpl	$0, -12(%rbp)
	jne	.L3
	movl	$62500, -24(%rbp)
	jmp	.L4
.L5:
	movl	-24(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rcx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-24(%rbp), %esi
	movl	-16(%rbp), %eax
	addl	%esi, %eax
	orq	%rdx, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	subl	$1, -24(%rbp)
.L4:
	cmpl	$0, -24(%rbp)
	jns	.L5
	jmp	.L2
.L3:
	movl	$62500, -20(%rbp)
	jmp	.L7
.L8:
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	$64, %eax
	subl	-12(%rbp), %eax
	movl	%eax, %ecx
	shrq	%cl, %rdx
	movq	%rdx, %rcx
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	addl	$1, %eax
	orq	%rsi, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-12(%rbp), %eax
	movl	%eax, %ecx
	salq	%cl, %rdx
	movq	%rdx, %rcx
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	orq	%rsi, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	subl	$1, -20(%rbp)
.L7:
	cmpl	$0, -20(%rbp)
	jns	.L8
.L2:
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -36(%rbp)
	testl	%eax, %eax
	jne	.L9
	movl	-28(%rbp), %eax
	addl	$1, %eax
	movl	%eax, %edx
	shrl	$31, %edx
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -28(%rbp)
	jmp	.L10
.L11:
	addl	$1, -28(%rbp)
.L10:
	movl	-28(%rbp), %eax
	leal	63(%rax), %edx
	testl	%eax, %eax
	cmovs	%edx, %eax
	sarl	$6, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rax
	notq	%rax
	movq	%rax, %rdx
	movl	-28(%rbp), %eax
	andl	$63, %eax
	movl	%eax, %ecx
	shrq	%cl, %rdx
	movq	%rdx, %rax
	andl	$1, %eax
	testq	%rax, %rax
	jne	.L11
	movl	-28(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.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
	.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:
.LFB51:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %rsi
	call	__isoc99_scanf@PLT
	movl	(%rsp), %edx
	movq	$1, dp(%rip)
	leal	-1(%rdx), %eax
	movl	%eax, (%rsp)
	testl	%edx, %edx
	je	.L2
	leaq	dp(%rip), %r15
	xorl	%ebx, %ebx
	leaq	4(%rsp), %r12
	leaq	-16(%r15), %r14
	leaq	500008(%r14), %r13
	.p2align 4,,10
	.p2align 3
.L8:
	movq	%rbp, %rdi
	xorl	%eax, %eax
	movq	%r12, %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %ecx
	addl	%ecx, %ebx
	leal	63(%rcx), %eax
	testl	%ecx, %ecx
	movl	%ecx, %edi
	cmovns	%ecx, %eax
	sarl	$6, %eax
	movl	%eax, %edx
	andl	$63, %edi
	jne	.L3
	cmpl	$-1, %eax
	je	.L4
	leal	62500(%rax), %eax
	cltq
	leaq	-8(%r15,%rax,8), %rcx
	xorl	%eax, %eax
	.p2align 4,,10
	.p2align 3
.L5:
	movdqu	0(%r13,%rax), %xmm0
	movdqu	(%rcx,%rax), %xmm1
	shufpd	$1, %xmm0, %xmm0
	shufpd	$1, %xmm1, %xmm1
	por	%xmm1, %xmm0
	shufpd	$1, %xmm0, %xmm0
	movups	%xmm0, (%rcx,%rax)
	subq	$16, %rax
	cmpq	$-500000, %rax
	jne	.L5
	movslq	%edx, %rax
	movq	(%r15), %rdx
	orq	%rdx, (%r15,%rax,8)
.L11:
	movl	(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, (%rsp)
	testl	%eax, %eax
	jne	.L8
	leal	1(%rbx), %ecx
	leal	128(%rbx), %eax
	movl	%ecx, %edx
	shrl	$31, %edx
	addl	%ecx, %edx
	sarl	%edx
	testl	%ecx, %ecx
	cmovns	%ecx, %eax
	sarl	$7, %eax
	jmp	.L27
	.p2align 4,,10
	.p2align 3
.L29:
	addl	$1, %edx
	leal	63(%rdx), %eax
	cmovns	%edx, %eax
	sarl	$6, %eax
.L27:
	cltq
	movq	(%r15,%rax,8), %rax
	notq	%rax
	btq	%rdx, %rax
	jc	.L29
.L2:
	xorl	%eax, %eax
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L30
	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
.L3:
	.cfi_restore_state
	movl	%ecx, %eax
	sarl	$31, %eax
	shrl	$26, %eax
	addl	%eax, %ecx
	andl	$63, %ecx
	subl	%ecx, %eax
	leaq	500008+dp(%rip), %rcx
	leal	64(%rax), %r11d
	movslq	%edx, %rax
	leaq	0(,%rax,8), %rsi
	movq	(%rcx,%rax,8), %rdx
	subq	$500016, %rcx
	leaq	500000(%r15,%rsi), %rax
	leaq	(%rcx,%rsi), %r10
	negq	%rsi
	.p2align 4,,10
	.p2align 3
.L10:
	movq	(%rax,%rsi), %r8
	movl	%r11d, %ecx
	subq	$8, %rax
	shrq	%cl, %r8
	movl	%edi, %ecx
	orq	%r8, %rdx
	movq	%rdx, 16(%rax)
	movq	8(%rax,%rsi), %rdx
	salq	%cl, %rdx
	orq	8(%rax), %rdx
	movq	%rdx, 8(%rax)
	cmpq	%rax, %r10
	jne	.L10
	jmp	.L11
.L4:
	leaq	499992+dp(%rip), %rax
	.p2align 4,,10
	.p2align 3
.L7:
	movq	8(%rax), %rdx
	orq	%rdx, (%rax)
	subq	$8, %rax
	cmpq	%rax, %r14
	jne	.L7
	jmp	.L11
.L30:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE51:
	.size	main, .-main
	.globl	dp
	.bss
	.align 32
	.type	dp, @object
	.size	dp, 508000
dp:
	.zero	508000
	.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
	.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:
.LFB51:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %rsi
	call	__isoc99_scanf@PLT
	movl	(%rsp), %edx
	movq	$1, dp(%rip)
	leal	-1(%rdx), %eax
	movl	%eax, (%rsp)
	testl	%edx, %edx
	je	.L2
	leaq	dp(%rip), %r15
	xorl	%ebx, %ebx
	leaq	4(%rsp), %r12
	leaq	-16(%r15), %r14
	leaq	500008(%r14), %r13
	.p2align 4,,10
	.p2align 3
.L8:
	movq	%rbp, %rdi
	xorl	%eax, %eax
	movq	%r12, %rsi
	call	__isoc99_scanf@PLT
	movl	4(%rsp), %ecx
	addl	%ecx, %ebx
	leal	63(%rcx), %eax
	testl	%ecx, %ecx
	movl	%ecx, %edi
	cmovns	%ecx, %eax
	sarl	$6, %eax
	movl	%eax, %edx
	andl	$63, %edi
	jne	.L3
	cmpl	$-1, %eax
	je	.L4
	leal	62500(%rax), %eax
	cltq
	leaq	-8(%r15,%rax,8), %rcx
	xorl	%eax, %eax
	.p2align 4,,10
	.p2align 3
.L5:
	movdqu	0(%r13,%rax), %xmm0
	movdqu	(%rcx,%rax), %xmm1
	shufpd	$1, %xmm0, %xmm0
	shufpd	$1, %xmm1, %xmm1
	por	%xmm1, %xmm0
	shufpd	$1, %xmm0, %xmm0
	movups	%xmm0, (%rcx,%rax)
	subq	$16, %rax
	cmpq	$-500000, %rax
	jne	.L5
	movslq	%edx, %rax
	movq	(%r15), %rdx
	orq	%rdx, (%r15,%rax,8)
.L11:
	movl	(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, (%rsp)
	testl	%eax, %eax
	jne	.L8
	leal	1(%rbx), %ecx
	leal	128(%rbx), %eax
	movl	%ecx, %edx
	shrl	$31, %edx
	addl	%ecx, %edx
	sarl	%edx
	testl	%ecx, %ecx
	cmovns	%ecx, %eax
	sarl	$7, %eax
	jmp	.L27
	.p2align 4,,10
	.p2align 3
.L29:
	addl	$1, %edx
	leal	63(%rdx), %eax
	cmovns	%edx, %eax
	sarl	$6, %eax
.L27:
	cltq
	movq	(%r15,%rax,8), %rax
	notq	%rax
	btq	%rdx, %rax
	jc	.L29
.L2:
	xorl	%eax, %eax
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	call	__printf_chk@PLT
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L30
	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
.L3:
	.cfi_restore_state
	movl	%ecx, %eax
	sarl	$31, %eax
	shrl	$26, %eax
	addl	%eax, %ecx
	andl	$63, %ecx
	subl	%ecx, %eax
	leaq	500008+dp(%rip), %rcx
	leal	64(%rax), %r11d
	movslq	%edx, %rax
	leaq	0(,%rax,8), %rsi
	movq	(%rcx,%rax,8), %rdx
	subq	$500016, %rcx
	leaq	500000(%r15,%rsi), %rax
	leaq	(%rcx,%rsi), %r10
	negq	%rsi
	.p2align 4,,10
	.p2align 3
.L10:
	movq	(%rax,%rsi), %r8
	movl	%r11d, %ecx
	subq	$8, %rax
	shrq	%cl, %r8
	movl	%edi, %ecx
	orq	%r8, %rdx
	movq	%rdx, 16(%rax)
	movq	8(%rax,%rsi), %rdx
	salq	%cl, %rdx
	orq	8(%rax), %rdx
	movq	%rdx, 8(%rax)
	cmpq	%rax, %r10
	jne	.L10
	jmp	.L11
.L4:
	leaq	499992+dp(%rip), %rax
	.p2align 4,,10
	.p2align 3
.L7:
	movq	8(%rax), %rdx
	orq	%rdx, (%rax)
	subq	$8, %rax
	cmpq	%rax, %r14
	jne	.L7
	jmp	.L11
.L30:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE51:
	.size	main, .-main
	.globl	dp
	.bss
	.align 32
	.type	dp, @object
	.size	dp, 508000
dp:
	.zero	508000
	.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 <stdlib.h>
#include <string.h>

typedef unsigned long long u64;

#define N (62500)

u64 dp[N + 1000];

int main(void) {
  int n;
  scanf("%d", &n);
  
  dp[0] = 1;

  int s = 0;
  while (n--) {
    int a;
    scanf("%d", &a);

    s += a;

    int H = a / 64;
    int L = a % 64;

    if (L == 0) {
      for (int i = N; i >= 0; i--) {
        dp[i + H] |= dp[i];
      }
    } else {
      for (int i = N; i >= 0; i--) {
        dp[i + H + 1] |= dp[i] >> (64 - L);
        dp[i + H] |= dp[i] << L;
      }
    }
  }

  s = (s + 1) / 2;
  while (~dp[s / 64] >> s % 64 & 1) s++;

  printf("%d\n", s);

  return 0;
}

3
1 2 0
 1
32
 1
62
 1
26
 3
1 2 -1
 1
4
 3
1 3 -1
 1
7
 1
0
 3
3 5 -1

2
 32
 62
 26
 1
 4
 3
 7
 0
 5

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

typedef unsigned long long u64;

#define N (62500)

u64 dp[N + 1000];

int main(void) {
  int n;
  scanf("%d", &n);
  
  dp[0] = 1;

  int s = 0;
  while (n--) {
    int a;
    scanf("%d", &a);

    s += a;

    int H = a / 64;
    int L = a % 64;

    if (L == 0) {
      for (int i = N; i >= 0; i--) {
        dp[i + H] |= dp[i];
      }
    } else {
      for (int i = N; i >= 0; i--) {
        dp[i + H + 1] |= dp[i] >> (64 - L);
        dp[i + H] |= dp[i] << L;
      }
    }
  }

  s = (s + 1) / 2;
  while (~dp[s / 64] >> s % 64 & 1) s++;

  printf("%d\n", s);

  return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	dp
	.bss
	.align 32
	.type	dp, @object
	.size	dp, 508000
dp:
	.zero	508000
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-36(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$1, dp(%rip)
	movl	$0, -28(%rbp)
	jmp	.L2
.L9:
	leaq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-32(%rbp), %eax
	addl	%eax, -28(%rbp)
	movl	-32(%rbp), %eax
	leal	63(%rax), %edx
	testl	%eax, %eax
	cmovs	%edx, %eax
	sarl	$6, %eax
	movl	%eax, -16(%rbp)
	movl	-32(%rbp), %eax
	cltd
	shrl	$26, %edx
	addl	%edx, %eax
	andl	$63, %eax
	subl	%edx, %eax
	movl	%eax, -12(%rbp)
	cmpl	$0, -12(%rbp)
	jne	.L3
	movl	$62500, -24(%rbp)
	jmp	.L4
.L5:
	movl	-24(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rcx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-24(%rbp), %esi
	movl	-16(%rbp), %eax
	addl	%esi, %eax
	orq	%rdx, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	subl	$1, -24(%rbp)
.L4:
	cmpl	$0, -24(%rbp)
	jns	.L5
	jmp	.L2
.L3:
	movl	$62500, -20(%rbp)
	jmp	.L7
.L8:
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	$64, %eax
	subl	-12(%rbp), %eax
	movl	%eax, %ecx
	shrq	%cl, %rdx
	movq	%rdx, %rcx
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	addl	$1, %eax
	orq	%rsi, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-12(%rbp), %eax
	movl	%eax, %ecx
	salq	%cl, %rdx
	movq	%rdx, %rcx
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	orq	%rsi, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	subl	$1, -20(%rbp)
.L7:
	cmpl	$0, -20(%rbp)
	jns	.L8
.L2:
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -36(%rbp)
	testl	%eax, %eax
	jne	.L9
	movl	-28(%rbp), %eax
	addl	$1, %eax
	movl	%eax, %edx
	shrl	$31, %edx
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -28(%rbp)
	jmp	.L10
.L11:
	addl	$1, -28(%rbp)
.L10:
	movl	-28(%rbp), %eax
	leal	63(%rax), %edx
	testl	%eax, %eax
	cmovs	%edx, %eax
	sarl	$6, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rax
	notq	%rax
	movq	%rax, %rdx
	movl	-28(%rbp), %eax
	andl	$63, %eax
	movl	%eax, %ecx
	shrq	%cl, %rdx
	movq	%rdx, %rax
	andl	$1, %eax
	testq	%rax, %rax
	jne	.L11
	movl	-28(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.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	dp
	.bss
	.align 32
	.type	dp, @object
	.size	dp, 508000
dp:
	.zero	508000
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$48, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-36(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$1, dp(%rip)
	movl	$0, -28(%rbp)
	jmp	.L2
.L9:
	leaq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-32(%rbp), %eax
	addl	%eax, -28(%rbp)
	movl	-32(%rbp), %eax
	leal	63(%rax), %edx
	testl	%eax, %eax
	cmovs	%edx, %eax
	sarl	$6, %eax
	movl	%eax, -16(%rbp)
	movl	-32(%rbp), %eax
	cltd
	shrl	$26, %edx
	addl	%edx, %eax
	andl	$63, %eax
	subl	%edx, %eax
	movl	%eax, -12(%rbp)
	cmpl	$0, -12(%rbp)
	jne	.L3
	movl	$62500, -24(%rbp)
	jmp	.L4
.L5:
	movl	-24(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rcx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-24(%rbp), %esi
	movl	-16(%rbp), %eax
	addl	%esi, %eax
	orq	%rdx, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	subl	$1, -24(%rbp)
.L4:
	cmpl	$0, -24(%rbp)
	jns	.L5
	jmp	.L2
.L3:
	movl	$62500, -20(%rbp)
	jmp	.L7
.L8:
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	$64, %eax
	subl	-12(%rbp), %eax
	movl	%eax, %ecx
	shrq	%cl, %rdx
	movq	%rdx, %rcx
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	addl	$1, %eax
	orq	%rsi, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-12(%rbp), %eax
	movl	%eax, %ecx
	salq	%cl, %rdx
	movq	%rdx, %rcx
	movl	-20(%rbp), %edx
	movl	-16(%rbp), %eax
	addl	%edx, %eax
	orq	%rsi, %rcx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	subl	$1, -20(%rbp)
.L7:
	cmpl	$0, -20(%rbp)
	jns	.L8
.L2:
	movl	-36(%rbp), %eax
	leal	-1(%rax), %edx
	movl	%edx, -36(%rbp)
	testl	%eax, %eax
	jne	.L9
	movl	-28(%rbp), %eax
	addl	$1, %eax
	movl	%eax, %edx
	shrl	$31, %edx
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -28(%rbp)
	jmp	.L10
.L11:
	addl	$1, -28(%rbp)
.L10:
	movl	-28(%rbp), %eax
	leal	63(%rax), %edx
	testl	%eax, %eax
	cmovs	%edx, %eax
	sarl	$6, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	dp(%rip), %rax
	movq	(%rdx,%rax), %rax
	notq	%rax
	movq	%rax, %rdx
	movl	-28(%rbp), %eax
	andl	$63, %eax
	movl	%eax, %ecx
	shrq	%cl, %rdx
	movq	%rdx, %rax
	andl	$1, %eax
	testq	%rax, %rax
	jne	.L11
	movl	-28(%rbp), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.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:
