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>

int asc(const void *a, const void *b) {
  return *(int *)a - *(int *)b;
}



int main(){
    int N;
    scanf("%d", &N);

    int i,j,tmp;
    int A[200000+1] = {0};
    for( i = 0; i < N; i++ ){
        scanf("%d", &A[i]);
    }

    qsort(A, N, sizeof(A[0]), asc);
/*
    for( i = 0; i < N; i++ ){
        for( j = i+1; j < N; j++ ){
            if( A[i] > A[j] ){
                tmp = A[i];
                A[i] = A[j];
                A[j] = tmp;
            }
        }
    }
*/
    

    for( i = 0; i < N-1; i++ ){
        if( A[i] == A[i+1] ){
            printf("NO\n");
            return 0;
        }
    }

    printf("YES\n");

    return 0;
}



```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	asc
	.type	asc, @function
asc:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-8(%rbp), %rax
	movl	(%rax), %edx
	movq	-16(%rbp), %rax
	movl	(%rax), %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	asc, .-asc
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"NO"
.LC2:
	.string	"YES"
	.text
	.globl	main
	.type	main, @function
main:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	leaq	-798720(%rsp), %r11
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	subq	$1312, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-800024(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-800016(%rbp), %rax
	movl	$800004, %edx
	movl	$0, %esi
	movq	%rax, %rdi
	call	memset@PLT
	movl	$0, -800020(%rbp)
	jmp	.L4
.L5:
	leaq	-800016(%rbp), %rdx
	movl	-800020(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -800020(%rbp)
.L4:
	movl	-800024(%rbp), %eax
	cmpl	%eax, -800020(%rbp)
	jl	.L5
	movl	-800024(%rbp), %eax
	movslq	%eax, %rsi
	leaq	-800016(%rbp), %rax
	leaq	asc(%rip), %rdx
	movq	%rdx, %rcx
	movl	$4, %edx
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$0, -800020(%rbp)
	jmp	.L6
.L9:
	movl	-800020(%rbp), %eax
	cltq
	movl	-800016(%rbp,%rax,4), %edx
	movl	-800020(%rbp), %eax
	addl	$1, %eax
	cltq
	movl	-800016(%rbp,%rax,4), %eax
	cmpl	%eax, %edx
	jne	.L7
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	movl	$0, %eax
	jmp	.L10
.L7:
	addl	$1, -800020(%rbp)
.L6:
	movl	-800024(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -800020(%rbp)
	jl	.L9
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	movl	$0, %eax
.L10:
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L11
	call	__stack_chk_fail@PLT
.L11:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.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	asc
	.type	asc, @function
asc:
.LFB39:
	.cfi_startproc
	endbr64
	movl	(%rdi), %eax
	subl	(%rsi), %eax
	ret
	.cfi_endproc
.LFE39:
	.size	asc, .-asc
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"NO"
.LC2:
	.string	"YES"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB40:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	leaq	-798720(%rsp), %r11
	.cfi_def_cfa 11, 798760
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1320, %rsp
	.cfi_def_cfa_offset 800080
	leaq	.LC0(%rip), %r13
	movq	%r13, %rdi
	movq	%fs:40, %rax
	movq	%rax, 800024(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rsi
	leaq	16(%rsp), %r12
	call	__isoc99_scanf@PLT
	xorl	%esi, %esi
	movl	$800004, %edx
	movq	%r12, %rdi
	call	memset@PLT
	movslq	12(%rsp), %rsi
	testl	%esi, %esi
	jle	.L4
	movq	%r12, %rbp
	xorl	%ebx, %ebx
	.p2align 4,,10
	.p2align 3
.L5:
	movq	%rbp, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addl	$1, %ebx
	call	__isoc99_scanf@PLT
	movslq	12(%rsp), %rsi
	addq	$4, %rbp
	cmpl	%ebx, %esi
	jg	.L5
.L4:
	leaq	asc(%rip), %rcx
	movl	$4, %edx
	movq	%r12, %rdi
	call	qsort@PLT
	movl	12(%rsp), %eax
	movl	16(%rsp), %ecx
	leal	-1(%rax), %esi
	xorl	%eax, %eax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L8:
	movl	4(%r12,%rax,4), %edx
	addq	$1, %rax
	cmpl	%ecx, %edx
	je	.L13
	movl	%edx, %ecx
.L6:
	cmpl	%eax, %esi
	jg	.L8
	leaq	.LC2(%rip), %rdi
	call	puts@PLT
.L7:
	movq	800024(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L14
	addq	$800040, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
.L13:
	.cfi_restore_state
	leaq	.LC1(%rip), %rdi
	call	puts@PLT
	jmp	.L7
.L14:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE40:
	.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:

rule
	.file	"temp.c"
	.text
	.p2align 4
	.globl	asc
	.type	asc, @function
asc:
.LFB39:
	.cfi_startproc
	endbr64
	movl	(%rdi), %eax
	subl	(%rsi), %eax
	ret
	.cfi_endproc
.LFE39:
	.size	asc, .-asc
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"NO"
.LC2:
	.string	"YES"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB40:
	.cfi_startproc
	endbr64
	pushq	%r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	pushq	%r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	pushq	%rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	pushq	%rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	leaq	-798720(%rsp), %r11
	.cfi_def_cfa 11, 798760
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	.cfi_def_cfa_register 7
	subq	$1320, %rsp
	.cfi_def_cfa_offset 800080
	leaq	.LC0(%rip), %r13
	movq	%r13, %rdi
	movq	%fs:40, %rax
	movq	%rax, 800024(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rsi
	leaq	16(%rsp), %r12
	call	__isoc99_scanf@PLT
	xorl	%esi, %esi
	movl	$800004, %edx
	movq	%r12, %rdi
	call	memset@PLT
	movslq	12(%rsp), %rsi
	testl	%esi, %esi
	jle	.L4
	movq	%r12, %rbp
	xorl	%ebx, %ebx
	.p2align 4,,10
	.p2align 3
.L5:
	movq	%rbp, %rsi
	movq	%r13, %rdi
	xorl	%eax, %eax
	addl	$1, %ebx
	call	__isoc99_scanf@PLT
	movslq	12(%rsp), %rsi
	addq	$4, %rbp
	cmpl	%ebx, %esi
	jg	.L5
.L4:
	leaq	asc(%rip), %rcx
	movl	$4, %edx
	movq	%r12, %rdi
	call	qsort@PLT
	movl	12(%rsp), %eax
	movl	16(%rsp), %ecx
	leal	-1(%rax), %esi
	xorl	%eax, %eax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L8:
	movl	4(%r12,%rax,4), %edx
	addq	$1, %rax
	cmpl	%ecx, %edx
	je	.L13
	movl	%edx, %ecx
.L6:
	cmpl	%eax, %esi
	jg	.L8
	leaq	.LC2(%rip), %rdi
	call	puts@PLT
.L7:
	movq	800024(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L14
	addq	$800040, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 32
	popq	%rbp
	.cfi_def_cfa_offset 24
	popq	%r12
	.cfi_def_cfa_offset 16
	popq	%r13
	.cfi_def_cfa_offset 8
	ret
.L13:
	.cfi_restore_state
	leaq	.LC1(%rip), %rdi
	call	puts@PLT
	jmp	.L7
.L14:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE40:
	.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:

#include<stdio.h>
#include<stdlib.h>

int asc(const void *a, const void *b) {
  return *(int *)a - *(int *)b;
}



int main(){
    int N;
    scanf("%d", &N);

    int i,j,tmp;
    int A[200000+1] = {0};
    for( i = 0; i < N; i++ ){
        scanf("%d", &A[i]);
    }

    qsort(A, N, sizeof(A[0]), asc);
/*
    for( i = 0; i < N; i++ ){
        for( j = i+1; j < N; j++ ){
            if( A[i] > A[j] ){
                tmp = A[i];
                A[i] = A[j];
                A[j] = tmp;
            }
        }
    }
*/
    

    for( i = 0; i < N-1; i++ ){
        if( A[i] == A[i+1] ){
            printf("NO\n");
            return 0;
        }
    }

    printf("YES\n");

    return 0;
}




6
4 1 3 1 6 1
 2
10000100 10000000
 5
2 9 1 4 5
 6
4 1 3 1 2 1
 2
10000100 10001000
 5
2 9 1 3 5
 6
4 1 3 1 2 0
 2
10000100 10101000
 5
2 9 0 3 5
 6
4 1 3 2 2 0

NO
 YES
 YES
 NO
 YES
 YES
 NO
 YES
 YES
 NO

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>

int asc(const void *a, const void *b) {
  return *(int *)a - *(int *)b;
}



int main(){
    int N;
    scanf("%d", &N);

    int i,j,tmp;
    int A[200000+1] = {0};
    for( i = 0; i < N; i++ ){
        scanf("%d", &A[i]);
    }

    qsort(A, N, sizeof(A[0]), asc);
/*
    for( i = 0; i < N; i++ ){
        for( j = i+1; j < N; j++ ){
            if( A[i] > A[j] ){
                tmp = A[i];
                A[i] = A[j];
                A[j] = tmp;
            }
        }
    }
*/
    

    for( i = 0; i < N-1; i++ ){
        if( A[i] == A[i+1] ){
            printf("NO\n");
            return 0;
        }
    }

    printf("YES\n");

    return 0;
}



```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	asc
	.type	asc, @function
