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

```c
// Aizu 1108: A Long Ride on a Railway
// 2017.9.16 bal4u@uu

#include <stdio.h>
#include <string.h>

typedef struct { int a, b, d, f; } T;
T tbl[25]; int n, m;
int ans[12], tmp[12], len, num;

void combi(int k, int a, int w)
{
	int i, b;

	for (b = 1; b <= n; b++) {
		if (b == a) continue;
		for (i = 0; i < m; i++) {
			if ((tbl[i].a == a && tbl[i].b == b || tbl[i].a == b && tbl[i].b == a) && !tbl[i].f) {
				tbl[i].f = 1, tmp[k] = b;
				combi(k+1, b, w + tbl[i].d);
				tbl[i].f = 0;
			}
		}
	}
	if (w > len) num = k, len = w, memcpy(ans, tmp, sizeof(int)*num);
}

int main()
{
	int i, a, b;

	while (scanf("%d%d", &n, &m) && n) {
		for (i = 0; i < m; i++) scanf("%d%d%d", &tbl[i].a, &tbl[i].b, &tbl[i].d), tbl[i].f = 0;
		for (len = num = 0, a = 1; a <= n; a++) for (b = 1; b <= n; b++) {
			if (b == a) continue;
			for (i = 0; i < m; i++) {
				if ((tbl[i].a == a && tbl[i].b == b || tbl[i].b == a && tbl[i].a == b) && !tbl[i].f) {
					tbl[i].f = 1;
					tmp[0] = a, tmp[1] = b, combi(2, b, tbl[i].d);
					tbl[i].f = 0;
				}
			}
		}
		printf("%d\n", len);
		printf("%d", ans[0]);
		for (i = 1; i < num; i++) printf(" %d", ans[i]);
		printf("\n");
    }
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	tbl
	.bss
	.align 32
	.type	tbl, @object
	.size	tbl, 400
tbl:
	.zero	400
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	m
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.globl	ans
	.align 32
	.type	ans, @object
	.size	ans, 48
ans:
	.zero	48
	.globl	tmp
	.align 32
	.type	tmp, @object
	.size	tmp, 48
tmp:
	.zero	48
	.globl	len
	.align 4
	.type	len, @object
	.size	len, 4
len:
	.zero	4
	.globl	num
	.align 4
	.type	num, @object
	.size	num, 4
num:
	.zero	4
	.text
	.globl	combi
	.type	combi, @function
combi:
.LFB0:
	.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
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movl	%edx, -28(%rbp)
	movl	$1, -4(%rbp)
	jmp	.L2
.L10:
	movl	-4(%rbp), %eax
	cmpl	-24(%rbp), %eax
	je	.L12
	movl	$0, -8(%rbp)
	jmp	.L5
.L9:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jne	.L6
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	je	.L7
.L6:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	jne	.L8
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jne	.L8
.L7:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jne	.L8
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$1, (%rdx,%rax)
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	tmp(%rip), %rdx
	movl	-4(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+tbl(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-28(%rbp), %eax
	addl	%eax, %edx
	movl	-20(%rbp), %eax
	leal	1(%rax), %ecx
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	movl	%ecx, %edi
	call	combi
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
.L8:
	addl	$1, -8(%rbp)
.L5:
	movl	m(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L9
	jmp	.L4
.L12:
	nop
.L4:
	addl	$1, -4(%rbp)
.L2:
	movl	n(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jle	.L10
	movl	len(%rip), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L13
	movl	-20(%rbp), %eax
	movl	%eax, num(%rip)
	movl	-28(%rbp), %eax
	movl	%eax, len(%rip)
	movl	num(%rip), %eax
	cltq
	salq	$2, %rax
	movq	%rax, %rdx
	leaq	tmp(%rip), %rax
	movq	%rax, %rsi
	leaq	ans(%rip), %rax
	movq	%rax, %rdi
	call	memcpy@PLT
.L13:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	combi, .-combi
	.section	.rodata
.LC0:
	.string	"%d%d%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
.LC3:
	.string	" %d"
.LC4:
	.string	"%d%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	jmp	.L15
.L32:
	movl	$0, -12(%rbp)
	jmp	.L16
.L17:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rcx
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	addq	%rdx, %rax
	leaq	4(%rax), %rdx
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rsi
	leaq	tbl(%rip), %rax
	addq	%rsi, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
	addl	$1, -12(%rbp)
.L16:
	movl	m(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L17
	movl	$0, num(%rip)
	movl	num(%rip), %eax
	movl	%eax, len(%rip)
	movl	$1, -8(%rbp)
	jmp	.L18
.L28:
	movl	$1, -4(%rbp)
	jmp	.L19
.L27:
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	je	.L34
	movl	$0, -12(%rbp)
	jmp	.L22
.L26:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -8(%rbp)
	jne	.L23
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	je	.L24
.L23:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -8(%rbp)
	jne	.L25
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	jne	.L25
.L24:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jne	.L25
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$1, (%rdx,%rax)
	movl	-8(%rbp), %eax
	movl	%eax, tmp(%rip)
	movl	-4(%rbp), %eax
	movl	%eax, 4+tmp(%rip)
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+tbl(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	movl	$2, %edi
	call	combi
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
.L25:
	addl	$1, -12(%rbp)
.L22:
	movl	m(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L26
	jmp	.L21
.L34:
	nop
.L21:
	addl	$1, -4(%rbp)
.L19:
	movl	n(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jle	.L27
	addl	$1, -8(%rbp)
.L18:
	movl	n(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jle	.L28
	movl	len(%rip), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	ans(%rip), %eax
	movl	%eax, %esi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$1, -12(%rbp)
	jmp	.L29
.L30:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	ans(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %esi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	addl	$1, -12(%rbp)
.L29:
	movl	num(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L30
	movl	$10, %edi
	call	putchar@PLT
.L15:
	leaq	m(%rip), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC4(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L31
	movl	n(%rip), %eax
	testl	%eax, %eax
	jne	.L32
.L31:
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.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	combi
	.type	combi, @function
combi:
.LFB35:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	tmp(%rip), %rcx
	movl	%edi, %r15d
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	movl	%edx, %r14d
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	movl	%esi, %r13d
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	movl	$1, %ebp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$8, %rsp
	.cfi_def_cfa_offset 64
	movl	n(%rip), %eax
	testl	%eax, %eax
	jle	.L10
.L2:
	cmpl	%ebp, %r13d
	jne	.L19
.L5:
	addl	$1, %ebp
	cmpl	%eax, %ebp
	jle	.L2
.L10:
	cmpl	%r14d, len(%rip)
	jl	.L20
	addq	$8, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	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
.L19:
	.cfi_restore_state
	movl	m(%rip), %edx
	testl	%edx, %edx
	jle	.L5
	leaq	tbl(%rip), %rbx
	xorl	%r12d, %r12d
.L9:
	movl	(%rbx), %eax
	cmpl	%r13d, %eax
	je	.L21
	cmpl	%ebp, %eax
	je	.L22
.L8:
	addl	$1, %r12d
	addq	$16, %rbx
	cmpl	%r12d, %edx
	jg	.L9
	movl	n(%rip), %eax
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L21:
	cmpl	%ebp, 4(%rbx)
	jne	.L8
	movl	12(%rbx), %eax
	testl	%eax, %eax
	jne	.L8
.L23:
	movslq	%r15d, %rax
	movl	8(%rbx), %edx
	leal	1(%r15), %edi
	movl	%ebp, %esi
	movl	%ebp, (%rcx,%rax,4)
	addl	%r14d, %edx
	movl	$1, 12(%rbx)
	call	combi
	movl	$0, 12(%rbx)
	movl	m(%rip), %edx
	leaq	tmp(%rip), %rcx
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L22:
	cmpl	%r13d, 4(%rbx)
	jne	.L8
	movl	12(%rbx), %eax
	testl	%eax, %eax
	jne	.L8
	jmp	.L23
	.p2align 4,,10
	.p2align 3
.L20:
	movl	%r15d, num(%rip)
	movslq	%r15d, %rdx
	movl	$48, %ecx
	leaq	tmp(%rip), %rsi
	movl	%r14d, len(%rip)
	addq	$8, %rsp
	.cfi_def_cfa_offset 56
	salq	$2, %rdx
	leaq	ans(%rip), %rdi
	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
	jmp	__memcpy_chk@PLT
	.cfi_endproc
.LFE35:
	.size	combi, .-combi
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
.LC3:
	.string	" %d"
.LC4:
	.string	"%d%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB36:
	.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
	leaq	ans(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	tbl(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
.L25:
	xorl	%eax, %eax
	leaq	m(%rip), %rdx
	leaq	n(%rip), %rsi
	leaq	.LC4(%rip), %rdi
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L56
	movl	n(%rip), %esi
	testl	%esi, %esi
	je	.L56
	movl	m(%rip), %eax
	leaq	tbl(%rip), %rbx
	xorl	%r13d, %r13d
	testl	%eax, %eax
	jle	.L47
	.p2align 4,,10
	.p2align 3
.L26:
	leaq	8(%rbx), %rcx
	leaq	4(%rbx), %rdx
	movq	%rbx, %rsi
	xorl	%eax, %eax
	leaq	.LC0(%rip), %rdi
	addl	$1, %r13d
	addq	$16, %rbx
	call	__isoc99_scanf@PLT
	movl	$0, -4(%rbx)
	cmpl	%r13d, m(%rip)
	jg	.L26
	movl	n(%rip), %esi
.L47:
	movl	$0, num(%rip)
	movl	$0, len(%rip)
	testl	%esi, %esi
	jle	.L50
	movl	$1, %r15d
	.p2align 4,,10
	.p2align 3
.L48:
	movl	$1, %r14d
	.p2align 4,,10
	.p2align 3
.L41:
	movd	%r15d, %xmm0
	movd	%r14d, %xmm1
	punpckldq	%xmm1, %xmm0
	cmpl	%r15d, %r14d
	je	.L28
	movl	m(%rip), %edx
	testl	%edx, %edx
	jle	.L28
	leaq	tbl(%rip), %rbx
	xorl	%r13d, %r13d
	jmp	.L40
	.p2align 4,,10
	.p2align 3
.L29:
	cmpl	%r14d, %eax
	jne	.L31
	cmpl	%r15d, %ecx
	je	.L30
.L31:
	addl	$1, %r13d
	addq	$16, %rbx
	cmpl	%edx, %r13d
	jge	.L28
.L40:
	movl	(%rbx), %eax
	movl	4(%rbx), %ecx
	cmpl	%r15d, %eax
	jne	.L29
	cmpl	%ecx, %r14d
	jne	.L31
.L30:
	movl	12(%rbx), %edi
	testl	%edi, %edi
	jne	.L31
	movl	$1, 12(%rbx)
	movl	8(%rbx), %r9d
	movq	%xmm0, tmp(%rip)
	testl	%esi, %esi
	jle	.L32
	movl	%r15d, %r8d
	movl	$1, %ecx
	movl	%r13d, %r15d
	movq	%rbx, %r10
.L38:
	cmpl	%ecx, %r14d
	jne	.L79
.L33:
	addl	$1, %ecx
	cmpl	%esi, %ecx
	jle	.L38
	movl	%r15d, %r13d
	movq	%r10, %rbx
	movl	%r8d, %r15d
.L32:
	cmpl	len(%rip), %r9d
	jg	.L80
.L39:
	addl	$1, %r13d
	movl	$0, 12(%rbx)
	addq	$16, %rbx
	cmpl	%edx, %r13d
	jl	.L40
	.p2align 4,,10
	.p2align 3
.L28:
	addl	$1, %r14d
	cmpl	%esi, %r14d
	jle	.L41
	addl	$1, %r15d
	cmpl	%r15d, %esi
	jge	.L48
	movl	len(%rip), %edx
.L27:
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	movl	$1, %ebx
	call	__printf_chk@PLT
	movl	(%r12), %edx
	xorl	%eax, %eax
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	leaq	.LC3(%rip), %r13
	call	__printf_chk@PLT
	cmpl	$1, num(%rip)
	jle	.L44
	.p2align 4,,10
	.p2align 3
.L43:
	movl	(%r12,%rbx,4), %edx
	xorl	%eax, %eax
	movq	%r13, %rsi
	movl	$1, %edi
	addq	$1, %rbx
	call	__printf_chk@PLT
	cmpl	%ebx, num(%rip)
	jg	.L43
.L44:
	movl	$10, %edi
	call	putchar@PLT
	jmp	.L25
	.p2align 4,,10
	.p2align 3
.L79:
	testl	%edx, %edx
	jle	.L33
	movq	%rbp, %rbx
	xorl	%r13d, %r13d
.L37:
	movl	(%rbx), %eax
	cmpl	%r14d, %eax
	je	.L81
	cmpl	%ecx, %eax
	je	.L82
.L36:
	addl	$1, %r13d
	addq	$16, %rbx
	cmpl	%edx, %r13d
	jl	.L37
	movl	n(%rip), %esi
	jmp	.L33
	.p2align 4,,10
	.p2align 3
.L81:
	cmpl	%ecx, 4(%rbx)
	jne	.L36
	movl	12(%rbx), %esi
	testl	%esi, %esi
	jne	.L36
.L83:
	movl	%r9d, %edx
	movl	$1, 12(%rbx)
	addl	8(%rbx), %edx
	movl	%ecx, %esi
	movl	$3, %edi
	movq	%r10, 16(%rsp)
	movl	%r8d, 12(%rsp)
	movl	%ecx, 8+tmp(%rip)
	movl	%r9d, 8(%rsp)
	movl	%ecx, 4(%rsp)
	movq	%xmm0, 24(%rsp)
	call	combi
	movl	$0, 12(%rbx)
	movl	m(%rip), %edx
	movq	24(%rsp), %xmm0
	movq	16(%rsp), %r10
	movl	12(%rsp), %r8d
	movl	8(%rsp), %r9d
	movl	4(%rsp), %ecx
	jmp	.L36
	.p2align 4,,10
	.p2align 3
.L82:
	cmpl	%r14d, 4(%rbx)
	jne	.L36
	movl	12(%rbx), %esi
	testl	%esi, %esi
	jne	.L36
	jmp	.L83
	.p2align 4,,10
	.p2align 3
.L80:
	movq	tmp(%rip), %rax
	movl	%r9d, len(%rip)
	movl	$2, num(%rip)
	movq	%rax, (%r12)
	jmp	.L39
.L50:
	xorl	%edx, %edx
	jmp	.L27
.L56:
	addq	$40, %rsp
	.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
	.cfi_endproc
.LFE36:
	.size	main, .-main
	.globl	num
	.bss
	.align 4
	.type	num, @object
	.size	num, 4
num:
	.zero	4
	.globl	len
	.align 4
	.type	len, @object
	.size	len, 4
len:
	.zero	4
	.globl	tmp
	.align 32
	.type	tmp, @object
	.size	tmp, 48
tmp:
	.zero	48
	.globl	ans
	.align 32
	.type	ans, @object
	.size	ans, 48
ans:
	.zero	48
	.globl	m
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	tbl
	.align 32
	.type	tbl, @object
	.size	tbl, 400
tbl:
	.zero	400
	.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	combi
	.type	combi, @function
combi:
.LFB35:
	.cfi_startproc
	endbr64
	pushq	%r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	leaq	tmp(%rip), %rcx
	movl	%edi, %r15d
	pushq	%r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	movl	%edx, %r14d
	pushq	%r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	movl	%esi, %r13d
	pushq	%r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	movl	$1, %ebp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$8, %rsp
	.cfi_def_cfa_offset 64
	movl	n(%rip), %eax
	testl	%eax, %eax
	jle	.L10
.L2:
	cmpl	%ebp, %r13d
	jne	.L19
.L5:
	addl	$1, %ebp
	cmpl	%eax, %ebp
	jle	.L2
.L10:
	cmpl	%r14d, len(%rip)
	jl	.L20
	addq	$8, %rsp
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	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
.L19:
	.cfi_restore_state
	movl	m(%rip), %edx
	testl	%edx, %edx
	jle	.L5
	leaq	tbl(%rip), %rbx
	xorl	%r12d, %r12d
.L9:
	movl	(%rbx), %eax
	cmpl	%r13d, %eax
	je	.L21
	cmpl	%ebp, %eax
	je	.L22
.L8:
	addl	$1, %r12d
	addq	$16, %rbx
	cmpl	%r12d, %edx
	jg	.L9
	movl	n(%rip), %eax
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L21:
	cmpl	%ebp, 4(%rbx)
	jne	.L8
	movl	12(%rbx), %eax
	testl	%eax, %eax
	jne	.L8
.L23:
	movslq	%r15d, %rax
	movl	8(%rbx), %edx
	leal	1(%r15), %edi
	movl	%ebp, %esi
	movl	%ebp, (%rcx,%rax,4)
	addl	%r14d, %edx
	movl	$1, 12(%rbx)
	call	combi
	movl	$0, 12(%rbx)
	movl	m(%rip), %edx
	leaq	tmp(%rip), %rcx
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L22:
	cmpl	%r13d, 4(%rbx)
	jne	.L8
	movl	12(%rbx), %eax
	testl	%eax, %eax
	jne	.L8
	jmp	.L23
	.p2align 4,,10
	.p2align 3
.L20:
	movl	%r15d, num(%rip)
	movslq	%r15d, %rdx
	movl	$48, %ecx
	leaq	tmp(%rip), %rsi
	movl	%r14d, len(%rip)
	addq	$8, %rsp
	.cfi_def_cfa_offset 56
	salq	$2, %rdx
	leaq	ans(%rip), %rdi
	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
	jmp	__memcpy_chk@PLT
	.cfi_endproc
.LFE35:
	.size	combi, .-combi
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%d%d%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
.LC3:
	.string	" %d"
.LC4:
	.string	"%d%d"
	.section	.text.startup,"ax",@progbits
	.p2align 4
	.globl	main
	.type	main, @function
main:
.LFB36:
	.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
	leaq	ans(%rip), %r12
	pushq	%rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	leaq	tbl(%rip), %rbp
	pushq	%rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	subq	$40, %rsp
	.cfi_def_cfa_offset 96
.L25:
	xorl	%eax, %eax
	leaq	m(%rip), %rdx
	leaq	n(%rip), %rsi
	leaq	.LC4(%rip), %rdi
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L56
	movl	n(%rip), %esi
	testl	%esi, %esi
	je	.L56
	movl	m(%rip), %eax
	leaq	tbl(%rip), %rbx
	xorl	%r13d, %r13d
	testl	%eax, %eax
	jle	.L47
	.p2align 4,,10
	.p2align 3
.L26:
	leaq	8(%rbx), %rcx
	leaq	4(%rbx), %rdx
	movq	%rbx, %rsi
	xorl	%eax, %eax
	leaq	.LC0(%rip), %rdi
	addl	$1, %r13d
	addq	$16, %rbx
	call	__isoc99_scanf@PLT
	movl	$0, -4(%rbx)
	cmpl	%r13d, m(%rip)
	jg	.L26
	movl	n(%rip), %esi
.L47:
	movl	$0, num(%rip)
	movl	$0, len(%rip)
	testl	%esi, %esi
	jle	.L50
	movl	$1, %r15d
	.p2align 4,,10
	.p2align 3
.L48:
	movl	$1, %r14d
	.p2align 4,,10
	.p2align 3
.L41:
	movd	%r15d, %xmm0
	movd	%r14d, %xmm1
	punpckldq	%xmm1, %xmm0
	cmpl	%r15d, %r14d
	je	.L28
	movl	m(%rip), %edx
	testl	%edx, %edx
	jle	.L28
	leaq	tbl(%rip), %rbx
	xorl	%r13d, %r13d
	jmp	.L40
	.p2align 4,,10
	.p2align 3
.L29:
	cmpl	%r14d, %eax
	jne	.L31
	cmpl	%r15d, %ecx
	je	.L30
.L31:
	addl	$1, %r13d
	addq	$16, %rbx
	cmpl	%edx, %r13d
	jge	.L28
.L40:
	movl	(%rbx), %eax
	movl	4(%rbx), %ecx
	cmpl	%r15d, %eax
	jne	.L29
	cmpl	%ecx, %r14d
	jne	.L31
.L30:
	movl	12(%rbx), %edi
	testl	%edi, %edi
	jne	.L31
	movl	$1, 12(%rbx)
	movl	8(%rbx), %r9d
	movq	%xmm0, tmp(%rip)
	testl	%esi, %esi
	jle	.L32
	movl	%r15d, %r8d
	movl	$1, %ecx
	movl	%r13d, %r15d
	movq	%rbx, %r10
.L38:
	cmpl	%ecx, %r14d
	jne	.L79
.L33:
	addl	$1, %ecx
	cmpl	%esi, %ecx
	jle	.L38
	movl	%r15d, %r13d
	movq	%r10, %rbx
	movl	%r8d, %r15d
.L32:
	cmpl	len(%rip), %r9d
	jg	.L80
.L39:
	addl	$1, %r13d
	movl	$0, 12(%rbx)
	addq	$16, %rbx
	cmpl	%edx, %r13d
	jl	.L40
	.p2align 4,,10
	.p2align 3
.L28:
	addl	$1, %r14d
	cmpl	%esi, %r14d
	jle	.L41
	addl	$1, %r15d
	cmpl	%r15d, %esi
	jge	.L48
	movl	len(%rip), %edx
.L27:
	leaq	.LC1(%rip), %rsi
	movl	$1, %edi
	xorl	%eax, %eax
	movl	$1, %ebx
	call	__printf_chk@PLT
	movl	(%r12), %edx
	xorl	%eax, %eax
	movl	$1, %edi
	leaq	.LC2(%rip), %rsi
	leaq	.LC3(%rip), %r13
	call	__printf_chk@PLT
	cmpl	$1, num(%rip)
	jle	.L44
	.p2align 4,,10
	.p2align 3
.L43:
	movl	(%r12,%rbx,4), %edx
	xorl	%eax, %eax
	movq	%r13, %rsi
	movl	$1, %edi
	addq	$1, %rbx
	call	__printf_chk@PLT
	cmpl	%ebx, num(%rip)
	jg	.L43
.L44:
	movl	$10, %edi
	call	putchar@PLT
	jmp	.L25
	.p2align 4,,10
	.p2align 3
.L79:
	testl	%edx, %edx
	jle	.L33
	movq	%rbp, %rbx
	xorl	%r13d, %r13d
.L37:
	movl	(%rbx), %eax
	cmpl	%r14d, %eax
	je	.L81
	cmpl	%ecx, %eax
	je	.L82
.L36:
	addl	$1, %r13d
	addq	$16, %rbx
	cmpl	%edx, %r13d
	jl	.L37
	movl	n(%rip), %esi
	jmp	.L33
	.p2align 4,,10
	.p2align 3
.L81:
	cmpl	%ecx, 4(%rbx)
	jne	.L36
	movl	12(%rbx), %esi
	testl	%esi, %esi
	jne	.L36
.L83:
	movl	%r9d, %edx
	movl	$1, 12(%rbx)
	addl	8(%rbx), %edx
	movl	%ecx, %esi
	movl	$3, %edi
	movq	%r10, 16(%rsp)
	movl	%r8d, 12(%rsp)
	movl	%ecx, 8+tmp(%rip)
	movl	%r9d, 8(%rsp)
	movl	%ecx, 4(%rsp)
	movq	%xmm0, 24(%rsp)
	call	combi
	movl	$0, 12(%rbx)
	movl	m(%rip), %edx
	movq	24(%rsp), %xmm0
	movq	16(%rsp), %r10
	movl	12(%rsp), %r8d
	movl	8(%rsp), %r9d
	movl	4(%rsp), %ecx
	jmp	.L36
	.p2align 4,,10
	.p2align 3
.L82:
	cmpl	%r14d, 4(%rbx)
	jne	.L36
	movl	12(%rbx), %esi
	testl	%esi, %esi
	jne	.L36
	jmp	.L83
	.p2align 4,,10
	.p2align 3
.L80:
	movq	tmp(%rip), %rax
	movl	%r9d, len(%rip)
	movl	$2, num(%rip)
	movq	%rax, (%r12)
	jmp	.L39
.L50:
	xorl	%edx, %edx
	jmp	.L27
.L56:
	addq	$40, %rsp
	.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
	.cfi_endproc
.LFE36:
	.size	main, .-main
	.globl	num
	.bss
	.align 4
	.type	num, @object
	.size	num, 4
num:
	.zero	4
	.globl	len
	.align 4
	.type	len, @object
	.size	len, 4
len:
	.zero	4
	.globl	tmp
	.align 32
	.type	tmp, @object
	.size	tmp, 48
tmp:
	.zero	48
	.globl	ans
	.align 32
	.type	ans, @object
	.size	ans, 48
ans:
	.zero	48
	.globl	m
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	tbl
	.align 32
	.type	tbl, @object
	.size	tbl, 400
tbl:
	.zero	400
	.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:

// Aizu 1108: A Long Ride on a Railway
// 2017.9.16 bal4u@uu

#include <stdio.h>
#include <string.h>

typedef struct { int a, b, d, f; } T;
T tbl[25]; int n, m;
int ans[12], tmp[12], len, num;

void combi(int k, int a, int w)
{
	int i, b;

	for (b = 1; b <= n; b++) {
		if (b == a) continue;
		for (i = 0; i < m; i++) {
			if ((tbl[i].a == a && tbl[i].b == b || tbl[i].a == b && tbl[i].b == a) && !tbl[i].f) {
				tbl[i].f = 1, tmp[k] = b;
				combi(k+1, b, w + tbl[i].d);
				tbl[i].f = 0;
			}
		}
	}
	if (w > len) num = k, len = w, memcpy(ans, tmp, sizeof(int)*num);
}

int main()
{
	int i, a, b;

	while (scanf("%d%d", &n, &m) && n) {
		for (i = 0; i < m; i++) scanf("%d%d%d", &tbl[i].a, &tbl[i].b, &tbl[i].d), tbl[i].f = 0;
		for (len = num = 0, a = 1; a <= n; a++) for (b = 1; b <= n; b++) {
			if (b == a) continue;
			for (i = 0; i < m; i++) {
				if ((tbl[i].a == a && tbl[i].b == b || tbl[i].b == a && tbl[i].a == b) && !tbl[i].f) {
					tbl[i].f = 1;
					tmp[0] = a, tmp[1] = b, combi(2, b, tbl[i].d);
					tbl[i].f = 0;
				}
			}
		}
		printf("%d\n", len);
		printf("%d", ans[0]);
		for (i = 1; i < num; i++) printf(" %d", ans[i]);
		printf("\n");
    }
	return 0;
}
6  5
1  3  10
2  3  12
3  4   2
4  5  13
4  6  11
10 10
1  2  11
2  3  25
2  5  81
2  6  82
4  5  58
4  9  68
6  7  80
6  9  67
8  9  44
9 10  21
0  0
 6  5
 1  3  10
 2  3  12
 3  4   2
 2  5  13
 4  6  11
10 10
 1  2  11
 2  3  25
 2  5  81
 2  6  82
 4  5  58
 5  9  68
 6  7  80
 6  9  67
 8  9  44
 9 10  21
 0  0
 6  5
1  3  10
2  3  12
3  4   2
4  5  13
4  6  11
10 10
1  2  11
2  3  25
2  5  81
2  6  82
4  5  58
5  9  68
6  7  80
6  9  67
8  9  44
9 4  21
0  0
 6  5
1  3  10
2  3  12
3  4   2
4  5  13
4  6  11
10 10
1  2  11
2  3  25
2  5  81
2  6  82
4  5  58
5  9  68
6  7  80
6  9  67
8  9  82
9 4  21
0  0
 6  5
1  3  10
2  3  0
3  4   2
4  5  13
4  6  11
10 10
1  2  11
2  3  25
2  5  81
2  6  82
4  5  58
5  9  68
6  7  80
6  9  67
8  9  82
9 4  21
0  0
 6  5
 1  3  10
 2  2  12
 3  4   2
 4  5  13
 4  6  11
10 10
 1  2  11
 2  3  25
 2  5  81
 2  6  82
 4  5  58
 5  9  68
 6  7  80
 6  9  67
 8  9  44
 9 10  21
 0  0
 6  5
1  3  10
2  3  12
3  4   2
4  5  13
4  6  11
10 10
1  2  11
2  3  25
2  5  81
3  6  82
4  5  58
4  9  68
6  7  80
6  9  67
8  9  44
9 10  21
0  0
 6  5
 1  3  10
 2  2  12
 3  4   2
 4  5  13
 4  6  11
10 10
 1  2  11
 2  3  25
 2  5  81
 2  6  82
 4  5  58
 5  9  128
 6  7  80
 6  9  67
 8  9  44
 9 10  21
 0  0
 6  5
 1  3  10
 2  3  12
 3  4   2
 2  5  13
 4  6  11
10 10
 1  3  11
 2  3  25
 2  5  81
 3  6  82
 4  5  58
 5  9  68
 6  7  80
 6  9  67
 8  9  44
 9 10  21
 0  0
 6  5
 1  3  10
 2  2  12
 3  4   2
 4  5  13
 4  6  11
10 10
 1  2  11
 2  3  25
 2  5  81
 2  6  82
 4  5  58
 5  9  128
 6  7  80
 1  9  67
 8  9  44
 9 10  21
 0  0

27
2 3 4 5
436
6 2 5 4 9 6 7
 38
5 2 3 4 6
378
6 2 5 9 6 7
 27
2 3 4 5
421
5 2 6 9 4 5 9 8
 27
2 3 4 5
459
5 2 6 9 4 5 9 8
 25
1 3 4 5
459
5 2 6 9 4 5 9 8
 25
1 3 4 5
378
6 2 5 9 6 7
 27
2 3 4 5
461
6 3 2 5 4 9 6 7
 25
1 3 4 5
438
6 2 5 9 6 7
 38
5 2 3 4 6
403
6 3 2 5 9 6 7
 25
1 3 4 5
474
3 2 1 9 5 2 6 7

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

```c
// Aizu 1108: A Long Ride on a Railway
// 2017.9.16 bal4u@uu

#include <stdio.h>
#include <string.h>

typedef struct { int a, b, d, f; } T;
T tbl[25]; int n, m;
int ans[12], tmp[12], len, num;

void combi(int k, int a, int w)
{
	int i, b;

	for (b = 1; b <= n; b++) {
		if (b == a) continue;
		for (i = 0; i < m; i++) {
			if ((tbl[i].a == a && tbl[i].b == b || tbl[i].a == b && tbl[i].b == a) && !tbl[i].f) {
				tbl[i].f = 1, tmp[k] = b;
				combi(k+1, b, w + tbl[i].d);
				tbl[i].f = 0;
			}
		}
	}
	if (w > len) num = k, len = w, memcpy(ans, tmp, sizeof(int)*num);
}

int main()
{
	int i, a, b;

	while (scanf("%d%d", &n, &m) && n) {
		for (i = 0; i < m; i++) scanf("%d%d%d", &tbl[i].a, &tbl[i].b, &tbl[i].d), tbl[i].f = 0;
		for (len = num = 0, a = 1; a <= n; a++) for (b = 1; b <= n; b++) {
			if (b == a) continue;
			for (i = 0; i < m; i++) {
				if ((tbl[i].a == a && tbl[i].b == b || tbl[i].b == a && tbl[i].a == b) && !tbl[i].f) {
					tbl[i].f = 1;
					tmp[0] = a, tmp[1] = b, combi(2, b, tbl[i].d);
					tbl[i].f = 0;
				}
			}
		}
		printf("%d\n", len);
		printf("%d", ans[0]);
		for (i = 1; i < num; i++) printf(" %d", ans[i]);
		printf("\n");
    }
	return 0;
}```

Unoptimized Assembly Code:

```assembly
	.file	"temp.c"
	.text
	.globl	tbl
	.bss
	.align 32
	.type	tbl, @object
	.size	tbl, 400
tbl:
	.zero	400
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	m
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.globl	ans
	.align 32
	.type	ans, @object
	.size	ans, 48
ans:
	.zero	48
	.globl	tmp
	.align 32
	.type	tmp, @object
	.size	tmp, 48
tmp:
	.zero	48
	.globl	len
	.align 4
	.type	len, @object
	.size	len, 4
len:
	.zero	4
	.globl	num
	.align 4
	.type	num, @object
	.size	num, 4
num:
	.zero	4
	.text
	.globl	combi
	.type	combi, @function
combi:
.LFB0:
	.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
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movl	%edx, -28(%rbp)
	movl	$1, -4(%rbp)
	jmp	.L2
.L10:
	movl	-4(%rbp), %eax
	cmpl	-24(%rbp), %eax
	je	.L12
	movl	$0, -8(%rbp)
	jmp	.L5
.L9:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jne	.L6
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	je	.L7
.L6:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	jne	.L8
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jne	.L8
.L7:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jne	.L8
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$1, (%rdx,%rax)
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	tmp(%rip), %rdx
	movl	-4(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+tbl(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-28(%rbp), %eax
	addl	%eax, %edx
	movl	-20(%rbp), %eax
	leal	1(%rax), %ecx
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	movl	%ecx, %edi
	call	combi
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
.L8:
	addl	$1, -8(%rbp)
.L5:
	movl	m(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L9
	jmp	.L4
.L12:
	nop
.L4:
	addl	$1, -4(%rbp)
.L2:
	movl	n(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jle	.L10
	movl	len(%rip), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L13
	movl	-20(%rbp), %eax
	movl	%eax, num(%rip)
	movl	-28(%rbp), %eax
	movl	%eax, len(%rip)
	movl	num(%rip), %eax
	cltq
	salq	$2, %rax
	movq	%rax, %rdx
	leaq	tmp(%rip), %rax
	movq	%rax, %rsi
	leaq	ans(%rip), %rax
	movq	%rax, %rdi
	call	memcpy@PLT
.L13:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	combi, .-combi
	.section	.rodata
.LC0:
	.string	"%d%d%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
.LC3:
	.string	" %d"
.LC4:
	.string	"%d%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	jmp	.L15
.L32:
	movl	$0, -12(%rbp)
	jmp	.L16
.L17:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rcx
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	addq	%rdx, %rax
	leaq	4(%rax), %rdx
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rsi
	leaq	tbl(%rip), %rax
	addq	%rsi, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
	addl	$1, -12(%rbp)
.L16:
	movl	m(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L17
	movl	$0, num(%rip)
	movl	num(%rip), %eax
	movl	%eax, len(%rip)
	movl	$1, -8(%rbp)
	jmp	.L18
.L28:
	movl	$1, -4(%rbp)
	jmp	.L19
.L27:
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	je	.L34
	movl	$0, -12(%rbp)
	jmp	.L22
.L26:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -8(%rbp)
	jne	.L23
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	je	.L24
.L23:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -8(%rbp)
	jne	.L25
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	jne	.L25
.L24:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jne	.L25
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$1, (%rdx,%rax)
	movl	-8(%rbp), %eax
	movl	%eax, tmp(%rip)
	movl	-4(%rbp), %eax
	movl	%eax, 4+tmp(%rip)
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+tbl(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	movl	$2, %edi
	call	combi
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
.L25:
	addl	$1, -12(%rbp)
.L22:
	movl	m(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L26
	jmp	.L21
.L34:
	nop
.L21:
	addl	$1, -4(%rbp)
.L19:
	movl	n(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jle	.L27
	addl	$1, -8(%rbp)
.L18:
	movl	n(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jle	.L28
	movl	len(%rip), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	ans(%rip), %eax
	movl	%eax, %esi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$1, -12(%rbp)
	jmp	.L29
.L30:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	ans(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %esi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	addl	$1, -12(%rbp)
.L29:
	movl	num(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L30
	movl	$10, %edi
	call	putchar@PLT
.L15:
	leaq	m(%rip), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC4(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L31
	movl	n(%rip), %eax
	testl	%eax, %eax
	jne	.L32
.L31:
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.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	tbl
	.bss
	.align 32
	.type	tbl, @object
	.size	tbl, 400
tbl:
	.zero	400
	.globl	n
	.align 4
	.type	n, @object
	.size	n, 4
n:
	.zero	4
	.globl	m
	.align 4
	.type	m, @object
	.size	m, 4
m:
	.zero	4
	.globl	ans
	.align 32
	.type	ans, @object
	.size	ans, 48
ans:
	.zero	48
	.globl	tmp
	.align 32
	.type	tmp, @object
	.size	tmp, 48
tmp:
	.zero	48
	.globl	len
	.align 4
	.type	len, @object
	.size	len, 4
len:
	.zero	4
	.globl	num
	.align 4
	.type	num, @object
	.size	num, 4
num:
	.zero	4
	.text
	.globl	combi
	.type	combi, @function
combi:
.LFB0:
	.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
	movl	%edi, -20(%rbp)
	movl	%esi, -24(%rbp)
	movl	%edx, -28(%rbp)
	movl	$1, -4(%rbp)
	jmp	.L2
.L10:
	movl	-4(%rbp), %eax
	cmpl	-24(%rbp), %eax
	je	.L12
	movl	$0, -8(%rbp)
	jmp	.L5
.L9:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jne	.L6
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	je	.L7
.L6:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	jne	.L8
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -24(%rbp)
	jne	.L8
.L7:
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jne	.L8
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$1, (%rdx,%rax)
	movl	-20(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rcx
	leaq	tmp(%rip), %rdx
	movl	-4(%rbp), %eax
	movl	%eax, (%rcx,%rdx)
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+tbl(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-28(%rbp), %eax
	addl	%eax, %edx
	movl	-20(%rbp), %eax
	leal	1(%rax), %ecx
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	movl	%ecx, %edi
	call	combi
	movl	-8(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
.L8:
	addl	$1, -8(%rbp)
.L5:
	movl	m(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jl	.L9
	jmp	.L4
.L12:
	nop
.L4:
	addl	$1, -4(%rbp)
.L2:
	movl	n(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jle	.L10
	movl	len(%rip), %eax
	cmpl	%eax, -28(%rbp)
	jle	.L13
	movl	-20(%rbp), %eax
	movl	%eax, num(%rip)
	movl	-28(%rbp), %eax
	movl	%eax, len(%rip)
	movl	num(%rip), %eax
	cltq
	salq	$2, %rax
	movq	%rax, %rdx
	leaq	tmp(%rip), %rax
	movq	%rax, %rsi
	leaq	ans(%rip), %rax
	movq	%rax, %rdi
	call	memcpy@PLT
.L13:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	combi, .-combi
	.section	.rodata
.LC0:
	.string	"%d%d%d"
.LC1:
	.string	"%d\n"
.LC2:
	.string	"%d"
.LC3:
	.string	" %d"
.LC4:
	.string	"%d%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB1:
	.cfi_startproc
	endbr64
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register 6
	subq	$16, %rsp
	jmp	.L15
.L32:
	movl	$0, -12(%rbp)
	jmp	.L16
.L17:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	addq	%rdx, %rax
	leaq	8(%rax), %rcx
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	addq	%rdx, %rax
	leaq	4(%rax), %rdx
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rsi
	leaq	tbl(%rip), %rax
	addq	%rsi, %rax
	movq	%rax, %rsi
	leaq	.LC0(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
	addl	$1, -12(%rbp)
.L16:
	movl	m(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L17
	movl	$0, num(%rip)
	movl	num(%rip), %eax
	movl	%eax, len(%rip)
	movl	$1, -8(%rbp)
	jmp	.L18
.L28:
	movl	$1, -4(%rbp)
	jmp	.L19
.L27:
	movl	-4(%rbp), %eax
	cmpl	-8(%rbp), %eax
	je	.L34
	movl	$0, -12(%rbp)
	jmp	.L22
.L26:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -8(%rbp)
	jne	.L23
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	je	.L24
.L23:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	4+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -8(%rbp)
	jne	.L25
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	cmpl	%eax, -4(%rbp)
	jne	.L25
.L24:
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	(%rdx,%rax), %eax
	testl	%eax, %eax
	jne	.L25
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$1, (%rdx,%rax)
	movl	-8(%rbp), %eax
	movl	%eax, tmp(%rip)
	movl	-4(%rbp), %eax
	movl	%eax, 4+tmp(%rip)
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	8+tbl(%rip), %rax
	movl	(%rdx,%rax), %edx
	movl	-4(%rbp), %eax
	movl	%eax, %esi
	movl	$2, %edi
	call	combi
	movl	-12(%rbp), %eax
	cltq
	salq	$4, %rax
	movq	%rax, %rdx
	leaq	12+tbl(%rip), %rax
	movl	$0, (%rdx,%rax)
.L25:
	addl	$1, -12(%rbp)
.L22:
	movl	m(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L26
	jmp	.L21
.L34:
	nop
.L21:
	addl	$1, -4(%rbp)
.L19:
	movl	n(%rip), %eax
	cmpl	%eax, -4(%rbp)
	jle	.L27
	addl	$1, -8(%rbp)
.L18:
	movl	n(%rip), %eax
	cmpl	%eax, -8(%rbp)
	jle	.L28
	movl	len(%rip), %eax
	movl	%eax, %esi
	leaq	.LC1(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	ans(%rip), %eax
	movl	%eax, %esi
	leaq	.LC2(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	movl	$1, -12(%rbp)
	jmp	.L29
.L30:
	movl	-12(%rbp), %eax
	cltq
	leaq	0(,%rax,4), %rdx
	leaq	ans(%rip), %rax
	movl	(%rdx,%rax), %eax
	movl	%eax, %esi
	leaq	.LC3(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	printf@PLT
	addl	$1, -12(%rbp)
.L29:
	movl	num(%rip), %eax
	cmpl	%eax, -12(%rbp)
	jl	.L30
	movl	$10, %edi
	call	putchar@PLT
.L15:
	leaq	m(%rip), %rax
	movq	%rax, %rdx
	leaq	n(%rip), %rax
	movq	%rax, %rsi
	leaq	.LC4(%rip), %rax
	movq	%rax, %rdi
	movl	$0, %eax
	call	__isoc99_scanf@PLT
	testl	%eax, %eax
	je	.L31
	movl	n(%rip), %eax
	testl	%eax, %eax
	jne	.L32
.L31:
	movl	$0, %eax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.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:
