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

```c
#include <stdio.h>

typedef struct node_t {
	int val;
	struct node_t *next;
} node;

node* new_node(int val) {
	static int it = 0;
	static node pool[200000];
	pool[it] = (node) { val, NULL };
	return &pool[it++];
}

node* st[1000];

int main(void)
{
	int n, q, com, t, x;
	node *tmp;
	scanf("%d%d", &n, &q);
	while (q--) {
		scanf("%d%d", &com, &t);
		if (com == 0) {
			scanf("%d", &x);
			tmp = new_node(x);
			tmp->next = st[t];
			st[t] = tmp;
		}
		else if (com == 1) {
			if (st[t]) printf("%d\n", st[t]->val);
		}
		else {
			if (st[t]) st[t] = st[t]->next;
		}
	}
	return 0;
}

```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.p2align 4
	.globl	new_node
	.type	new_node, @function
new_node:
.LFB23:
	.cfi_startproc
	endbr64
	movslq	it.1(%rip), %rcx
	leaq	pool.0(%rip), %rax
	movq	%rcx, %rdx
	salq	$4, %rcx
	addq	%rcx, %rax
	addl	$1, %edx
	movl	%edi, (%rax)
	movq	$0, 8(%rax)
	movl	%edx, it.1(%rip)
	ret
	.cfi_endproc
.LFE23:
	.size	new_node, .-new_node
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rdx
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
	leaq	16(%rsp), %r13
	leaq	12(%rsp), %r12
	leaq	st(%rip), %rbx
	leaq	20(%rsp), %r15
	leaq	.LC1(%rip), %r14
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L5:
	movslq	16(%rsp), %rcx
	movq	(%rbx,%rcx,8), %rdx
	cmpl	$1, %eax
	je	.L22
	testq	%rdx, %rdx
	je	.L6
	movq	8(%rdx), %rax
	movq	%rax, (%rbx,%rcx,8)
.L6:
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
.L4:
	movq	%r13, %rdx
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	testl	%eax, %eax
	jne	.L5
	movq	%r14, %rdi
	movq	%r15, %rsi
	call	__isoc99_scanf@PLT
	movslq	it.1(%rip), %rax
	movl	20(%rsp), %ecx
	leaq	pool.0(%rip), %rdi
	movq	%rax, %rdx
	salq	$4, %rax
	addl	$1, %edx
	addq	%rdi, %rax
	movl	%edx, it.1(%rip)
	movslq	16(%rsp), %rdx
	movl	%ecx, (%rax)
	movq	(%rbx,%rdx,8), %rcx
	movq	%rax, (%rbx,%rdx,8)
	movq	%rcx, 8(%rax)
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jne	.L4
.L8:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_restore_state
	testq	%rdx, %rdx
	je	.L6
	movl	(%rdx), %edx
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L6
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.local	pool.0
	.comm	pool.0,3200000,32
	.local	it.1
	.comm	it.1,4,4
	.globl	st
	.bss
	.align 32
	.type	st, @object
	.size	st, 8000
st:
	.zero	8000
	.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.
Optimized Assembly Code:

user
```assembly
	.file	"temp.c"
	.text
	.p2align 4
	.globl	new_node
	.type	new_node, @function
new_node:
.LFB23:
	.cfi_startproc
	endbr64
	movslq	it.1(%rip), %rcx
	leaq	pool.0(%rip), %rax
	movq	%rcx, %rdx
	salq	$4, %rcx
	addq	%rcx, %rax
	addl	$1, %edx
	movl	%edi, (%rax)
	movq	$0, 8(%rax)
	movl	%edx, it.1(%rip)
	ret
	.cfi_endproc
.LFE23:
	.size	new_node, .-new_node
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rdx
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
	leaq	16(%rsp), %r13
	leaq	12(%rsp), %r12
	leaq	st(%rip), %rbx
	leaq	20(%rsp), %r15
	leaq	.LC1(%rip), %r14
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L5:
	movslq	16(%rsp), %rcx
	movq	(%rbx,%rcx,8), %rdx
	cmpl	$1, %eax
	je	.L22
	testq	%rdx, %rdx
	je	.L6
	movq	8(%rdx), %rax
	movq	%rax, (%rbx,%rcx,8)
.L6:
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
.L4:
	movq	%r13, %rdx
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	testl	%eax, %eax
	jne	.L5
	movq	%r14, %rdi
	movq	%r15, %rsi
	call	__isoc99_scanf@PLT
	movslq	it.1(%rip), %rax
	movl	20(%rsp), %ecx
	leaq	pool.0(%rip), %rdi
	movq	%rax, %rdx
	salq	$4, %rax
	addl	$1, %edx
	addq	%rdi, %rax
	movl	%edx, it.1(%rip)
	movslq	16(%rsp), %rdx
	movl	%ecx, (%rax)
	movq	(%rbx,%rdx,8), %rcx
	movq	%rax, (%rbx,%rdx,8)
	movq	%rcx, 8(%rax)
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jne	.L4
.L8:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_restore_state
	testq	%rdx, %rdx
	je	.L6
	movl	(%rdx), %edx
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L6
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.local	pool.0
	.comm	pool.0,3200000,32
	.local	it.1
	.comm	it.1,4,4
	.globl	st
	.bss
	.align 32
	.type	st, @object
	.size	st, 8000
st:
	.zero	8000
	.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
```assembly
	.file	"temp.c"
	.text
	.p2align 4
	.globl	new_node
	.type	new_node, @function
new_node:
.LFB23:
	.cfi_startproc
	endbr64
	movslq	it.1(%rip), %rcx
	leaq	pool.0(%rip), %rax
	movq	%rcx, %rdx
	salq	$4, %rcx
	addq	%rcx, %rax
	addl	$1, %edx
	movl	%edi, (%rax)
	movq	$0, 8(%rax)
	movl	%edx, it.1(%rip)
	ret
	.cfi_endproc
.LFE23:
	.size	new_node, .-new_node
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rdx
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
	leaq	16(%rsp), %r13
	leaq	12(%rsp), %r12
	leaq	st(%rip), %rbx
	leaq	20(%rsp), %r15
	leaq	.LC1(%rip), %r14
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L5:
	movslq	16(%rsp), %rcx
	movq	(%rbx,%rcx,8), %rdx
	cmpl	$1, %eax
	je	.L22
	testq	%rdx, %rdx
	je	.L6
	movq	8(%rdx), %rax
	movq	%rax, (%rbx,%rcx,8)
.L6:
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
.L4:
	movq	%r13, %rdx
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	testl	%eax, %eax
	jne	.L5
	movq	%r14, %rdi
	movq	%r15, %rsi
	call	__isoc99_scanf@PLT
	movslq	it.1(%rip), %rax
	movl	20(%rsp), %ecx
	leaq	pool.0(%rip), %rdi
	movq	%rax, %rdx
	salq	$4, %rax
	addl	$1, %edx
	addq	%rdi, %rax
	movl	%edx, it.1(%rip)
	movslq	16(%rsp), %rdx
	movl	%ecx, (%rax)
	movq	(%rbx,%rdx,8), %rcx
	movq	%rax, (%rbx,%rdx,8)
	movq	%rcx, 8(%rax)
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jne	.L4
.L8:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_restore_state
	testq	%rdx, %rdx
	je	.L6
	movl	(%rdx), %edx
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L6
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.local	pool.0
	.comm	pool.0,3200000,32
	.local	it.1
	.comm	it.1,4,4
	.globl	st
	.bss
	.align 32
	.type	st, @object
	.size	st, 8000
st:
	.zero	8000
	.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:
```
```c
#include <stdio.h>

typedef struct node_t {
	int val;
	struct node_t *next;
} node;

node* new_node(int val) {
	static int it = 0;
	static node pool[200000];
	pool[it] = (node) { val, NULL };
	return &pool[it++];
}

node* st[1000];

int main(void)
{
	int n, q, com, t, x;
	node *tmp;
	scanf("%d%d", &n, &q);
	while (q--) {
		scanf("%d%d", &com, &t);
		if (com == 0) {
			scanf("%d", &x);
			tmp = new_node(x);
			tmp->next = st[t];
			st[t] = tmp;
		}
		else if (com == 1) {
			if (st[t]) printf("%d\n", st[t]->val);
		}
		else {
			if (st[t]) st[t] = st[t]->next;
		}
	}
	return 0;
}

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

```c
#include <stdio.h>

typedef struct node_t {
	int val;
	struct node_t *next;
} node;

node* new_node(int val) {
	static int it = 0;
	static node pool[200000];
	pool[it] = (node) { val, NULL };
	return &pool[it++];
}

node* st[1000];

int main(void)
{
	int n, q, com, t, x;
	node *tmp;
	scanf("%d%d", &n, &q);
	while (q--) {
		scanf("%d%d", &com, &t);
		if (com == 0) {
			scanf("%d", &x);
			tmp = new_node(x);
			tmp->next = st[t];
			st[t] = tmp;
		}
		else if (com == 1) {
			if (st[t]) printf("%d\n", st[t]->val);
		}
		else {
			if (st[t]) st[t] = st[t]->next;
		}
	}
	return 0;
}

```

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.
Optimized Assembly Code:

3 9
0 0 0
0 0 2
0 0 3
0 2 4
0 2 5
1 0
1 2
2 0
1 0
 3 9
0 0 0
0 0 2
0 0 3
0 2 4
0 0 5
1 0
1 2
2 0
1 0
 3 9
0 0 0
0 0 2
0 0 3
0 2 4
0 2 5
1 1
1 2
2 0
1 0
 6 9
0 0 0
0 0 2
0 0 3
0 2 4
0 0 5
1 1
1 2
2 0
1 0
 3 9
0 0 0
0 0 2
0 0 1
0 2 4
0 2 9
1 1
1 2
2 0
1 0
 3 9
0 0 1
0 0 2
0 0 6
0 2 4
0 2 5
1 0
1 2
2 0
1 0
 6 9
0 0 0
0 0 2
0 0 1
0 2 4
0 0 5
1 0
1 2
2 0
1 0
 3 9
0 0 0
0 0 2
0 0 1
0 2 4
0 2 9
1 1
1 2
1 0
1 0
 3 12
0 0 1
0 0 2
0 0 6
0 2 4
0 2 5
1 0
1 2
2 0
1 0
 3 9
0 0 0
0 0 2
0 0 1
0 0 4
0 2 9
1 1
1 2
1 0
1 0

3
5
2
 5
4
3
 5
2
 4
3
 9
2
 6
5
2
 5
4
1
 9
1
1
 6
5
2
2
2
2
 9
4
4

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

```c
#include <stdio.h>

typedef struct node_t {
	int val;
	struct node_t *next;
} node;

node* new_node(int val) {
	static int it = 0;
	static node pool[200000];
	pool[it] = (node) { val, NULL };
	return &pool[it++];
}

node* st[1000];

int main(void)
{
	int n, q, com, t, x;
	node *tmp;
	scanf("%d%d", &n, &q);
	while (q--) {
		scanf("%d%d", &com, &t);
		if (com == 0) {
			scanf("%d", &x);
			tmp = new_node(x);
			tmp->next = st[t];
			st[t] = tmp;
		}
		else if (com == 1) {
			if (st[t]) printf("%d\n", st[t]->val);
		}
		else {
			if (st[t]) st[t] = st[t]->next;
		}
	}
	return 0;
}

```

Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.p2align 4
	.globl	new_node
	.type	new_node, @function
new_node:
.LFB23:
	.cfi_startproc
	endbr64
	movslq	it.1(%rip), %rcx
	leaq	pool.0(%rip), %rax
	movq	%rcx, %rdx
	salq	$4, %rcx
	addq	%rcx, %rax
	addl	$1, %edx
	movl	%edi, (%rax)
	movq	$0, 8(%rax)
	movl	%edx, it.1(%rip)
	ret
	.cfi_endproc
.LFE23:
	.size	new_node, .-new_node
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rdx
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
	leaq	16(%rsp), %r13
	leaq	12(%rsp), %r12
	leaq	st(%rip), %rbx
	leaq	20(%rsp), %r15
	leaq	.LC1(%rip), %r14
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L5:
	movslq	16(%rsp), %rcx
	movq	(%rbx,%rcx,8), %rdx
	cmpl	$1, %eax
	je	.L22
	testq	%rdx, %rdx
	je	.L6
	movq	8(%rdx), %rax
	movq	%rax, (%rbx,%rcx,8)
.L6:
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
.L4:
	movq	%r13, %rdx
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	testl	%eax, %eax
	jne	.L5
	movq	%r14, %rdi
	movq	%r15, %rsi
	call	__isoc99_scanf@PLT
	movslq	it.1(%rip), %rax
	movl	20(%rsp), %ecx
	leaq	pool.0(%rip), %rdi
	movq	%rax, %rdx
	salq	$4, %rax
	addl	$1, %edx
	addq	%rdi, %rax
	movl	%edx, it.1(%rip)
	movslq	16(%rsp), %rdx
	movl	%ecx, (%rax)
	movq	(%rbx,%rdx,8), %rcx
	movq	%rax, (%rbx,%rdx,8)
	movq	%rcx, 8(%rax)
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jne	.L4
.L8:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_restore_state
	testq	%rdx, %rdx
	je	.L6
	movl	(%rdx), %edx
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L6
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.local	pool.0
	.comm	pool.0,3200000,32
	.local	it.1
	.comm	it.1,4,4
	.globl	st
	.bss
	.align 32
	.type	st, @object
	.size	st, 8000
st:
	.zero	8000
	.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.
Optimized Assembly Code:

train
```assembly
	.file	"temp.c"
	.text
	.p2align 4
	.globl	new_node
	.type	new_node, @function
new_node:
.LFB23:
	.cfi_startproc
	endbr64
	movslq	it.1(%rip), %rcx
	leaq	pool.0(%rip), %rax
	movq	%rcx, %rdx
	salq	$4, %rcx
	addq	%rcx, %rax
	addl	$1, %edx
	movl	%edi, (%rax)
	movq	$0, 8(%rax)
	movl	%edx, it.1(%rip)
	ret
	.cfi_endproc
.LFE23:
	.size	new_node, .-new_node
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d"
.LC1:
	.string	"%d"
.LC2:
	.string	"%d\n"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB24:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	.LC0(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	movq	%rbp, %rdi
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
	movq	%fs:40, %rax
	movq	%rax, 24(%rsp)
	xorl	%eax, %eax
	leaq	8(%rsp), %rdx
	leaq	4(%rsp), %rsi
	call	__isoc99_scanf@PLT
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
	leaq	16(%rsp), %r13
	leaq	12(%rsp), %r12
	leaq	st(%rip), %rbx
	leaq	20(%rsp), %r15
	leaq	.LC1(%rip), %r14
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L5:
	movslq	16(%rsp), %rcx
	movq	(%rbx,%rcx,8), %rdx
	cmpl	$1, %eax
	je	.L22
	testq	%rdx, %rdx
	je	.L6
	movq	8(%rdx), %rax
	movq	%rax, (%rbx,%rcx,8)
.L6:
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	je	.L8
.L4:
	movq	%r13, %rdx
	movq	%r12, %rsi
	movq	%rbp, %rdi
	xorl	%eax, %eax
	call	__isoc99_scanf@PLT
	movl	12(%rsp), %eax
	testl	%eax, %eax
	jne	.L5
	movq	%r14, %rdi
	movq	%r15, %rsi
	call	__isoc99_scanf@PLT
	movslq	it.1(%rip), %rax
	movl	20(%rsp), %ecx
	leaq	pool.0(%rip), %rdi
	movq	%rax, %rdx
	salq	$4, %rax
	addl	$1, %edx
	addq	%rdi, %rax
	movl	%edx, it.1(%rip)
	movslq	16(%rsp), %rdx
	movl	%ecx, (%rax)
	movq	(%rbx,%rdx,8), %rcx
	movq	%rax, (%rbx,%rdx,8)
	movq	%rcx, 8(%rax)
	movl	8(%rsp), %eax
	leal	-1(%rax), %edx
	movl	%edx, 8(%rsp)
	testl	%eax, %eax
	jne	.L4
.L8:
	movq	24(%rsp), %rax
	subq	%fs:40, %rax
	jne	.L23
	addq	$40, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xorl	%eax, %eax
	popq	%rbx
	.cfi_def_cfa_offset 48
	popq	%rbp
	.cfi_def_cfa_offset 40
	popq	%r12
	.cfi_def_cfa_offset 32
	popq	%r13
	.cfi_def_cfa_offset 24
	popq	%r14
	.cfi_def_cfa_offset 16
	popq	%r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_restore_state
	testq	%rdx, %rdx
	je	.L6
	movl	(%rdx), %edx
	leaq	.LC2(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	call	__printf_chk@PLT
	jmp	.L6
.L23:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE24:
	.size	main, .-main
	.local	pool.0
	.comm	pool.0,3200000,32
	.local	it.1
	.comm	it.1,4,4
	.globl	st
	.bss
	.align 32
	.type	st, @object
	.size	st, 8000
st:
	.zero	8000
	.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:
```