asc:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-8(%rbp), %rax
	movl	(%rax), %edx
	movq	-16(%rbp), %rax
	movl	(%rax), %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	asc, .-asc
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"NO"
.LC2:
	.string	"YES"
	.text
	.globl	main
	.type	main, @function
main:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	leaq	-798720(%rsp), %r11
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	subq	$1312, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-800024(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-800016(%rbp), %rax
	movl	$800004, %edx
	movl	$0, %esi
	movq	%rax, %rdi
	call	memset@PLT
	movl	$0, -800020(%rbp)
	jmp	.L4
.L5:
	leaq	-800016(%rbp), %rdx
	movl	-800020(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -800020(%rbp)
.L4:
	movl	-800024(%rbp), %eax
	cmpl	%eax, -800020(%rbp)
	jl	.L5
	movl	-800024(%rbp), %eax
	movslq	%eax, %rsi
	leaq	-800016(%rbp), %rax
	leaq	asc(%rip), %rdx
	movq	%rdx, %rcx
	movl	$4, %edx
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$0, -800020(%rbp)
	jmp	.L6
.L9:
	movl	-800020(%rbp), %eax
	cltq
	movl	-800016(%rbp,%rax,4), %edx
	movl	-800020(%rbp), %eax
	addl	$1, %eax
	cltq
	movl	-800016(%rbp,%rax,4), %eax
	cmpl	%eax, %edx
	jne	.L7
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	movl	$0, %eax
	jmp	.L10
.L7:
	addl	$1, -800020(%rbp)
.L6:
	movl	-800024(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -800020(%rbp)
	jl	.L9
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	movl	$0, %eax
.L10:
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L11
	call	__stack_chk_fail@PLT
.L11:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.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	asc
	.type	asc, @function
asc:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -8(%rbp)
	movq	%rsi, -16(%rbp)
	movq	-8(%rbp), %rax
	movl	(%rax), %edx
	movq	-16(%rbp), %rax
	movl	(%rax), %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	asc, .-asc
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"NO"
.LC2:
	.string	"YES"
	.text
	.globl	main
	.type	main, @function
main:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	leaq	-798720(%rsp), %r11
.LPSRL0:
	subq	$4096, %rsp
	orq	$0, (%rsp)
	cmpq	%r11, %rsp
	jne	.LPSRL0
	subq	$1312, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-800024(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	leaq	-800016(%rbp), %rax
	movl	$800004, %edx
	movl	$0, %esi
	movq	%rax, %rdi
	call	memset@PLT
	movl	$0, -800020(%rbp)
	jmp	.L4
.L5:
	leaq	-800016(%rbp), %rdx
	movl	-800020(%rbp), %eax
	cltq
	salq	$2, %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -800020(%rbp)
.L4:
	movl	-800024(%rbp), %eax
	cmpl	%eax, -800020(%rbp)
	jl	.L5
	movl	-800024(%rbp), %eax
	movslq	%eax, %rsi
	leaq	-800016(%rbp), %rax
	leaq	asc(%rip), %rdx
	movq	%rdx, %rcx
	movl	$4, %edx
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$0, -800020(%rbp)
	jmp	.L6
.L9:
	movl	-800020(%rbp), %eax
	cltq
	movl	-800016(%rbp,%rax,4), %edx
	movl	-800020(%rbp), %eax
	addl	$1, %eax
	cltq
	movl	-800016(%rbp,%rax,4), %eax
	cmpl	%eax, %edx
	jne	.L7
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	movl	$0, %eax
	jmp	.L10
.L7:
	addl	$1, -800020(%rbp)
.L6:
	movl	-800024(%rbp), %eax
	subl	$1, %eax
	cmpl	%eax, -800020(%rbp)
	jl	.L9
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	call	puts@PLT
	movl	$0, %eax
.L10:
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L11
	call	__stack_chk_fail@PLT
.L11:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.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:
