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>
#define ll long long
#define rep(i,l,r)for(ll i=(l);i<(r);i++)
#define INF ((1LL<<62)-(1LL<<31))
#define max(p,q)((p)>(q)?(p):(q))
#define min(p,q)((p)<(q)?(p):(q))

typedef struct piar{ll l,r;}I;

int hikaku(const void*p,const void*q){
	I pp=*(I*)p,qq=*(I*)q;
	if(pp.l<qq.l)return -1;
	if(pp.l>qq.l)return 1;
	return 0;
}

I a[200010];
ll rm[200010],rM[200010];
int main(){
	int n;
	scanf("%d",&n);
	rep(i,0,n){
		int x,y;
		scanf("%d%d",&x,&y);
		if(x>y){ll t=x;x=y;y=t;}
		a[i].l=x;
		a[i].r=y;
	}
	
	qsort(a,n,sizeof(I),hikaku);
	
	rm[0]=INF,rM[0]=0;
	rep(i,0,n){
		rm[i+1]=min(rm[i],a[i].r);
		rM[i+1]=max(rM[i],a[i].r);
	}
	ll ans=(a[n-1].l-a[0].l)*(rM[n]-rm[n]);

	rep(i,0,n)ans=min(ans,(max(a[n-1].l,rM[i])-min(a[i].l,rm[i]))*(rM[n]-a[0].l));
	printf("%lld\n",ans);
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	hikaku
	.type	hikaku, @function
hikaku:
.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, -40(%rbp)
	movq	%rsi, -48(%rbp)
	movq	-40(%rbp), %rax
	movq	8(%rax), %rdx
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	%rdx, -24(%rbp)
	movq	-48(%rbp), %rax
	movq	8(%rax), %rdx
	movq	(%rax), %rax
	movq	%rax, -16(%rbp)
	movq	%rdx, -8(%rbp)
	movq	-32(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	jge	.L2
	movl	$-1, %eax
	jmp	.L5
.L2:
	movq	-32(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	jle	.L4
	movl	$1, %eax
	jmp	.L5
.L4:
	movl	$0, %eax
.L5:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	hikaku, .-hikaku
	.globl	a
	.bss
	.align 32
	.type	a, @object
	.size	a, 3200160
a:
	.zero	3200160
	.globl	rm
	.align 32
	.type	rm, @object
	.size	rm, 1600080
rm:
	.zero	1600080
	.globl	rM
	.align 32
	.type	rM, @object
	.size	rM, 1600080
rM:
	.zero	1600080
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d%d"
.LC2:
	.string	"%lld\n"
	.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
	subq	$64, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-60(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$0, -48(%rbp)
	jmp	.L7
.L9:
	leaq	-52(%rbp), %rdx
	leaq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-56(%rbp), %edx
	movl	-52(%rbp), %eax
	cmpl	%eax, %edx
	jle	.L8
	movl	-56(%rbp), %eax
	cltq
	movq	%rax, -16(%rbp)
	movl	-52(%rbp), %eax
	movl	%eax, -56(%rbp)
	movq	-16(%rbp), %rax
	movl	%eax, -52(%rbp)
.L8:
	movl	-56(%rbp), %eax
	cltq
	movq	-48(%rbp), %rdx
	movq	%rdx, %rcx
	salq	$4, %rcx
	leaq	a(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-52(%rbp), %eax
	cltq
	movq	-48(%rbp), %rdx
	movq	%rdx, %rcx
	salq	$4, %rcx
	leaq	8+a(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addq	$1, -48(%rbp)
.L7:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -48(%rbp)
	jl	.L9
	movl	-60(%rbp), %eax
	cltq
	leaq	hikaku(%rip), %rdx
	movq	%rdx, %rcx
	movl	$16, %edx
	movq	%rax, %rsi
	leaq	a(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movabsq	$4611686016279904256, %rax
	movq	%rax, rm(%rip)
	movq	$0, rM(%rip)
	movq	$0, -40(%rbp)
	jmp	.L10
.L11:
	movq	-40(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+a(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rcx
	leaq	rm(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	-40(%rbp), %rcx
	addq	$1, %rcx
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	salq	$3, %rcx
	leaq	rm(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	-40(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+a(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rcx
	leaq	rM(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	-40(%rbp), %rcx
	addq	$1, %rcx
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	salq	$3, %rcx
	leaq	rM(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addq	$1, -40(%rbp)
.L10:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L11
	movl	-60(%rbp), %eax
	subl	$1, %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	a(%rip), %rdx
	subq	%rdx, %rax
	movq	%rax, %rsi
	movl	-60(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-60(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	rm(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	imulq	%rsi, %rax
	movq	%rax, -32(%rbp)
	movq	$0, -24(%rbp)
	jmp	.L12
.L13:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-60(%rbp), %eax
	subl	$1, %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	a(%rip), %rax
	movq	(%rcx,%rax), %rax
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	movq	%rax, %rcx
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	rm(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-24(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rsi
	leaq	a(%rip), %rax
	movq	(%rsi,%rax), %rax
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	subq	%rax, %rcx
	movl	-60(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	a(%rip), %rdx
	subq	%rdx, %rax
	imulq	%rcx, %rax
	movq	-32(%rbp), %rdx
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	movq	%rax, -32(%rbp)
	addq	$1, -24(%rbp)
.L12:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -24(%rbp)
	jl	.L13
	movq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	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	hikaku
	.type	hikaku, @function
hikaku:
.LFB39:
	.cfi_startproc
	endbr64
	movq	(%rsi), %rax
	cmpq	%rax, (%rdi)
	movl	$-1, %edx
	setg	%al
	movzbl	%al, %eax
	cmovl	%edx, %eax
	ret
	.cfi_endproc
.LFE39:
	.size	hikaku, .-hikaku
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d%d"
.LC2:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB40:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	.LC0(%rip), %rdi
	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
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	a(%rip), %rbx
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movslq	12(%rsp), %rsi
	testl	%esi, %esi
	jle	.L6
	movq	%rbx, %r15
	leaq	20(%rsp), %r13
	leaq	16(%rsp), %r12
	xorl	%r14d, %r14d
	leaq	.LC1(%rip), %rbp
	.p2align 4,,10
	.p2align 3
.L9:
	movq	%r13, %rdx
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	16(%rsp), %rax
	movslq	20(%rsp), %rdx
	cmpl	%edx, %eax
	jle	.L7
	movslq	%edx, %rdi
	movq	%rax, %xmm1
	addq	$1, %r14
	addq	$16, %r15
	movq	%rdi, %xmm0
	movslq	12(%rsp), %rsi
	punpcklqdq	%xmm1, %xmm0
	movaps	%xmm0, -16(%r15)
	cmpq	%rsi, %r14
	jl	.L9
.L6:
	leaq	hikaku(%rip), %rcx
	movq	%rbx, %rdi
	movl	$16, %edx
	call	qsort@PLT
	movslq	12(%rsp), %r11
	movabsq	$4611686016279904256, %rcx
	movq	$0, rM(%rip)
	movq	%rcx, rm(%rip)
	leaq	rm(%rip), %rdi
	leaq	rM(%rip), %r8
	testl	%r11d, %r11d
	jle	.L10
	movslq	%r11d, %r12
	movl	$8, %eax
	xorl	%esi, %esi
	leaq	8(,%r12,8), %r10
	leaq	-8+a(%rip), %r9
	.p2align 4,,10
	.p2align 3
.L11:
	movq	(%r9,%rax,2), %rdx
	cmpq	%rdx, %rcx
	cmovg	%rdx, %rcx
	cmpq	%rdx, %rsi
	cmovl	%rdx, %rsi
	movq	%rcx, (%rdi,%rax)
	movq	%rsi, (%r8,%rax)
	addq	$8, %rax
	cmpq	%rax, %r10
	jne	.L11
	subl	$1, %r11d
	movq	(%r8,%r12,8), %rbp
	subq	$8, %r10
	xorl	%edx, %edx
	movslq	%r11d, %r11
	salq	$4, %r11
	movq	%rbp, %r9
	subq	(%rdi,%r12,8), %r9
	subq	a(%rip), %rbp
	movq	(%rbx,%r11), %r11
	movq	%r11, %rax
	subq	a(%rip), %rax
	imulq	%rax, %r9
	.p2align 4,,10
	.p2align 3
.L13:
	movq	(%r8,%rdx), %rax
	movq	(%rdi,%rdx), %rcx
	movq	(%rbx,%rdx,2), %rsi
	cmpq	%rax, %r11
	cmovge	%r11, %rax
	cmpq	%rsi, %rcx
	cmovg	%rsi, %rcx
	subq	%rcx, %rax
	imulq	%rbp, %rax
	cmpq	%rax, %r9
	cmovg	%rax, %r9
	addq	$8, %rdx
	cmpq	%r10, %rdx
	jne	.L13
.L14:
	xorl	%eax, %eax
	movq	%r9, %rdx
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	call	__printf_chk@PLT
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$40, %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
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	movq	%rax, %xmm0
	movq	%rdx, %xmm2
	addq	$1, %r14
	addq	$16, %r15
	movslq	12(%rsp), %rsi
	punpcklqdq	%xmm2, %xmm0
	movaps	%xmm0, -16(%r15)
	cmpq	%r14, %rsi
	jg	.L9
	jmp	.L6
.L10:
	leal	-1(%r11), %eax
	cltq
	salq	$4, %rax
	movq	(%rbx,%rax), %r9
	movq	(%r8,%r11,8), %rax
	subq	a(%rip), %r9
	subq	(%rdi,%r11,8), %rax
	imulq	%rax, %r9
	jmp	.L14
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE40:
	.size	main, .-main
	.globl	rM
	.bss
	.align 32
	.type	rM, @object
	.size	rM, 1600080
rM:
	.zero	1600080
	.globl	rm
	.align 32
	.type	rm, @object
	.size	rm, 1600080
rm:
	.zero	1600080
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 3200160
a:
	.zero	3200160
	.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	hikaku
	.type	hikaku, @function
hikaku:
.LFB39:
	.cfi_startproc
	endbr64
	movq	(%rsi), %rax
	cmpq	%rax, (%rdi)
	movl	$-1, %edx
	setg	%al
	movzbl	%al, %eax
	cmovl	%edx, %eax
	ret
	.cfi_endproc
.LFE39:
	.size	hikaku, .-hikaku
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d"
.LC1:
	.string	"%d%d"
.LC2:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB40:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	.LC0(%rip), %rdi
	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
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	a(%rip), %rbx
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movslq	12(%rsp), %rsi
	testl	%esi, %esi
	jle	.L6
	movq	%rbx, %r15
	leaq	20(%rsp), %r13
	leaq	16(%rsp), %r12
	xorl	%r14d, %r14d
	leaq	.LC1(%rip), %rbp
	.p2align 4,,10
	.p2align 3
.L9:
	movq	%r13, %rdx
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movslq	16(%rsp), %rax
	movslq	20(%rsp), %rdx
	cmpl	%edx, %eax
	jle	.L7
	movslq	%edx, %rdi
	movq	%rax, %xmm1
	addq	$1, %r14
	addq	$16, %r15
	movq	%rdi, %xmm0
	movslq	12(%rsp), %rsi
	punpcklqdq	%xmm1, %xmm0
	movaps	%xmm0, -16(%r15)
	cmpq	%rsi, %r14
	jl	.L9
.L6:
	leaq	hikaku(%rip), %rcx
	movq	%rbx, %rdi
	movl	$16, %edx
	call	qsort@PLT
	movslq	12(%rsp), %r11
	movabsq	$4611686016279904256, %rcx
	movq	$0, rM(%rip)
	movq	%rcx, rm(%rip)
	leaq	rm(%rip), %rdi
	leaq	rM(%rip), %r8
	testl	%r11d, %r11d
	jle	.L10
	movslq	%r11d, %r12
	movl	$8, %eax
	xorl	%esi, %esi
	leaq	8(,%r12,8), %r10
	leaq	-8+a(%rip), %r9
	.p2align 4,,10
	.p2align 3
.L11:
	movq	(%r9,%rax,2), %rdx
	cmpq	%rdx, %rcx
	cmovg	%rdx, %rcx
	cmpq	%rdx, %rsi
	cmovl	%rdx, %rsi
	movq	%rcx, (%rdi,%rax)
	movq	%rsi, (%r8,%rax)
	addq	$8, %rax
	cmpq	%rax, %r10
	jne	.L11
	subl	$1, %r11d
	movq	(%r8,%r12,8), %rbp
	subq	$8, %r10
	xorl	%edx, %edx
	movslq	%r11d, %r11
	salq	$4, %r11
	movq	%rbp, %r9
	subq	(%rdi,%r12,8), %r9
	subq	a(%rip), %rbp
	movq	(%rbx,%r11), %r11
	movq	%r11, %rax
	subq	a(%rip), %rax
	imulq	%rax, %r9
	.p2align 4,,10
	.p2align 3
.L13:
	movq	(%r8,%rdx), %rax
	movq	(%rdi,%rdx), %rcx
	movq	(%rbx,%rdx,2), %rsi
	cmpq	%rax, %r11
	cmovge	%r11, %rax
	cmpq	%rsi, %rcx
	cmovg	%rsi, %rcx
	subq	%rcx, %rax
	imulq	%rbp, %rax
	cmpq	%rax, %r9
	cmovg	%rax, %r9
	addq	$8, %rdx
	cmpq	%r10, %rdx
	jne	.L13
.L14:
	xorl	%eax, %eax
	movq	%r9, %rdx
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	call	__printf_chk@PLT
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$40, %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
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	movq	%rax, %xmm0
	movq	%rdx, %xmm2
	addq	$1, %r14
	addq	$16, %r15
	movslq	12(%rsp), %rsi
	punpcklqdq	%xmm2, %xmm0
	movaps	%xmm0, -16(%r15)
	cmpq	%r14, %rsi
	jg	.L9
	jmp	.L6
.L10:
	leal	-1(%r11), %eax
	cltq
	salq	$4, %rax
	movq	(%rbx,%rax), %r9
	movq	(%r8,%r11,8), %rax
	subq	a(%rip), %r9
	subq	(%rdi,%r11,8), %rax
	imulq	%rax, %r9
	jmp	.L14
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE40:
	.size	main, .-main
	.globl	rM
	.bss
	.align 32
	.type	rM, @object
	.size	rM, 1600080
rM:
	.zero	1600080
	.globl	rm
	.align 32
	.type	rm, @object
	.size	rm, 1600080
rm:
	.zero	1600080
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 3200160
a:
	.zero	3200160
	.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>
#define ll long long
#define rep(i,l,r)for(ll i=(l);i<(r);i++)
#define INF ((1LL<<62)-(1LL<<31))
#define max(p,q)((p)>(q)?(p):(q))
#define min(p,q)((p)<(q)?(p):(q))

typedef struct piar{ll l,r;}I;

int hikaku(const void*p,const void*q){
	I pp=*(I*)p,qq=*(I*)q;
	if(pp.l<qq.l)return -1;
	if(pp.l>qq.l)return 1;
	return 0;
}

I a[200010];
ll rm[200010],rM[200010];
int main(){
	int n;
	scanf("%d",&n);
	rep(i,0,n){
		int x,y;
		scanf("%d%d",&x,&y);
		if(x>y){ll t=x;x=y;y=t;}
		a[i].l=x;
		a[i].r=y;
	}
	
	qsort(a,n,sizeof(I),hikaku);
	
	rm[0]=INF,rM[0]=0;
	rep(i,0,n){
		rm[i+1]=min(rm[i],a[i].r);
		rM[i+1]=max(rM[i],a[i].r);
	}
	ll ans=(a[n-1].l-a[0].l)*(rM[n]-rm[n]);

	rep(i,0,n)ans=min(ans,(max(a[n-1].l,rM[i])-min(a[i].l,rm[i]))*(rM[n]-a[0].l));
	printf("%lld\n",ans);
	return 0;
}
2
1 1
1000000000 1000000100
 3
1 2
3 4
3 6
 3
1010 10
1000 1
20 294
 2
1 1
1000000000 1000100100
 3
1010 10
1000 1
26 294
 3
1 2
3 4
3 9
 3
1010 10
1000 1
50 294
 3
0 2
3 4
3 9
 3
1010 10
0000 1
50 294
 3
1010 0
0000 1
50 294

1000000097999999901
 5
 13604
 1000100097999899901
 17900
 8
 35084
 9
 49490
 50450

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>
#define ll long long
#define rep(i,l,r)for(ll i=(l);i<(r);i++)
#define INF ((1LL<<62)-(1LL<<31))
#define max(p,q)((p)>(q)?(p):(q))
#define min(p,q)((p)<(q)?(p):(q))

typedef struct piar{ll l,r;}I;

int hikaku(const void*p,const void*q){
	I pp=*(I*)p,qq=*(I*)q;
	if(pp.l<qq.l)return -1;
	if(pp.l>qq.l)return 1;
	return 0;
}

I a[200010];
ll rm[200010],rM[200010];
int main(){
	int n;
	scanf("%d",&n);
	rep(i,0,n){
		int x,y;
		scanf("%d%d",&x,&y);
		if(x>y){ll t=x;x=y;y=t;}
		a[i].l=x;
		a[i].r=y;
	}
	
	qsort(a,n,sizeof(I),hikaku);
	
	rm[0]=INF,rM[0]=0;
	rep(i,0,n){
		rm[i+1]=min(rm[i],a[i].r);
		rM[i+1]=max(rM[i],a[i].r);
	}
	ll ans=(a[n-1].l-a[0].l)*(rM[n]-rm[n]);

	rep(i,0,n)ans=min(ans,(max(a[n-1].l,rM[i])-min(a[i].l,rm[i]))*(rM[n]-a[0].l));
	printf("%lld\n",ans);
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	hikaku
	.type	hikaku, @function
hikaku:
.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, -40(%rbp)
	movq	%rsi, -48(%rbp)
	movq	-40(%rbp), %rax
	movq	8(%rax), %rdx
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	%rdx, -24(%rbp)
	movq	-48(%rbp), %rax
	movq	8(%rax), %rdx
	movq	(%rax), %rax
	movq	%rax, -16(%rbp)
	movq	%rdx, -8(%rbp)
	movq	-32(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	jge	.L2
	movl	$-1, %eax
	jmp	.L5
.L2:
	movq	-32(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	jle	.L4
	movl	$1, %eax
	jmp	.L5
.L4:
	movl	$0, %eax
.L5:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	hikaku, .-hikaku
	.globl	a
	.bss
	.align 32
	.type	a, @object
	.size	a, 3200160
a:
	.zero	3200160
	.globl	rm
	.align 32
	.type	rm, @object
	.size	rm, 1600080
rm:
	.zero	1600080
	.globl	rM
	.align 32
	.type	rM, @object
	.size	rM, 1600080
rM:
	.zero	1600080
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d%d"
.LC2:
	.string	"%lld\n"
	.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
	subq	$64, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-60(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$0, -48(%rbp)
	jmp	.L7
.L9:
	leaq	-52(%rbp), %rdx
	leaq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-56(%rbp), %edx
	movl	-52(%rbp), %eax
	cmpl	%eax, %edx
	jle	.L8
	movl	-56(%rbp), %eax
	cltq
	movq	%rax, -16(%rbp)
	movl	-52(%rbp), %eax
	movl	%eax, -56(%rbp)
	movq	-16(%rbp), %rax
	movl	%eax, -52(%rbp)
.L8:
	movl	-56(%rbp), %eax
	cltq
	movq	-48(%rbp), %rdx
	movq	%rdx, %rcx
	salq	$4, %rcx
	leaq	a(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-52(%rbp), %eax
	cltq
	movq	-48(%rbp), %rdx
	movq	%rdx, %rcx
	salq	$4, %rcx
	leaq	8+a(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addq	$1, -48(%rbp)
.L7:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -48(%rbp)
	jl	.L9
	movl	-60(%rbp), %eax
	cltq
	leaq	hikaku(%rip), %rdx
	movq	%rdx, %rcx
	movl	$16, %edx
	movq	%rax, %rsi
	leaq	a(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movabsq	$4611686016279904256, %rax
	movq	%rax, rm(%rip)
	movq	$0, rM(%rip)
	movq	$0, -40(%rbp)
	jmp	.L10
.L11:
	movq	-40(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+a(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rcx
	leaq	rm(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	-40(%rbp), %rcx
	addq	$1, %rcx
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	salq	$3, %rcx
	leaq	rm(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	-40(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+a(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rcx
	leaq	rM(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	-40(%rbp), %rcx
	addq	$1, %rcx
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	salq	$3, %rcx
	leaq	rM(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addq	$1, -40(%rbp)
.L10:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L11
	movl	-60(%rbp), %eax
	subl	$1, %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	a(%rip), %rdx
	subq	%rdx, %rax
	movq	%rax, %rsi
	movl	-60(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-60(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	rm(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	imulq	%rsi, %rax
	movq	%rax, -32(%rbp)
	movq	$0, -24(%rbp)
	jmp	.L12
.L13:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-60(%rbp), %eax
	subl	$1, %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	a(%rip), %rax
	movq	(%rcx,%rax), %rax
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	movq	%rax, %rcx
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	rm(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-24(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rsi
	leaq	a(%rip), %rax
	movq	(%rsi,%rax), %rax
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	subq	%rax, %rcx
	movl	-60(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	a(%rip), %rdx
	subq	%rdx, %rax
	imulq	%rcx, %rax
	movq	-32(%rbp), %rdx
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	movq	%rax, -32(%rbp)
	addq	$1, -24(%rbp)
.L12:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -24(%rbp)
	jl	.L13
	movq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	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	hikaku
	.type	hikaku, @function
hikaku:
.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, -40(%rbp)
	movq	%rsi, -48(%rbp)
	movq	-40(%rbp), %rax
	movq	8(%rax), %rdx
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	%rdx, -24(%rbp)
	movq	-48(%rbp), %rax
	movq	8(%rax), %rdx
	movq	(%rax), %rax
	movq	%rax, -16(%rbp)
	movq	%rdx, -8(%rbp)
	movq	-32(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	jge	.L2
	movl	$-1, %eax
	jmp	.L5
.L2:
	movq	-32(%rbp), %rdx
	movq	-16(%rbp), %rax
	cmpq	%rax, %rdx
	jle	.L4
	movl	$1, %eax
	jmp	.L5
.L4:
	movl	$0, %eax
.L5:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	hikaku, .-hikaku
	.globl	a
	.bss
	.align 32
	.type	a, @object
	.size	a, 3200160
a:
	.zero	3200160
	.globl	rm
	.align 32
	.type	rm, @object
	.size	rm, 1600080
rm:
	.zero	1600080
	.globl	rM
	.align 32
	.type	rM, @object
	.size	rM, 1600080
rM:
	.zero	1600080
	.section	.rodata
.LC0:
	.string	"%d"
.LC1:
	.string	"%d%d"
.LC2:
	.string	"%lld\n"
	.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
	subq	$64, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	leaq	-60(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movq	$0, -48(%rbp)
	jmp	.L7
.L9:
	leaq	-52(%rbp), %rdx
	leaq	-56(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-56(%rbp), %edx
	movl	-52(%rbp), %eax
	cmpl	%eax, %edx
	jle	.L8
	movl	-56(%rbp), %eax
	cltq
	movq	%rax, -16(%rbp)
	movl	-52(%rbp), %eax
	movl	%eax, -56(%rbp)
	movq	-16(%rbp), %rax
	movl	%eax, -52(%rbp)
.L8:
	movl	-56(%rbp), %eax
	cltq
	movq	-48(%rbp), %rdx
	movq	%rdx, %rcx
	salq	$4, %rcx
	leaq	a(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-52(%rbp), %eax
	cltq
	movq	-48(%rbp), %rdx
	movq	%rdx, %rcx
	salq	$4, %rcx
	leaq	8+a(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addq	$1, -48(%rbp)
.L7:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -48(%rbp)
	jl	.L9
	movl	-60(%rbp), %eax
	cltq
	leaq	hikaku(%rip), %rdx
	movq	%rdx, %rcx
	movl	$16, %edx
	movq	%rax, %rsi
	leaq	a(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movabsq	$4611686016279904256, %rax
	movq	%rax, rm(%rip)
	movq	$0, rM(%rip)
	movq	$0, -40(%rbp)
	jmp	.L10
.L11:
	movq	-40(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+a(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rcx
	leaq	rm(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	-40(%rbp), %rcx
	addq	$1, %rcx
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	salq	$3, %rcx
	leaq	rm(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	-40(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+a(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-40(%rbp), %rax
	leaq	0(,%rax,8), %rcx
	leaq	rM(%rip), %rax
	movq	(%rcx,%rax), %rax
	movq	-40(%rbp), %rcx
	addq	$1, %rcx
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	salq	$3, %rcx
	leaq	rM(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	addq	$1, -40(%rbp)
.L10:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -40(%rbp)
	jl	.L11
	movl	-60(%rbp), %eax
	subl	$1, %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	a(%rip), %rdx
	subq	%rdx, %rax
	movq	%rax, %rsi
	movl	-60(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-60(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	rm(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	imulq	%rsi, %rax
	movq	%rax, -32(%rbp)
	movq	$0, -24(%rbp)
	jmp	.L12
.L13:
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movl	-60(%rbp), %eax
	subl	$1, %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rcx
	leaq	a(%rip), %rax
	movq	(%rcx,%rax), %rax
	cmpq	%rax, %rdx
	cmovge	%rdx, %rax
	movq	%rax, %rcx
	movq	-24(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	leaq	rm(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-24(%rbp), %rax
	salq	$4, %rax
	movq	%rax, %rsi
	leaq	a(%rip), %rax
	movq	(%rsi,%rax), %rax
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	subq	%rax, %rcx
	movl	-60(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	rM(%rip), %rax
	movq	(%rdx,%rax), %rax
	movq	a(%rip), %rdx
	subq	%rdx, %rax
	imulq	%rcx, %rax
	movq	-32(%rbp), %rdx
	cmpq	%rax, %rdx
	cmovle	%rdx, %rax
	movq	%rax, -32(%rbp)
	addq	$1, -24(%rbp)
.L12:
	movl	-60(%rbp), %eax
	cltq
	cmpq	%rax, -24(%rbp)
	jl	.L13
	movq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	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:
