Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
// AOJ 2801: Suntan
// 2017.11.20 bal4u@uu

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

long long s[100001], t[100001]; int N;
long long a[100001];

char buf[50], *p;
long long getlong()
{
	long long n = 0;
	while (*p >= '0') n = (n<<3) + (n<<1) + (*p++ & 0xf);
	return n;
}

int bsch(long long x)
{
	int m, l = 0, r = N+1;

    while (l < r) {
        m = (l + r) >> 1;
        if (t[m] < x) l = m + 1; else r = m;
    }
	return l-1;
}

int main()
{
	int i, k;
	long long ans, T, x, y;
	
	fgets(p=buf, 50, stdin), T = getlong();
	fgets(buf, 50, stdin), N = atoi(buf);
	for (i = 1; i <= N; i++) {
		fgets(p=buf, 50, stdin);
		s[i] = getlong(), p++, t[i] = getlong();
		a[i] = a[i-1] + (t[i]-s[i]);
	}
	s[N+1] = t[N+1] = 1LL << 62;

	ans = 0;
	for (k = bsch(T), i = 1; i <= N; i++) {
		x = s[i] + T; while (t[k+1] <= x) k++;
		y = a[k]-a[i-1];
		if (x > s[k+1]) y += x-s[k+1];
		if (y > ans) {
			ans = y;
			if (ans == T) break;
		}
	}
	printf("%lld\n", ans);
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	s
	.bss
	.align 32
	.type	s, @object
	.size	s, 800008
s:
	.zero	800008
	.globl	t
	.align 32
	.type	t, @object
	.size	t, 800008
t:
	.zero	800008
	.globl	N
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 800008
a:
	.zero	800008
	.globl	buf
	.align 32
	.type	buf, @object
	.size	buf, 50
buf:
	.zero	50
	.globl	p
	.align 8
	.type	p, @object
	.size	p, 8
p:
	.zero	8
	.text
	.globl	getlong
	.type	getlong, @function
getlong:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	$0, -8(%rbp)
	jmp	.L2
.L3:
	movq	-8(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	movq	-8(%rbp), %rax
	addq	%rax, %rax
	leaq	(%rdx,%rax), %rcx
	movq	p(%rip), %rax
	leaq	1(%rax), %rdx
	movq	%rdx, p(%rip)
	movzbl	(%rax), %eax
	movsbq	%al, %rax
	andl	$15, %eax
	addq	%rcx, %rax
	movq	%rax, -8(%rbp)
.L2:
	movq	p(%rip), %rax
	movzbl	(%rax), %eax
	cmpb	$47, %al
	jg	.L3
	movq	-8(%rbp), %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	getlong, .-getlong
	.globl	bsch
	.type	bsch, @function
bsch:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, -12(%rbp)
	movl	N(%rip), %eax
	addl	$1, %eax
	movl	%eax, -8(%rbp)
	jmp	.L6
.L8:
	movl	-12(%rbp), %edx
	movl	-8(%rbp), %eax
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -24(%rbp)
	jle	.L7
	movl	-4(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -12(%rbp)
	jmp	.L6
.L7:
	movl	-4(%rbp), %eax
	movl	%eax, -8(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jl	.L8
	movl	-12(%rbp), %eax
	subl	$1, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	bsch, .-bsch
	.section	.rodata
.LC0:
	.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	$48, %rsp
	movq	stdin(%rip), %rdx
	leaq	buf(%rip), %rax
	movq	%rax, p(%rip)
	movq	p(%rip), %rax
	movl	$50, %esi
	movq	%rax, %rdi
	call	fgets@PLT
	movl	$0, %eax
	call	getlong
	movq	%rax, -16(%rbp)
	movq	stdin(%rip), %rax
	movq	%rax, %rdx
	movl	$50, %esi
	leaq	buf(%rip), %rax
	movq	%rax, %rdi
	call	fgets@PLT
	leaq	buf(%rip), %rax
	movq	%rax, %rdi
	call	atoi@PLT
	movl	%eax, N(%rip)
	movl	$1, -40(%rbp)
	jmp	.L11
.L12:
	movq	stdin(%rip), %rdx
	leaq	buf(%rip), %rax
	movq	%rax, p(%rip)
	movq	p(%rip), %rax
	movl	$50, %esi
	movq	%rax, %rdi
	call	fgets@PLT
	movl	$0, %eax
	call	getlong
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	p(%rip), %rax
	addq	$1, %rax
	movq	%rax, p(%rip)
	movl	$0, %eax
	call	getlong
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	t(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-40(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	leaq	(%rsi,%rax), %rcx
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	addl	$1, -40(%rbp)
.L11:
	movl	N(%rip), %eax
	cmpl	%eax, -40(%rbp)
	jle	.L12
	movl	N(%rip), %eax
	addl	$1, %eax
	movslq	%eax, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	t(%rip), %rdx
	movabsq	$4611686018427387904, %rsi
	movq	%rsi, (%rcx,%rdx)
	movl	N(%rip), %edx
	leal	1(%rdx), %ecx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	movslq	%ecx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	$0, -32(%rbp)
	movq	-16(%rbp), %rax
	movq	%rax, %rdi
	call	bsch
	movl	%eax, -36(%rbp)
	movl	$1, -40(%rbp)
	jmp	.L13
.L19:
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-16(%rbp), %rax
	addq	%rdx, %rax
	movq	%rax, -8(%rbp)
	jmp	.L14
.L15:
	addl	$1, -36(%rbp)
.L14:
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -8(%rbp)
	jge	.L15
	movl	-36(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-40(%rbp), %edx
	subl	$1, %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, -24(%rbp)
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -8(%rbp)
	jle	.L16
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-8(%rbp), %rax
	subq	%rdx, %rax
	addq	%rax, -24(%rbp)
.L16:
	movq	-24(%rbp), %rax
	cmpq	-32(%rbp), %rax
	jle	.L17
	movq	-24(%rbp), %rax
	movq	%rax, -32(%rbp)
	movq	-32(%rbp), %rax
	cmpq	-16(%rbp), %rax
	je	.L21
.L17:
	addl	$1, -40(%rbp)
.L13:
	movl	N(%rip), %eax
	cmpl	%eax, -40(%rbp)
	jle	.L19
	jmp	.L18
.L21:
	nop
.L18:
	movq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%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	getlong
	.type	getlong, @function
getlong:
.LFB39:
	.cfi_startproc
	endbr64
	movq	p(%rip), %rax
	cmpb	$47, (%rax)
	jle	.L4
	addq	$1, %rax
	xorl	%r8d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rax, p(%rip)
	movzbl	-1(%rax), %edx
	addq	$1, %rax
	leaq	(%r8,%r8,4), %rcx
	andl	$15, %edx
	cmpb	$47, -1(%rax)
	leaq	(%rdx,%rcx,2), %r8
	jg	.L3
	movq	%r8, %rax
	ret
	.p2align 4,,10
	.p2align 3
.L4:
	xorl	%r8d, %r8d
	movq	%r8, %rax
	ret
	.cfi_endproc
.LFE39:
	.size	getlong, .-getlong
	.p2align 4
	.globl	bsch
	.type	bsch, @function
bsch:
.LFB40:
	.cfi_startproc
	endbr64
	movl	N(%rip), %eax
	leaq	t(%rip), %r8
	leal	1(%rax), %ecx
	xorl	%eax, %eax
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L10:
	leal	(%rcx,%rax), %edx
	sarl	%edx
	movslq	%edx, %rsi
	cmpq	%rdi, (%r8,%rsi,8)
	jl	.L12
	movl	%edx, %ecx
.L9:
	cmpl	%eax, %ecx
	jg	.L10
	subl	$1, %eax
	ret
	.p2align 4,,10
	.p2align 3
.L12:
	leal	1(%rdx), %eax
	jmp	.L9
	.cfi_endproc
.LFE40:
	.size	bsch, .-bsch
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.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
	movl	$50, %esi
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	buf(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	movq	%r13, %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	stdin(%rip), %rdx
	movq	%r13, p(%rip)
	call	fgets@PLT
	movq	p(%rip), %rax
	cmpb	$47, (%rax)
	jle	.L30
	addq	$1, %rax
	xorl	%ebx, %ebx
	.p2align 4,,10
	.p2align 3
.L15:
	movq	%rax, p(%rip)
	movzbl	-1(%rax), %edx
	addq	$1, %rax
	leaq	(%rbx,%rbx,4), %rsi
	andl	$15, %edx
	cmpb	$47, -1(%rax)
	leaq	(%rdx,%rsi,2), %rbx
	jg	.L15
.L14:
	movq	stdin(%rip), %rdx
	movl	$50, %esi
	movq	%r13, %rdi
	leaq	s(%rip), %r12
	leaq	t(%rip), %rbp
	call	fgets@PLT
	movq	%r13, %rdi
	movl	$10, %edx
	xorl	%esi, %esi
	call	strtol@PLT
	movl	%eax, N(%rip)
	movl	%eax, %edi
	testl	%eax, %eax
	jle	.L16
	leaq	a(%rip), %r14
	movl	$1, %r15d
	leaq	-8(%r14), %rax
	movq	%rax, 8(%rsp)
	.p2align 4,,10
	.p2align 3
.L21:
	movq	stdin(%rip), %rdx
	movl	$50, %esi
	movq	%r13, %rdi
	movq	%r13, p(%rip)
	call	fgets@PLT
	movq	p(%rip), %rax
	cmpb	$47, (%rax)
	jle	.L31
	leaq	1(%rax), %rdx
	xorl	%esi, %esi
	.p2align 4,,10
	.p2align 3
.L18:
	movq	%rdx, p(%rip)
	leaq	(%rsi,%rsi,4), %rdi
	movzbl	-1(%rdx), %esi
	movq	%rdx, %rax
	addq	$1, %rdx
	andl	$15, %esi
	cmpb	$47, -1(%rdx)
	leaq	(%rsi,%rdi,2), %rsi
	jg	.L18
.L17:
	leaq	1(%rax), %rdx
	movq	%rsi, (%r12,%r15,8)
	movq	%rdx, p(%rip)
	cmpb	$47, 1(%rax)
	jle	.L32
	addq	$2, %rax
	xorl	%edx, %edx
	.p2align 4,,10
	.p2align 3
.L20:
	movq	%rax, p(%rip)
	leaq	(%rdx,%rdx,4), %rdi
	movzbl	-1(%rax), %edx
	addq	$1, %rax
	andl	$15, %edx
	cmpb	$47, -1(%rax)
	leaq	(%rdx,%rdi,2), %rdx
	jg	.L20
.L19:
	movq	8(%rsp), %rax
	movl	N(%rip), %edi
	movq	%rdx, 0(%rbp,%r15,8)
	subq	%rsi, %rdx
	addq	(%rax,%r15,8), %rdx
	movq	%rdx, (%r14,%r15,8)
	addq	$1, %r15
	cmpl	%r15d, %edi
	jge	.L21
.L16:
	movabsq	$4611686018427387904, %rdx
	leal	1(%rdi), %ecx
	movslq	%ecx, %rax
	movq	%rdx, 0(%rbp,%rax,8)
	movq	%rdx, (%r12,%rax,8)
	xorl	%edx, %edx
	jmp	.L23
	.p2align 4,,10
	.p2align 3
.L24:
	leal	(%rcx,%rdx), %eax
	sarl	%eax
	movslq	%eax, %rsi
	cmpq	%rbx, 0(%rbp,%rsi,8)
	jl	.L44
	movl	%eax, %ecx
.L23:
	cmpl	%edx, %ecx
	jg	.L24
	subl	$1, %edx
	testl	%edi, %edi
	jle	.L34
	leaq	a(%rip), %r14
	movl	$1, %r8d
	xorl	%r9d, %r9d
	movslq	%edx, %r10
	leaq	-8(%r14), %rax
	movq	%rax, 8(%rsp)
	.p2align 4,,10
	.p2align 3
.L29:
	movq	(%r12,%r8,8), %rsi
	leaq	0(%rbp,%r10,8), %rax
	movl	%edx, %ecx
	addq	%rbx, %rsi
	.p2align 4,,10
	.p2align 3
.L26:
	addq	$8, %rax
	movl	%ecx, %edx
	leal	1(%rcx), %ecx
	cmpq	%rsi, (%rax)
	jle	.L26
	movq	8(%rsp), %r11
	movslq	%ecx, %rcx
	movslq	%edx, %r10
	movq	(%r14,%r10,8), %rax
	subq	(%r11,%r8,8), %rax
	movq	(%r12,%rcx,8), %r11
	movq	%rsi, %rcx
	subq	%r11, %rcx
	addq	%rax, %rcx
	cmpq	%rsi, %r11
	cmovl	%rcx, %rax
	cmpq	%r9, %rax
	jle	.L28
	cmpq	%rbx, %rax
	je	.L35
	movq	%rax, %r9
.L28:
	addq	$1, %r8
	cmpl	%r8d, %edi
	jge	.L29
.L25:
	movq	%r9, %rdx
	leaq	.LC0(%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
.L44:
	.cfi_restore_state
	leal	1(%rax), %edx
	jmp	.L23
.L32:
	xorl	%edx, %edx
	jmp	.L19
.L31:
	xorl	%esi, %esi
	jmp	.L17
.L35:
	movq	%rbx, %r9
	jmp	.L25
.L30:
	xorl	%ebx, %ebx
	jmp	.L14
.L34:
	xorl	%r9d, %r9d
	jmp	.L25
	.cfi_endproc
.LFE41:
	.size	main, .-main
	.globl	p
	.bss
	.align 8
	.type	p, @object
	.size	p, 8
p:
	.zero	8
	.globl	buf
	.align 32
	.type	buf, @object
	.size	buf, 50
buf:
	.zero	50
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 800008
a:
	.zero	800008
	.globl	N
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.globl	t
	.align 32
	.type	t, @object
	.size	t, 800008
t:
	.zero	800008
	.globl	s
	.align 32
	.type	s, @object
	.size	s, 800008
s:
	.zero	800008
	.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	getlong
	.type	getlong, @function
getlong:
.LFB39:
	.cfi_startproc
	endbr64
	movq	p(%rip), %rax
	cmpb	$47, (%rax)
	jle	.L4
	addq	$1, %rax
	xorl	%r8d, %r8d
	.p2align 4,,10
	.p2align 3
.L3:
	movq	%rax, p(%rip)
	movzbl	-1(%rax), %edx
	addq	$1, %rax
	leaq	(%r8,%r8,4), %rcx
	andl	$15, %edx
	cmpb	$47, -1(%rax)
	leaq	(%rdx,%rcx,2), %r8
	jg	.L3
	movq	%r8, %rax
	ret
	.p2align 4,,10
	.p2align 3
.L4:
	xorl	%r8d, %r8d
	movq	%r8, %rax
	ret
	.cfi_endproc
.LFE39:
	.size	getlong, .-getlong
	.p2align 4
	.globl	bsch
	.type	bsch, @function
bsch:
.LFB40:
	.cfi_startproc
	endbr64
	movl	N(%rip), %eax
	leaq	t(%rip), %r8
	leal	1(%rax), %ecx
	xorl	%eax, %eax
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L10:
	leal	(%rcx,%rax), %edx
	sarl	%edx
	movslq	%edx, %rsi
	cmpq	%rdi, (%r8,%rsi,8)
	jl	.L12
	movl	%edx, %ecx
.L9:
	cmpl	%eax, %ecx
	jg	.L10
	subl	$1, %eax
	ret
	.p2align 4,,10
	.p2align 3
.L12:
	leal	1(%rdx), %eax
	jmp	.L9
	.cfi_endproc
.LFE40:
	.size	bsch, .-bsch
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.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
	movl	$50, %esi
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	leaq	buf(%rip), %r13
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	movq	%r13, %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$24, %rsp
	.cfi_def_cfa_offset 80
	movq	stdin(%rip), %rdx
	movq	%r13, p(%rip)
	call	fgets@PLT
	movq	p(%rip), %rax
	cmpb	$47, (%rax)
	jle	.L30
	addq	$1, %rax
	xorl	%ebx, %ebx
	.p2align 4,,10
	.p2align 3
.L15:
	movq	%rax, p(%rip)
	movzbl	-1(%rax), %edx
	addq	$1, %rax
	leaq	(%rbx,%rbx,4), %rsi
	andl	$15, %edx
	cmpb	$47, -1(%rax)
	leaq	(%rdx,%rsi,2), %rbx
	jg	.L15
.L14:
	movq	stdin(%rip), %rdx
	movl	$50, %esi
	movq	%r13, %rdi
	leaq	s(%rip), %r12
	leaq	t(%rip), %rbp
	call	fgets@PLT
	movq	%r13, %rdi
	movl	$10, %edx
	xorl	%esi, %esi
	call	strtol@PLT
	movl	%eax, N(%rip)
	movl	%eax, %edi
	testl	%eax, %eax
	jle	.L16
	leaq	a(%rip), %r14
	movl	$1, %r15d
	leaq	-8(%r14), %rax
	movq	%rax, 8(%rsp)
	.p2align 4,,10
	.p2align 3
.L21:
	movq	stdin(%rip), %rdx
	movl	$50, %esi
	movq	%r13, %rdi
	movq	%r13, p(%rip)
	call	fgets@PLT
	movq	p(%rip), %rax
	cmpb	$47, (%rax)
	jle	.L31
	leaq	1(%rax), %rdx
	xorl	%esi, %esi
	.p2align 4,,10
	.p2align 3
.L18:
	movq	%rdx, p(%rip)
	leaq	(%rsi,%rsi,4), %rdi
	movzbl	-1(%rdx), %esi
	movq	%rdx, %rax
	addq	$1, %rdx
	andl	$15, %esi
	cmpb	$47, -1(%rdx)
	leaq	(%rsi,%rdi,2), %rsi
	jg	.L18
.L17:
	leaq	1(%rax), %rdx
	movq	%rsi, (%r12,%r15,8)
	movq	%rdx, p(%rip)
	cmpb	$47, 1(%rax)
	jle	.L32
	addq	$2, %rax
	xorl	%edx, %edx
	.p2align 4,,10
	.p2align 3
.L20:
	movq	%rax, p(%rip)
	leaq	(%rdx,%rdx,4), %rdi
	movzbl	-1(%rax), %edx
	addq	$1, %rax
	andl	$15, %edx
	cmpb	$47, -1(%rax)
	leaq	(%rdx,%rdi,2), %rdx
	jg	.L20
.L19:
	movq	8(%rsp), %rax
	movl	N(%rip), %edi
	movq	%rdx, 0(%rbp,%r15,8)
	subq	%rsi, %rdx
	addq	(%rax,%r15,8), %rdx
	movq	%rdx, (%r14,%r15,8)
	addq	$1, %r15
	cmpl	%r15d, %edi
	jge	.L21
.L16:
	movabsq	$4611686018427387904, %rdx
	leal	1(%rdi), %ecx
	movslq	%ecx, %rax
	movq	%rdx, 0(%rbp,%rax,8)
	movq	%rdx, (%r12,%rax,8)
	xorl	%edx, %edx
	jmp	.L23
	.p2align 4,,10
	.p2align 3
.L24:
	leal	(%rcx,%rdx), %eax
	sarl	%eax
	movslq	%eax, %rsi
	cmpq	%rbx, 0(%rbp,%rsi,8)
	jl	.L44
	movl	%eax, %ecx
.L23:
	cmpl	%edx, %ecx
	jg	.L24
	subl	$1, %edx
	testl	%edi, %edi
	jle	.L34
	leaq	a(%rip), %r14
	movl	$1, %r8d
	xorl	%r9d, %r9d
	movslq	%edx, %r10
	leaq	-8(%r14), %rax
	movq	%rax, 8(%rsp)
	.p2align 4,,10
	.p2align 3
.L29:
	movq	(%r12,%r8,8), %rsi
	leaq	0(%rbp,%r10,8), %rax
	movl	%edx, %ecx
	addq	%rbx, %rsi
	.p2align 4,,10
	.p2align 3
.L26:
	addq	$8, %rax
	movl	%ecx, %edx
	leal	1(%rcx), %ecx
	cmpq	%rsi, (%rax)
	jle	.L26
	movq	8(%rsp), %r11
	movslq	%ecx, %rcx
	movslq	%edx, %r10
	movq	(%r14,%r10,8), %rax
	subq	(%r11,%r8,8), %rax
	movq	(%r12,%rcx,8), %r11
	movq	%rsi, %rcx
	subq	%r11, %rcx
	addq	%rax, %rcx
	cmpq	%rsi, %r11
	cmovl	%rcx, %rax
	cmpq	%r9, %rax
	jle	.L28
	cmpq	%rbx, %rax
	je	.L35
	movq	%rax, %r9
.L28:
	addq	$1, %r8
	cmpl	%r8d, %edi
	jge	.L29
.L25:
	movq	%r9, %rdx
	leaq	.LC0(%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
.L44:
	.cfi_restore_state
	leal	1(%rax), %edx
	jmp	.L23
.L32:
	xorl	%edx, %edx
	jmp	.L19
.L31:
	xorl	%esi, %esi
	jmp	.L17
.L35:
	movq	%rbx, %r9
	jmp	.L25
.L30:
	xorl	%ebx, %ebx
	jmp	.L14
.L34:
	xorl	%r9d, %r9d
	jmp	.L25
	.cfi_endproc
.LFE41:
	.size	main, .-main
	.globl	p
	.bss
	.align 8
	.type	p, @object
	.size	p, 8
p:
	.zero	8
	.globl	buf
	.align 32
	.type	buf, @object
	.size	buf, 50
buf:
	.zero	50
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 800008
a:
	.zero	800008
	.globl	N
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.globl	t
	.align 32
	.type	t, @object
	.size	t, 800008
t:
	.zero	800008
	.globl	s
	.align 32
	.type	s, @object
	.size	s, 800008
s:
	.zero	800008
	.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:

// AOJ 2801: Suntan
// 2017.11.20 bal4u@uu

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

long long s[100001], t[100001]; int N;
long long a[100001];

char buf[50], *p;
long long getlong()
{
	long long n = 0;
	while (*p >= '0') n = (n<<3) + (n<<1) + (*p++ & 0xf);
	return n;
}

int bsch(long long x)
{
	int m, l = 0, r = N+1;

    while (l < r) {
        m = (l + r) >> 1;
        if (t[m] < x) l = m + 1; else r = m;
    }
	return l-1;
}

int main()
{
	int i, k;
	long long ans, T, x, y;
	
	fgets(p=buf, 50, stdin), T = getlong();
	fgets(buf, 50, stdin), N = atoi(buf);
	for (i = 1; i <= N; i++) {
		fgets(p=buf, 50, stdin);
		s[i] = getlong(), p++, t[i] = getlong();
		a[i] = a[i-1] + (t[i]-s[i]);
	}
	s[N+1] = t[N+1] = 1LL << 62;

	ans = 0;
	for (k = bsch(T), i = 1; i <= N; i++) {
		x = s[i] + T; while (t[k+1] <= x) k++;
		y = a[k]-a[i-1];
		if (x > s[k+1]) y += x-s[k+1];
		if (y > ans) {
			ans = y;
			if (ans == T) break;
		}
	}
	printf("%lld\n", ans);
	return 0;
}
20
1
1 10
 20
1
0 7
 20
1
2 10
 20
1
3 7
 20
1
0 19
 20
1
0 12
 20
1
2 7
 20
1
4 10
 20
1
0 28
 20
0
0 12

9
 7
 8
 4
 19
 12
 5
 6
 20
 0

Given the following C code and unoptimized assembly code, your task is to generate highly optimized x86-64 assembly code.
C Code:

```c
// AOJ 2801: Suntan
// 2017.11.20 bal4u@uu

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

long long s[100001], t[100001]; int N;
long long a[100001];

char buf[50], *p;
long long getlong()
{
	long long n = 0;
	while (*p >= '0') n = (n<<3) + (n<<1) + (*p++ & 0xf);
	return n;
}

int bsch(long long x)
{
	int m, l = 0, r = N+1;

    while (l < r) {
        m = (l + r) >> 1;
        if (t[m] < x) l = m + 1; else r = m;
    }
	return l-1;
}

int main()
{
	int i, k;
	long long ans, T, x, y;
	
	fgets(p=buf, 50, stdin), T = getlong();
	fgets(buf, 50, stdin), N = atoi(buf);
	for (i = 1; i <= N; i++) {
		fgets(p=buf, 50, stdin);
		s[i] = getlong(), p++, t[i] = getlong();
		a[i] = a[i-1] + (t[i]-s[i]);
	}
	s[N+1] = t[N+1] = 1LL << 62;

	ans = 0;
	for (k = bsch(T), i = 1; i <= N; i++) {
		x = s[i] + T; while (t[k+1] <= x) k++;
		y = a[k]-a[i-1];
		if (x > s[k+1]) y += x-s[k+1];
		if (y > ans) {
			ans = y;
			if (ans == T) break;
		}
	}
	printf("%lld\n", ans);
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	s
	.bss
	.align 32
	.type	s, @object
	.size	s, 800008
s:
	.zero	800008
	.globl	t
	.align 32
	.type	t, @object
	.size	t, 800008
t:
	.zero	800008
	.globl	N
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 800008
a:
	.zero	800008
	.globl	buf
	.align 32
	.type	buf, @object
	.size	buf, 50
buf:
	.zero	50
	.globl	p
	.align 8
	.type	p, @object
	.size	p, 8
p:
	.zero	8
	.text
	.globl	getlong
	.type	getlong, @function
getlong:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	$0, -8(%rbp)
	jmp	.L2
.L3:
	movq	-8(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	movq	-8(%rbp), %rax
	addq	%rax, %rax
	leaq	(%rdx,%rax), %rcx
	movq	p(%rip), %rax
	leaq	1(%rax), %rdx
	movq	%rdx, p(%rip)
	movzbl	(%rax), %eax
	movsbq	%al, %rax
	andl	$15, %eax
	addq	%rcx, %rax
	movq	%rax, -8(%rbp)
.L2:
	movq	p(%rip), %rax
	movzbl	(%rax), %eax
	cmpb	$47, %al
	jg	.L3
	movq	-8(%rbp), %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	getlong, .-getlong
	.globl	bsch
	.type	bsch, @function
bsch:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, -12(%rbp)
	movl	N(%rip), %eax
	addl	$1, %eax
	movl	%eax, -8(%rbp)
	jmp	.L6
.L8:
	movl	-12(%rbp), %edx
	movl	-8(%rbp), %eax
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -24(%rbp)
	jle	.L7
	movl	-4(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -12(%rbp)
	jmp	.L6
.L7:
	movl	-4(%rbp), %eax
	movl	%eax, -8(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jl	.L8
	movl	-12(%rbp), %eax
	subl	$1, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	bsch, .-bsch
	.section	.rodata
.LC0:
	.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	$48, %rsp
	movq	stdin(%rip), %rdx
	leaq	buf(%rip), %rax
	movq	%rax, p(%rip)
	movq	p(%rip), %rax
	movl	$50, %esi
	movq	%rax, %rdi
	call	fgets@PLT
	movl	$0, %eax
	call	getlong
	movq	%rax, -16(%rbp)
	movq	stdin(%rip), %rax
	movq	%rax, %rdx
	movl	$50, %esi
	leaq	buf(%rip), %rax
	movq	%rax, %rdi
	call	fgets@PLT
	leaq	buf(%rip), %rax
	movq	%rax, %rdi
	call	atoi@PLT
	movl	%eax, N(%rip)
	movl	$1, -40(%rbp)
	jmp	.L11
.L12:
	movq	stdin(%rip), %rdx
	leaq	buf(%rip), %rax
	movq	%rax, p(%rip)
	movq	p(%rip), %rax
	movl	$50, %esi
	movq	%rax, %rdi
	call	fgets@PLT
	movl	$0, %eax
	call	getlong
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	p(%rip), %rax
	addq	$1, %rax
	movq	%rax, p(%rip)
	movl	$0, %eax
	call	getlong
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	t(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-40(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	leaq	(%rsi,%rax), %rcx
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	addl	$1, -40(%rbp)
.L11:
	movl	N(%rip), %eax
	cmpl	%eax, -40(%rbp)
	jle	.L12
	movl	N(%rip), %eax
	addl	$1, %eax
	movslq	%eax, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	t(%rip), %rdx
	movabsq	$4611686018427387904, %rsi
	movq	%rsi, (%rcx,%rdx)
	movl	N(%rip), %edx
	leal	1(%rdx), %ecx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	movslq	%ecx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	$0, -32(%rbp)
	movq	-16(%rbp), %rax
	movq	%rax, %rdi
	call	bsch
	movl	%eax, -36(%rbp)
	movl	$1, -40(%rbp)
	jmp	.L13
.L19:
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-16(%rbp), %rax
	addq	%rdx, %rax
	movq	%rax, -8(%rbp)
	jmp	.L14
.L15:
	addl	$1, -36(%rbp)
.L14:
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -8(%rbp)
	jge	.L15
	movl	-36(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-40(%rbp), %edx
	subl	$1, %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, -24(%rbp)
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -8(%rbp)
	jle	.L16
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-8(%rbp), %rax
	subq	%rdx, %rax
	addq	%rax, -24(%rbp)
.L16:
	movq	-24(%rbp), %rax
	cmpq	-32(%rbp), %rax
	jle	.L17
	movq	-24(%rbp), %rax
	movq	%rax, -32(%rbp)
	movq	-32(%rbp), %rax
	cmpq	-16(%rbp), %rax
	je	.L21
.L17:
	addl	$1, -40(%rbp)
.L13:
	movl	N(%rip), %eax
	cmpl	%eax, -40(%rbp)
	jle	.L19
	jmp	.L18
.L21:
	nop
.L18:
	movq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%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	s
	.bss
	.align 32
	.type	s, @object
	.size	s, 800008
s:
	.zero	800008
	.globl	t
	.align 32
	.type	t, @object
	.size	t, 800008
t:
	.zero	800008
	.globl	N
	.align 4
	.type	N, @object
	.size	N, 4
N:
	.zero	4
	.globl	a
	.align 32
	.type	a, @object
	.size	a, 800008
a:
	.zero	800008
	.globl	buf
	.align 32
	.type	buf, @object
	.size	buf, 50
buf:
	.zero	50
	.globl	p
	.align 8
	.type	p, @object
	.size	p, 8
p:
	.zero	8
	.text
	.globl	getlong
	.type	getlong, @function
getlong:
.LFB6:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	$0, -8(%rbp)
	jmp	.L2
.L3:
	movq	-8(%rbp), %rax
	leaq	0(,%rax,8), %rdx
	movq	-8(%rbp), %rax
	addq	%rax, %rax
	leaq	(%rdx,%rax), %rcx
	movq	p(%rip), %rax
	leaq	1(%rax), %rdx
	movq	%rdx, p(%rip)
	movzbl	(%rax), %eax
	movsbq	%al, %rax
	andl	$15, %eax
	addq	%rcx, %rax
	movq	%rax, -8(%rbp)
.L2:
	movq	p(%rip), %rax
	movzbl	(%rax), %eax
	cmpb	$47, %al
	jg	.L3
	movq	-8(%rbp), %rax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	getlong, .-getlong
	.globl	bsch
	.type	bsch, @function
bsch:
.LFB7:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movq	%rdi, -24(%rbp)
	movl	$0, -12(%rbp)
	movl	N(%rip), %eax
	addl	$1, %eax
	movl	%eax, -8(%rbp)
	jmp	.L6
.L8:
	movl	-12(%rbp), %edx
	movl	-8(%rbp), %eax
	addl	%edx, %eax
	sarl	%eax
	movl	%eax, -4(%rbp)
	movl	-4(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -24(%rbp)
	jle	.L7
	movl	-4(%rbp), %eax
	addl	$1, %eax
	movl	%eax, -12(%rbp)
	jmp	.L6
.L7:
	movl	-4(%rbp), %eax
	movl	%eax, -8(%rbp)
.L6:
	movl	-12(%rbp), %eax
	cmpl	-8(%rbp), %eax
	jl	.L8
	movl	-12(%rbp), %eax
	subl	$1, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	bsch, .-bsch
	.section	.rodata
.LC0:
	.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	$48, %rsp
	movq	stdin(%rip), %rdx
	leaq	buf(%rip), %rax
	movq	%rax, p(%rip)
	movq	p(%rip), %rax
	movl	$50, %esi
	movq	%rax, %rdi
	call	fgets@PLT
	movl	$0, %eax
	call	getlong
	movq	%rax, -16(%rbp)
	movq	stdin(%rip), %rax
	movq	%rax, %rdx
	movl	$50, %esi
	leaq	buf(%rip), %rax
	movq	%rax, %rdi
	call	fgets@PLT
	leaq	buf(%rip), %rax
	movq	%rax, %rdi
	call	atoi@PLT
	movl	%eax, N(%rip)
	movl	$1, -40(%rbp)
	jmp	.L11
.L12:
	movq	stdin(%rip), %rdx
	leaq	buf(%rip), %rax
	movq	%rax, p(%rip)
	movq	p(%rip), %rax
	movl	$50, %esi
	movq	%rax, %rdi
	call	fgets@PLT
	movl	$0, %eax
	call	getlong
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	p(%rip), %rax
	addq	$1, %rax
	movq	%rax, p(%rip)
	movl	$0, %eax
	call	getlong
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	t(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movl	-40(%rbp), %eax
	subl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rsi
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-40(%rbp), %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	leaq	(%rsi,%rax), %rcx
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	%rcx, (%rdx,%rax)
	addl	$1, -40(%rbp)
.L11:
	movl	N(%rip), %eax
	cmpl	%eax, -40(%rbp)
	jle	.L12
	movl	N(%rip), %eax
	addl	$1, %eax
	movslq	%eax, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	t(%rip), %rdx
	movabsq	$4611686018427387904, %rsi
	movq	%rsi, (%rcx,%rdx)
	movl	N(%rip), %edx
	leal	1(%rdx), %ecx
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	movslq	%ecx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	s(%rip), %rdx
	movq	%rax, (%rcx,%rdx)
	movq	$0, -32(%rbp)
	movq	-16(%rbp), %rax
	movq	%rax, %rdi
	call	bsch
	movl	%eax, -36(%rbp)
	movl	$1, -40(%rbp)
	jmp	.L13
.L19:
	movl	-40(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-16(%rbp), %rax
	addq	%rdx, %rax
	movq	%rax, -8(%rbp)
	jmp	.L14
.L15:
	addl	$1, -36(%rbp)
.L14:
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	t(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -8(%rbp)
	jge	.L15
	movl	-36(%rbp), %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	a(%rip), %rax
	movq	(%rdx,%rax), %rax
	movl	-40(%rbp), %edx
	subl	$1, %edx
	movslq	%edx, %rdx
	leaq	0(,%rdx,8), %rcx
	leaq	a(%rip), %rdx
	movq	(%rcx,%rdx), %rdx
	subq	%rdx, %rax
	movq	%rax, -24(%rbp)
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rax
	cmpq	%rax, -8(%rbp)
	jle	.L16
	movl	-36(%rbp), %eax
	addl	$1, %eax
	cltq
	leaq	0(,%rax,8), %rdx
	leaq	s(%rip), %rax
	movq	(%rdx,%rax), %rdx
	movq	-8(%rbp), %rax
	subq	%rdx, %rax
	addq	%rax, -24(%rbp)
.L16:
	movq	-24(%rbp), %rax
	cmpq	-32(%rbp), %rax
	jle	.L17
	movq	-24(%rbp), %rax
	movq	%rax, -32(%rbp)
	movq	-32(%rbp), %rax
	cmpq	-16(%rbp), %rax
	je	.L21
.L17:
	addl	$1, -40(%rbp)
.L13:
	movl	N(%rip), %eax
	cmpl	%eax, -40(%rbp)
	jle	.L19
	jmp	.L18
.L21:
	nop
.L18:
	movq	-32(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC0(%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:
