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>
long long div[10000];
int inde;

void getDiv(long long n){
  inde = 0;
  long long i;
  for(i=1;i*i<=n;i++)
    if(n%i == 0)
	{
	  div[inde++] = i;
	  if(i*i != n)
	    div[inde++] = n/i;
	}
}

long long gcd(long long x,long long y)
{
  long long r;
  if(x < y)
    {
      long long tmp = x;
      x = y;
      y = tmp;
    }
  while(y > 0)
    {
      r = x%y;
      x = y;
      y = r;
    }
  return x;
}

int main()
{
  long long n;
  
  while(1)
    {
      scanf("%lld",&n);
      if(n == 0)
	break;
      long long cnt = 0;
      long long i,j;
      getDiv(n);
      for(i=0;i<inde;i++)
	{
	  for(j=i;j<inde;j++)
	    {
	      long long a,b;
	      a = div[i];
	      b = div[j];
	      if(a/gcd(a,b)*b == n)
		cnt++;
	    }
	}
      printf("%lld\n",cnt);
    }
  
  return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	div
	.bss
	.align 32
	.type	div, @object
	.size	div, 80000
div:
	.zero	80000
	.globl	inde
	.align 4
	.type	inde, @object
	.size	inde, 4
inde:
	.zero	4
	.text
	.globl	getDiv
	.type	getDiv, @function
getDiv:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, inde(%rip)
	movq	$1, -8(%rbp)
	jmp	.L2
.L4:
	movq	-24(%rbp), %rax
	cqto
	idivq	-8(%rbp)
	movq	%rdx, %rax
	testq	%rax, %rax
	jne	.L3
	movl	inde(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, inde(%rip)
	cltq
	leaq	0(,%rax,8), %rcx
	leaq	div(%rip), %rdx
	movq	-8(%rbp), %rax
	movq	%rax, (%rcx,%rdx)
	movq	-8(%rbp), %rax
	imulq	%rax, %rax
	cmpq	%rax, -24(%rbp)
	je	.L3
	movl	inde(%rip), %ecx
	leal	1(%rcx), %eax
	movl	%eax, inde(%rip)
	movq	-24(%rbp), %rax
	cqto
	idivq	-8(%rbp)
	movq	%rax, %rsi
	movslq	%ecx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	%rsi, (%rdx,%rax)
.L3:
	addq	$1, -8(%rbp)
.L2:
	movq	-8(%rbp), %rax
	imulq	%rax, %rax
	cmpq	%rax, -24(%rbp)
	jge	.L4
	nop
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	getDiv, .-getDiv
	.globl	gcd
	.type	gcd, @function
gcd:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	cmpq	-32(%rbp), %rax
	jge	.L7
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -24(%rbp)
	movq	-16(%rbp), %rax
	movq	%rax, -32(%rbp)
	jmp	.L7
.L8:
	movq	-24(%rbp), %rax
	cqto
	idivq	-32(%rbp)
	movq	%rdx, -8(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -24(%rbp)
	movq	-8(%rbp), %rax
	movq	%rax, -32(%rbp)
.L7:
	cmpq	$0, -32(%rbp)
	jg	.L8
	movq	-24(%rbp), %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	gcd, .-gcd
	.section	.rodata
.LC0:
	.string	"%lld"
.LC1:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$64, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
.L18:
	leaq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	-56(%rbp), %rax
	testq	%rax, %rax
	je	.L22
	movq	$0, -48(%rbp)
	movq	-56(%rbp), %rax
	movq	%rax, %rdi
	call	getDiv
	movq	$0, -40(%rbp)
	jmp	.L13
.L17:
	movq	-40(%rbp), %rax
	movq	%rax, -32(%rbp)
	jmp	.L14
.L16:
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, -24(%rbp)
	movq	-32(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, -16(%rbp)
	movq	-16(%rbp), %rdx
	movq	-24(%rbp), %rax
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	gcd
	movq	%rax, %rcx
	movq	-24(%rbp), %rax
	cqto
	idivq	%rcx
	imulq	-16(%rbp), %rax
	movq	%rax, %rdx
	movq	-56(%rbp), %rax
	cmpq	%rax, %rdx
	jne	.L15
	addq	$1, -48(%rbp)
.L15:
	addq	$1, -32(%rbp)
.L14:
	movl	inde(%rip), %eax
	cltq
	cmpq	%rax, -32(%rbp)
	jl	.L16
	addq	$1, -40(%rbp)
.L13:
	movl	inde(%rip), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L17
	movq	-48(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	jmp	.L18
.L22:
	nop
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L20
	call	__stack_chk_fail@PLT
.L20:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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	getDiv
	.type	getDiv, @function
getDiv:
.LFB23:
	.cfi_startproc
	endbr64
	movl	$0, inde(%rip)
	testq	%rdi, %rdi
	jle	.L1
	xorl	%r9d, %r9d
	xorl	%r8d, %r8d
	movl	$1, %ecx
	movl	$1, %esi
	leaq	div(%rip), %r10
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L14:
	movslq	%edx, %rdx
	addl	$2, %r8d
	movl	$1, %r9d
	movq	%rax, (%r10,%rdx,8)
.L4:
	addq	$1, %rcx
	movq	%rcx, %rsi
	imulq	%rcx, %rsi
	cmpq	%rdi, %rsi
	jg	.L13
.L2:
	movq	%rdi, %rax
	cqto
	idivq	%rcx
	testq	%rdx, %rdx
	jne	.L4
	movslq	%r8d, %r9
	leal	1(%r8), %edx
	movq	%rcx, (%r10,%r9,8)
	cmpq	%rsi, %rdi
	jne	.L14
	addq	$1, %rcx
	movl	%edx, %r8d
	movl	$1, %r9d
	movq	%rcx, %rsi
	imulq	%rcx, %rsi
	cmpq	%rdi, %rsi
	jle	.L2
	.p2align 4,,10
	.p2align 3
.L13:
	testb	%r9b, %r9b
	je	.L1
	movl	%r8d, inde(%rip)
.L1:
	ret
	.cfi_endproc
.LFE23:
	.size	getDiv, .-getDiv
	.p2align 4
	.globl	gcd
	.type	gcd, @function
gcd:
.LFB24:
	.cfi_startproc
	endbr64
	movq	%rdi, %rax
	movq	%rsi, %rdx
	cmpq	%rsi, %rdi
	jge	.L16
	movq	%rsi, %rax
	movq	%rdi, %rdx
.L16:
	testq	%rdx, %rdx
	jle	.L19
	.p2align 4,,10
	.p2align 3
.L18:
	movq	%rdx, %r8
	cqto
	idivq	%r8
	movq	%r8, %rax
	testq	%rdx, %rdx
	jg	.L18
	movq	%r8, %rax
	ret
	.p2align 4,,10
	.p2align 3
.L19:
	movq	%rax, %r8
	movq	%r8, %rax
	ret
	.cfi_endproc
.LFE24:
	.size	gcd, .-gcd
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%lld"
.LC1:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB25:
	.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
	leaq	div(%rip), %r13
	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
	leaq	.LC1(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %r12
.L33:
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	(%rsp), %r10
	testq	%r10, %r10
	je	.L22
	movl	$0, inde(%rip)
	jle	.L26
	xorl	%r8d, %r8d
	xorl	%edi, %edi
	movl	$1, %esi
	movl	$1, %ecx
	jmp	.L23
.L51:
	movslq	%edx, %rdx
	addl	$2, %edi
	movl	$1, %r8d
	movq	%rax, 0(%r13,%rdx,8)
.L25:
	addq	$1, %rcx
	movq	%rcx, %rsi
	imulq	%rcx, %rsi
	cmpq	%rsi, %r10
	jl	.L50
.L23:
	movq	%r10, %rax
	cqto
	idivq	%rcx
	testq	%rdx, %rdx
	jne	.L25
	movslq	%edi, %r8
	leal	1(%rdi), %edx
	movq	%rcx, 0(%r13,%r8,8)
	cmpq	%rsi, %r10
	jne	.L51
	addq	$1, %rcx
	movl	%edx, %edi
	movl	$1, %r8d
	movq	%rcx, %rsi
	imulq	%rcx, %rsi
	cmpq	%rsi, %r10
	jge	.L23
.L50:
	testb	%r8b, %r8b
	je	.L26
	movl	%edi, inde(%rip)
	movslq	%edi, %r11
	testl	%edi, %edi
	je	.L26
	xorl	%r14d, %r14d
	xorl	%r9d, %r9d
	.p2align 4,,10
	.p2align 3
.L32:
	movq	0(%r13,%r14,8), %rdi
	movq	%r14, %rsi
	.p2align 4,,10
	.p2align 3
.L31:
	movq	0(%r13,%rsi,8), %r8
	cmpq	%r8, %rdi
	jge	.L37
	movq	%rdi, %rdx
	movq	%r8, %rax
	testq	%rdx, %rdx
	jle	.L38
	.p2align 4,,10
	.p2align 3
.L29:
	movq	%rdx, %rcx
	cqto
	idivq	%rcx
	movq	%rcx, %rax
	testq	%rdx, %rdx
	jg	.L29
.L28:
	movq	%rdi, %rax
	cqto
	idivq	%rcx
	imulq	%r8, %rax
	cmpq	%rax, %r10
	sete	%al
	addq	$1, %rsi
	movzbl	%al, %eax
	addq	%rax, %r9
	cmpq	%r11, %rsi
	jl	.L31
	addq	$1, %r14
	cmpq	%r11, %r14
	jne	.L32
.L24:
	movq	%r9, %rdx
	movq	%rbx, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L33
	.p2align 4,,10
	.p2align 3
.L37:
	movq	%r8, %rdx
	movq	%rdi, %rax
	testq	%rdx, %rdx
	jg	.L29
.L38:
	movq	%rax, %rcx
	jmp	.L28
.L26:
	xorl	%r9d, %r9d
	jmp	.L24
.L22:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L52
	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
.L52:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE25:
	.size	main, .-main
	.globl	inde
	.bss
	.align 4
	.type	inde, @object
	.size	inde, 4
inde:
	.zero	4
	.globl	div
	.align 32
	.type	div, @object
	.size	div, 80000
div:
	.zero	80000
	.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	getDiv
	.type	getDiv, @function
getDiv:
.LFB23:
	.cfi_startproc
	endbr64
	movl	$0, inde(%rip)
	testq	%rdi, %rdi
	jle	.L1
	xorl	%r9d, %r9d
	xorl	%r8d, %r8d
	movl	$1, %ecx
	movl	$1, %esi
	leaq	div(%rip), %r10
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L14:
	movslq	%edx, %rdx
	addl	$2, %r8d
	movl	$1, %r9d
	movq	%rax, (%r10,%rdx,8)
.L4:
	addq	$1, %rcx
	movq	%rcx, %rsi
	imulq	%rcx, %rsi
	cmpq	%rdi, %rsi
	jg	.L13
.L2:
	movq	%rdi, %rax
	cqto
	idivq	%rcx
	testq	%rdx, %rdx
	jne	.L4
	movslq	%r8d, %r9
	leal	1(%r8), %edx
	movq	%rcx, (%r10,%r9,8)
	cmpq	%rsi, %rdi
	jne	.L14
	addq	$1, %rcx
	movl	%edx, %r8d
	movl	$1, %r9d
	movq	%rcx, %rsi
	imulq	%rcx, %rsi
	cmpq	%rdi, %rsi
	jle	.L2
	.p2align 4,,10
	.p2align 3
.L13:
	testb	%r9b, %r9b
	je	.L1
	movl	%r8d, inde(%rip)
.L1:
	ret
	.cfi_endproc
.LFE23:
	.size	getDiv, .-getDiv
	.p2align 4
	.globl	gcd
	.type	gcd, @function
gcd:
.LFB24:
	.cfi_startproc
	endbr64
	movq	%rdi, %rax
	movq	%rsi, %rdx
	cmpq	%rsi, %rdi
	jge	.L16
	movq	%rsi, %rax
	movq	%rdi, %rdx
.L16:
	testq	%rdx, %rdx
	jle	.L19
	.p2align 4,,10
	.p2align 3
.L18:
	movq	%rdx, %r8
	cqto
	idivq	%r8
	movq	%r8, %rax
	testq	%rdx, %rdx
	jg	.L18
	movq	%r8, %rax
	ret
	.p2align 4,,10
	.p2align 3
.L19:
	movq	%rax, %r8
	movq	%r8, %rax
	ret
	.cfi_endproc
.LFE24:
	.size	gcd, .-gcd
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%lld"
.LC1:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB25:
	.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
	leaq	div(%rip), %r13
	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
	leaq	.LC1(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	%fs:40, %rax
	movq	%rax, 8(%rsp)
	xorl	%eax, %eax
	movq	%rsp, %r12
.L33:
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movq	(%rsp), %r10
	testq	%r10, %r10
	je	.L22
	movl	$0, inde(%rip)
	jle	.L26
	xorl	%r8d, %r8d
	xorl	%edi, %edi
	movl	$1, %esi
	movl	$1, %ecx
	jmp	.L23
.L51:
	movslq	%edx, %rdx
	addl	$2, %edi
	movl	$1, %r8d
	movq	%rax, 0(%r13,%rdx,8)
.L25:
	addq	$1, %rcx
	movq	%rcx, %rsi
	imulq	%rcx, %rsi
	cmpq	%rsi, %r10
	jl	.L50
.L23:
	movq	%r10, %rax
	cqto
	idivq	%rcx
	testq	%rdx, %rdx
	jne	.L25
	movslq	%edi, %r8
	leal	1(%rdi), %edx
	movq	%rcx, 0(%r13,%r8,8)
	cmpq	%rsi, %r10
	jne	.L51
	addq	$1, %rcx
	movl	%edx, %edi
	movl	$1, %r8d
	movq	%rcx, %rsi
	imulq	%rcx, %rsi
	cmpq	%rsi, %r10
	jge	.L23
.L50:
	testb	%r8b, %r8b
	je	.L26
	movl	%edi, inde(%rip)
	movslq	%edi, %r11
	testl	%edi, %edi
	je	.L26
	xorl	%r14d, %r14d
	xorl	%r9d, %r9d
	.p2align 4,,10
	.p2align 3
.L32:
	movq	0(%r13,%r14,8), %rdi
	movq	%r14, %rsi
	.p2align 4,,10
	.p2align 3
.L31:
	movq	0(%r13,%rsi,8), %r8
	cmpq	%r8, %rdi
	jge	.L37
	movq	%rdi, %rdx
	movq	%r8, %rax
	testq	%rdx, %rdx
	jle	.L38
	.p2align 4,,10
	.p2align 3
.L29:
	movq	%rdx, %rcx
	cqto
	idivq	%rcx
	movq	%rcx, %rax
	testq	%rdx, %rdx
	jg	.L29
.L28:
	movq	%rdi, %rax
	cqto
	idivq	%rcx
	imulq	%r8, %rax
	cmpq	%rax, %r10
	sete	%al
	addq	$1, %rsi
	movzbl	%al, %eax
	addq	%rax, %r9
	cmpq	%r11, %rsi
	jl	.L31
	addq	$1, %r14
	cmpq	%r11, %r14
	jne	.L32
.L24:
	movq	%r9, %rdx
	movq	%rbx, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L33
	.p2align 4,,10
	.p2align 3
.L37:
	movq	%r8, %rdx
	movq	%rdi, %rax
	testq	%rdx, %rdx
	jg	.L29
.L38:
	movq	%rax, %rcx
	jmp	.L28
.L26:
	xorl	%r9d, %r9d
	jmp	.L24
.L22:
	movq	8(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L52
	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
.L52:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE25:
	.size	main, .-main
	.globl	inde
	.bss
	.align 4
	.type	inde, @object
	.size	inde, 4
inde:
	.zero	4
	.globl	div
	.align 32
	.type	div, @object
	.size	div, 80000
div:
	.zero	80000
	.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>
long long div[10000];
int inde;

void getDiv(long long n){
  inde = 0;
  long long i;
  for(i=1;i*i<=n;i++)
    if(n%i == 0)
	{
	  div[inde++] = i;
	  if(i*i != n)
	    div[inde++] = n/i;
	}
}

long long gcd(long long x,long long y)
{
  long long r;
  if(x < y)
    {
      long long tmp = x;
      x = y;
      y = tmp;
    }
  while(y > 0)
    {
      r = x%y;
      x = y;
      y = r;
    }
  return x;
}

int main()
{
  long long n;
  
  while(1)
    {
      scanf("%lld",&n);
      if(n == 0)
	break;
      long long cnt = 0;
      long long i,j;
      getDiv(n);
      for(i=0;i<inde;i++)
	{
	  for(j=i;j<inde;j++)
	    {
	      long long a,b;
	      a = div[i];
	      b = div[j];
	      if(a/gcd(a,b)*b == n)
		cnt++;
	    }
	}
      printf("%lld\n",cnt);
    }
  
  return 0;
}
12
11
2
0
 12
9
3
0
 12
8
2
0
 12
9
0
0
 12
0
3
0
 12
15
2
0
 12
9
1
0
 12
8
1
0
 12
9
4
0
 12
11
4
0

8
2
2
 8
3
2
 8
4
2
 8
3
 8
 8
5
2
 8
3
1
 8
4
1
 8
3
3
 8
2
3

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>
long long div[10000];
int inde;

void getDiv(long long n){
  inde = 0;
  long long i;
  for(i=1;i*i<=n;i++)
    if(n%i == 0)
	{
	  div[inde++] = i;
	  if(i*i != n)
	    div[inde++] = n/i;
	}
}

long long gcd(long long x,long long y)
{
  long long r;
  if(x < y)
    {
      long long tmp = x;
      x = y;
      y = tmp;
    }
  while(y > 0)
    {
      r = x%y;
      x = y;
      y = r;
    }
  return x;
}

int main()
{
  long long n;
  
  while(1)
    {
      scanf("%lld",&n);
      if(n == 0)
	break;
      long long cnt = 0;
      long long i,j;
      getDiv(n);
      for(i=0;i<inde;i++)
	{
	  for(j=i;j<inde;j++)
	    {
	      long long a,b;
	      a = div[i];
	      b = div[j];
	      if(a/gcd(a,b)*b == n)
		cnt++;
	    }
	}
      printf("%lld\n",cnt);
    }
  
  return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	div
	.bss
	.align 32
	.type	div, @object
	.size	div, 80000
div:
	.zero	80000
	.globl	inde
	.align 4
	.type	inde, @object
	.size	inde, 4
inde:
	.zero	4
	.text
	.globl	getDiv
	.type	getDiv, @function
getDiv:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, inde(%rip)
	movq	$1, -8(%rbp)
	jmp	.L2
.L4:
	movq	-24(%rbp), %rax
	cqto
	idivq	-8(%rbp)
	movq	%rdx, %rax
	testq	%rax, %rax
	jne	.L3
	movl	inde(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, inde(%rip)
	cltq
	leaq	0(,%rax,8), %rcx
	leaq	div(%rip), %rdx
	movq	-8(%rbp), %rax
	movq	%rax, (%rcx,%rdx)
	movq	-8(%rbp), %rax
	imulq	%rax, %rax
	cmpq	%rax, -24(%rbp)
	je	.L3
	movl	inde(%rip), %ecx
	leal	1(%rcx), %eax
	movl	%eax, inde(%rip)
	movq	-24(%rbp), %rax
	cqto
	idivq	-8(%rbp)
	movq	%rax, %rsi
	movslq	%ecx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	%rsi, (%rdx,%rax)
.L3:
	addq	$1, -8(%rbp)
.L2:
	movq	-8(%rbp), %rax
	imulq	%rax, %rax
	cmpq	%rax, -24(%rbp)
	jge	.L4
	nop
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	getDiv, .-getDiv
	.globl	gcd
	.type	gcd, @function
gcd:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	cmpq	-32(%rbp), %rax
	jge	.L7
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -24(%rbp)
	movq	-16(%rbp), %rax
	movq	%rax, -32(%rbp)
	jmp	.L7
.L8:
	movq	-24(%rbp), %rax
	cqto
	idivq	-32(%rbp)
	movq	%rdx, -8(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -24(%rbp)
	movq	-8(%rbp), %rax
	movq	%rax, -32(%rbp)
.L7:
	cmpq	$0, -32(%rbp)
	jg	.L8
	movq	-24(%rbp), %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	gcd, .-gcd
	.section	.rodata
.LC0:
	.string	"%lld"
.LC1:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$64, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
.L18:
	leaq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	-56(%rbp), %rax
	testq	%rax, %rax
	je	.L22
	movq	$0, -48(%rbp)
	movq	-56(%rbp), %rax
	movq	%rax, %rdi
	call	getDiv
	movq	$0, -40(%rbp)
	jmp	.L13
.L17:
	movq	-40(%rbp), %rax
	movq	%rax, -32(%rbp)
	jmp	.L14
.L16:
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, -24(%rbp)
	movq	-32(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, -16(%rbp)
	movq	-16(%rbp), %rdx
	movq	-24(%rbp), %rax
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	gcd
	movq	%rax, %rcx
	movq	-24(%rbp), %rax
	cqto
	idivq	%rcx
	imulq	-16(%rbp), %rax
	movq	%rax, %rdx
	movq	-56(%rbp), %rax
	cmpq	%rax, %rdx
	jne	.L15
	addq	$1, -48(%rbp)
.L15:
	addq	$1, -32(%rbp)
.L14:
	movl	inde(%rip), %eax
	cltq
	cmpq	%rax, -32(%rbp)
	jl	.L16
	addq	$1, -40(%rbp)
.L13:
	movl	inde(%rip), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L17
	movq	-48(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	jmp	.L18
.L22:
	nop
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L20
	call	__stack_chk_fail@PLT
.L20:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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	div
	.bss
	.align 32
	.type	div, @object
	.size	div, 80000
div:
	.zero	80000
	.globl	inde
	.align 4
	.type	inde, @object
	.size	inde, 4
inde:
	.zero	4
	.text
	.globl	getDiv
	.type	getDiv, @function
getDiv:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, inde(%rip)
	movq	$1, -8(%rbp)
	jmp	.L2
.L4:
	movq	-24(%rbp), %rax
	cqto
	idivq	-8(%rbp)
	movq	%rdx, %rax
	testq	%rax, %rax
	jne	.L3
	movl	inde(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, inde(%rip)
	cltq
	leaq	0(,%rax,8), %rcx
	leaq	div(%rip), %rdx
	movq	-8(%rbp), %rax
	movq	%rax, (%rcx,%rdx)
	movq	-8(%rbp), %rax
	imulq	%rax, %rax
	cmpq	%rax, -24(%rbp)
	je	.L3
	movl	inde(%rip), %ecx
	leal	1(%rcx), %eax
	movl	%eax, inde(%rip)
	movq	-24(%rbp), %rax
	cqto
	idivq	-8(%rbp)
	movq	%rax, %rsi
	movslq	%ecx, %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	%rsi, (%rdx,%rax)
.L3:
	addq	$1, -8(%rbp)
.L2:
	movq	-8(%rbp), %rax
	imulq	%rax, %rax
	cmpq	%rax, -24(%rbp)
	jge	.L4
	nop
	nop
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	getDiv, .-getDiv
	.globl	gcd
	.type	gcd, @function
gcd:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	cmpq	-32(%rbp), %rax
	jge	.L7
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -24(%rbp)
	movq	-16(%rbp), %rax
	movq	%rax, -32(%rbp)
	jmp	.L7
.L8:
	movq	-24(%rbp), %rax
	cqto
	idivq	-32(%rbp)
	movq	%rdx, -8(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -24(%rbp)
	movq	-8(%rbp), %rax
	movq	%rax, -32(%rbp)
.L7:
	cmpq	$0, -32(%rbp)
	jg	.L8
	movq	-24(%rbp), %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	gcd, .-gcd
	.section	.rodata
.LC0:
	.string	"%lld"
.LC1:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$64, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
.L18:
	leaq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	-56(%rbp), %rax
	testq	%rax, %rax
	je	.L22
	movq	$0, -48(%rbp)
	movq	-56(%rbp), %rax
	movq	%rax, %rdi
	call	getDiv
	movq	$0, -40(%rbp)
	jmp	.L13
.L17:
	movq	-40(%rbp), %rax
	movq	%rax, -32(%rbp)
	jmp	.L14
.L16:
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, -24(%rbp)
	movq	-32(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	div(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	%rax, -16(%rbp)
	movq	-16(%rbp), %rdx
	movq	-24(%rbp), %rax
	movq	%rdx, %rsi
	movq	%rax, %rdi
	call	gcd
	movq	%rax, %rcx
	movq	-24(%rbp), %rax
	cqto
	idivq	%rcx
	imulq	-16(%rbp), %rax
	movq	%rax, %rdx
	movq	-56(%rbp), %rax
	cmpq	%rax, %rdx
	jne	.L15
	addq	$1, -48(%rbp)
.L15:
	addq	$1, -32(%rbp)
.L14:
	movl	inde(%rip), %eax
	cltq
	cmpq	%rax, -32(%rbp)
	jl	.L16
	addq	$1, -40(%rbp)
.L13:
	movl	inde(%rip), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L17
	movq	-48(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	jmp	.L18
.L22:
	nop
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L20
	call	__stack_chk_fail@PLT
.L20:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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:
