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<string.h>
#define LEN 100005
typedef struct part
{
    char name[100];
    int t;
}p;
p Q[LEN];
int head,tail,n;
void enqueue(p x)
{
    Q[tail]=x;
    tail=(tail+1)%LEN;
}
p dequeue()
{
    p x;
    x=Q[head];
    head=(head+1)%LEN;
    return x;
}
int compare(int a,int b){return a<b?a:b;}
int main()
{
    int elaps=0,c,q,i;
    p u;
    scanf("%d%d",&n,&c);
    for(i=1;i<=n;i++)
    {
        scanf("%s%d",Q[i].name,&Q[i].t);
    }
    head=1;
    tail=n+1;
    while(head!=tail)
    {u=dequeue();
    q=compare(c,u.t);
    u.t-=q;
    elaps+=q;
    if(u.t>0)
    {
        enqueue(u);
    }
    else printf("%s %d\n",u.name,elaps);}
return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	Q
	.bss
	.align 32
	.type	Q, @object
	.size	Q, 10400520
Q:
	.zero	10400520
	.globl	head
	.align 4
	.type	head, @object
	.size	head, 4
head:
	.zero	4
	.globl	tail
	.align 4
	.type	tail, @object
	.size	tail, 4
tail:
	.zero	4
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.text
	.globl	enqueue
	.type	enqueue, @function
enqueue:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	.cfi_offset 3, -24
	movl	tail(%rip), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	movq	%rax, %rdx
	leaq	Q(%rip), %rax
	movq	16(%rbp), %rcx
	movq	24(%rbp), %rbx
	movq	%rcx, (%rdx,%rax)
	movq	%rbx, 8(%rdx,%rax)
	movq	32(%rbp), %rcx
	movq	40(%rbp), %rbx
	movq	%rcx, 16(%rdx,%rax)
	movq	%rbx, 24(%rdx,%rax)
	movq	48(%rbp), %rcx
	movq	56(%rbp), %rbx
	movq	%rcx, 32(%rdx,%rax)
	movq	%rbx, 40(%rdx,%rax)
	movq	64(%rbp), %rcx
	movq	72(%rbp), %rbx
	movq	%rcx, 48(%rdx,%rax)
	movq	%rbx, 56(%rdx,%rax)
	movq	80(%rbp), %rcx
	movq	88(%rbp), %rbx
	movq	%rcx, 64(%rdx,%rax)
	movq	%rbx, 72(%rdx,%rax)
	movq	96(%rbp), %rcx
	movq	104(%rbp), %rbx
	movq	%rcx, 80(%rdx,%rax)
	movq	%rbx, 88(%rdx,%rax)
	movq	112(%rbp), %rcx
	movq	%rcx, 96(%rdx,%rax)
	movl	tail(%rip), %eax
	leal	1(%rax), %edx
	movslq	%edx, %rax
	imulq	$-1480358259, %rax, %rax
	shrq	$32, %rax
	addl	%edx, %eax
	sarl	$16, %eax
	movl	%edx, %ecx
	sarl	$31, %ecx
	subl	%ecx, %eax
	imull	$100005, %eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, tail(%rip)
	nop
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	enqueue, .-enqueue
	.globl	dequeue
	.type	dequeue, @function
dequeue:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$136, %rsp
	.cfi_offset 3, -24
	movq	%rdi, -136(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	movl	head(%rip), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	movq	%rax, %rdx
	leaq	Q(%rip), %rax
	movq	(%rdx,%rax), %rcx
	movq	8(%rdx,%rax), %rbx
	movq	%rcx, -128(%rbp)
	movq	%rbx, -120(%rbp)
	movq	16(%rdx,%rax), %rcx
	movq	24(%rdx,%rax), %rbx
	movq	%rcx, -112(%rbp)
	movq	%rbx, -104(%rbp)
	movq	32(%rdx,%rax), %rcx
	movq	40(%rdx,%rax), %rbx
	movq	%rcx, -96(%rbp)
	movq	%rbx, -88(%rbp)
	movq	48(%rdx,%rax), %rcx
	movq	56(%rdx,%rax), %rbx
	movq	%rcx, -80(%rbp)
	movq	%rbx, -72(%rbp)
	movq	64(%rdx,%rax), %rcx
	movq	72(%rdx,%rax), %rbx
	movq	%rcx, -64(%rbp)
	movq	%rbx, -56(%rbp)
	movq	80(%rdx,%rax), %rcx
	movq	88(%rdx,%rax), %rbx
	movq	%rcx, -48(%rbp)
	movq	%rbx, -40(%rbp)
	movq	96(%rdx,%rax), %rax
	movq	%rax, -32(%rbp)
	movl	head(%rip), %eax
	leal	1(%rax), %edx
	movslq	%edx, %rax
	imulq	$-1480358259, %rax, %rax
	shrq	$32, %rax
	addl	%edx, %eax
	sarl	$16, %eax
	movl	%edx, %ecx
	sarl	$31, %ecx
	subl	%ecx, %eax
	imull	$100005, %eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, head(%rip)
	movq	-136(%rbp), %rax
	movq	-128(%rbp), %rcx
	movq	-120(%rbp), %rbx
	movq	%rcx, (%rax)
	movq	%rbx, 8(%rax)
	movq	-112(%rbp), %rcx
	movq	-104(%rbp), %rbx
	movq	%rcx, 16(%rax)
	movq	%rbx, 24(%rax)
	movq	-96(%rbp), %rcx
	movq	-88(%rbp), %rbx
	movq	%rcx, 32(%rax)
	movq	%rbx, 40(%rax)
	movq	-80(%rbp), %rcx
	movq	-72(%rbp), %rbx
	movq	%rcx, 48(%rax)
	movq	%rbx, 56(%rax)
	movq	-64(%rbp), %rcx
	movq	-56(%rbp), %rbx
	movq	%rcx, 64(%rax)
	movq	%rbx, 72(%rax)
	movq	-48(%rbp), %rcx
	movq	-40(%rbp), %rbx
	movq	%rcx, 80(%rax)
	movq	%rbx, 88(%rax)
	movq	-32(%rbp), %rdx
	movq	%rdx, 96(%rax)
	movq	-24(%rbp), %rax
	subq	%fs:40, %rax
	je	.L4
	call	__stack_chk_fail@PLT
.L4:
	movq	-136(%rbp), %rax
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	dequeue, .-dequeue
	.globl	compare
	.type	compare, @function
compare:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-8(%rbp), %edx
	movl	-4(%rbp), %eax
	cmpl	%eax, %edx
	cmovle	%edx, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	compare, .-compare
	.section	.rodata
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%s%d"
.LC2:
	.string	"%s %d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB3:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$240, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -124(%rbp)
	leaq	-128(%rbp), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$1, -120(%rbp)
	jmp	.L8
.L9:
	movl	-120(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	96(%rax), %rdx
	leaq	Q(%rip), %rax
	addq	%rdx, %rax
	leaq	4(%rax), %rcx
	movl	-120(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	Q(%rip), %rdx
	addq	%rdx, %rax
	movq	%rcx, %rdx
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -120(%rbp)
.L8:
	movl	n(%rip), %eax
	cmpl	%eax, -120(%rbp)
	jle	.L9
	movl	$1, head(%rip)
	movl	n(%rip), %eax
	addl	$1, %eax
	movl	%eax, tail(%rip)
	jmp	.L10
.L12:
	leaq	-240(%rbp), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	dequeue
	movq	-240(%rbp), %rax
	movq	-232(%rbp), %rdx
	movq	%rax, -112(%rbp)
	movq	%rdx, -104(%rbp)
	movq	-224(%rbp), %rax
	movq	-216(%rbp), %rdx
	movq	%rax, -96(%rbp)
	movq	%rdx, -88(%rbp)
	movq	-208(%rbp), %rax
	movq	-200(%rbp), %rdx
	movq	%rax, -80(%rbp)
	movq	%rdx, -72(%rbp)
	movq	-192(%rbp), %rax
	movq	-184(%rbp), %rdx
	movq	%rax, -64(%rbp)
	movq	%rdx, -56(%rbp)
	movq	-176(%rbp), %rax
	movq	-168(%rbp), %rdx
	movq	%rax, -48(%rbp)
	movq	%rdx, -40(%rbp)
	movq	-160(%rbp), %rax
	movq	-152(%rbp), %rdx
	movq	%rax, -32(%rbp)
	movq	%rdx, -24(%rbp)
	movq	-144(%rbp), %rax
	movq	%rax, -16(%rbp)
	movl	-12(%rbp), %edx
	movl	-128(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	compare
	movl	%eax, -116(%rbp)
	movl	-12(%rbp), %eax
	subl	-116(%rbp), %eax
	movl	%eax, -12(%rbp)
	movl	-116(%rbp), %eax
	addl	%eax, -124(%rbp)
	movl	-12(%rbp), %eax
	testl	%eax, %eax
	jle	.L11
	subq	$8, %rsp
	pushq	-16(%rbp)
	pushq	-24(%rbp)
	pushq	-32(%rbp)
	pushq	-40(%rbp)
	pushq	-48(%rbp)
	pushq	-56(%rbp)
	pushq	-64(%rbp)
	pushq	-72(%rbp)
	pushq	-80(%rbp)
	pushq	-88(%rbp)
	pushq	-96(%rbp)
	pushq	-104(%rbp)
	pushq	-112(%rbp)
	call	enqueue
	addq	$112, %rsp
	jmp	.L10
.L11:
	movl	-124(%rbp), %edx
	leaq	-112(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L10:
	movl	head(%rip), %edx
	movl	tail(%rip), %eax
	cmpl	%eax, %edx
	jne	.L12
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L14
	call	__stack_chk_fail@PLT
.L14:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.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	enqueue
	.type	enqueue, @function
enqueue:
.LFB35:
	.cfi_startproc
	endbr64
	movslq	tail(%rip), %rax
	movdqu	8(%rsp), %xmm0
	movdqu	24(%rsp), %xmm1
	movdqu	40(%rsp), %xmm2
	leaq	(%rax,%rax,2), %rcx
	movq	%rax, %rdx
	movdqu	56(%rsp), %xmm3
	movdqu	72(%rsp), %xmm4
	leaq	(%rax,%rcx,4), %rcx
	leaq	Q(%rip), %rax
	movdqu	88(%rsp), %xmm5
	addl	$1, %edx
	leaq	(%rax,%rcx,8), %rax
	movq	104(%rsp), %rcx
	movups	%xmm0, (%rax)
	movq	%rcx, 96(%rax)
	movl	%edx, %ecx
	movups	%xmm1, 16(%rax)
	sarl	$31, %ecx
	movups	%xmm2, 32(%rax)
	movups	%xmm3, 48(%rax)
	movups	%xmm4, 64(%rax)
	movups	%xmm5, 80(%rax)
	movslq	%edx, %rax
	imulq	$-1480358259, %rax, %rax
	shrq	$32, %rax
	addl	%edx, %eax
	sarl	$16, %eax
	subl	%ecx, %eax
	imull	$100005, %eax, %eax
	subl	%eax, %edx
	movl	%edx, tail(%rip)
	ret
	.cfi_endproc
.LFE35:
	.size	enqueue, .-enqueue
	.p2align 4
	.globl	dequeue
	.type	dequeue, @function
dequeue:
.LFB36:
	.cfi_startproc
	endbr64
	subq	$120, %rsp
	.cfi_def_cfa_offset 128
	movq	%fs:40, %rax
	movq	%rax, 104(%rsp)
	xorl	%eax, %eax
	movslq	head(%rip), %rax
	leaq	(%rax,%rax,2), %rcx
	movq	%rax, %rdx
	leaq	(%rax,%rcx,4), %rcx
	leaq	Q(%rip), %rax
	addl	$1, %edx
	leaq	(%rax,%rcx,8), %rax
	movl	%edx, %esi
	movdqu	(%rax), %xmm5
	movdqu	16(%rax), %xmm4
	sarl	$31, %esi
	movdqu	32(%rax), %xmm3
	movdqu	48(%rax), %xmm2
	movdqu	64(%rax), %xmm1
	movdqu	80(%rax), %xmm0
	movups	%xmm5, (%rdi)
	movq	96(%rax), %rcx
	movslq	%edx, %rax
	movups	%xmm4, 16(%rdi)
	imulq	$-1480358259, %rax, %rax
	movups	%xmm3, 32(%rdi)
	movq	%rcx, 96(%rdi)
	movups	%xmm2, 48(%rdi)
	shrq	$32, %rax
	movups	%xmm1, 64(%rdi)
	addl	%edx, %eax
	movups	%xmm0, 80(%rdi)
	sarl	$16, %eax
	subl	%esi, %eax
	imull	$100005, %eax, %eax
	subl	%eax, %edx
	movl	%edx, head(%rip)
	movq	104(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L6
	movq	%rdi, %rax
	addq	$120, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
.L6:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE36:
	.size	dequeue, .-dequeue
	.p2align 4
	.globl	compare
	.type	compare, @function
compare:
.LFB37:
	.cfi_startproc
	endbr64
	cmpl	%edi, %esi
	movl	%edi, %eax
	cmovle	%esi, %eax
	ret
	.cfi_endproc
.LFE37:
	.size	compare, .-compare
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%s%d"
.LC2:
	.string	"%s %d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB38:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	n(%rip), %rsi
	leaq	.LC0(%rip), %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	subq	$352, %rsp
	.cfi_def_cfa_offset 384
	movq	%fs:40, %rax
	movq	%rax, 344(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	call	__isoc99_scanf@PLT
	movl	n(%rip), %edx
	testl	%edx, %edx
	jle	.L9
	leaq	104+Q(%rip), %rbx
	movl	$1, %ebp
	leaq	.LC1(%rip), %r12
	.p2align 4,,10
	.p2align 3
.L10:
	leaq	100(%rbx), %rdx
	movq	%rbx, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	n(%rip), %edx
	addl	$1, %ebp
	addq	$104, %rbx
	cmpl	%ebp, %edx
	jge	.L10
.L9:
	addl	$1, %edx
	xorl	%ebx, %ebx
	movl	$1, head(%rip)
	movl	$1, %eax
	movl	%edx, tail(%rip)
	leaq	Q(%rip), %rbp
	leaq	.LC2(%rip), %r12
	cmpl	$1, %edx
	je	.L14
	.p2align 4,,10
	.p2align 3
.L11:
	movslq	%eax, %rcx
	leaq	(%rcx,%rcx,2), %rsi
	leaq	(%rcx,%rsi,4), %rcx
	leaq	0(%rbp,%rcx,8), %rcx
	movq	96(%rcx), %rsi
	movdqu	(%rcx), %xmm5
	movdqu	16(%rcx), %xmm4
	movdqu	32(%rcx), %xmm3
	movdqu	48(%rcx), %xmm2
	movdqu	64(%rcx), %xmm1
	movq	%rsi, 112(%rsp)
	movdqu	80(%rcx), %xmm0
	leal	1(%rax), %ecx
	movq	%rsi, 336(%rsp)
	movslq	%ecx, %rax
	movl	%ecx, %edi
	movaps	%xmm5, 240(%rsp)
	imulq	$-1480358259, %rax, %rax
	sarl	$31, %edi
	movaps	%xmm4, 256(%rsp)
	movaps	%xmm3, 272(%rsp)
	movaps	%xmm2, 288(%rsp)
	shrq	$32, %rax
	movaps	%xmm1, 304(%rsp)
	addl	%ecx, %eax
	movaps	%xmm0, 320(%rsp)
	sarl	$16, %eax
	movaps	%xmm5, 16(%rsp)
	subl	%edi, %eax
	movaps	%xmm4, 32(%rsp)
	imull	$100005, %eax, %edi
	movl	%ecx, %eax
	movaps	%xmm3, 48(%rsp)
	movaps	%xmm2, 64(%rsp)
	movaps	%xmm1, 80(%rsp)
	subl	%edi, %eax
	movq	%rsi, %rdi
	movl	12(%rsp), %esi
	movaps	%xmm0, 96(%rsp)
	shrq	$32, %rdi
	movl	%eax, head(%rip)
	cmpl	%esi, %edi
	movq	%rdi, %rcx
	cmovle	%edi, %esi
	subl	%esi, %ecx
	addl	%esi, %ebx
	movl	%ecx, 116(%rsp)
	testl	%ecx, %ecx
	jle	.L12
	movslq	%edx, %rcx
	movq	112(%rsp), %rsi
	leaq	(%rcx,%rcx,2), %rdi
	leaq	(%rcx,%rdi,4), %rcx
	movq	%rsi, 336(%rsp)
	leaq	0(%rbp,%rcx,8), %rcx
	movq	%rsi, 96(%rcx)
	movups	%xmm5, (%rcx)
	movups	%xmm4, 16(%rcx)
	movups	%xmm3, 32(%rcx)
	movups	%xmm2, 48(%rcx)
	movups	%xmm1, 64(%rcx)
	movups	%xmm0, 80(%rcx)
	leal	1(%rdx), %ecx
	movslq	%ecx, %rdx
	movl	%ecx, %esi
	imulq	$-1480358259, %rdx, %rdx
	sarl	$31, %esi
	shrq	$32, %rdx
	addl	%ecx, %edx
	sarl	$16, %edx
	subl	%esi, %edx
	imull	$100005, %edx, %esi
	movl	%ecx, %edx
	subl	%esi, %edx
	movl	%edx, tail(%rip)
	cmpl	%eax, %edx
	jne	.L11
.L14:
	movq	344(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L21
	addq	$352, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L12:
	.cfi_restore_state
	leaq	16(%rsp), %rdx
	movl	%ebx, %ecx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	head(%rip), %eax
	movl	tail(%rip), %edx
	cmpl	%edx, %eax
	jne	.L11
	jmp	.L14
.L21:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE38:
	.size	main, .-main
	.globl	n
	.bss
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	tail
	.align 4
	.type	tail, @object
	.size	tail, 4
tail:
	.zero	4
	.globl	head
	.align 4
	.type	head, @object
	.size	head, 4
head:
	.zero	4
	.globl	Q
	.align 32
	.type	Q, @object
	.size	Q, 10400520
Q:
	.zero	10400520
	.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	enqueue
	.type	enqueue, @function
enqueue:
.LFB35:
	.cfi_startproc
	endbr64
	movslq	tail(%rip), %rax
	movdqu	8(%rsp), %xmm0
	movdqu	24(%rsp), %xmm1
	movdqu	40(%rsp), %xmm2
	leaq	(%rax,%rax,2), %rcx
	movq	%rax, %rdx
	movdqu	56(%rsp), %xmm3
	movdqu	72(%rsp), %xmm4
	leaq	(%rax,%rcx,4), %rcx
	leaq	Q(%rip), %rax
	movdqu	88(%rsp), %xmm5
	addl	$1, %edx
	leaq	(%rax,%rcx,8), %rax
	movq	104(%rsp), %rcx
	movups	%xmm0, (%rax)
	movq	%rcx, 96(%rax)
	movl	%edx, %ecx
	movups	%xmm1, 16(%rax)
	sarl	$31, %ecx
	movups	%xmm2, 32(%rax)
	movups	%xmm3, 48(%rax)
	movups	%xmm4, 64(%rax)
	movups	%xmm5, 80(%rax)
	movslq	%edx, %rax
	imulq	$-1480358259, %rax, %rax
	shrq	$32, %rax
	addl	%edx, %eax
	sarl	$16, %eax
	subl	%ecx, %eax
	imull	$100005, %eax, %eax
	subl	%eax, %edx
	movl	%edx, tail(%rip)
	ret
	.cfi_endproc
.LFE35:
	.size	enqueue, .-enqueue
	.p2align 4
	.globl	dequeue
	.type	dequeue, @function
dequeue:
.LFB36:
	.cfi_startproc
	endbr64
	subq	$120, %rsp
	.cfi_def_cfa_offset 128
	movq	%fs:40, %rax
	movq	%rax, 104(%rsp)
	xorl	%eax, %eax
	movslq	head(%rip), %rax
	leaq	(%rax,%rax,2), %rcx
	movq	%rax, %rdx
	leaq	(%rax,%rcx,4), %rcx
	leaq	Q(%rip), %rax
	addl	$1, %edx
	leaq	(%rax,%rcx,8), %rax
	movl	%edx, %esi
	movdqu	(%rax), %xmm5
	movdqu	16(%rax), %xmm4
	sarl	$31, %esi
	movdqu	32(%rax), %xmm3
	movdqu	48(%rax), %xmm2
	movdqu	64(%rax), %xmm1
	movdqu	80(%rax), %xmm0
	movups	%xmm5, (%rdi)
	movq	96(%rax), %rcx
	movslq	%edx, %rax
	movups	%xmm4, 16(%rdi)
	imulq	$-1480358259, %rax, %rax
	movups	%xmm3, 32(%rdi)
	movq	%rcx, 96(%rdi)
	movups	%xmm2, 48(%rdi)
	shrq	$32, %rax
	movups	%xmm1, 64(%rdi)
	addl	%edx, %eax
	movups	%xmm0, 80(%rdi)
	sarl	$16, %eax
	subl	%esi, %eax
	imull	$100005, %eax, %eax
	subl	%eax, %edx
	movl	%edx, head(%rip)
	movq	104(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L6
	movq	%rdi, %rax
	addq	$120, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
.L6:
	.cfi_restore_state
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE36:
	.size	dequeue, .-dequeue
	.p2align 4
	.globl	compare
	.type	compare, @function
compare:
.LFB37:
	.cfi_startproc
	endbr64
	cmpl	%edi, %esi
	movl	%edi, %eax
	cmovle	%esi, %eax
	ret
	.cfi_endproc
.LFE37:
	.size	compare, .-compare
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%s%d"
.LC2:
	.string	"%s %d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB38:
	.cfi_startproc
	endbr64
	pushq	%r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	leaq	n(%rip), %rsi
	leaq	.LC0(%rip), %rdi
	pushq	%rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	pushq	%rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	subq	$352, %rsp
	.cfi_def_cfa_offset 384
	movq	%fs:40, %rax
	movq	%rax, 344(%rsp)
	xorl	%eax, %eax
	leaq	12(%rsp), %rdx
	call	__isoc99_scanf@PLT
	movl	n(%rip), %edx
	testl	%edx, %edx
	jle	.L9
	leaq	104+Q(%rip), %rbx
	movl	$1, %ebp
	leaq	.LC1(%rip), %r12
	.p2align 4,,10
	.p2align 3
.L10:
	leaq	100(%rbx), %rdx
	movq	%rbx, %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	n(%rip), %edx
	addl	$1, %ebp
	addq	$104, %rbx
	cmpl	%ebp, %edx
	jge	.L10
.L9:
	addl	$1, %edx
	xorl	%ebx, %ebx
	movl	$1, head(%rip)
	movl	$1, %eax
	movl	%edx, tail(%rip)
	leaq	Q(%rip), %rbp
	leaq	.LC2(%rip), %r12
	cmpl	$1, %edx
	je	.L14
	.p2align 4,,10
	.p2align 3
.L11:
	movslq	%eax, %rcx
	leaq	(%rcx,%rcx,2), %rsi
	leaq	(%rcx,%rsi,4), %rcx
	leaq	0(%rbp,%rcx,8), %rcx
	movq	96(%rcx), %rsi
	movdqu	(%rcx), %xmm5
	movdqu	16(%rcx), %xmm4
	movdqu	32(%rcx), %xmm3
	movdqu	48(%rcx), %xmm2
	movdqu	64(%rcx), %xmm1
	movq	%rsi, 112(%rsp)
	movdqu	80(%rcx), %xmm0
	leal	1(%rax), %ecx
	movq	%rsi, 336(%rsp)
	movslq	%ecx, %rax
	movl	%ecx, %edi
	movaps	%xmm5, 240(%rsp)
	imulq	$-1480358259, %rax, %rax
	sarl	$31, %edi
	movaps	%xmm4, 256(%rsp)
	movaps	%xmm3, 272(%rsp)
	movaps	%xmm2, 288(%rsp)
	shrq	$32, %rax
	movaps	%xmm1, 304(%rsp)
	addl	%ecx, %eax
	movaps	%xmm0, 320(%rsp)
	sarl	$16, %eax
	movaps	%xmm5, 16(%rsp)
	subl	%edi, %eax
	movaps	%xmm4, 32(%rsp)
	imull	$100005, %eax, %edi
	movl	%ecx, %eax
	movaps	%xmm3, 48(%rsp)
	movaps	%xmm2, 64(%rsp)
	movaps	%xmm1, 80(%rsp)
	subl	%edi, %eax
	movq	%rsi, %rdi
	movl	12(%rsp), %esi
	movaps	%xmm0, 96(%rsp)
	shrq	$32, %rdi
	movl	%eax, head(%rip)
	cmpl	%esi, %edi
	movq	%rdi, %rcx
	cmovle	%edi, %esi
	subl	%esi, %ecx
	addl	%esi, %ebx
	movl	%ecx, 116(%rsp)
	testl	%ecx, %ecx
	jle	.L12
	movslq	%edx, %rcx
	movq	112(%rsp), %rsi
	leaq	(%rcx,%rcx,2), %rdi
	leaq	(%rcx,%rdi,4), %rcx
	movq	%rsi, 336(%rsp)
	leaq	0(%rbp,%rcx,8), %rcx
	movq	%rsi, 96(%rcx)
	movups	%xmm5, (%rcx)
	movups	%xmm4, 16(%rcx)
	movups	%xmm3, 32(%rcx)
	movups	%xmm2, 48(%rcx)
	movups	%xmm1, 64(%rcx)
	movups	%xmm0, 80(%rcx)
	leal	1(%rdx), %ecx
	movslq	%ecx, %rdx
	movl	%ecx, %esi
	imulq	$-1480358259, %rdx, %rdx
	sarl	$31, %esi
	shrq	$32, %rdx
	addl	%ecx, %edx
	sarl	$16, %edx
	subl	%esi, %edx
	imull	$100005, %edx, %esi
	movl	%ecx, %edx
	subl	%esi, %edx
	movl	%edx, tail(%rip)
	cmpl	%eax, %edx
	jne	.L11
.L14:
	movq	344(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L21
	addq	$352, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 24
	popq	%rbp
	.cfi_def_cfa_offset 16
	popq	%r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L12:
	.cfi_restore_state
	leaq	16(%rsp), %rdx
	movl	%ebx, %ecx
	movq	%r12, %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	movl	head(%rip), %eax
	movl	tail(%rip), %edx
	cmpl	%edx, %eax
	jne	.L11
	jmp	.L14
.L21:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE38:
	.size	main, .-main
	.globl	n
	.bss
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	tail
	.align 4
	.type	tail, @object
	.size	tail, 4
tail:
	.zero	4
	.globl	head
	.align 4
	.type	head, @object
	.size	head, 4
head:
	.zero	4
	.globl	Q
	.align 32
	.type	Q, @object
	.size	Q, 10400520
Q:
	.zero	10400520
	.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<string.h>
#define LEN 100005
typedef struct part
{
    char name[100];
    int t;
}p;
p Q[LEN];
int head,tail,n;
void enqueue(p x)
{
    Q[tail]=x;
    tail=(tail+1)%LEN;
}
p dequeue()
{
    p x;
    x=Q[head];
    head=(head+1)%LEN;
    return x;
}
int compare(int a,int b){return a<b?a:b;}
int main()
{
    int elaps=0,c,q,i;
    p u;
    scanf("%d%d",&n,&c);
    for(i=1;i<=n;i++)
    {
        scanf("%s%d",Q[i].name,&Q[i].t);
    }
    head=1;
    tail=n+1;
    while(head!=tail)
    {u=dequeue();
    q=compare(c,u.t);
    u.t-=q;
    elaps+=q;
    if(u.t>0)
    {
        enqueue(u);
    }
    else printf("%s %d\n",u.name,elaps);}
return 0;
}

5 100
p1 150
p2 80
p3 200
p4 350
p5 14
 5 100
p1 150
2p 80
p3 200
p4 350
p5 14
 4 100
p1 150
2p 80
p3 200
p4 350
p5 14
 3 100
p1 150
2p 80
p3 200
p4 350
p5 14
 5 100
p1 150
p2 125
p3 200
p4 350
p5 20
 4 100
p1 150
p2 80
p3 200
p4 350
p5 14
 5 100
p1 150
2p 80
3p 200
p4 350
p5 14
 4 100
p1 150
2p 80
p2 200
p4 350
p5 14
 3 100
p1 150
p2 80
p3 200
p4 350
p5 14
 5 100
p1 150
p2 216
p3 200
p4 350
p5 20

p2 180
p5 394
p1 444
p3 544
p4 794
 2p 180
p5 394
p1 444
p3 544
p4 794
 2p 180
p1 430
p3 530
p4 780
 2p 180
p1 330
p3 430
 p5 420
p1 470
p2 495
p3 595
p4 845
 p2 180
p1 430
p3 530
p4 780
 2p 180
p5 394
p1 444
3p 544
p4 794
 2p 180
p1 430
p2 530
p4 780
 p2 180
p1 330
p3 430
 p5 420
p1 470
p3 670
p2 786
p4 936

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<string.h>
#define LEN 100005
typedef struct part
{
    char name[100];
    int t;
}p;
p Q[LEN];
int head,tail,n;
void enqueue(p x)
{
    Q[tail]=x;
    tail=(tail+1)%LEN;
}
p dequeue()
{
    p x;
    x=Q[head];
    head=(head+1)%LEN;
    return x;
}
int compare(int a,int b){return a<b?a:b;}
int main()
{
    int elaps=0,c,q,i;
    p u;
    scanf("%d%d",&n,&c);
    for(i=1;i<=n;i++)
    {
        scanf("%s%d",Q[i].name,&Q[i].t);
    }
    head=1;
    tail=n+1;
    while(head!=tail)
    {u=dequeue();
    q=compare(c,u.t);
    u.t-=q;
    elaps+=q;
    if(u.t>0)
    {
        enqueue(u);
    }
    else printf("%s %d\n",u.name,elaps);}
return 0;
}
```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	Q
	.bss
	.align 32
	.type	Q, @object
	.size	Q, 10400520
Q:
	.zero	10400520
	.globl	head
	.align 4
	.type	head, @object
	.size	head, 4
head:
	.zero	4
	.globl	tail
	.align 4
	.type	tail, @object
	.size	tail, 4
tail:
	.zero	4
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.text
	.globl	enqueue
	.type	enqueue, @function
enqueue:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	.cfi_offset 3, -24
	movl	tail(%rip), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	movq	%rax, %rdx
	leaq	Q(%rip), %rax
	movq	16(%rbp), %rcx
	movq	24(%rbp), %rbx
	movq	%rcx, (%rdx,%rax)
	movq	%rbx, 8(%rdx,%rax)
	movq	32(%rbp), %rcx
	movq	40(%rbp), %rbx
	movq	%rcx, 16(%rdx,%rax)
	movq	%rbx, 24(%rdx,%rax)
	movq	48(%rbp), %rcx
	movq	56(%rbp), %rbx
	movq	%rcx, 32(%rdx,%rax)
	movq	%rbx, 40(%rdx,%rax)
	movq	64(%rbp), %rcx
	movq	72(%rbp), %rbx
	movq	%rcx, 48(%rdx,%rax)
	movq	%rbx, 56(%rdx,%rax)
	movq	80(%rbp), %rcx
	movq	88(%rbp), %rbx
	movq	%rcx, 64(%rdx,%rax)
	movq	%rbx, 72(%rdx,%rax)
	movq	96(%rbp), %rcx
	movq	104(%rbp), %rbx
	movq	%rcx, 80(%rdx,%rax)
	movq	%rbx, 88(%rdx,%rax)
	movq	112(%rbp), %rcx
	movq	%rcx, 96(%rdx,%rax)
	movl	tail(%rip), %eax
	leal	1(%rax), %edx
	movslq	%edx, %rax
	imulq	$-1480358259, %rax, %rax
	shrq	$32, %rax
	addl	%edx, %eax
	sarl	$16, %eax
	movl	%edx, %ecx
	sarl	$31, %ecx
	subl	%ecx, %eax
	imull	$100005, %eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, tail(%rip)
	nop
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	enqueue, .-enqueue
	.globl	dequeue
	.type	dequeue, @function
dequeue:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$136, %rsp
	.cfi_offset 3, -24
	movq	%rdi, -136(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	movl	head(%rip), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	movq	%rax, %rdx
	leaq	Q(%rip), %rax
	movq	(%rdx,%rax), %rcx
	movq	8(%rdx,%rax), %rbx
	movq	%rcx, -128(%rbp)
	movq	%rbx, -120(%rbp)
	movq	16(%rdx,%rax), %rcx
	movq	24(%rdx,%rax), %rbx
	movq	%rcx, -112(%rbp)
	movq	%rbx, -104(%rbp)
	movq	32(%rdx,%rax), %rcx
	movq	40(%rdx,%rax), %rbx
	movq	%rcx, -96(%rbp)
	movq	%rbx, -88(%rbp)
	movq	48(%rdx,%rax), %rcx
	movq	56(%rdx,%rax), %rbx
	movq	%rcx, -80(%rbp)
	movq	%rbx, -72(%rbp)
	movq	64(%rdx,%rax), %rcx
	movq	72(%rdx,%rax), %rbx
	movq	%rcx, -64(%rbp)
	movq	%rbx, -56(%rbp)
	movq	80(%rdx,%rax), %rcx
	movq	88(%rdx,%rax), %rbx
	movq	%rcx, -48(%rbp)
	movq	%rbx, -40(%rbp)
	movq	96(%rdx,%rax), %rax
	movq	%rax, -32(%rbp)
	movl	head(%rip), %eax
	leal	1(%rax), %edx
	movslq	%edx, %rax
	imulq	$-1480358259, %rax, %rax
	shrq	$32, %rax
	addl	%edx, %eax
	sarl	$16, %eax
	movl	%edx, %ecx
	sarl	$31, %ecx
	subl	%ecx, %eax
	imull	$100005, %eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, head(%rip)
	movq	-136(%rbp), %rax
	movq	-128(%rbp), %rcx
	movq	-120(%rbp), %rbx
	movq	%rcx, (%rax)
	movq	%rbx, 8(%rax)
	movq	-112(%rbp), %rcx
	movq	-104(%rbp), %rbx
	movq	%rcx, 16(%rax)
	movq	%rbx, 24(%rax)
	movq	-96(%rbp), %rcx
	movq	-88(%rbp), %rbx
	movq	%rcx, 32(%rax)
	movq	%rbx, 40(%rax)
	movq	-80(%rbp), %rcx
	movq	-72(%rbp), %rbx
	movq	%rcx, 48(%rax)
	movq	%rbx, 56(%rax)
	movq	-64(%rbp), %rcx
	movq	-56(%rbp), %rbx
	movq	%rcx, 64(%rax)
	movq	%rbx, 72(%rax)
	movq	-48(%rbp), %rcx
	movq	-40(%rbp), %rbx
	movq	%rcx, 80(%rax)
	movq	%rbx, 88(%rax)
	movq	-32(%rbp), %rdx
	movq	%rdx, 96(%rax)
	movq	-24(%rbp), %rax
	subq	%fs:40, %rax
	je	.L4
	call	__stack_chk_fail@PLT
.L4:
	movq	-136(%rbp), %rax
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	dequeue, .-dequeue
	.globl	compare
	.type	compare, @function
compare:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-8(%rbp), %edx
	movl	-4(%rbp), %eax
	cmpl	%eax, %edx
	cmovle	%edx, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	compare, .-compare
	.section	.rodata
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%s%d"
.LC2:
	.string	"%s %d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB3:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$240, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -124(%rbp)
	leaq	-128(%rbp), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$1, -120(%rbp)
	jmp	.L8
.L9:
	movl	-120(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	96(%rax), %rdx
	leaq	Q(%rip), %rax
	addq	%rdx, %rax
	leaq	4(%rax), %rcx
	movl	-120(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	Q(%rip), %rdx
	addq	%rdx, %rax
	movq	%rcx, %rdx
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -120(%rbp)
.L8:
	movl	n(%rip), %eax
	cmpl	%eax, -120(%rbp)
	jle	.L9
	movl	$1, head(%rip)
	movl	n(%rip), %eax
	addl	$1, %eax
	movl	%eax, tail(%rip)
	jmp	.L10
.L12:
	leaq	-240(%rbp), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	dequeue
	movq	-240(%rbp), %rax
	movq	-232(%rbp), %rdx
	movq	%rax, -112(%rbp)
	movq	%rdx, -104(%rbp)
	movq	-224(%rbp), %rax
	movq	-216(%rbp), %rdx
	movq	%rax, -96(%rbp)
	movq	%rdx, -88(%rbp)
	movq	-208(%rbp), %rax
	movq	-200(%rbp), %rdx
	movq	%rax, -80(%rbp)
	movq	%rdx, -72(%rbp)
	movq	-192(%rbp), %rax
	movq	-184(%rbp), %rdx
	movq	%rax, -64(%rbp)
	movq	%rdx, -56(%rbp)
	movq	-176(%rbp), %rax
	movq	-168(%rbp), %rdx
	movq	%rax, -48(%rbp)
	movq	%rdx, -40(%rbp)
	movq	-160(%rbp), %rax
	movq	-152(%rbp), %rdx
	movq	%rax, -32(%rbp)
	movq	%rdx, -24(%rbp)
	movq	-144(%rbp), %rax
	movq	%rax, -16(%rbp)
	movl	-12(%rbp), %edx
	movl	-128(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	compare
	movl	%eax, -116(%rbp)
	movl	-12(%rbp), %eax
	subl	-116(%rbp), %eax
	movl	%eax, -12(%rbp)
	movl	-116(%rbp), %eax
	addl	%eax, -124(%rbp)
	movl	-12(%rbp), %eax
	testl	%eax, %eax
	jle	.L11
	subq	$8, %rsp
	pushq	-16(%rbp)
	pushq	-24(%rbp)
	pushq	-32(%rbp)
	pushq	-40(%rbp)
	pushq	-48(%rbp)
	pushq	-56(%rbp)
	pushq	-64(%rbp)
	pushq	-72(%rbp)
	pushq	-80(%rbp)
	pushq	-88(%rbp)
	pushq	-96(%rbp)
	pushq	-104(%rbp)
	pushq	-112(%rbp)
	call	enqueue
	addq	$112, %rsp
	jmp	.L10
.L11:
	movl	-124(%rbp), %edx
	leaq	-112(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L10:
	movl	head(%rip), %edx
	movl	tail(%rip), %eax
	cmpl	%eax, %edx
	jne	.L12
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L14
	call	__stack_chk_fail@PLT
.L14:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.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	Q
	.bss
	.align 32
	.type	Q, @object
	.size	Q, 10400520
Q:
	.zero	10400520
	.globl	head
	.align 4
	.type	head, @object
	.size	head, 4
head:
	.zero	4
	.globl	tail
	.align 4
	.type	tail, @object
	.size	tail, 4
tail:
	.zero	4
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.text
	.globl	enqueue
	.type	enqueue, @function
enqueue:
.LFB0:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	.cfi_offset 3, -24
	movl	tail(%rip), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	movq	%rax, %rdx
	leaq	Q(%rip), %rax
	movq	16(%rbp), %rcx
	movq	24(%rbp), %rbx
	movq	%rcx, (%rdx,%rax)
	movq	%rbx, 8(%rdx,%rax)
	movq	32(%rbp), %rcx
	movq	40(%rbp), %rbx
	movq	%rcx, 16(%rdx,%rax)
	movq	%rbx, 24(%rdx,%rax)
	movq	48(%rbp), %rcx
	movq	56(%rbp), %rbx
	movq	%rcx, 32(%rdx,%rax)
	movq	%rbx, 40(%rdx,%rax)
	movq	64(%rbp), %rcx
	movq	72(%rbp), %rbx
	movq	%rcx, 48(%rdx,%rax)
	movq	%rbx, 56(%rdx,%rax)
	movq	80(%rbp), %rcx
	movq	88(%rbp), %rbx
	movq	%rcx, 64(%rdx,%rax)
	movq	%rbx, 72(%rdx,%rax)
	movq	96(%rbp), %rcx
	movq	104(%rbp), %rbx
	movq	%rcx, 80(%rdx,%rax)
	movq	%rbx, 88(%rdx,%rax)
	movq	112(%rbp), %rcx
	movq	%rcx, 96(%rdx,%rax)
	movl	tail(%rip), %eax
	leal	1(%rax), %edx
	movslq	%edx, %rax
	imulq	$-1480358259, %rax, %rax
	shrq	$32, %rax
	addl	%edx, %eax
	sarl	$16, %eax
	movl	%edx, %ecx
	sarl	$31, %ecx
	subl	%ecx, %eax
	imull	$100005, %eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, tail(%rip)
	nop
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	enqueue, .-enqueue
	.globl	dequeue
	.type	dequeue, @function
dequeue:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	pushq	%rbx
	subq	$136, %rsp
	.cfi_offset 3, -24
	movq	%rdi, -136(%rbp)
	movq	%fs:40, %rax
	movq	%rax, -24(%rbp)
	xorl	%eax, %eax
	movl	head(%rip), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	movq	%rax, %rdx
	leaq	Q(%rip), %rax
	movq	(%rdx,%rax), %rcx
	movq	8(%rdx,%rax), %rbx
	movq	%rcx, -128(%rbp)
	movq	%rbx, -120(%rbp)
	movq	16(%rdx,%rax), %rcx
	movq	24(%rdx,%rax), %rbx
	movq	%rcx, -112(%rbp)
	movq	%rbx, -104(%rbp)
	movq	32(%rdx,%rax), %rcx
	movq	40(%rdx,%rax), %rbx
	movq	%rcx, -96(%rbp)
	movq	%rbx, -88(%rbp)
	movq	48(%rdx,%rax), %rcx
	movq	56(%rdx,%rax), %rbx
	movq	%rcx, -80(%rbp)
	movq	%rbx, -72(%rbp)
	movq	64(%rdx,%rax), %rcx
	movq	72(%rdx,%rax), %rbx
	movq	%rcx, -64(%rbp)
	movq	%rbx, -56(%rbp)
	movq	80(%rdx,%rax), %rcx
	movq	88(%rdx,%rax), %rbx
	movq	%rcx, -48(%rbp)
	movq	%rbx, -40(%rbp)
	movq	96(%rdx,%rax), %rax
	movq	%rax, -32(%rbp)
	movl	head(%rip), %eax
	leal	1(%rax), %edx
	movslq	%edx, %rax
	imulq	$-1480358259, %rax, %rax
	shrq	$32, %rax
	addl	%edx, %eax
	sarl	$16, %eax
	movl	%edx, %ecx
	sarl	$31, %ecx
	subl	%ecx, %eax
	imull	$100005, %eax, %ecx
	movl	%edx, %eax
	subl	%ecx, %eax
	movl	%eax, head(%rip)
	movq	-136(%rbp), %rax
	movq	-128(%rbp), %rcx
	movq	-120(%rbp), %rbx
	movq	%rcx, (%rax)
	movq	%rbx, 8(%rax)
	movq	-112(%rbp), %rcx
	movq	-104(%rbp), %rbx
	movq	%rcx, 16(%rax)
	movq	%rbx, 24(%rax)
	movq	-96(%rbp), %rcx
	movq	-88(%rbp), %rbx
	movq	%rcx, 32(%rax)
	movq	%rbx, 40(%rax)
	movq	-80(%rbp), %rcx
	movq	-72(%rbp), %rbx
	movq	%rcx, 48(%rax)
	movq	%rbx, 56(%rax)
	movq	-64(%rbp), %rcx
	movq	-56(%rbp), %rbx
	movq	%rcx, 64(%rax)
	movq	%rbx, 72(%rax)
	movq	-48(%rbp), %rcx
	movq	-40(%rbp), %rbx
	movq	%rcx, 80(%rax)
	movq	%rbx, 88(%rax)
	movq	-32(%rbp), %rdx
	movq	%rdx, 96(%rax)
	movq	-24(%rbp), %rax
	subq	%fs:40, %rax
	je	.L4
	call	__stack_chk_fail@PLT
.L4:
	movq	-136(%rbp), %rax
	movq	-8(%rbp), %rbx
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	dequeue, .-dequeue
	.globl	compare
	.type	compare, @function
compare:
.LFB2:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	movl	%edi, -4(%rbp)
	movl	%esi, -8(%rbp)
	movl	-8(%rbp), %edx
	movl	-4(%rbp), %eax
	cmpl	%eax, %edx
	cmovle	%edx, %eax
	popq	%rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	compare, .-compare
	.section	.rodata
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%s%d"
.LC2:
	.string	"%s %d\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB3:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$240, %rsp
	movq	%fs:40, %rax
	movq	%rax, -8(%rbp)
	xorl	%eax, %eax
	movl	$0, -124(%rbp)
	leaq	-128(%rbp), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	$1, -120(%rbp)
	jmp	.L8
.L9:
	movl	-120(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	96(%rax), %rdx
	leaq	Q(%rip), %rax
	addq	%rdx, %rax
	leaq	4(%rax), %rcx
	movl	-120(%rbp), %eax
	movslq	%eax, %rdx
	movq	%rdx, %rax
	addq	%rax, %rax
	addq	%rdx, %rax
	salq	$2, %rax
	addq	%rdx, %rax
	salq	$3, %rax
	leaq	Q(%rip), %rdx
	addq	%rdx, %rax
	movq	%rcx, %rdx
	movq	%rax, %rsi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	addl	$1, -120(%rbp)
.L8:
	movl	n(%rip), %eax
	cmpl	%eax, -120(%rbp)
	jle	.L9
	movl	$1, head(%rip)
	movl	n(%rip), %eax
	addl	$1, %eax
	movl	%eax, tail(%rip)
	jmp	.L10
.L12:
	leaq	-240(%rbp), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	dequeue
	movq	-240(%rbp), %rax
	movq	-232(%rbp), %rdx
	movq	%rax, -112(%rbp)
	movq	%rdx, -104(%rbp)
	movq	-224(%rbp), %rax
	movq	-216(%rbp), %rdx
	movq	%rax, -96(%rbp)
	movq	%rdx, -88(%rbp)
	movq	-208(%rbp), %rax
	movq	-200(%rbp), %rdx
	movq	%rax, -80(%rbp)
	movq	%rdx, -72(%rbp)
	movq	-192(%rbp), %rax
	movq	-184(%rbp), %rdx
	movq	%rax, -64(%rbp)
	movq	%rdx, -56(%rbp)
	movq	-176(%rbp), %rax
	movq	-168(%rbp), %rdx
	movq	%rax, -48(%rbp)
	movq	%rdx, -40(%rbp)
	movq	-160(%rbp), %rax
	movq	-152(%rbp), %rdx
	movq	%rax, -32(%rbp)
	movq	%rdx, -24(%rbp)
	movq	-144(%rbp), %rax
	movq	%rax, -16(%rbp)
	movl	-12(%rbp), %edx
	movl	-128(%rbp), %eax
	movl	%edx, %esi
	movl	%eax, %edi
	call	compare
	movl	%eax, -116(%rbp)
	movl	-12(%rbp), %eax
	subl	-116(%rbp), %eax
	movl	%eax, -12(%rbp)
	movl	-116(%rbp), %eax
	addl	%eax, -124(%rbp)
	movl	-12(%rbp), %eax
	testl	%eax, %eax
	jle	.L11
	subq	$8, %rsp
	pushq	-16(%rbp)
	pushq	-24(%rbp)
	pushq	-32(%rbp)
	pushq	-40(%rbp)
	pushq	-48(%rbp)
	pushq	-56(%rbp)
	pushq	-64(%rbp)
	pushq	-72(%rbp)
	pushq	-80(%rbp)
	pushq	-88(%rbp)
	pushq	-96(%rbp)
	pushq	-104(%rbp)
	pushq	-112(%rbp)
	call	enqueue
	addq	$112, %rsp
	jmp	.L10
.L11:
	movl	-124(%rbp), %edx
	leaq	-112(%rbp), %rax
	movq	%rax, %rsi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
.L10:
	movl	head(%rip), %edx
	movl	tail(%rip), %eax
	cmpl	%eax, %edx
	jne	.L12
	movl	$0, %eax
	movq	-8(%rbp), %rdx
	subq	%fs:40, %rdx
	je	.L14
	call	__stack_chk_fail@PLT
.L14:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.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:
