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 zahyou_num;
int zahyou_list[300001];

/* syo-zyun */
int qsort_comp(const void* x,const void* y) {
	int* a=(int*)x;
	int* b=(int*)y;
	if(*a>*b)return 1;
	if(*a<*b)return -1;
	return 0;
}

int get_id(int zahyou) {
	int left,right,mid;
	left=0;right=zahyou_num-1;
	while(left<=right) {
		mid=(left+right)/2;
		if(zahyou_list[mid]==zahyou)return mid;
		else if(zahyou_list[mid]<zahyou)left=mid+1;
		else right=mid-1;
	}
	return 0;
}

int st_num,p_num;
int input_s[100000];
int input_t[100000];
int input_p[100000];

int rope_exist[300001];
int rope_vanished[300001];
int rope_cut[300001];

int main(void) {
	int i;
	int start,end;
	int temp;
	long long result;
	scanf("%d%d",&st_num,&p_num);
	zahyou_num=1;
	zahyou_list[0]=0;
	for(i=0;i<st_num;i++) {
		scanf("%d%d",&input_s[i],&input_t[i]);
		zahyou_list[zahyou_num++]=input_s[i];
		zahyou_list[zahyou_num++]=input_t[i];
	}
	for(i=0;i<p_num;i++) {
		scanf("%d",&input_p[i]);
		zahyou_list[zahyou_num++]=input_p[i];
	}
	qsort(zahyou_list,zahyou_num,sizeof(int),qsort_comp);
	for(i=0;i<p_num;i++) {
		rope_cut[get_id(input_p[i])]++;
	}
	for(i=1;i<zahyou_num;i++)rope_cut[i]+=rope_cut[i-1];
	for(i=0;i<st_num;i++) {
		start=get_id(input_s[i]);
		end=get_id(input_t[i]);
		if(start<end) {
			if((rope_cut[end]-rope_cut[start])%2==0) {
				rope_exist[start]++;
				rope_exist[end]--;
			} else {
				rope_exist[start]++;
				rope_vanished[end]--;
			}
		} else {
			if((rope_cut[start]-rope_cut[end])%2==0) {
				rope_exist[end]++;
				rope_exist[start]--;
			} else {
				rope_vanished[end]++;
				rope_exist[start]--;
			}
		}
	}
	result=0;
	for(i=1;i<zahyou_num;i++) {
		rope_exist[i]+=rope_exist[i-1];
		rope_vanished[i]+=rope_vanished[i-1];
		if(rope_cut[i]!=rope_cut[i-1]) {
			temp=rope_exist[i];
			rope_exist[i]=rope_vanished[i];
			rope_vanished[i]=temp;
		}
	}
	for(i=0;i+1<zahyou_num;i++) {
		result+=(long long)(zahyou_list[i+1]-zahyou_list[i])*
			(long long)rope_exist[i];
	}
	printf("%lld\n",result);
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	zahyou_num
	.bss
	.align 4
	.type	zahyou_num, @object
	.size	zahyou_num, 4
zahyou_num:
	.zero	4
	.globl	zahyou_list
	.align 32
	.type	zahyou_list, @object
	.size	zahyou_list, 1200004
zahyou_list:
	.zero	1200004
	.text
	.globl	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.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, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -8(%rbp)
	movq	-16(%rbp), %rax
	movl	(%rax), %edx
	movq	-8(%rbp), %rax
	movl	(%rax), %eax
	cmpl	%eax, %edx
	jle	.L2
	movl	$1, %eax
	jmp	.L3
.L2:
	movq	-16(%rbp), %rax
	movl	(%rax), %edx
	movq	-8(%rbp), %rax
	movl	(%rax), %eax
	cmpl	%eax, %edx
	jge	.L4
	movl	$-1, %eax
	jmp	.L3
.L4:
	movl	$0, %eax
.L3:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	qsort_comp, .-qsort_comp
	.globl	get_id
	.type	get_id, @function
get_id:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	$0, -12(%rbp)
	movl	zahyou_num(%rip), %eax
	subl	$1, %eax
	movl	%eax, -8(%rbp)
	jmp	.L6
.L10:
	movl	-12(%rbp), %edx
	movl	-8(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, %edx
	shrl	$31, %edx
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -20(%rbp)
	jne	.L7
	movl	-4(%rbp), %eax
	jmp	.L8
.L7:
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L9
	movl	-4(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -12(%rbp)
	jmp	.L6
.L9:
	movl	-4(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -8(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L10
	movl	$0, %eax
.L8:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	get_id, .-get_id
	.globl	st_num
	.bss
	.align 4
	.type	st_num, @object
	.size	st_num, 4
st_num:
	.zero	4
	.globl	p_num
	.align 4
	.type	p_num, @object
	.size	p_num, 4
p_num:
	.zero	4
	.globl	input_s
	.align 32
	.type	input_s, @object
	.size	input_s, 400000
input_s:
	.zero	400000
	.globl	input_t
	.align 32
	.type	input_t, @object
	.size	input_t, 400000
input_t:
	.zero	400000
	.globl	input_p
	.align 32
	.type	input_p, @object
	.size	input_p, 400000
input_p:
	.zero	400000
	.globl	rope_exist
	.align 32
	.type	rope_exist, @object
	.size	rope_exist, 1200004
rope_exist:
	.zero	1200004
	.globl	rope_vanished
	.align 32
	.type	rope_vanished, @object
	.size	rope_vanished, 1200004
rope_vanished:
	.zero	1200004
	.globl	rope_cut
	.align 32
	.type	rope_cut, @object
	.size	rope_cut, 1200004
rope_cut:
	.zero	1200004
	.section	.rodata
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB8:
	.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
	leaq	p_num(%rip), %rax
	movq	%rax, %rdx
	leaq	st_num(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$1, zahyou_num(%rip)
	movl	$0, zahyou_list(%rip)
	movl	$0, -24(%rbp)
	jmp	.L12
.L13:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_t(%rip), %rax
	addq	%rax, %rdx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	input_s(%rip), %rax
	addq	%rcx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_s(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_t(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	addl	$1, -24(%rbp)
.L12:
	movl	st_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L13
	movl	$0, -24(%rbp)
	jmp	.L14
.L15:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_p(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_p(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	addl	$1, -24(%rbp)
.L14:
	movl	p_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L15
	movl	zahyou_num(%rip), %eax
	cltq
	leaq	qsort_comp(%rip), %rdx
	movq	%rdx, %rcx
	movl	$4, %edx
	movq	%rax, %rsi
	leaq	zahyou_list(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$0, -24(%rbp)
	jmp	.L16
.L17:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_p(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movslq	%eax, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	leal	1(%rdx), %ecx
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	addl	$1, -24(%rbp)
.L16:
	movl	p_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L17
	movl	$1, -24(%rbp)
	jmp	.L18
.L19:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	addl	$1, -24(%rbp)
.L18:
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L19
	movl	$0, -24(%rbp)
	jmp	.L20
.L25:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_s(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movl	%eax, -16(%rbp)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_t(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movl	%eax, -12(%rbp)
	movl	-16(%rbp), %eax
	cmpl	-12(%rbp), %eax
	jge	.L21
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-16(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L22
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L22:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L21:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-12(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L24
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L24:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
.L23:
	addl	$1, -24(%rbp)
.L20:
	movl	st_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L25
	movq	$0, -8(%rbp)
	movl	$1, -24(%rbp)
	jmp	.L26
.L28:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_cut(%rip), %rax
	movl	(%rcx,%rax), %eax
	cmpl	%eax, %edx
	je	.L27
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -20(%rbp)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_exist(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_vanished(%rip), %rdx
	movl	-20(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
.L27:
	addl	$1, -24(%rbp)
.L26:
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L28
	movl	$0, -24(%rbp)
	jmp	.L29
.L30:
	movl	-24(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	zahyou_list(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	movslq	%eax, %rdx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_exist(%rip), %rax
	movl	(%rcx,%rax), %eax
	cltq
	imulq	%rdx, %rax
	addq	%rax, -8(%rbp)
	addl	$1, -24(%rbp)
.L29:
	movl	-24(%rbp), %eax
	leal	1(%rax), %edx
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, %edx
	jl	.L30
	movq	-8(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.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	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.LFB39:
	.cfi_startproc
	endbr64
	movl	(%rsi), %edx
	movl	$1, %eax
	cmpl	%edx, (%rdi)
	jg	.L1
	setl	%al
	movzbl	%al, %eax
	negl	%eax
.L1:
	ret
	.cfi_endproc
.LFE39:
	.size	qsort_comp, .-qsort_comp
	.p2align 4
	.globl	get_id
	.type	get_id, @function
get_id:
.LFB40:
	.cfi_startproc
	endbr64
	movl	zahyou_num(%rip), %edx
	subl	$1, %edx
	js	.L11
	xorl	%ecx, %ecx
	leaq	zahyou_list(%rip), %r8
	.p2align 4,,10
	.p2align 3
.L9:
	leal	(%rdx,%rcx), %eax
	sarl	%eax
	movslq	%eax, %rsi
	cmpl	%edi, (%r8,%rsi,4)
	je	.L5
	jge	.L7
	leal	1(%rax), %ecx
	cmpl	%edx, %ecx
	jle	.L9
.L11:
	xorl	%eax, %eax
.L5:
	ret
	.p2align 4,,10
	.p2align 3
.L7:
	leal	-1(%rax), %edx
	cmpl	%ecx, %edx
	jge	.L9
	xorl	%eax, %eax
	jmp	.L5
	.cfi_endproc
.LFE40:
	.size	get_id, .-get_id
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB41:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	p_num(%rip), %rdx
	leaq	st_num(%rip), %rsi
	xorl	%eax, %eax
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	xorl	%r14d, %r14d
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	.LC0(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	movq	%r13, %rdi
	leaq	input_s(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	input_t(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	zahyou_list(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	call	__isoc99_scanf@PLT
	movl	st_num(%rip), %edx
	movl	$1, zahyou_num(%rip)
	movl	$0, zahyou_list(%rip)
	testl	%edx, %edx
	jle	.L17
	.p2align 4,,10
	.p2align 3
.L16:
	movq	%rbp, %rdx
	movq	%r12, %rsi
	xorl	%eax, %eax
	movq	%r13, %rdi
	call	__isoc99_scanf@PLT
	addl	$1, %r14d
	addq	$4, %r12
	addq	$4, %rbp
	movd	-4(%r12), %xmm0
	movd	-4(%rbp), %xmm6
	movslq	zahyou_num(%rip), %rax
	cmpl	%r14d, st_num(%rip)
	punpckldq	%xmm6, %xmm0
	leal	2(%rax), %edx
	movq	%xmm0, (%rbx,%rax,4)
	movl	%edx, zahyou_num(%rip)
	jg	.L16
.L17:
	movl	p_num(%rip), %eax
	leaq	input_p(%rip), %rbp
	xorl	%r12d, %r12d
	leaq	.LC1(%rip), %r13
	testl	%eax, %eax
	jle	.L87
	.p2align 4,,10
	.p2align 3
.L18:
	movq	%rbp, %rsi
	xorl	%eax, %eax
	movq	%r13, %rdi
	addl	$1, %r12d
	call	__isoc99_scanf@PLT
	movslq	zahyou_num(%rip), %rax
	movl	0(%rbp), %ecx
	addq	$4, %rbp
	cmpl	%r12d, p_num(%rip)
	leal	1(%rax), %edx
	movl	%ecx, (%rbx,%rax,4)
	movl	%edx, zahyou_num(%rip)
	jg	.L18
.L19:
	movslq	%edx, %rsi
	leaq	qsort_comp(%rip), %rcx
	movl	$4, %edx
	movq	%rbx, %rdi
	call	qsort@PLT
	movl	p_num(%rip), %eax
	movl	zahyou_num(%rip), %r15d
	testl	%eax, %eax
	jle	.L26
	leaq	input_p(%rip), %r8
	leal	-1(%rax), %edx
	leaq	4(%r8), %rax
	leal	-1(%r15), %r10d
	leaq	(%rax,%rdx,4), %r9
	leaq	rope_cut(%rip), %r11
	.p2align 4,,10
	.p2align 3
.L25:
	movl	(%r8), %edi
	testl	%r10d, %r10d
	js	.L58
	movl	%r10d, %ecx
	xorl	%edx, %edx
	.p2align 4,,10
	.p2align 3
.L24:
	leal	(%rdx,%rcx), %eax
	sarl	%eax
	movslq	%eax, %rsi
	cmpl	(%rbx,%rsi,4), %edi
	je	.L21
	jle	.L22
	leal	1(%rax), %edx
	cmpl	%ecx, %edx
	jle	.L24
.L58:
	xorl	%esi, %esi
.L21:
	addq	$4, %r8
	addl	$1, (%r11,%rsi,4)
	cmpq	%r9, %r8
	jne	.L25
.L26:
	cmpl	$1, %r15d
	jle	.L27
	leaq	4+rope_cut(%rip), %rax
	leal	-2(%r15), %esi
	movl	rope_cut(%rip), %edx
	leaq	4(%rax), %rcx
	movq	%rsi, %rbp
	leaq	(%rcx,%rsi,4), %rcx
	.p2align 4,,10
	.p2align 3
.L28:
	addl	(%rax), %edx
	addq	$4, %rax
	movl	%edx, -4(%rax)
	cmpq	%rcx, %rax
	jne	.L28
	movslq	st_num(%rip), %rax
	leal	-1(%r15), %r10d
	leaq	rope_cut(%rip), %r11
	leaq	rope_exist(%rip), %r12
	testl	%eax, %eax
	jle	.L30
.L56:
	movl	%r15d, 8(%rsp)
	leal	-1(%r15), %r10d
	xorl	%ebp, %ebp
	leaq	input_s(%rip), %r13
	leaq	rope_cut(%rip), %r11
	leaq	rope_exist(%rip), %r12
	movq	%rax, %r15
	leaq	rope_vanished(%rip), %r14
	.p2align 4,,10
	.p2align 3
.L43:
	movl	0(%r13,%rbp,4), %esi
	testl	%r10d, %r10d
	js	.L59
	movl	%r10d, %ecx
	xorl	%edx, %edx
	.p2align 4,,10
	.p2align 3
.L36:
	leal	(%rdx,%rcx), %eax
	sarl	%eax
	movslq	%eax, %rdi
	cmpl	(%rbx,%rdi,4), %esi
	je	.L33
	jle	.L34
	leal	1(%rax), %edx
	cmpl	%ecx, %edx
	jle	.L36
.L60:
	xorl	%eax, %eax
	xorl	%edi, %edi
.L33:
	leaq	input_t(%rip), %rsi
	xorl	%ecx, %ecx
	movl	(%rsi,%rbp,4), %r9d
	movl	%r10d, %esi
	.p2align 4,,10
	.p2align 3
.L55:
	leal	(%rcx,%rsi), %edx
	sarl	%edx
	movslq	%edx, %r8
	cmpl	%r9d, (%rbx,%r8,4)
	je	.L37
.L88:
	jge	.L38
	leal	1(%rdx), %ecx
	cmpl	%esi, %ecx
	jle	.L55
.L84:
	xorl	%r8d, %r8d
.L32:
	movl	(%r11,%rdi,4), %eax
	subl	(%r11,%r8,4), %eax
	testb	$1, %al
	jne	.L42
	addl	$1, (%r12,%r8,4)
	subl	$1, (%r12,%rdi,4)
.L41:
	addq	$1, %rbp
	cmpq	%r15, %rbp
	jne	.L43
	movl	8(%rsp), %r15d
	leal	-2(%r15), %ebp
	cmpl	$1, %r15d
	jle	.L85
.L30:
	cmpl	$3, %r15d
	jle	.L61
	leal	-4(%r15), %edx
	leaq	rope_vanished(%rip), %rax
	movl	rope_cut(%rip), %r13d
	shrl	%edx
	leaq	rope_exist(%rip), %rsi
	movq	%rax, %rcx
	leaq	5(%rdx,%rdx), %rdi
	leaq	-4+rope_cut(%rip), %rdx
	movq	%rdi, 8(%rsp)
	movl	$3, %edi
.L48:
	leaq	-8+rope_cut(%rip), %r14
	movl	4(%rsi), %r8d
	movl	4(%rcx), %r9d
	movl	(%r14,%rdi,4), %r14d
	addl	(%rsi), %r8d
	addl	(%rcx), %r9d
	movl	%r8d, 4(%rsi)
	movl	%r9d, 4(%rcx)
	cmpl	%r14d, %r13d
	je	.L46
	movl	%r9d, 4(%rsi)
	movl	%r8d, 4(%rcx)
.L46:
	movl	(%rdx,%rdi,4), %r13d
	movl	8(%rsi), %r8d
	movl	8(%rcx), %r9d
	addl	4(%rsi), %r8d
	addl	4(%rcx), %r9d
	movl	%r8d, 8(%rsi)
	movl	%r9d, 8(%rcx)
	cmpl	%r14d, %r13d
	je	.L47
	movl	%r9d, 8(%rsi)
	movl	%r8d, 8(%rcx)
.L47:
	movl	%edi, %r8d
	addq	$8, %rsi
	addq	$2, %rdi
	addq	$8, %rcx
	cmpq	8(%rsp), %rdi
	jne	.L48
.L45:
	movslq	%r8d, %rsi
	leaq	0(,%rsi,4), %rdi
	leaq	(%r12,%rdi), %rcx
	addq	%rdi, %rax
	.p2align 4,,10
	.p2align 3
.L50:
	movl	-4(%rcx), %edi
	movl	-4(%rax), %r8d
	addl	(%rcx), %edi
	addl	(%rax), %r8d
	movl	%edi, (%rcx)
	movl	(%rdx,%rsi,4), %r14d
	movl	%r8d, (%rax)
	cmpl	%r14d, (%r11,%rsi,4)
	je	.L49
	movl	%r8d, (%rcx)
	movl	%edi, (%rax)
.L49:
	addq	$1, %rsi
	addq	$4, %rcx
	addq	$4, %rax
	cmpl	%esi, %r15d
	jg	.L50
	cmpl	$2, %ebp
	jbe	.L62
	movl	%r10d, %ecx
	leaq	rope_exist(%rip), %rdx
	leaq	zahyou_list(%rip), %rax
	leaq	16(%rdx), %rsi
	pxor	%xmm2, %xmm2
	shrl	$2, %ecx
	pxor	%xmm5, %xmm5
	subl	$1, %ecx
	salq	$4, %rcx
	addq	%rsi, %rcx
	.p2align 4,,10
	.p2align 3
.L52:
	movdqa	(%rdx), %xmm0
	movdqa	%xmm5, %xmm4
	movdqa	%xmm5, %xmm6
	addq	$16, %rdx
	movdqu	4(%rax), %xmm3
	psubd	(%rax), %xmm3
	addq	$16, %rax
	movdqa	%xmm0, %xmm1
	movdqa	%xmm3, %xmm7
	punpckldq	%xmm0, %xmm1
	punpckhdq	%xmm0, %xmm0
	punpckldq	%xmm3, %xmm7
	pcmpgtd	%xmm1, %xmm4
	punpckhdq	%xmm3, %xmm3
	pcmpgtd	%xmm7, %xmm6
	pmuludq	%xmm7, %xmm4
	pmuludq	%xmm1, %xmm6
	pmuludq	%xmm7, %xmm1
	paddq	%xmm6, %xmm4
	psllq	$32, %xmm4
	paddq	%xmm4, %xmm1
	movdqa	%xmm5, %xmm4
	paddq	%xmm1, %xmm2
	pcmpgtd	%xmm3, %xmm4
	movdqa	%xmm5, %xmm1
	pcmpgtd	%xmm0, %xmm1
	pmuludq	%xmm0, %xmm4
	pmuludq	%xmm3, %xmm0
	pmuludq	%xmm3, %xmm1
	paddq	%xmm4, %xmm1
	psllq	$32, %xmm1
	paddq	%xmm1, %xmm0
	paddq	%xmm0, %xmm2
	cmpq	%rcx, %rdx
	jne	.L52
	movdqa	%xmm2, %xmm0
	movl	%r10d, %ecx
	psrldq	$8, %xmm0
	andl	$-4, %ecx
	paddq	%xmm0, %xmm2
	leal	1(%rcx), %eax
	movq	%xmm2, %rdx
	cmpl	%ecx, %r10d
	je	.L31
.L51:
	movslq	%eax, %rdi
	movslq	%ecx, %rcx
	movl	(%rbx,%rdi,4), %r9d
	movl	%r9d, %esi
	subl	(%rbx,%rcx,4), %esi
	movslq	(%r12,%rcx,4), %rcx
	movslq	%esi, %rsi
	imulq	%rsi, %rcx
	addq	%rcx, %rdx
	leal	1(%rax), %ecx
	cmpl	%r15d, %ecx
	jge	.L31
	movslq	%ecx, %rcx
	movslq	(%r12,%rdi,4), %rsi
	addl	$2, %eax
	movl	(%rbx,%rcx,4), %r8d
	movl	%r8d, %edi
	subl	%r9d, %edi
	movslq	%edi, %rdi
	imulq	%rdi, %rsi
	addq	%rsi, %rdx
	cmpl	%r15d, %eax
	jge	.L31
	cltq
	movslq	(%r12,%rcx,4), %rcx
	movl	(%rbx,%rax,4), %eax
	subl	%r8d, %eax
	cltq
	imulq	%rcx, %rax
	addq	%rax, %rdx
.L31:
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	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
	.p2align 4,,10
	.p2align 3
.L38:
	.cfi_restore_state
	leal	-1(%rdx), %esi
	cmpl	%ecx, %esi
	jl	.L84
	leal	(%rcx,%rsi), %edx
	sarl	%edx
	movslq	%edx, %r8
	cmpl	%r9d, (%rbx,%r8,4)
	jne	.L88
.L37:
	movl	(%r11,%r8,4), %esi
	movl	(%r11,%rdi,4), %ecx
	cmpl	%eax, %edx
	jle	.L32
	movl	(%r12,%rdi,4), %eax
	leal	1(%rax), %edx
	movl	%esi, %eax
	subl	%ecx, %eax
	movl	%edx, (%r12,%rdi,4)
	testb	$1, %al
	jne	.L40
	subl	$1, (%r12,%r8,4)
	jmp	.L41
	.p2align 4,,10
	.p2align 3
.L34:
	leal	-1(%rax), %ecx
	cmpl	%edx, %ecx
	jge	.L36
	jmp	.L60
	.p2align 4,,10
	.p2align 3
.L22:
	leal	-1(%rax), %ecx
	cmpl	%edx, %ecx
	jge	.L24
	jmp	.L58
	.p2align 4,,10
	.p2align 3
.L42:
	addl	$1, (%r14,%r8,4)
	subl	$1, (%r12,%rdi,4)
	jmp	.L41
	.p2align 4,,10
	.p2align 3
.L40:
	subl	$1, (%r14,%r8,4)
	jmp	.L41
.L59:
	xorl	%edi, %edi
	jmp	.L84
.L27:
	movslq	st_num(%rip), %rax
	testl	%eax, %eax
	jg	.L56
.L85:
	xorl	%edx, %edx
	jmp	.L31
.L87:
	movl	zahyou_num(%rip), %edx
	jmp	.L19
.L62:
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	movl	$1, %eax
	jmp	.L51
.L61:
	movl	$1, %r8d
	leaq	rope_vanished(%rip), %rax
	leaq	-4+rope_cut(%rip), %rdx
	jmp	.L45
	.cfi_endproc
.LFE41:
	.size	main, .-main
	.globl	rope_cut
	.bss
	.align 32
	.type	rope_cut, @object
	.size	rope_cut, 1200004
rope_cut:
	.zero	1200004
	.globl	rope_vanished
	.align 32
	.type	rope_vanished, @object
	.size	rope_vanished, 1200004
rope_vanished:
	.zero	1200004
	.globl	rope_exist
	.align 32
	.type	rope_exist, @object
	.size	rope_exist, 1200004
rope_exist:
	.zero	1200004
	.globl	input_p
	.align 32
	.type	input_p, @object
	.size	input_p, 400000
input_p:
	.zero	400000
	.globl	input_t
	.align 32
	.type	input_t, @object
	.size	input_t, 400000
input_t:
	.zero	400000
	.globl	input_s
	.align 32
	.type	input_s, @object
	.size	input_s, 400000
input_s:
	.zero	400000
	.globl	p_num
	.align 4
	.type	p_num, @object
	.size	p_num, 4
p_num:
	.zero	4
	.globl	st_num
	.align 4
	.type	st_num, @object
	.size	st_num, 4
st_num:
	.zero	4
	.globl	zahyou_list
	.align 32
	.type	zahyou_list, @object
	.size	zahyou_list, 1200004
zahyou_list:
	.zero	1200004
	.globl	zahyou_num
	.align 4
	.type	zahyou_num, @object
	.size	zahyou_num, 4
zahyou_num:
	.zero	4
	.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	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.LFB39:
	.cfi_startproc
	endbr64
	movl	(%rsi), %edx
	movl	$1, %eax
	cmpl	%edx, (%rdi)
	jg	.L1
	setl	%al
	movzbl	%al, %eax
	negl	%eax
.L1:
	ret
	.cfi_endproc
.LFE39:
	.size	qsort_comp, .-qsort_comp
	.p2align 4
	.globl	get_id
	.type	get_id, @function
get_id:
.LFB40:
	.cfi_startproc
	endbr64
	movl	zahyou_num(%rip), %edx
	subl	$1, %edx
	js	.L11
	xorl	%ecx, %ecx
	leaq	zahyou_list(%rip), %r8
	.p2align 4,,10
	.p2align 3
.L9:
	leal	(%rdx,%rcx), %eax
	sarl	%eax
	movslq	%eax, %rsi
	cmpl	%edi, (%r8,%rsi,4)
	je	.L5
	jge	.L7
	leal	1(%rax), %ecx
	cmpl	%edx, %ecx
	jle	.L9
.L11:
	xorl	%eax, %eax
.L5:
	ret
	.p2align 4,,10
	.p2align 3
.L7:
	leal	-1(%rax), %edx
	cmpl	%ecx, %edx
	jge	.L9
	xorl	%eax, %eax
	jmp	.L5
	.cfi_endproc
.LFE40:
	.size	get_id, .-get_id
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%lld\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB41:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	p_num(%rip), %rdx
	leaq	st_num(%rip), %rsi
	xorl	%eax, %eax
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	xorl	%r14d, %r14d
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	.LC0(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	movq	%r13, %rdi
	leaq	input_s(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	input_t(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	leaq	zahyou_list(%rip), %rbx
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	call	__isoc99_scanf@PLT
	movl	st_num(%rip), %edx
	movl	$1, zahyou_num(%rip)
	movl	$0, zahyou_list(%rip)
	testl	%edx, %edx
	jle	.L17
	.p2align 4,,10
	.p2align 3
.L16:
	movq	%rbp, %rdx
	movq	%r12, %rsi
	xorl	%eax, %eax
	movq	%r13, %rdi
	call	__isoc99_scanf@PLT
	addl	$1, %r14d
	addq	$4, %r12
	addq	$4, %rbp
	movd	-4(%r12), %xmm0
	movd	-4(%rbp), %xmm6
	movslq	zahyou_num(%rip), %rax
	cmpl	%r14d, st_num(%rip)
	punpckldq	%xmm6, %xmm0
	leal	2(%rax), %edx
	movq	%xmm0, (%rbx,%rax,4)
	movl	%edx, zahyou_num(%rip)
	jg	.L16
.L17:
	movl	p_num(%rip), %eax
	leaq	input_p(%rip), %rbp
	xorl	%r12d, %r12d
	leaq	.LC1(%rip), %r13
	testl	%eax, %eax
	jle	.L87
	.p2align 4,,10
	.p2align 3
.L18:
	movq	%rbp, %rsi
	xorl	%eax, %eax
	movq	%r13, %rdi
	addl	$1, %r12d
	call	__isoc99_scanf@PLT
	movslq	zahyou_num(%rip), %rax
	movl	0(%rbp), %ecx
	addq	$4, %rbp
	cmpl	%r12d, p_num(%rip)
	leal	1(%rax), %edx
	movl	%ecx, (%rbx,%rax,4)
	movl	%edx, zahyou_num(%rip)
	jg	.L18
.L19:
	movslq	%edx, %rsi
	leaq	qsort_comp(%rip), %rcx
	movl	$4, %edx
	movq	%rbx, %rdi
	call	qsort@PLT
	movl	p_num(%rip), %eax
	movl	zahyou_num(%rip), %r15d
	testl	%eax, %eax
	jle	.L26
	leaq	input_p(%rip), %r8
	leal	-1(%rax), %edx
	leaq	4(%r8), %rax
	leal	-1(%r15), %r10d
	leaq	(%rax,%rdx,4), %r9
	leaq	rope_cut(%rip), %r11
	.p2align 4,,10
	.p2align 3
.L25:
	movl	(%r8), %edi
	testl	%r10d, %r10d
	js	.L58
	movl	%r10d, %ecx
	xorl	%edx, %edx
	.p2align 4,,10
	.p2align 3
.L24:
	leal	(%rdx,%rcx), %eax
	sarl	%eax
	movslq	%eax, %rsi
	cmpl	(%rbx,%rsi,4), %edi
	je	.L21
	jle	.L22
	leal	1(%rax), %edx
	cmpl	%ecx, %edx
	jle	.L24
.L58:
	xorl	%esi, %esi
.L21:
	addq	$4, %r8
	addl	$1, (%r11,%rsi,4)
	cmpq	%r9, %r8
	jne	.L25
.L26:
	cmpl	$1, %r15d
	jle	.L27
	leaq	4+rope_cut(%rip), %rax
	leal	-2(%r15), %esi
	movl	rope_cut(%rip), %edx
	leaq	4(%rax), %rcx
	movq	%rsi, %rbp
	leaq	(%rcx,%rsi,4), %rcx
	.p2align 4,,10
	.p2align 3
.L28:
	addl	(%rax), %edx
	addq	$4, %rax
	movl	%edx, -4(%rax)
	cmpq	%rcx, %rax
	jne	.L28
	movslq	st_num(%rip), %rax
	leal	-1(%r15), %r10d
	leaq	rope_cut(%rip), %r11
	leaq	rope_exist(%rip), %r12
	testl	%eax, %eax
	jle	.L30
.L56:
	movl	%r15d, 8(%rsp)
	leal	-1(%r15), %r10d
	xorl	%ebp, %ebp
	leaq	input_s(%rip), %r13
	leaq	rope_cut(%rip), %r11
	leaq	rope_exist(%rip), %r12
	movq	%rax, %r15
	leaq	rope_vanished(%rip), %r14
	.p2align 4,,10
	.p2align 3
.L43:
	movl	0(%r13,%rbp,4), %esi
	testl	%r10d, %r10d
	js	.L59
	movl	%r10d, %ecx
	xorl	%edx, %edx
	.p2align 4,,10
	.p2align 3
.L36:
	leal	(%rdx,%rcx), %eax
	sarl	%eax
	movslq	%eax, %rdi
	cmpl	(%rbx,%rdi,4), %esi
	je	.L33
	jle	.L34
	leal	1(%rax), %edx
	cmpl	%ecx, %edx
	jle	.L36
.L60:
	xorl	%eax, %eax
	xorl	%edi, %edi
.L33:
	leaq	input_t(%rip), %rsi
	xorl	%ecx, %ecx
	movl	(%rsi,%rbp,4), %r9d
	movl	%r10d, %esi
	.p2align 4,,10
	.p2align 3
.L55:
	leal	(%rcx,%rsi), %edx
	sarl	%edx
	movslq	%edx, %r8
	cmpl	%r9d, (%rbx,%r8,4)
	je	.L37
.L88:
	jge	.L38
	leal	1(%rdx), %ecx
	cmpl	%esi, %ecx
	jle	.L55
.L84:
	xorl	%r8d, %r8d
.L32:
	movl	(%r11,%rdi,4), %eax
	subl	(%r11,%r8,4), %eax
	testb	$1, %al
	jne	.L42
	addl	$1, (%r12,%r8,4)
	subl	$1, (%r12,%rdi,4)
.L41:
	addq	$1, %rbp
	cmpq	%r15, %rbp
	jne	.L43
	movl	8(%rsp), %r15d
	leal	-2(%r15), %ebp
	cmpl	$1, %r15d
	jle	.L85
.L30:
	cmpl	$3, %r15d
	jle	.L61
	leal	-4(%r15), %edx
	leaq	rope_vanished(%rip), %rax
	movl	rope_cut(%rip), %r13d
	shrl	%edx
	leaq	rope_exist(%rip), %rsi
	movq	%rax, %rcx
	leaq	5(%rdx,%rdx), %rdi
	leaq	-4+rope_cut(%rip), %rdx
	movq	%rdi, 8(%rsp)
	movl	$3, %edi
.L48:
	leaq	-8+rope_cut(%rip), %r14
	movl	4(%rsi), %r8d
	movl	4(%rcx), %r9d
	movl	(%r14,%rdi,4), %r14d
	addl	(%rsi), %r8d
	addl	(%rcx), %r9d
	movl	%r8d, 4(%rsi)
	movl	%r9d, 4(%rcx)
	cmpl	%r14d, %r13d
	je	.L46
	movl	%r9d, 4(%rsi)
	movl	%r8d, 4(%rcx)
.L46:
	movl	(%rdx,%rdi,4), %r13d
	movl	8(%rsi), %r8d
	movl	8(%rcx), %r9d
	addl	4(%rsi), %r8d
	addl	4(%rcx), %r9d
	movl	%r8d, 8(%rsi)
	movl	%r9d, 8(%rcx)
	cmpl	%r14d, %r13d
	je	.L47
	movl	%r9d, 8(%rsi)
	movl	%r8d, 8(%rcx)
.L47:
	movl	%edi, %r8d
	addq	$8, %rsi
	addq	$2, %rdi
	addq	$8, %rcx
	cmpq	8(%rsp), %rdi
	jne	.L48
.L45:
	movslq	%r8d, %rsi
	leaq	0(,%rsi,4), %rdi
	leaq	(%r12,%rdi), %rcx
	addq	%rdi, %rax
	.p2align 4,,10
	.p2align 3
.L50:
	movl	-4(%rcx), %edi
	movl	-4(%rax), %r8d
	addl	(%rcx), %edi
	addl	(%rax), %r8d
	movl	%edi, (%rcx)
	movl	(%rdx,%rsi,4), %r14d
	movl	%r8d, (%rax)
	cmpl	%r14d, (%r11,%rsi,4)
	je	.L49
	movl	%r8d, (%rcx)
	movl	%edi, (%rax)
.L49:
	addq	$1, %rsi
	addq	$4, %rcx
	addq	$4, %rax
	cmpl	%esi, %r15d
	jg	.L50
	cmpl	$2, %ebp
	jbe	.L62
	movl	%r10d, %ecx
	leaq	rope_exist(%rip), %rdx
	leaq	zahyou_list(%rip), %rax
	leaq	16(%rdx), %rsi
	pxor	%xmm2, %xmm2
	shrl	$2, %ecx
	pxor	%xmm5, %xmm5
	subl	$1, %ecx
	salq	$4, %rcx
	addq	%rsi, %rcx
	.p2align 4,,10
	.p2align 3
.L52:
	movdqa	(%rdx), %xmm0
	movdqa	%xmm5, %xmm4
	movdqa	%xmm5, %xmm6
	addq	$16, %rdx
	movdqu	4(%rax), %xmm3
	psubd	(%rax), %xmm3
	addq	$16, %rax
	movdqa	%xmm0, %xmm1
	movdqa	%xmm3, %xmm7
	punpckldq	%xmm0, %xmm1
	punpckhdq	%xmm0, %xmm0
	punpckldq	%xmm3, %xmm7
	pcmpgtd	%xmm1, %xmm4
	punpckhdq	%xmm3, %xmm3
	pcmpgtd	%xmm7, %xmm6
	pmuludq	%xmm7, %xmm4
	pmuludq	%xmm1, %xmm6
	pmuludq	%xmm7, %xmm1
	paddq	%xmm6, %xmm4
	psllq	$32, %xmm4
	paddq	%xmm4, %xmm1
	movdqa	%xmm5, %xmm4
	paddq	%xmm1, %xmm2
	pcmpgtd	%xmm3, %xmm4
	movdqa	%xmm5, %xmm1
	pcmpgtd	%xmm0, %xmm1
	pmuludq	%xmm0, %xmm4
	pmuludq	%xmm3, %xmm0
	pmuludq	%xmm3, %xmm1
	paddq	%xmm4, %xmm1
	psllq	$32, %xmm1
	paddq	%xmm1, %xmm0
	paddq	%xmm0, %xmm2
	cmpq	%rcx, %rdx
	jne	.L52
	movdqa	%xmm2, %xmm0
	movl	%r10d, %ecx
	psrldq	$8, %xmm0
	andl	$-4, %ecx
	paddq	%xmm0, %xmm2
	leal	1(%rcx), %eax
	movq	%xmm2, %rdx
	cmpl	%ecx, %r10d
	je	.L31
.L51:
	movslq	%eax, %rdi
	movslq	%ecx, %rcx
	movl	(%rbx,%rdi,4), %r9d
	movl	%r9d, %esi
	subl	(%rbx,%rcx,4), %esi
	movslq	(%r12,%rcx,4), %rcx
	movslq	%esi, %rsi
	imulq	%rsi, %rcx
	addq	%rcx, %rdx
	leal	1(%rax), %ecx
	cmpl	%r15d, %ecx
	jge	.L31
	movslq	%ecx, %rcx
	movslq	(%r12,%rdi,4), %rsi
	addl	$2, %eax
	movl	(%rbx,%rcx,4), %r8d
	movl	%r8d, %edi
	subl	%r9d, %edi
	movslq	%edi, %rdi
	imulq	%rdi, %rsi
	addq	%rsi, %rdx
	cmpl	%r15d, %eax
	jge	.L31
	cltq
	movslq	(%r12,%rcx,4), %rcx
	movl	(%rbx,%rax,4), %eax
	subl	%r8d, %eax
	cltq
	imulq	%rcx, %rax
	addq	%rax, %rdx
.L31:
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	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
	.p2align 4,,10
	.p2align 3
.L38:
	.cfi_restore_state
	leal	-1(%rdx), %esi
	cmpl	%ecx, %esi
	jl	.L84
	leal	(%rcx,%rsi), %edx
	sarl	%edx
	movslq	%edx, %r8
	cmpl	%r9d, (%rbx,%r8,4)
	jne	.L88
.L37:
	movl	(%r11,%r8,4), %esi
	movl	(%r11,%rdi,4), %ecx
	cmpl	%eax, %edx
	jle	.L32
	movl	(%r12,%rdi,4), %eax
	leal	1(%rax), %edx
	movl	%esi, %eax
	subl	%ecx, %eax
	movl	%edx, (%r12,%rdi,4)
	testb	$1, %al
	jne	.L40
	subl	$1, (%r12,%r8,4)
	jmp	.L41
	.p2align 4,,10
	.p2align 3
.L34:
	leal	-1(%rax), %ecx
	cmpl	%edx, %ecx
	jge	.L36
	jmp	.L60
	.p2align 4,,10
	.p2align 3
.L22:
	leal	-1(%rax), %ecx
	cmpl	%edx, %ecx
	jge	.L24
	jmp	.L58
	.p2align 4,,10
	.p2align 3
.L42:
	addl	$1, (%r14,%r8,4)
	subl	$1, (%r12,%rdi,4)
	jmp	.L41
	.p2align 4,,10
	.p2align 3
.L40:
	subl	$1, (%r14,%r8,4)
	jmp	.L41
.L59:
	xorl	%edi, %edi
	jmp	.L84
.L27:
	movslq	st_num(%rip), %rax
	testl	%eax, %eax
	jg	.L56
.L85:
	xorl	%edx, %edx
	jmp	.L31
.L87:
	movl	zahyou_num(%rip), %edx
	jmp	.L19
.L62:
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	movl	$1, %eax
	jmp	.L51
.L61:
	movl	$1, %r8d
	leaq	rope_vanished(%rip), %rax
	leaq	-4+rope_cut(%rip), %rdx
	jmp	.L45
	.cfi_endproc
.LFE41:
	.size	main, .-main
	.globl	rope_cut
	.bss
	.align 32
	.type	rope_cut, @object
	.size	rope_cut, 1200004
rope_cut:
	.zero	1200004
	.globl	rope_vanished
	.align 32
	.type	rope_vanished, @object
	.size	rope_vanished, 1200004
rope_vanished:
	.zero	1200004
	.globl	rope_exist
	.align 32
	.type	rope_exist, @object
	.size	rope_exist, 1200004
rope_exist:
	.zero	1200004
	.globl	input_p
	.align 32
	.type	input_p, @object
	.size	input_p, 400000
input_p:
	.zero	400000
	.globl	input_t
	.align 32
	.type	input_t, @object
	.size	input_t, 400000
input_t:
	.zero	400000
	.globl	input_s
	.align 32
	.type	input_s, @object
	.size	input_s, 400000
input_s:
	.zero	400000
	.globl	p_num
	.align 4
	.type	p_num, @object
	.size	p_num, 4
p_num:
	.zero	4
	.globl	st_num
	.align 4
	.type	st_num, @object
	.size	st_num, 4
st_num:
	.zero	4
	.globl	zahyou_list
	.align 32
	.type	zahyou_list, @object
	.size	zahyou_list, 1200004
zahyou_list:
	.zero	1200004
	.globl	zahyou_num
	.align 4
	.type	zahyou_num, @object
	.size	zahyou_num, 4
zahyou_num:
	.zero	4
	.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 zahyou_num;
int zahyou_list[300001];

/* syo-zyun */
int qsort_comp(const void* x,const void* y) {
	int* a=(int*)x;
	int* b=(int*)y;
	if(*a>*b)return 1;
	if(*a<*b)return -1;
	return 0;
}

int get_id(int zahyou) {
	int left,right,mid;
	left=0;right=zahyou_num-1;
	while(left<=right) {
		mid=(left+right)/2;
		if(zahyou_list[mid]==zahyou)return mid;
		else if(zahyou_list[mid]<zahyou)left=mid+1;
		else right=mid-1;
	}
	return 0;
}

int st_num,p_num;
int input_s[100000];
int input_t[100000];
int input_p[100000];

int rope_exist[300001];
int rope_vanished[300001];
int rope_cut[300001];

int main(void) {
	int i;
	int start,end;
	int temp;
	long long result;
	scanf("%d%d",&st_num,&p_num);
	zahyou_num=1;
	zahyou_list[0]=0;
	for(i=0;i<st_num;i++) {
		scanf("%d%d",&input_s[i],&input_t[i]);
		zahyou_list[zahyou_num++]=input_s[i];
		zahyou_list[zahyou_num++]=input_t[i];
	}
	for(i=0;i<p_num;i++) {
		scanf("%d",&input_p[i]);
		zahyou_list[zahyou_num++]=input_p[i];
	}
	qsort(zahyou_list,zahyou_num,sizeof(int),qsort_comp);
	for(i=0;i<p_num;i++) {
		rope_cut[get_id(input_p[i])]++;
	}
	for(i=1;i<zahyou_num;i++)rope_cut[i]+=rope_cut[i-1];
	for(i=0;i<st_num;i++) {
		start=get_id(input_s[i]);
		end=get_id(input_t[i]);
		if(start<end) {
			if((rope_cut[end]-rope_cut[start])%2==0) {
				rope_exist[start]++;
				rope_exist[end]--;
			} else {
				rope_exist[start]++;
				rope_vanished[end]--;
			}
		} else {
			if((rope_cut[start]-rope_cut[end])%2==0) {
				rope_exist[end]++;
				rope_exist[start]--;
			} else {
				rope_vanished[end]++;
				rope_exist[start]--;
			}
		}
	}
	result=0;
	for(i=1;i<zahyou_num;i++) {
		rope_exist[i]+=rope_exist[i-1];
		rope_vanished[i]+=rope_vanished[i-1];
		if(rope_cut[i]!=rope_cut[i-1]) {
			temp=rope_exist[i];
			rope_exist[i]=rope_vanished[i];
			rope_vanished[i]=temp;
		}
	}
	for(i=0;i+1<zahyou_num;i++) {
		result+=(long long)(zahyou_list[i+1]-zahyou_list[i])*
			(long long)rope_exist[i];
	}
	printf("%lld\n",result);
	return 0;
}
2 3
1 8
20 5
3
7
15

10

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 zahyou_num;
int zahyou_list[300001];

/* syo-zyun */
int qsort_comp(const void* x,const void* y) {
	int* a=(int*)x;
	int* b=(int*)y;
	if(*a>*b)return 1;
	if(*a<*b)return -1;
	return 0;
}

int get_id(int zahyou) {
	int left,right,mid;
	left=0;right=zahyou_num-1;
	while(left<=right) {
		mid=(left+right)/2;
		if(zahyou_list[mid]==zahyou)return mid;
		else if(zahyou_list[mid]<zahyou)left=mid+1;
		else right=mid-1;
	}
	return 0;
}

int st_num,p_num;
int input_s[100000];
int input_t[100000];
int input_p[100000];

int rope_exist[300001];
int rope_vanished[300001];
int rope_cut[300001];

int main(void) {
	int i;
	int start,end;
	int temp;
	long long result;
	scanf("%d%d",&st_num,&p_num);
	zahyou_num=1;
	zahyou_list[0]=0;
	for(i=0;i<st_num;i++) {
		scanf("%d%d",&input_s[i],&input_t[i]);
		zahyou_list[zahyou_num++]=input_s[i];
		zahyou_list[zahyou_num++]=input_t[i];
	}
	for(i=0;i<p_num;i++) {
		scanf("%d",&input_p[i]);
		zahyou_list[zahyou_num++]=input_p[i];
	}
	qsort(zahyou_list,zahyou_num,sizeof(int),qsort_comp);
	for(i=0;i<p_num;i++) {
		rope_cut[get_id(input_p[i])]++;
	}
	for(i=1;i<zahyou_num;i++)rope_cut[i]+=rope_cut[i-1];
	for(i=0;i<st_num;i++) {
		start=get_id(input_s[i]);
		end=get_id(input_t[i]);
		if(start<end) {
			if((rope_cut[end]-rope_cut[start])%2==0) {
				rope_exist[start]++;
				rope_exist[end]--;
			} else {
				rope_exist[start]++;
				rope_vanished[end]--;
			}
		} else {
			if((rope_cut[start]-rope_cut[end])%2==0) {
				rope_exist[end]++;
				rope_exist[start]--;
			} else {
				rope_vanished[end]++;
				rope_exist[start]--;
			}
		}
	}
	result=0;
	for(i=1;i<zahyou_num;i++) {
		rope_exist[i]+=rope_exist[i-1];
		rope_vanished[i]+=rope_vanished[i-1];
		if(rope_cut[i]!=rope_cut[i-1]) {
			temp=rope_exist[i];
			rope_exist[i]=rope_vanished[i];
			rope_vanished[i]=temp;
		}
	}
	for(i=0;i+1<zahyou_num;i++) {
		result+=(long long)(zahyou_list[i+1]-zahyou_list[i])*
			(long long)rope_exist[i];
	}
	printf("%lld\n",result);
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	zahyou_num
	.bss
	.align 4
	.type	zahyou_num, @object
	.size	zahyou_num, 4
zahyou_num:
	.zero	4
	.globl	zahyou_list
	.align 32
	.type	zahyou_list, @object
	.size	zahyou_list, 1200004
zahyou_list:
	.zero	1200004
	.text
	.globl	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.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, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -8(%rbp)
	movq	-16(%rbp), %rax
	movl	(%rax), %edx
	movq	-8(%rbp), %rax
	movl	(%rax), %eax
	cmpl	%eax, %edx
	jle	.L2
	movl	$1, %eax
	jmp	.L3
.L2:
	movq	-16(%rbp), %rax
	movl	(%rax), %edx
	movq	-8(%rbp), %rax
	movl	(%rax), %eax
	cmpl	%eax, %edx
	jge	.L4
	movl	$-1, %eax
	jmp	.L3
.L4:
	movl	$0, %eax
.L3:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	qsort_comp, .-qsort_comp
	.globl	get_id
	.type	get_id, @function
get_id:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	$0, -12(%rbp)
	movl	zahyou_num(%rip), %eax
	subl	$1, %eax
	movl	%eax, -8(%rbp)
	jmp	.L6
.L10:
	movl	-12(%rbp), %edx
	movl	-8(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, %edx
	shrl	$31, %edx
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -20(%rbp)
	jne	.L7
	movl	-4(%rbp), %eax
	jmp	.L8
.L7:
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L9
	movl	-4(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -12(%rbp)
	jmp	.L6
.L9:
	movl	-4(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -8(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L10
	movl	$0, %eax
.L8:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	get_id, .-get_id
	.globl	st_num
	.bss
	.align 4
	.type	st_num, @object
	.size	st_num, 4
st_num:
	.zero	4
	.globl	p_num
	.align 4
	.type	p_num, @object
	.size	p_num, 4
p_num:
	.zero	4
	.globl	input_s
	.align 32
	.type	input_s, @object
	.size	input_s, 400000
input_s:
	.zero	400000
	.globl	input_t
	.align 32
	.type	input_t, @object
	.size	input_t, 400000
input_t:
	.zero	400000
	.globl	input_p
	.align 32
	.type	input_p, @object
	.size	input_p, 400000
input_p:
	.zero	400000
	.globl	rope_exist
	.align 32
	.type	rope_exist, @object
	.size	rope_exist, 1200004
rope_exist:
	.zero	1200004
	.globl	rope_vanished
	.align 32
	.type	rope_vanished, @object
	.size	rope_vanished, 1200004
rope_vanished:
	.zero	1200004
	.globl	rope_cut
	.align 32
	.type	rope_cut, @object
	.size	rope_cut, 1200004
rope_cut:
	.zero	1200004
	.section	.rodata
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB8:
	.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
	leaq	p_num(%rip), %rax
	movq	%rax, %rdx
	leaq	st_num(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$1, zahyou_num(%rip)
	movl	$0, zahyou_list(%rip)
	movl	$0, -24(%rbp)
	jmp	.L12
.L13:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_t(%rip), %rax
	addq	%rax, %rdx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	input_s(%rip), %rax
	addq	%rcx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_s(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_t(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	addl	$1, -24(%rbp)
.L12:
	movl	st_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L13
	movl	$0, -24(%rbp)
	jmp	.L14
.L15:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_p(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_p(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	addl	$1, -24(%rbp)
.L14:
	movl	p_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L15
	movl	zahyou_num(%rip), %eax
	cltq
	leaq	qsort_comp(%rip), %rdx
	movq	%rdx, %rcx
	movl	$4, %edx
	movq	%rax, %rsi
	leaq	zahyou_list(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$0, -24(%rbp)
	jmp	.L16
.L17:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_p(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movslq	%eax, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	leal	1(%rdx), %ecx
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	addl	$1, -24(%rbp)
.L16:
	movl	p_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L17
	movl	$1, -24(%rbp)
	jmp	.L18
.L19:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	addl	$1, -24(%rbp)
.L18:
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L19
	movl	$0, -24(%rbp)
	jmp	.L20
.L25:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_s(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movl	%eax, -16(%rbp)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_t(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movl	%eax, -12(%rbp)
	movl	-16(%rbp), %eax
	cmpl	-12(%rbp), %eax
	jge	.L21
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-16(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L22
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L22:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L21:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-12(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L24
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L24:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
.L23:
	addl	$1, -24(%rbp)
.L20:
	movl	st_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L25
	movq	$0, -8(%rbp)
	movl	$1, -24(%rbp)
	jmp	.L26
.L28:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_cut(%rip), %rax
	movl	(%rcx,%rax), %eax
	cmpl	%eax, %edx
	je	.L27
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -20(%rbp)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_exist(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_vanished(%rip), %rdx
	movl	-20(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
.L27:
	addl	$1, -24(%rbp)
.L26:
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L28
	movl	$0, -24(%rbp)
	jmp	.L29
.L30:
	movl	-24(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	zahyou_list(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	movslq	%eax, %rdx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_exist(%rip), %rax
	movl	(%rcx,%rax), %eax
	cltq
	imulq	%rdx, %rax
	addq	%rax, -8(%rbp)
	addl	$1, -24(%rbp)
.L29:
	movl	-24(%rbp), %eax
	leal	1(%rax), %edx
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, %edx
	jl	.L30
	movq	-8(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.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	zahyou_num
	.bss
	.align 4
	.type	zahyou_num, @object
	.size	zahyou_num, 4
zahyou_num:
	.zero	4
	.globl	zahyou_list
	.align 32
	.type	zahyou_list, @object
	.size	zahyou_list, 1200004
zahyou_list:
	.zero	1200004
	.text
	.globl	qsort_comp
	.type	qsort_comp, @function
qsort_comp:
.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, -24(%rbp)
	movq	%rsi, -32(%rbp)
	movq	-24(%rbp), %rax
	movq	%rax, -16(%rbp)
	movq	-32(%rbp), %rax
	movq	%rax, -8(%rbp)
	movq	-16(%rbp), %rax
	movl	(%rax), %edx
	movq	-8(%rbp), %rax
	movl	(%rax), %eax
	cmpl	%eax, %edx
	jle	.L2
	movl	$1, %eax
	jmp	.L3
.L2:
	movq	-16(%rbp), %rax
	movl	(%rax), %edx
	movq	-8(%rbp), %rax
	movl	(%rax), %eax
	cmpl	%eax, %edx
	jge	.L4
	movl	$-1, %eax
	jmp	.L3
.L4:
	movl	$0, %eax
.L3:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	qsort_comp, .-qsort_comp
	.globl	get_id
	.type	get_id, @function
get_id:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -20(%rbp)
	movl	$0, -12(%rbp)
	movl	zahyou_num(%rip), %eax
	subl	$1, %eax
	movl	%eax, -8(%rbp)
	jmp	.L6
.L10:
	movl	-12(%rbp), %edx
	movl	-8(%rbp), %eax
	addl	%edx, %eax
	movl	%eax, %edx
	shrl	$31, %edx
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -20(%rbp)
	jne	.L7
	movl	-4(%rbp), %eax
	jmp	.L8
.L7:
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -20(%rbp)
	jle	.L9
	movl	-4(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -12(%rbp)
	jmp	.L6
.L9:
	movl	-4(%rbp), %eax
	subl	$1, %eax
	movl	%eax, -8(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jle	.L10
	movl	$0, %eax
.L8:
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	get_id, .-get_id
	.globl	st_num
	.bss
	.align 4
	.type	st_num, @object
	.size	st_num, 4
st_num:
	.zero	4
	.globl	p_num
	.align 4
	.type	p_num, @object
	.size	p_num, 4
p_num:
	.zero	4
	.globl	input_s
	.align 32
	.type	input_s, @object
	.size	input_s, 400000
input_s:
	.zero	400000
	.globl	input_t
	.align 32
	.type	input_t, @object
	.size	input_t, 400000
input_t:
	.zero	400000
	.globl	input_p
	.align 32
	.type	input_p, @object
	.size	input_p, 400000
input_p:
	.zero	400000
	.globl	rope_exist
	.align 32
	.type	rope_exist, @object
	.size	rope_exist, 1200004
rope_exist:
	.zero	1200004
	.globl	rope_vanished
	.align 32
	.type	rope_vanished, @object
	.size	rope_vanished, 1200004
rope_vanished:
	.zero	1200004
	.globl	rope_cut
	.align 32
	.type	rope_cut, @object
	.size	rope_cut, 1200004
rope_cut:
	.zero	1200004
	.section	.rodata
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%lld\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB8:
	.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
	leaq	p_num(%rip), %rax
	movq	%rax, %rdx
	leaq	st_num(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$1, zahyou_num(%rip)
	movl	$0, zahyou_list(%rip)
	movl	$0, -24(%rbp)
	jmp	.L12
.L13:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_t(%rip), %rax
	addq	%rax, %rdx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	input_s(%rip), %rax
	addq	%rcx, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_s(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_t(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	addl	$1, -24(%rbp)
.L12:
	movl	st_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L13
	movl	$0, -24(%rbp)
	jmp	.L14
.L15:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_p(%rip), %rax
	addq	%rdx, %rax
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	zahyou_num(%rip), %eax
	leal	1(%rax), %edx
	movl	%edx, zahyou_num(%rip)
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	input_p(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	zahyou_list(%rip), %rax
	movl	%edx, (%rcx,%rax)
	addl	$1, -24(%rbp)
.L14:
	movl	p_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L15
	movl	zahyou_num(%rip), %eax
	cltq
	leaq	qsort_comp(%rip), %rdx
	movq	%rdx, %rcx
	movl	$4, %edx
	movq	%rax, %rsi
	leaq	zahyou_list(%rip), %rax
	movq	%rax, %rdi
	call	qsort@PLT
	movl	$0, -24(%rbp)
	jmp	.L16
.L17:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_p(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movslq	%eax, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	leal	1(%rdx), %ecx
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	addl	$1, -24(%rbp)
.L16:
	movl	p_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L17
	movl	$1, -24(%rbp)
	jmp	.L18
.L19:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	addl	$1, -24(%rbp)
.L18:
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L19
	movl	$0, -24(%rbp)
	jmp	.L20
.L25:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_s(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movl	%eax, -16(%rbp)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	input_t(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %edi
	call	get_id
	movl	%eax, -12(%rbp)
	movl	-16(%rbp), %eax
	cmpl	-12(%rbp), %eax
	jge	.L21
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-16(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L22
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L22:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L21:
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-12(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_cut(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	andl	$1, %eax
	testl	%eax, %eax
	jne	.L24
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	jmp	.L23
.L24:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	1(%rax), %ecx
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	leal	-1(%rax), %ecx
	movl	-16(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
.L23:
	addl	$1, -24(%rbp)
.L20:
	movl	st_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L25
	movq	$0, -8(%rbp)
	movl	$1, -24(%rbp)
	jmp	.L26
.L28:
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %ecx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	addl	%eax, %ecx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	%ecx, (%rdx,%rax)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_cut(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-24(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_cut(%rip), %rax
	movl	(%rcx,%rax), %eax
	cmpl	%eax, %edx
	je	.L27
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_exist(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, -20(%rbp)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	rope_vanished(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	rope_exist(%rip), %rdx
	movl	%eax, (%rcx,%rdx)
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_vanished(%rip), %rdx
	movl	-20(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
.L27:
	addl	$1, -24(%rbp)
.L26:
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, -24(%rbp)
	jl	.L28
	movl	$0, -24(%rbp)
	jmp	.L29
.L30:
	movl	-24(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	zahyou_list(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	-24(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,4), %rcx
	leaq	zahyou_list(%rip), %rdx
	movl	(%rcx,%rdx), %edx
	subl	%edx, %eax
	movslq	%eax, %rdx
	movl	-24(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	rope_exist(%rip), %rax
	movl	(%rcx,%rax), %eax
	cltq
	imulq	%rdx, %rax
	addq	%rax, -8(%rbp)
	addl	$1, -24(%rbp)
.L29:
	movl	-24(%rbp), %eax
	leal	1(%rax), %edx
	movl	zahyou_num(%rip), %eax
	cmpl	%eax, %edx
	jl	.L30
	movq	-8(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.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:
