	.file	"127964.c"
	.intel_syntax noprefix
	.text
	.globl	frontier_head
	.bss
	.align 8
	.type	frontier_head, @object
	.size	frontier_head, 8
frontier_head:
	.zero	8
	.globl	frontier_tail
	.align 8
	.type	frontier_tail, @object
	.size	frontier_tail, 8
frontier_tail:
	.zero	8
	.globl	t1
	.align 8
	.type	t1, @object
	.size	t1, 8
t1:
	.zero	8
	.globl	t2
	.align 8
	.type	t2, @object
	.size	t2, 8
t2:
	.zero	8
	.globl	solution_length
	.align 4
	.type	solution_length, @object
	.size	solution_length, 4
solution_length:
	.zero	4
	.globl	solution
	.align 8
	.type	solution, @object
	.size	solution, 8
solution:
	.zero	8
	.globl	sol_moved0
	.align 8
	.type	sol_moved0, @object
	.size	sol_moved0, 8
sol_moved0:
	.zero	8
	.globl	sol_moved1
	.align 8
	.type	sol_moved1, @object
	.size	sol_moved1, 8
sol_moved1:
	.zero	8
	.globl	mem_error
	.align 4
	.type	mem_error, @object
	.size	mem_error, 4
mem_error:
	.zero	4
	.section	.rodata
	.align 8
.LC0:
	.string	"puzzle <method> <input-file> <output-file>\n"
.LC1:
	.string	"where: "
	.align 8
.LC2:
	.string	"<method> = breadth|depth|best|astar"
	.align 8
.LC3:
	.string	"<input-file> is a file containing a %dx%d puzzle description.\n"
	.align 8
.LC4:
	.string	"<output-file> is the file where the solution will be written."
	.text
	.globl	syntax_message
	.type	syntax_message, @function
syntax_message:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	lea	rdi, .LC0[rip]
	call	puts@PLT
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rdi, .LC2[rip]
	call	puts@PLT
	mov	edx, 8
	mov	esi, 8
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rdi, .LC4[rip]
	call	puts@PLT
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	syntax_message, .-syntax_message
	.section	.rodata
.LC5:
	.string	"breadth"
.LC6:
	.string	"depth"
.LC7:
	.string	"best"
.LC8:
	.string	"astar"
	.text
	.globl	get_method
	.type	get_method, @function
get_method:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC5[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L3
	mov	eax, 1
	jmp	.L4
.L3:
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC6[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L5
	mov	eax, 2
	jmp	.L4
.L5:
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L6
	mov	eax, 3
	jmp	.L4
.L6:
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC8[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L7
	mov	eax, 4
	jmp	.L4
.L7:
	mov	eax, -1
.L4:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	get_method, .-get_method
	.section	.rodata
.LC9:
	.string	"top: %d\n"
.LC10:
	.string	"%d "
	.text
	.globl	display_puzzle
	.type	display_puzzle, @function
display_puzzle:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -8[rbp], 0
	jmp	.L9
.L17:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	mov	esi, eax
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -4[rbp], 0
	jmp	.L10
.L16:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR 4[rax+rdx*8]
	cmp	eax, -1
	je	.L11
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	test	eax, eax
	jne	.L12
	mov	edi, 72
	call	putchar@PLT
	jmp	.L13
.L12:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 1
	jne	.L14
	mov	edi, 83
	call	putchar@PLT
	jmp	.L13
.L14:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 2
	jne	.L15
	mov	edi, 68
	call	putchar@PLT
	jmp	.L13
.L15:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 3
	jne	.L13
	mov	edi, 67
	call	putchar@PLT
.L13:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR 4[rax+rdx*8]
	mov	esi, eax
	lea	rdi, .LC10[rip]
	mov	eax, 0
	call	printf@PLT
.L11:
	add	DWORD PTR -4[rbp], 1
.L10:
	cmp	DWORD PTR -4[rbp], 31
	jle	.L16
	mov	edi, 10
	call	putchar@PLT
	add	DWORD PTR -8[rbp], 1
.L9:
	cmp	DWORD PTR -8[rbp], 15
	jle	.L17
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	display_puzzle, .-display_puzzle
	.globl	add_frontier_front
	.type	add_frontier_front, @function
add_frontier_front:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	edi, 24
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L19
	mov	eax, -1
	jmp	.L20
.L19:
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	mov	QWORD PTR [rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], 0
	mov	rdx, QWORD PTR frontier_head[rip]
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 16[rax], rdx
	mov	rax, QWORD PTR frontier_head[rip]
	test	rax, rax
	jne	.L21
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_head[rip], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_tail[rip], rax
	jmp	.L22
.L21:
	mov	rax, QWORD PTR frontier_head[rip]
	mov	rdx, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_head[rip], rax
.L22:
	mov	eax, 0
.L20:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	add_frontier_front, .-add_frontier_front
	.globl	add_frontier_back
	.type	add_frontier_back, @function
add_frontier_back:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	edi, 24
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L24
	mov	eax, -1
	jmp	.L25
.L24:
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	mov	QWORD PTR [rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 16[rax], 0
	mov	rdx, QWORD PTR frontier_tail[rip]
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	mov	rax, QWORD PTR frontier_tail[rip]
	test	rax, rax
	jne	.L26
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_head[rip], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_tail[rip], rax
	jmp	.L27
.L26:
	mov	rax, QWORD PTR frontier_tail[rip]
	mov	rdx, QWORD PTR -8[rbp]
	mov	QWORD PTR 16[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_tail[rip], rax
.L27:
	mov	eax, 0
.L25:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	add_frontier_back, .-add_frontier_back
	.globl	add_frontier_in_order
	.type	add_frontier_in_order, @function
add_frontier_in_order:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	edi, 24
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L29
	mov	eax, -1
	jmp	.L30
.L29:
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	mov	QWORD PTR [rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 16[rax], 0
	mov	rax, QWORD PTR frontier_head[rip]
	test	rax, rax
	jne	.L31
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_head[rip], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_tail[rip], rax
	jmp	.L32
.L31:
	mov	rax, QWORD PTR frontier_head[rip]
	mov	QWORD PTR -16[rbp], rax
	jmp	.L33
.L35:
	mov	rax, QWORD PTR -16[rbp]
	mov	rax, QWORD PTR 16[rax]
	mov	QWORD PTR -16[rbp], rax
.L33:
	cmp	QWORD PTR -16[rbp], 0
	je	.L34
	mov	rax, QWORD PTR -16[rbp]
	mov	rax, QWORD PTR [rax]
	mov	edx, DWORD PTR 4168[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4168[rax]
	cmp	edx, eax
	jg	.L35
	mov	rax, QWORD PTR -16[rbp]
	mov	rax, QWORD PTR [rax]
	mov	edx, DWORD PTR 4168[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4168[rax]
	cmp	edx, eax
	jne	.L34
	mov	rax, QWORD PTR -16[rbp]
	mov	rax, QWORD PTR [rax]
	mov	edx, DWORD PTR 4160[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4160[rax]
	cmp	edx, eax
	jg	.L35
.L34:
	cmp	QWORD PTR -16[rbp], 0
	je	.L36
	mov	rax, QWORD PTR -16[rbp]
	mov	rax, QWORD PTR 8[rax]
	test	rax, rax
	je	.L37
	mov	rax, QWORD PTR -16[rbp]
	mov	rax, QWORD PTR 8[rax]
	mov	rdx, QWORD PTR -8[rbp]
	mov	QWORD PTR 16[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -16[rbp]
	mov	QWORD PTR 16[rax], rdx
	mov	rax, QWORD PTR -16[rbp]
	mov	rdx, QWORD PTR 8[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	mov	rax, QWORD PTR -16[rbp]
	mov	rdx, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	jmp	.L32
.L37:
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -16[rbp]
	mov	QWORD PTR 16[rax], rdx
	mov	rax, QWORD PTR -16[rbp]
	mov	rdx, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_head[rip], rax
	jmp	.L32
.L36:
	mov	rax, QWORD PTR frontier_tail[rip]
	mov	rdx, QWORD PTR -8[rbp]
	mov	QWORD PTR 16[rax], rdx
	mov	rdx, QWORD PTR frontier_tail[rip]
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 8[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR frontier_tail[rip], rax
.L32:
	mov	eax, 0
.L30:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	add_frontier_in_order, .-add_frontier_in_order
	.section	.rodata
.LC11:
	.string	"r"
	.align 8
.LC12:
	.string	"Cannot open file %s. Program terminates.\n"
.LC13:
	.string	"%c"
	.text
	.globl	read_puzzle
	.type	read_puzzle, @function
read_puzzle:
.LFB12:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	QWORD PTR -40[rbp], rdi
	mov	QWORD PTR -48[rbp], rsi
	mov	QWORD PTR -56[rbp], rdx
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -40[rbp]
	lea	rsi, .LC11[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -24[rbp], rax
	cmp	QWORD PTR -24[rbp], 0
	jne	.L39
	mov	rax, QWORD PTR -40[rbp]
	mov	rsi, rax
	lea	rdi, .LC12[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, -1
	jmp	.L53
.L39:
	mov	DWORD PTR -32[rbp], 0
	jmp	.L41
.L44:
	mov	DWORD PTR -28[rbp], 0
	jmp	.L42
.L43:
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -48[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	mov	DWORD PTR [rdx+rax*8], -1
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -48[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	mov	DWORD PTR 4[rdx+rax*8], -1
	add	DWORD PTR -28[rbp], 1
.L42:
	cmp	DWORD PTR -28[rbp], 31
	jle	.L43
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -56[rbp]
	add	rax, rdx
	mov	DWORD PTR [rax], -1
	add	DWORD PTR -32[rbp], 1
.L41:
	cmp	DWORD PTR -32[rbp], 15
	jle	.L44
	mov	DWORD PTR -32[rbp], 0
	jmp	.L45
.L52:
	mov	DWORD PTR -28[rbp], 0
	jmp	.L46
.L51:
	lea	rdx, -16[rbp]
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, .LC13[rip]
	mov	rdi, rax
	mov	eax, 0
	call	__isoc99_fscanf@PLT
	movzx	eax, BYTE PTR -16[rbp]
	cmp	al, 72
	jne	.L47
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -48[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	mov	DWORD PTR [rdx+rax*8], 0
	jmp	.L48
.L47:
	movzx	eax, BYTE PTR -16[rbp]
	cmp	al, 83
	jne	.L49
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -48[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	mov	DWORD PTR [rdx+rax*8], 1
	jmp	.L48
.L49:
	movzx	eax, BYTE PTR -16[rbp]
	cmp	al, 68
	jne	.L50
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -48[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	mov	DWORD PTR [rdx+rax*8], 2
	jmp	.L48
.L50:
	movzx	eax, BYTE PTR -16[rbp]
	cmp	al, 67
	jne	.L48
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -48[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	mov	DWORD PTR [rdx+rax*8], 3
.L48:
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -48[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	sal	rax, 3
	add	rax, rdx
	lea	rdx, 4[rax]
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, .LC10[rip]
	mov	rdi, rax
	mov	eax, 0
	call	__isoc99_fscanf@PLT
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -56[rbp]
	add	rax, rdx
	mov	edx, DWORD PTR [rax]
	add	edx, 1
	mov	DWORD PTR [rax], edx
	add	DWORD PTR -28[rbp], 1
.L46:
	cmp	DWORD PTR -28[rbp], 3
	jle	.L51
	add	DWORD PTR -32[rbp], 1
.L45:
	cmp	DWORD PTR -32[rbp], 7
	jle	.L52
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	eax, 0
.L53:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L54
	call	__stack_chk_fail@PLT
.L54:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	read_puzzle, .-read_puzzle
	.globl	is_solution
	.type	is_solution, @function
is_solution:
.LFB13:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4144[rax]
	cmp	eax, 7
	jne	.L56
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4148[rax]
	cmp	eax, 7
	jne	.L56
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4152[rax]
	cmp	eax, 7
	jne	.L56
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4156[rax]
	cmp	eax, 7
	jne	.L56
	mov	eax, 1
	jmp	.L57
.L56:
	mov	eax, 0
.L57:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	is_solution, .-is_solution
	.globl	move_to_foundation
	.type	move_to_foundation, @function
move_to_foundation:
.LFB14:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	DWORD PTR -16[rbp], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rsi, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rsi
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR [rax+rcx*8], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rsi, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rsi
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR 4[rax+rcx*8], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR [rax+rdx*8], -1
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR 4[rax+rdx*8], -1
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, -1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	move_to_foundation, .-move_to_foundation
	.globl	move_to_empty_foundation
	.type	move_to_empty_foundation, @function
move_to_empty_foundation:
.LFB15:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	DWORD PTR -4[rbp], 12
	jmp	.L60
.L62:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	cmp	eax, -1
	jne	.L61
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, 1[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, edx
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rsi
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR [rax+rcx*8], edx
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, edx
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rsi
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR 4[rax+rcx*8], edx
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR [rax+rdx*8], -1
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR 4[rax+rdx*8], -1
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, -1[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	mov	DWORD PTR -4[rbp], 16
.L61:
	add	DWORD PTR -4[rbp], 1
.L60:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L62
	nop
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	move_to_empty_foundation, .-move_to_empty_foundation
	.globl	move_to_new_stack
	.type	move_to_new_stack, @function
move_to_new_stack:
.LFB16:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	DWORD PTR -4[rbp], 0
	jmp	.L64
.L66:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	cmp	eax, -1
	jne	.L65
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, 1[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, edx
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rsi
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR [rax+rcx*8], edx
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, edx
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rsi
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR 4[rax+rcx*8], edx
	mov	DWORD PTR -4[rbp], 9
.L65:
	add	DWORD PTR -4[rbp], 1
.L64:
	cmp	DWORD PTR -4[rbp], 7
	jle	.L66
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR [rax+rdx*8], -1
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR 4[rax+rdx*8], -1
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, -1[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -28[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE16:
	.size	move_to_new_stack, .-move_to_new_stack
	.globl	move_to_stack
	.type	move_to_stack, @function
move_to_stack:
.LFB17:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	DWORD PTR -16[rbp], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rsi, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rsi
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR [rax+rcx*8], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rsi, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rsi
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR 4[rax+rcx*8], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR [rax+rdx*8], -1
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR 4[rax+rdx*8], -1
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, -1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE17:
	.size	move_to_stack, .-move_to_stack
	.globl	move_to_a_freecell
	.type	move_to_a_freecell, @function
move_to_a_freecell:
.LFB18:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4128[rax]
	cmp	eax, -1
	jne	.L69
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4128[rax]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4128[rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 2048[rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 2052[rax], edx
	jmp	.L70
.L69:
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4132[rax]
	cmp	eax, -1
	jne	.L71
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4132[rax]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4132[rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 2304[rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 2308[rax], edx
	jmp	.L70
.L71:
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4136[rax]
	cmp	eax, -1
	jne	.L72
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4136[rax]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4136[rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 2560[rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 2564[rax], edx
	jmp	.L70
.L72:
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4140[rax]
	cmp	eax, -1
	jne	.L70
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4140[rax]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4140[rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 2816[rax], edx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 2820[rax], edx
.L70:
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR [rax+rdx*8], -1
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR 4[rax+rdx*8], -1
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	lea	ecx, -1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], ecx
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE18:
	.size	move_to_a_freecell, .-move_to_a_freecell
	.globl	equal_nodes
	.type	equal_nodes, @function
equal_nodes:
.LFB19:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	mov	DWORD PTR -8[rbp], 0
	jmp	.L74
.L80:
	mov	DWORD PTR -4[rbp], 0
	jmp	.L75
.L79:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -32[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -8[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	eax, DWORD PTR [rax+rcx*8]
	cmp	edx, eax
	jne	.L76
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -32[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -8[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	eax, DWORD PTR 4[rax+rcx*8]
	cmp	edx, eax
	je	.L77
.L76:
	mov	eax, 0
	jmp	.L78
.L77:
	add	DWORD PTR -4[rbp], 1
.L75:
	cmp	DWORD PTR -4[rbp], 31
	jle	.L79
	add	DWORD PTR -8[rbp], 1
.L74:
	cmp	DWORD PTR -8[rbp], 11
	jle	.L80
	mov	eax, 1
.L78:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE19:
	.size	equal_nodes, .-equal_nodes
	.globl	check_with_parents
	.type	check_with_parents, @function
check_with_parents:
.LFB20:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 24
	mov	QWORD PTR -24[rbp], rdi
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR 4176[rax]
	mov	QWORD PTR -8[rbp], rax
	jmp	.L82
.L85:
	mov	rdx, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	equal_nodes
	test	eax, eax
	je	.L83
	mov	eax, 0
	jmp	.L84
.L83:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 4176[rax]
	mov	QWORD PTR -8[rbp], rax
.L82:
	cmp	QWORD PTR -8[rbp], 0
	jne	.L85
	mov	eax, 1
.L84:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE20:
	.size	check_with_parents, .-check_with_parents
	.globl	freecells_count
	.type	freecells_count, @function
freecells_count:
.LFB21:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -4[rbp], 0
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4128[rax]
	cmp	eax, -1
	jne	.L87
	add	DWORD PTR -4[rbp], 1
.L87:
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4132[rax]
	cmp	eax, -1
	jne	.L88
	add	DWORD PTR -4[rbp], 1
.L88:
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4136[rax]
	cmp	eax, -1
	jne	.L89
	add	DWORD PTR -4[rbp], 1
.L89:
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4140[rax]
	cmp	eax, -1
	jne	.L90
	add	DWORD PTR -4[rbp], 1
.L90:
	mov	eax, DWORD PTR -4[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE21:
	.size	freecells_count, .-freecells_count
	.globl	num_cards_at_foundations
	.type	num_cards_at_foundations, @function
num_cards_at_foundations:
.LFB22:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -4[rbp], 0
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4144[rax]
	cmp	eax, -1
	je	.L93
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4144[rax]
	add	DWORD PTR -4[rbp], eax
	add	DWORD PTR -4[rbp], 1
.L93:
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4148[rax]
	cmp	eax, -1
	je	.L94
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4148[rax]
	add	DWORD PTR -4[rbp], eax
	add	DWORD PTR -4[rbp], 1
.L94:
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4152[rax]
	cmp	eax, -1
	je	.L95
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4152[rax]
	add	DWORD PTR -4[rbp], eax
	add	DWORD PTR -4[rbp], 1
.L95:
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4156[rax]
	cmp	eax, -1
	je	.L96
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4156[rax]
	add	DWORD PTR -4[rbp], eax
	add	DWORD PTR -4[rbp], 1
.L96:
	mov	edx, DWORD PTR -4[rbp]
	mov	eax, edx
	sal	eax, 2
	add	eax, edx
	add	eax, eax
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE22:
	.size	num_cards_at_foundations, .-num_cards_at_foundations
	.globl	freestacks_count
	.type	freestacks_count, @function
freestacks_count:
.LFB23:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -4[rbp], 0
	mov	DWORD PTR -8[rbp], 0
	jmp	.L99
.L101:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -8[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR 4[rax+rdx*8]
	cmp	eax, -1
	jne	.L100
	add	DWORD PTR -4[rbp], 1
.L100:
	add	DWORD PTR -8[rbp], 1
.L99:
	cmp	DWORD PTR -8[rbp], 7
	jle	.L101
	mov	edx, DWORD PTR -4[rbp]
	mov	eax, edx
	sal	eax, 2
	add	eax, edx
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE23:
	.size	freestacks_count, .-freestacks_count
	.globl	heuristic
	.type	heuristic, @function
heuristic:
.LFB24:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 24
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -16[rbp], 0
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	freestacks_count
	mov	DWORD PTR -12[rbp], eax
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	freecells_count
	mov	DWORD PTR -8[rbp], eax
	mov	rax, QWORD PTR -24[rbp]
	mov	rdi, rax
	call	num_cards_at_foundations
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	sub	eax, DWORD PTR -12[rbp]
	sub	eax, DWORD PTR -8[rbp]
	mov	DWORD PTR -16[rbp], eax
	mov	eax, DWORD PTR -16[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE24:
	.size	heuristic, .-heuristic
	.globl	evaluate_child
	.type	evaluate_child, @function
evaluate_child:
.LFB25:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 16
	.cfi_offset 3, -24
	mov	QWORD PTR -16[rbp], rdi
	mov	DWORD PTR -20[rbp], esi
	cmp	DWORD PTR -20[rbp], 3
	jne	.L106
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	heuristic
	mov	rdx, QWORD PTR -16[rbp]
	mov	DWORD PTR 4168[rdx], eax
	jmp	.L109
.L106:
	cmp	DWORD PTR -20[rbp], 4
	jne	.L108
	mov	rax, QWORD PTR -16[rbp]
	mov	ebx, DWORD PTR 4164[rax]
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	heuristic
	lea	edx, [rbx+rax]
	mov	rax, QWORD PTR -16[rbp]
	mov	DWORD PTR 4168[rax], edx
	jmp	.L109
.L108:
	mov	rax, QWORD PTR -16[rbp]
	mov	DWORD PTR 4168[rax], 0
.L109:
	nop
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE25:
	.size	evaluate_child, .-evaluate_child
	.globl	create_child
	.type	create_child, @function
create_child:
.LFB26:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 48
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	DWORD PTR -32[rbp], edx
	mov	DWORD PTR -36[rbp], ecx
	mov	DWORD PTR -40[rbp], r8d
	mov	DWORD PTR -44[rbp], r9d
	mov	edi, 4368
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L111
	mov	DWORD PTR mem_error[rip], -1
	jmp	.L110
.L111:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -32[rbp]
	movsx	rdx, edx
	lea	rcx, 526[rdx]
	mov	rdx, QWORD PTR -8[rbp]
	mov	QWORD PTR [rax+rcx*8], rdx
	mov	DWORD PTR -16[rbp], 0
	jmp	.L113
.L114:
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 526
	mov	QWORD PTR [rax+rdx*8], 0
	add	DWORD PTR -16[rbp], 1
.L113:
	cmp	DWORD PTR -16[rbp], 19
	jle	.L114
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	mov	QWORD PTR 4176[rax], rdx
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -28[rbp]
	mov	DWORD PTR 4184[rax], edx
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4164[rax]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4164[rax], edx
	mov	DWORD PTR -16[rbp], 0
	jmp	.L115
.L118:
	mov	DWORD PTR -12[rbp], 0
	jmp	.L116
.L117:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -12[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR [rax+rcx*8], edx
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -12[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR 4[rax+rcx*8], edx
	add	DWORD PTR -12[rbp], 1
.L116:
	cmp	DWORD PTR -12[rbp], 31
	jle	.L117
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	DWORD PTR [rax+rcx*4], edx
	add	DWORD PTR -16[rbp], 1
.L115:
	cmp	DWORD PTR -16[rbp], 15
	jle	.L118
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -40[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	ecx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -40[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	rdx, QWORD PTR [rdx+rcx*8]
	mov	QWORD PTR 4188[rax], rdx
	cmp	DWORD PTR -28[rbp], 0
	jne	.L119
	cmp	DWORD PTR -44[rbp], 0
	jne	.L120
	mov	edx, DWORD PTR -40[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	move_to_empty_foundation
	jmp	.L121
.L120:
	mov	edx, DWORD PTR -44[rbp]
	mov	ecx, DWORD PTR -40[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, ecx
	mov	rdi, rax
	call	move_to_foundation
	jmp	.L121
.L119:
	cmp	DWORD PTR -28[rbp], 1
	jne	.L122
	mov	edx, DWORD PTR -40[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	move_to_new_stack
	jmp	.L121
.L122:
	cmp	DWORD PTR -28[rbp], 2
	jne	.L123
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -44[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	ecx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -44[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	rdx, QWORD PTR [rdx+rcx*8]
	mov	QWORD PTR 4196[rax], rdx
	mov	edx, DWORD PTR -44[rbp]
	mov	ecx, DWORD PTR -40[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, ecx
	mov	rdi, rax
	call	move_to_stack
	jmp	.L121
.L123:
	mov	edx, DWORD PTR -40[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	move_to_a_freecell
.L121:
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	check_with_parents
	test	eax, eax
	jne	.L124
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -32[rbp]
	movsx	rdx, edx
	add	rdx, 526
	mov	QWORD PTR [rax+rdx*8], 0
	jmp	.L110
.L124:
	mov	edx, DWORD PTR -36[rbp]
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	evaluate_child
.L110:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE26:
	.size	create_child, .-create_child
	.globl	find_children
	.type	find_children, @function
find_children:
.LFB27:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	DWORD PTR -8[rbp], 0
	mov	DWORD PTR -12[rbp], 0
	jmp	.L126
.L146:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, -1
	je	.L127
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR 4[rax+rdx*8]
	test	eax, eax
	jne	.L128
	mov	esi, DWORD PTR -12[rbp]
	mov	ecx, DWORD PTR -28[rbp]
	mov	edx, DWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r9d, 0
	mov	r8d, esi
	mov	esi, 0
	mov	rdi, rax
	call	create_child
	add	DWORD PTR -8[rbp], 1
	jmp	.L127
.L128:
	mov	DWORD PTR -4[rbp], 12
	jmp	.L129
.L131:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	eax, DWORD PTR [rax+rcx*8]
	cmp	edx, eax
	jne	.L130
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	eax, DWORD PTR 4[rax+rcx*8]
	add	eax, 1
	cmp	edx, eax
	jne	.L130
	mov	edi, DWORD PTR -4[rbp]
	mov	esi, DWORD PTR -12[rbp]
	mov	ecx, DWORD PTR -28[rbp]
	mov	edx, DWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r9d, edi
	mov	r8d, esi
	mov	esi, 0
	mov	rdi, rax
	call	create_child
	add	DWORD PTR -8[rbp], 1
	mov	DWORD PTR -4[rbp], 16
.L130:
	add	DWORD PTR -4[rbp], 1
.L129:
	cmp	DWORD PTR -4[rbp], 15
	jle	.L131
	mov	DWORD PTR -4[rbp], 0
	jmp	.L132
.L142:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	test	eax, eax
	je	.L133
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 2
	jne	.L134
.L133:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 1
	je	.L135
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 3
	jne	.L134
.L135:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	eax, DWORD PTR 4[rax+rcx*8]
	sub	eax, 1
	cmp	edx, eax
	jne	.L137
	mov	edi, DWORD PTR -4[rbp]
	mov	esi, DWORD PTR -12[rbp]
	mov	ecx, DWORD PTR -28[rbp]
	mov	edx, DWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r9d, edi
	mov	r8d, esi
	mov	esi, 2
	mov	rdi, rax
	call	create_child
	add	DWORD PTR -8[rbp], 1
	jmp	.L137
.L134:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 1
	je	.L138
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 3
	jne	.L139
.L138:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	test	eax, eax
	je	.L140
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR [rax+rdx*8]
	cmp	eax, 2
	jne	.L139
.L140:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -4[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	eax, DWORD PTR 4[rax+rcx*8]
	sub	eax, 1
	cmp	edx, eax
	jne	.L137
	mov	edi, DWORD PTR -4[rbp]
	mov	esi, DWORD PTR -12[rbp]
	mov	ecx, DWORD PTR -28[rbp]
	mov	edx, DWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r9d, edi
	mov	r8d, esi
	mov	esi, 2
	mov	rdi, rax
	call	create_child
	add	DWORD PTR -8[rbp], 1
	jmp	.L137
.L139:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	cmp	eax, -1
	jne	.L137
	mov	edi, DWORD PTR -4[rbp]
	mov	esi, DWORD PTR -12[rbp]
	mov	ecx, DWORD PTR -28[rbp]
	mov	edx, DWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r9d, edi
	mov	r8d, esi
	mov	esi, 1
	mov	rdi, rax
	call	create_child
	add	DWORD PTR -8[rbp], 1
	mov	DWORD PTR -4[rbp], 16
.L137:
	add	DWORD PTR -4[rbp], 1
.L132:
	cmp	DWORD PTR -4[rbp], 7
	jle	.L142
	cmp	DWORD PTR -12[rbp], 8
	je	.L127
	cmp	DWORD PTR -12[rbp], 9
	je	.L127
	cmp	DWORD PTR -12[rbp], 10
	je	.L127
	cmp	DWORD PTR -12[rbp], 11
	je	.L127
	mov	DWORD PTR -4[rbp], 8
	jmp	.L143
.L145:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -4[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	eax, DWORD PTR [rax+rdx*4]
	cmp	eax, -1
	jne	.L144
	mov	edi, DWORD PTR -4[rbp]
	mov	esi, DWORD PTR -12[rbp]
	mov	ecx, DWORD PTR -28[rbp]
	mov	edx, DWORD PTR -8[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r9d, edi
	mov	r8d, esi
	mov	esi, 3
	mov	rdi, rax
	call	create_child
	add	DWORD PTR -8[rbp], 1
	mov	DWORD PTR -4[rbp], 12
.L144:
	add	DWORD PTR -4[rbp], 1
.L143:
	cmp	DWORD PTR -4[rbp], 11
	jle	.L145
.L127:
	add	DWORD PTR -12[rbp], 1
.L126:
	cmp	DWORD PTR -12[rbp], 11
	jle	.L146
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE27:
	.size	find_children, .-find_children
	.globl	initialize_search
	.type	initialize_search, @function
initialize_search:
.LFB28:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	QWORD PTR -40[rbp], rdi
	mov	QWORD PTR -48[rbp], rsi
	mov	DWORD PTR -52[rbp], edx
	mov	QWORD PTR -8[rbp], 0
	mov	edi, 4368
	call	malloc@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	QWORD PTR 4176[rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4184[rax], -1
	mov	DWORD PTR -12[rbp], 0
	jmp	.L148
.L149:
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -12[rbp]
	movsx	rdx, edx
	add	rdx, 526
	mov	QWORD PTR [rax+rdx*8], 0
	add	DWORD PTR -12[rbp], 1
.L148:
	cmp	DWORD PTR -12[rbp], 19
	jle	.L149
	mov	DWORD PTR -20[rbp], 0
	jmp	.L150
.L153:
	mov	DWORD PTR -16[rbp], 0
	jmp	.L151
.L152:
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -20[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR [rax+rdx*8], -1
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -20[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	DWORD PTR 4[rax+rdx*8], -1
	add	DWORD PTR -16[rbp], 1
.L151:
	cmp	DWORD PTR -16[rbp], 31
	jle	.L152
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR -20[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	DWORD PTR [rax+rdx*4], -1
	add	DWORD PTR -20[rbp], 1
.L150:
	cmp	DWORD PTR -20[rbp], 15
	jle	.L153
	mov	DWORD PTR -20[rbp], 0
	jmp	.L154
.L157:
	mov	DWORD PTR -16[rbp], 0
	jmp	.L155
.L156:
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	mov	edx, DWORD PTR [rdx+rax*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -20[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR [rax+rcx*8], edx
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	sal	rax, 8
	mov	rdx, rax
	mov	rax, QWORD PTR -40[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	mov	edx, DWORD PTR 4[rdx+rax*8]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -16[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -20[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	DWORD PTR 4[rax+rcx*8], edx
	add	DWORD PTR -16[rbp], 1
.L155:
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	DWORD PTR -16[rbp], eax
	jle	.L156
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	edx, DWORD PTR [rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, DWORD PTR -20[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	DWORD PTR [rax+rcx*4], edx
	add	DWORD PTR -20[rbp], 1
.L154:
	cmp	DWORD PTR -20[rbp], 7
	jle	.L157
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4164[rax], 0
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	heuristic
	mov	rdx, QWORD PTR -8[rbp]
	mov	DWORD PTR 4160[rdx], eax
	cmp	DWORD PTR -52[rbp], 3
	jne	.L158
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR 4160[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4168[rax], edx
	jmp	.L159
.L158:
	cmp	DWORD PTR -52[rbp], 4
	jne	.L160
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, DWORD PTR 4164[rax]
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4160[rax]
	add	edx, eax
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4168[rax], edx
	jmp	.L159
.L160:
	mov	rax, QWORD PTR -8[rbp]
	mov	DWORD PTR 4168[rax], 0
.L159:
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	add_frontier_front
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE28:
	.size	initialize_search, .-initialize_search
	.globl	complete_solution
	.type	complete_solution, @function
complete_solution:
.LFB29:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	rax, QWORD PTR -24[rbp]
	mov	QWORD PTR -8[rbp], rax
	mov	DWORD PTR -16[rbp], 0
	jmp	.L162
.L168:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR 4[rax+rdx*8]
	test	eax, eax
	jne	.L163
	mov	ecx, DWORD PTR -16[rbp]
	mov	edx, DWORD PTR -28[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r9d, 0
	mov	r8d, ecx
	mov	ecx, edx
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	call	create_child
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR 4208[rax]
	mov	edx, DWORD PTR -28[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	complete_solution
	mov	QWORD PTR -8[rbp], rax
	jmp	.L164
.L163:
	mov	DWORD PTR -12[rbp], 12
	jmp	.L165
.L167:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR [rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -12[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -12[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	eax, DWORD PTR [rax+rcx*8]
	cmp	edx, eax
	jne	.L166
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -16[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	edx, DWORD PTR 4[rax+rdx*8]
	mov	rax, QWORD PTR -24[rbp]
	mov	ecx, DWORD PTR -12[rbp]
	movsx	rcx, ecx
	add	rcx, 1024
	mov	ecx, DWORD PTR [rax+rcx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rsi, ecx
	mov	ecx, DWORD PTR -12[rbp]
	movsx	rcx, ecx
	sal	rcx, 5
	add	rcx, rsi
	mov	eax, DWORD PTR 4[rax+rcx*8]
	add	eax, 1
	cmp	edx, eax
	jne	.L166
	mov	esi, DWORD PTR -12[rbp]
	mov	ecx, DWORD PTR -16[rbp]
	mov	edx, DWORD PTR -28[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	r9d, esi
	mov	r8d, ecx
	mov	ecx, edx
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	call	create_child
	mov	rax, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR 4208[rax]
	mov	edx, DWORD PTR -28[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	complete_solution
	mov	QWORD PTR -8[rbp], rax
.L166:
	add	DWORD PTR -12[rbp], 1
.L165:
	cmp	DWORD PTR -12[rbp], 15
	jle	.L167
.L164:
	add	DWORD PTR -16[rbp], 1
.L162:
	cmp	DWORD PTR -16[rbp], 11
	jle	.L168
	mov	rax, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE29:
	.size	complete_solution, .-complete_solution
	.section	.rodata
.LC14:
	.string	"Timeout"
	.align 8
.LC15:
	.string	"Memory exhausted while creating new child node. Search is terminated..."
	.align 8
.LC16:
	.string	"Memory exhausted while creating new frontier node. Search is terminated..."
	.text
	.globl	search
	.type	search, @function
search:
.LFB30:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	DWORD PTR -52[rbp], edi
	jmp	.L171
.L189:
	call	clock@PLT
	mov	QWORD PTR -32[rbp], rax
	mov	rdx, QWORD PTR t1[rip]
	mov	rax, QWORD PTR -32[rbp]
	sub	rax, rdx
	cmp	rax, 300000000
	jle	.L172
	lea	rdi, .LC14[rip]
	call	puts@PLT
	mov	eax, 0
	jmp	.L173
.L172:
	mov	rax, QWORD PTR frontier_head[rip]
	mov	rax, QWORD PTR [rax]
	mov	QWORD PTR -24[rbp], rax
	mov	DWORD PTR -36[rbp], 0
	mov	DWORD PTR -44[rbp], 12
	jmp	.L174
.L176:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -44[rbp]
	movsx	rdx, edx
	add	rdx, 1024
	mov	edx, DWORD PTR [rax+rdx*4]
	mov	rax, QWORD PTR -24[rbp]
	movsx	rcx, edx
	mov	edx, DWORD PTR -44[rbp]
	movsx	rdx, edx
	sal	rdx, 5
	add	rdx, rcx
	mov	eax, DWORD PTR 4[rax+rdx*8]
	cmp	eax, 7
	jne	.L175
	add	DWORD PTR -36[rbp], 1
.L175:
	add	DWORD PTR -44[rbp], 1
.L174:
	cmp	DWORD PTR -44[rbp], 15
	jle	.L176
	cmp	DWORD PTR -36[rbp], 3
	jne	.L177
	mov	edx, DWORD PTR -52[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	complete_solution
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	jmp	.L173
.L177:
	mov	rax, QWORD PTR frontier_head[rip]
	mov	QWORD PTR -16[rbp], rax
	mov	rax, QWORD PTR frontier_head[rip]
	mov	rax, QWORD PTR 16[rax]
	mov	QWORD PTR frontier_head[rip], rax
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	rax, QWORD PTR frontier_head[rip]
	test	rax, rax
	jne	.L178
	mov	QWORD PTR frontier_tail[rip], 0
	jmp	.L179
.L178:
	mov	rax, QWORD PTR frontier_head[rip]
	mov	QWORD PTR 8[rax], 0
.L179:
	mov	edx, DWORD PTR -52[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	find_children
	mov	eax, DWORD PTR mem_error[rip]
	cmp	eax, -1
	jne	.L180
	lea	rdi, .LC15[rip]
	call	puts@PLT
	mov	eax, 0
	jmp	.L173
.L180:
	mov	DWORD PTR -44[rbp], 0
	jmp	.L181
.L188:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -44[rbp]
	movsx	rdx, edx
	add	rdx, 526
	mov	rax, QWORD PTR [rax+rdx*8]
	test	rax, rax
	je	.L182
	cmp	DWORD PTR -52[rbp], 2
	jne	.L183
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -44[rbp]
	movsx	rdx, edx
	add	rdx, 526
	mov	rax, QWORD PTR [rax+rdx*8]
	mov	rdi, rax
	call	add_frontier_front
	mov	DWORD PTR -40[rbp], eax
	jmp	.L184
.L183:
	cmp	DWORD PTR -52[rbp], 1
	jne	.L185
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -44[rbp]
	movsx	rdx, edx
	add	rdx, 526
	mov	rax, QWORD PTR [rax+rdx*8]
	mov	rdi, rax
	call	add_frontier_back
	mov	DWORD PTR -40[rbp], eax
	jmp	.L184
.L185:
	cmp	DWORD PTR -52[rbp], 3
	je	.L186
	cmp	DWORD PTR -52[rbp], 4
	jne	.L184
.L186:
	mov	rax, QWORD PTR -24[rbp]
	mov	edx, DWORD PTR -44[rbp]
	movsx	rdx, edx
	add	rdx, 526
	mov	rax, QWORD PTR [rax+rdx*8]
	mov	rdi, rax
	call	add_frontier_in_order
	mov	DWORD PTR -40[rbp], eax
.L184:
	cmp	DWORD PTR -40[rbp], 0
	jns	.L187
	lea	rdi, .LC16[rip]
	call	puts@PLT
	mov	eax, 0
	jmp	.L173
.L182:
	mov	DWORD PTR -44[rbp], 20
.L187:
	add	DWORD PTR -44[rbp], 1
.L181:
	cmp	DWORD PTR -44[rbp], 19
	jle	.L188
.L171:
	mov	rax, QWORD PTR frontier_head[rip]
	test	rax, rax
	jne	.L189
	mov	eax, 0
.L173:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE30:
	.size	search, .-search
	.globl	extract_solution
	.type	extract_solution, @function
extract_solution:
.LFB31:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	QWORD PTR -24[rbp], rdi
	mov	rax, QWORD PTR -24[rbp]
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR 4164[rax]
	mov	DWORD PTR solution_length[rip], eax
	mov	eax, DWORD PTR solution_length[rip]
	cdqe
	sal	rax, 2
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR solution[rip], rax
	mov	eax, DWORD PTR solution_length[rip]
	cdqe
	sal	rax, 3
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR sol_moved0[rip], rax
	mov	eax, DWORD PTR solution_length[rip]
	cdqe
	sal	rax, 3
	mov	rdi, rax
	call	malloc@PLT
	mov	QWORD PTR sol_moved1[rip], rax
	mov	rax, QWORD PTR solution[rip]
	test	rax, rax
	je	.L191
	mov	rax, QWORD PTR sol_moved0[rip]
	test	rax, rax
	je	.L191
	mov	rax, QWORD PTR sol_moved1[rip]
	test	rax, rax
	jne	.L192
.L191:
	mov	DWORD PTR mem_error[rip], -1
	jmp	.L190
.L192:
	mov	rax, QWORD PTR -24[rbp]
	mov	QWORD PTR -8[rbp], rax
	mov	eax, DWORD PTR solution_length[rip]
	mov	DWORD PTR -12[rbp], eax
	jmp	.L194
.L196:
	sub	DWORD PTR -12[rbp], 1
	mov	rdx, QWORD PTR solution[rip]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	sal	rax, 2
	add	rdx, rax
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4184[rax]
	mov	DWORD PTR [rdx], eax
	mov	rdx, QWORD PTR sol_moved0[rip]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	sal	rax, 3
	add	rdx, rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 4188[rax]
	mov	QWORD PTR [rdx], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR 4184[rax]
	cmp	eax, 2
	jne	.L195
	mov	rdx, QWORD PTR sol_moved1[rip]
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	sal	rax, 3
	add	rdx, rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 4196[rax]
	mov	QWORD PTR [rdx], rax
.L195:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 4176[rax]
	mov	QWORD PTR -8[rbp], rax
.L194:
	mov	rax, QWORD PTR -8[rbp]
	mov	rax, QWORD PTR 4176[rax]
	test	rax, rax
	jne	.L196
.L190:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE31:
	.size	extract_solution, .-extract_solution
	.section	.rodata
.LC17:
	.string	"w"
	.align 8
.LC18:
	.string	"Cannot open output file to write solution."
.LC19:
	.string	"Now exiting..."
.LC20:
	.string	"K = %d\n"
.LC21:
	.string	"foundation "
.LC22:
	.string	"newstack "
.LC23:
	.string	"stack "
.LC24:
	.string	"freecell "
.LC25:
	.string	"%d\n"
	.text
	.globl	write_solution_to_file
	.type	write_solution_to_file, @function
write_solution_to_file:
.LFB32:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 64
	mov	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	QWORD PTR -40[rbp], rdx
	mov	QWORD PTR -48[rbp], rcx
	mov	QWORD PTR -56[rbp], r8
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, .LC17[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -8[rbp], rax
	cmp	QWORD PTR -8[rbp], 0
	jne	.L198
	lea	rdi, .LC18[rip]
	call	puts@PLT
	lea	rdi, .LC19[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L197
.L198:
	mov	edx, DWORD PTR -28[rbp]
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC20[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	DWORD PTR -12[rbp], 0
	mov	DWORD PTR -16[rbp], 0
	jmp	.L200
.L215:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -40[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	jne	.L201
	mov	rax, QWORD PTR -8[rbp]
	mov	rcx, rax
	mov	edx, 11
	mov	esi, 1
	lea	rdi, .LC21[rip]
	call	fwrite@PLT
	jmp	.L202
.L201:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -40[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 1
	jne	.L203
	mov	rax, QWORD PTR -8[rbp]
	mov	rcx, rax
	mov	edx, 9
	mov	esi, 1
	lea	rdi, .LC22[rip]
	call	fwrite@PLT
	jmp	.L202
.L203:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -40[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 2
	jne	.L204
	mov	rax, QWORD PTR -8[rbp]
	mov	rcx, rax
	mov	edx, 6
	mov	esi, 1
	lea	rdi, .LC23[rip]
	call	fwrite@PLT
	jmp	.L202
.L204:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -40[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 3
	jne	.L202
	mov	rax, QWORD PTR -8[rbp]
	mov	rcx, rax
	mov	edx, 9
	mov	esi, 1
	lea	rdi, .LC24[rip]
	call	fwrite@PLT
.L202:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	jne	.L205
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 72
	call	fputc@PLT
	jmp	.L206
.L205:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 1
	jne	.L207
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 83
	call	fputc@PLT
	jmp	.L206
.L207:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 2
	jne	.L208
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 68
	call	fputc@PLT
	jmp	.L206
.L208:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 3
	jne	.L206
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 67
	call	fputc@PLT
.L206:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -48[rbp]
	add	rax, rdx
	mov	edx, DWORD PTR 4[rax]
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC10[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -40[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 2
	jne	.L209
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -56[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	jne	.L210
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 72
	call	fputc@PLT
	jmp	.L211
.L210:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -56[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 1
	jne	.L212
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 83
	call	fputc@PLT
	jmp	.L211
.L212:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -56[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 2
	jne	.L213
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 68
	call	fputc@PLT
	jmp	.L211
.L213:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -56[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	cmp	eax, 3
	jne	.L211
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 67
	call	fputc@PLT
.L211:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*8]
	mov	rax, QWORD PTR -56[rbp]
	add	rax, rdx
	mov	edx, DWORD PTR 4[rax]
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC25[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	jmp	.L214
.L209:
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	mov	edi, 10
	call	fputc@PLT
.L214:
	add	DWORD PTR -16[rbp], 1
.L200:
	mov	eax, DWORD PTR -16[rbp]
	cmp	eax, DWORD PTR -28[rbp]
	jl	.L215
.L197:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE32:
	.size	write_solution_to_file, .-write_solution_to_file
	.section	.rodata
	.align 8
.LC26:
	.string	"Wrong method. Use correct syntax:"
.LC27:
	.string	"Solving %s using %s...\n"
	.align 8
.LC28:
	.string	"Memory exhausted while creating solution path..."
.LC29:
	.string	"Solution found! (%d steps)\n"
.LC31:
	.string	"Time spent: %f secs\n"
.LC32:
	.string	"No solution found."
	.text
	.globl	main
	.type	main, @function
main:
.LFB33:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 112
	mov	DWORD PTR -4196[rbp], edi
	mov	QWORD PTR -4208[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -4208[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	get_method
	mov	DWORD PTR -4192[rbp], eax
	cmp	DWORD PTR -4192[rbp], 0
	jns	.L217
	lea	rdi, .LC26[rip]
	call	puts@PLT
	mov	eax, 0
	call	syntax_message
	mov	eax, -1
	jmp	.L223
.L217:
	mov	rax, QWORD PTR -4208[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	lea	rdx, -4176[rbp]
	lea	rcx, -4112[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	read_puzzle
	mov	DWORD PTR -4188[rbp], eax
	cmp	DWORD PTR -4188[rbp], 0
	jns	.L219
	mov	eax, -1
	jmp	.L223
.L219:
	mov	rax, QWORD PTR -4208[rbp]
	add	rax, 8
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR -4208[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC27[rip]
	mov	eax, 0
	call	printf@PLT
	call	clock@PLT
	mov	QWORD PTR t1[rip], rax
	mov	edx, DWORD PTR -4192[rbp]
	lea	rcx, -4176[rbp]
	lea	rax, -4112[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	initialize_search
	mov	eax, DWORD PTR -4192[rbp]
	mov	edi, eax
	call	search
	mov	QWORD PTR -4184[rbp], rax
	call	clock@PLT
	mov	QWORD PTR t2[rip], rax
	cmp	QWORD PTR -4184[rbp], 0
	je	.L220
	mov	rax, QWORD PTR -4184[rbp]
	mov	rdi, rax
	call	extract_solution
	mov	eax, DWORD PTR mem_error[rip]
	cmp	eax, -1
	jne	.L221
	lea	rdi, .LC28[rip]
	call	puts@PLT
	jmp	.L222
.L221:
	mov	eax, DWORD PTR solution_length[rip]
	test	eax, eax
	jle	.L222
	mov	eax, DWORD PTR solution_length[rip]
	mov	esi, eax
	lea	rdi, .LC29[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR t2[rip]
	pxor	xmm0, xmm0
	cvtsi2ss	xmm0, rax
	mov	rax, QWORD PTR t1[rip]
	pxor	xmm1, xmm1
	cvtsi2ss	xmm1, rax
	subss	xmm0, xmm1
	movss	xmm1, DWORD PTR .LC30[rip]
	divss	xmm0, xmm1
	pxor	xmm2, xmm2
	cvtss2sd	xmm2, xmm0
	movq	rax, xmm2
	movq	xmm0, rax
	lea	rdi, .LC31[rip]
	mov	eax, 1
	call	printf@PLT
	mov	rdi, QWORD PTR sol_moved1[rip]
	mov	rcx, QWORD PTR sol_moved0[rip]
	mov	rdx, QWORD PTR solution[rip]
	mov	esi, DWORD PTR solution_length[rip]
	mov	rax, QWORD PTR -4208[rbp]
	add	rax, 24
	mov	rax, QWORD PTR [rax]
	mov	r8, rdi
	mov	rdi, rax
	call	write_solution_to_file
	jmp	.L222
.L220:
	lea	rdi, .LC32[rip]
	call	puts@PLT
.L222:
	mov	eax, 0
.L223:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L224
	call	__stack_chk_fail@PLT
.L224:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE33:
	.size	main, .-main
	.section	.rodata
	.align 4
.LC30:
	.long	1232348160
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.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:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"127964.c"
	.text
	.global	frontier_head
	.bss
	.align	2
	.type	frontier_head, %object
	.size	frontier_head, 4
frontier_head:
	.space	4
	.global	frontier_tail
	.align	2
	.type	frontier_tail, %object
	.size	frontier_tail, 4
frontier_tail:
	.space	4
	.comm	t1,4,4
	.comm	t2,4,4
	.comm	solution_length,4,4
	.comm	solution,4,4
	.comm	sol_moved0,4,4
	.comm	sol_moved1,4,4
	.comm	mem_error,4,4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"puzzle <method> <input-file> <output-file>\012\000"
	.align	2
.LC1:
	.ascii	"where: \000"
	.align	2
.LC2:
	.ascii	"<method> = breadth|depth|best|astar\000"
	.align	2
.LC3:
	.ascii	"<input-file> is a file containing a %dx%d puzzle de"
	.ascii	"scription.\012\000"
	.align	2
.LC4:
	.ascii	"<output-file> is the file where the solution will b"
	.ascii	"e written.\000"
	.text
	.align	2
	.global	syntax_message
	.syntax unified
	.arm
	.fpu softvfp
	.type	syntax_message, %function
syntax_message:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	ldr	r0, .L2
	bl	puts
	ldr	r0, .L2+4
	bl	printf
	ldr	r0, .L2+8
	bl	puts
	mov	r2, #8
	mov	r1, #8
	ldr	r0, .L2+12
	bl	printf
	ldr	r0, .L2+16
	bl	puts
	nop
	pop	{fp, pc}
.L3:
	.align	2
.L2:
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.size	syntax_message, .-syntax_message
	.section	.rodata
	.align	2
.LC5:
	.ascii	"breadth\000"
	.align	2
.LC6:
	.ascii	"depth\000"
	.align	2
.LC7:
	.ascii	"best\000"
	.align	2
.LC8:
	.ascii	"astar\000"
	.text
	.align	2
	.global	get_method
	.syntax unified
	.arm
	.fpu softvfp
	.type	get_method, %function
get_method:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r1, .L10
	ldr	r0, [fp, #-8]
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L5
	mov	r3, #1
	b	.L6
.L5:
	ldr	r1, .L10+4
	ldr	r0, [fp, #-8]
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L7
	mov	r3, #2
	b	.L6
.L7:
	ldr	r1, .L10+8
	ldr	r0, [fp, #-8]
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L8
	mov	r3, #3
	b	.L6
.L8:
	ldr	r1, .L10+12
	ldr	r0, [fp, #-8]
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L9
	mov	r3, #4
	b	.L6
.L9:
	mvn	r3, #0
.L6:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L11:
	.align	2
.L10:
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.size	get_method, .-get_method
	.section	.rodata
	.align	2
.LC9:
	.ascii	"top: %d\012\000"
	.align	2
.LC10:
	.ascii	"%d \000"
	.text
	.align	2
	.global	display_puzzle
	.syntax unified
	.arm
	.fpu softvfp
	.type	display_puzzle, %function
display_puzzle:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L13
.L21:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	mov	r1, r3
	ldr	r0, .L22
	bl	printf
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L14
.L20:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-12]
	lsl	r1, r3, #5
	ldr	r3, [fp, #-8]
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	cmn	r3, #1
	beq	.L15
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-12]
	lsl	r1, r2, #5
	ldr	r2, [fp, #-8]
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #0
	bne	.L16
	mov	r0, #72
	bl	putchar
	b	.L17
.L16:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-12]
	lsl	r1, r2, #5
	ldr	r2, [fp, #-8]
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #1
	bne	.L18
	mov	r0, #83
	bl	putchar
	b	.L17
.L18:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-12]
	lsl	r1, r2, #5
	ldr	r2, [fp, #-8]
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #2
	bne	.L19
	mov	r0, #68
	bl	putchar
	b	.L17
.L19:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-12]
	lsl	r1, r2, #5
	ldr	r2, [fp, #-8]
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #3
	bne	.L17
	mov	r0, #67
	bl	putchar
.L17:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-12]
	lsl	r1, r3, #5
	ldr	r3, [fp, #-8]
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	mov	r1, r3
	ldr	r0, .L22+4
	bl	printf
.L15:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L14:
	ldr	r3, [fp, #-8]
	cmp	r3, #31
	ble	.L20
	mov	r0, #10
	bl	putchar
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L13:
	ldr	r3, [fp, #-12]
	cmp	r3, #15
	ble	.L21
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L23:
	.align	2
.L22:
	.word	.LC9
	.word	.LC10
	.size	display_puzzle, .-display_puzzle
	.align	2
	.global	add_frontier_front
	.syntax unified
	.arm
	.fpu softvfp
	.type	add_frontier_front, %function
add_frontier_front:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	mov	r0, #12
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L25
	mvn	r3, #0
	b	.L26
.L25:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	str	r2, [r3]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	str	r2, [r3, #4]
	ldr	r3, .L29
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #8]
	ldr	r3, .L29
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L27
	ldr	r2, .L29
	ldr	r3, [fp, #-8]
	str	r3, [r2]
	ldr	r2, .L29+4
	ldr	r3, [fp, #-8]
	str	r3, [r2]
	b	.L28
.L27:
	ldr	r3, .L29
	ldr	r3, [r3]
	ldr	r2, [fp, #-8]
	str	r2, [r3, #4]
	ldr	r2, .L29
	ldr	r3, [fp, #-8]
	str	r3, [r2]
.L28:
	mov	r3, #0
.L26:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L30:
	.align	2
.L29:
	.word	frontier_head
	.word	frontier_tail
	.size	add_frontier_front, .-add_frontier_front
	.align	2
	.global	add_frontier_back
	.syntax unified
	.arm
	.fpu softvfp
	.type	add_frontier_back, %function
add_frontier_back:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	mov	r0, #12
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L32
	mvn	r3, #0
	b	.L33
.L32:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	str	r2, [r3]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	str	r2, [r3, #8]
	ldr	r3, .L36
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
	ldr	r3, .L36
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L34
	ldr	r2, .L36+4
	ldr	r3, [fp, #-8]
	str	r3, [r2]
	ldr	r2, .L36
	ldr	r3, [fp, #-8]
	str	r3, [r2]
	b	.L35
.L34:
	ldr	r3, .L36
	ldr	r3, [r3]
	ldr	r2, [fp, #-8]
	str	r2, [r3, #8]
	ldr	r2, .L36
	ldr	r3, [fp, #-8]
	str	r3, [r2]
.L35:
	mov	r3, #0
.L33:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L37:
	.align	2
.L36:
	.word	frontier_tail
	.word	frontier_head
	.size	add_frontier_back, .-add_frontier_back
	.align	2
	.global	add_frontier_in_order
	.syntax unified
	.arm
	.fpu softvfp
	.type	add_frontier_in_order, %function
add_frontier_in_order:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	mov	r0, #12
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L39
	mvn	r3, #0
	b	.L40
.L39:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	str	r2, [r3]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	mov	r2, #0
	str	r2, [r3, #8]
	ldr	r3, .L48
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L41
	ldr	r2, .L48
	ldr	r3, [fp, #-8]
	str	r3, [r2]
	ldr	r2, .L48+4
	ldr	r3, [fp, #-8]
	str	r3, [r2]
	b	.L42
.L41:
	ldr	r3, .L48
	ldr	r3, [r3]
	str	r3, [fp, #-12]
	b	.L43
.L45:
	ldr	r3, [fp, #-12]
	ldr	r3, [r3, #8]
	str	r3, [fp, #-12]
.L43:
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	beq	.L44
	ldr	r3, [fp, #-12]
	ldr	r3, [r3]
	add	r3, r3, #4096
	ldr	r2, [r3, #72]
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #72]
	cmp	r2, r3
	bgt	.L45
	ldr	r3, [fp, #-12]
	ldr	r3, [r3]
	add	r3, r3, #4096
	ldr	r2, [r3, #72]
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #72]
	cmp	r2, r3
	bne	.L44
	ldr	r3, [fp, #-12]
	ldr	r3, [r3]
	add	r3, r3, #4096
	ldr	r2, [r3, #64]
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #64]
	cmp	r2, r3
	bgt	.L45
.L44:
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	beq	.L46
	ldr	r3, [fp, #-12]
	ldr	r3, [r3, #4]
	cmp	r3, #0
	beq	.L47
	ldr	r3, [fp, #-12]
	ldr	r3, [r3, #4]
	ldr	r2, [fp, #-8]
	str	r2, [r3, #8]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	str	r2, [r3, #8]
	ldr	r3, [fp, #-12]
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
	ldr	r3, [fp, #-12]
	ldr	r2, [fp, #-8]
	str	r2, [r3, #4]
	b	.L42
.L47:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	str	r2, [r3, #8]
	ldr	r3, [fp, #-12]
	ldr	r2, [fp, #-8]
	str	r2, [r3, #4]
	ldr	r2, .L48
	ldr	r3, [fp, #-8]
	str	r3, [r2]
	b	.L42
.L46:
	ldr	r3, .L48+4
	ldr	r3, [r3]
	ldr	r2, [fp, #-8]
	str	r2, [r3, #8]
	ldr	r3, .L48+4
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #4]
	ldr	r2, .L48+4
	ldr	r3, [fp, #-8]
	str	r3, [r2]
.L42:
	mov	r3, #0
.L40:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L49:
	.align	2
.L48:
	.word	frontier_head
	.word	frontier_tail
	.size	add_frontier_in_order, .-add_frontier_in_order
	.section	.rodata
	.align	2
.LC11:
	.ascii	"r\000"
	.align	2
.LC12:
	.ascii	"Cannot open file %s. Program terminates.\012\000"
	.align	2
.LC13:
	.ascii	"%c\000"
	.align	2
.LC14:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	read_puzzle
	.syntax unified
	.arm
	.fpu softvfp
	.type	read_puzzle, %function
read_puzzle:
	@ args = 0, pretend = 0, frame = 40
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #40
	str	r0, [fp, #-32]
	str	r1, [fp, #-36]
	str	r2, [fp, #-40]
	ldr	r3, .L67
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r1, .L67+4
	ldr	r0, [fp, #-32]
	bl	fopen
	str	r0, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bne	.L51
	ldr	r1, [fp, #-32]
	ldr	r0, .L67+8
	bl	printf
	mvn	r3, #0
	b	.L65
.L51:
	mov	r3, #0
	str	r3, [fp, #-28]
	b	.L53
.L56:
	mov	r3, #0
	str	r3, [fp, #-24]
	b	.L54
.L55:
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r2, [fp, #-24]
	mvn	r1, #0
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-36]
	add	r2, r2, r3
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #3
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-24]
	add	r3, r3, #1
	str	r3, [fp, #-24]
.L54:
	ldr	r3, [fp, #-24]
	cmp	r3, #31
	ble	.L55
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-40]
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3]
	ldr	r3, [fp, #-28]
	add	r3, r3, #1
	str	r3, [fp, #-28]
.L53:
	ldr	r3, [fp, #-28]
	cmp	r3, #15
	ble	.L56
	mov	r3, #0
	str	r3, [fp, #-28]
	b	.L57
.L64:
	mov	r3, #0
	str	r3, [fp, #-24]
	b	.L58
.L63:
	sub	r3, fp, #16
	mov	r2, r3
	ldr	r1, .L67+12
	ldr	r0, [fp, #-20]
	bl	__isoc99_fscanf
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	cmp	r3, #72
	bne	.L59
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r2, [fp, #-24]
	mov	r1, #0
	str	r1, [r3, r2, lsl #3]
	b	.L60
.L59:
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	cmp	r3, #83
	bne	.L61
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r2, [fp, #-24]
	mov	r1, #1
	str	r1, [r3, r2, lsl #3]
	b	.L60
.L61:
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	cmp	r3, #68
	bne	.L62
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r2, [fp, #-24]
	mov	r1, #2
	str	r1, [r3, r2, lsl #3]
	b	.L60
.L62:
	ldrb	r3, [fp, #-16]	@ zero_extendqisi2
	cmp	r3, #67
	bne	.L60
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r2, [fp, #-24]
	mov	r1, #3
	str	r1, [r3, r2, lsl #3]
.L60:
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-36]
	add	r2, r2, r3
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #3
	add	r3, r2, r3
	add	r3, r3, #4
	mov	r2, r3
	ldr	r1, .L67+16
	ldr	r0, [fp, #-20]
	bl	__isoc99_fscanf
	ldr	r3, [fp, #-28]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-40]
	add	r3, r2, r3
	ldr	r2, [r3]
	add	r2, r2, #1
	str	r2, [r3]
	ldr	r3, [fp, #-24]
	add	r3, r3, #1
	str	r3, [fp, #-24]
.L58:
	ldr	r3, [fp, #-24]
	cmp	r3, #3
	ble	.L63
	ldr	r3, [fp, #-28]
	add	r3, r3, #1
	str	r3, [fp, #-28]
.L57:
	ldr	r3, [fp, #-28]
	cmp	r3, #7
	ble	.L64
	ldr	r0, [fp, #-20]
	bl	fclose
	mov	r3, #0
.L65:
	ldr	r2, .L67
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L66
	bl	__stack_chk_fail
.L66:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L68:
	.align	2
.L67:
	.word	.LC14
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC10
	.size	read_puzzle, .-read_puzzle
	.align	2
	.global	is_solution
	.syntax unified
	.arm
	.fpu softvfp
	.type	is_solution, %function
is_solution:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #48]
	cmp	r3, #7
	bne	.L70
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #52]
	cmp	r3, #7
	bne	.L70
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #56]
	cmp	r3, #7
	bne	.L70
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #60]
	cmp	r3, #7
	bne	.L70
	mov	r3, #1
	b	.L71
.L70:
	mov	r3, #0
.L71:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	is_solution, .-is_solution
	.align	2
	.global	move_to_foundation
	.syntax unified
	.arm
	.fpu softvfp
	.type	move_to_foundation, %function
move_to_foundation:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	str	r2, [fp, #-16]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	add	r1, r3, #1
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r0, [fp, #-12]
	lsl	r0, r0, #5
	add	r1, r0, r1
	ldr	r1, [r3, r1, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r0, [fp, #-16]
	lsl	r0, r0, #5
	add	r2, r0, r2
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-16]
	add	r1, r1, #1024
	ldr	r0, [r2, r1, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r1, [fp, #-8]
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #5
	add	r3, r3, r0
	lsl	r3, r3, #3
	add	r3, r1, r3
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r2, r1, r2
	mvn	r1, #0
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	sub	r1, r3, #1
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	move_to_foundation, .-move_to_foundation
	.align	2
	.global	move_to_empty_foundation
	.syntax unified
	.arm
	.fpu softvfp
	.type	move_to_empty_foundation, %function
move_to_empty_foundation:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	mov	r3, #12
	str	r3, [fp, #-8]
	b	.L74
.L76:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	cmn	r3, #1
	bne	.L75
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	add	r1, r3, #1
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	ldr	r0, [fp, #-20]
	lsl	r0, r0, #5
	add	r1, r0, r1
	ldr	r1, [r3, r1, lsl #3]
	ldr	r3, [fp, #-16]
	ldr	r0, [fp, #-8]
	lsl	r0, r0, #5
	add	r2, r0, r2
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-8]
	add	r1, r1, #1024
	ldr	r0, [r2, r1, lsl #2]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-20]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r1, [fp, #-16]
	ldr	r3, [fp, #-8]
	lsl	r3, r3, #5
	add	r3, r3, r0
	lsl	r3, r3, #3
	add	r3, r1, r3
	str	r2, [r3, #4]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	ldr	r1, [fp, #-20]
	lsl	r1, r1, #5
	add	r2, r1, r2
	mvn	r1, #0
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-20]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	sub	r1, r3, #1
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	mov	r3, #16
	str	r3, [fp, #-8]
.L75:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L74:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L76
	nop
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	move_to_empty_foundation, .-move_to_empty_foundation
	.align	2
	.global	move_to_new_stack
	.syntax unified
	.arm
	.fpu softvfp
	.type	move_to_new_stack, %function
move_to_new_stack:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L78
.L80:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	cmn	r3, #1
	bne	.L79
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	add	r1, r3, #1
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	ldr	r0, [fp, #-20]
	lsl	r0, r0, #5
	add	r1, r0, r1
	ldr	r1, [r3, r1, lsl #3]
	ldr	r3, [fp, #-16]
	ldr	r0, [fp, #-8]
	lsl	r0, r0, #5
	add	r2, r0, r2
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-8]
	add	r1, r1, #1024
	ldr	r0, [r2, r1, lsl #2]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-20]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r1, [fp, #-16]
	ldr	r3, [fp, #-8]
	lsl	r3, r3, #5
	add	r3, r3, r0
	lsl	r3, r3, #3
	add	r3, r1, r3
	str	r2, [r3, #4]
	mov	r3, #9
	str	r3, [fp, #-8]
.L79:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L78:
	ldr	r3, [fp, #-8]
	cmp	r3, #7
	ble	.L80
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	ldr	r1, [fp, #-20]
	lsl	r1, r1, #5
	add	r2, r1, r2
	mvn	r1, #0
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-20]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	sub	r1, r3, #1
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	move_to_new_stack, .-move_to_new_stack
	.align	2
	.global	move_to_stack
	.syntax unified
	.arm
	.fpu softvfp
	.type	move_to_stack, %function
move_to_stack:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	str	r2, [fp, #-16]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	add	r1, r3, #1
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r0, [fp, #-12]
	lsl	r0, r0, #5
	add	r1, r0, r1
	ldr	r1, [r3, r1, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r0, [fp, #-16]
	lsl	r0, r0, #5
	add	r2, r0, r2
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-16]
	add	r1, r1, #1024
	ldr	r0, [r2, r1, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r1, [fp, #-8]
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #5
	add	r3, r3, r0
	lsl	r3, r3, #3
	add	r3, r1, r3
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r2, r1, r2
	mvn	r1, #0
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	sub	r1, r3, #1
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	move_to_stack, .-move_to_stack
	.align	2
	.global	move_to_a_freecell
	.syntax unified
	.arm
	.fpu softvfp
	.type	move_to_a_freecell, %function
move_to_a_freecell:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #32]
	cmn	r3, #1
	bne	.L83
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #32]
	add	r3, r3, #1
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	str	r3, [r2, #32]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r2, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #2048]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #2052]
	b	.L84
.L83:
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #36]
	cmn	r3, #1
	bne	.L85
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #36]
	add	r3, r3, #1
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	str	r3, [r2, #36]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r2, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #2304]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #2308]
	b	.L84
.L85:
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #40]
	cmn	r3, #1
	bne	.L86
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #40]
	add	r3, r3, #1
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	str	r3, [r2, #40]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r2, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #2560]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #2564]
	b	.L84
.L86:
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #44]
	cmn	r3, #1
	bne	.L84
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #44]
	add	r3, r3, #1
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	str	r3, [r2, #44]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r2, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #2816]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	str	r2, [r3, #2820]
.L84:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r2, r1, r2
	mvn	r1, #0
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	sub	r1, r3, #1
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	move_to_a_freecell, .-move_to_a_freecell
	.align	2
	.global	equal_nodes
	.syntax unified
	.arm
	.fpu softvfp
	.type	equal_nodes, %function
equal_nodes:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L88
.L94:
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L89
.L93:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-12]
	lsl	r1, r2, #5
	ldr	r2, [fp, #-8]
	add	r2, r1, r2
	ldr	r2, [r3, r2, lsl #3]
	ldr	r3, [fp, #-20]
	ldr	r1, [fp, #-12]
	lsl	r0, r1, #5
	ldr	r1, [fp, #-8]
	add	r1, r0, r1
	ldr	r3, [r3, r1, lsl #3]
	cmp	r2, r3
	bne	.L90
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-12]
	lsl	r1, r3, #5
	ldr	r3, [fp, #-8]
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r1, [fp, #-20]
	ldr	r3, [fp, #-12]
	lsl	r0, r3, #5
	ldr	r3, [fp, #-8]
	add	r3, r0, r3
	lsl	r3, r3, #3
	add	r3, r1, r3
	ldr	r3, [r3, #4]
	cmp	r2, r3
	beq	.L91
.L90:
	mov	r3, #0
	b	.L92
.L91:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L89:
	ldr	r3, [fp, #-8]
	cmp	r3, #31
	ble	.L93
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L88:
	ldr	r3, [fp, #-12]
	cmp	r3, #11
	ble	.L94
	mov	r3, #1
.L92:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	equal_nodes, .-equal_nodes
	.align	2
	.global	check_with_parents
	.syntax unified
	.arm
	.fpu softvfp
	.type	check_with_parents, %function
check_with_parents:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #76]
	str	r3, [fp, #-8]
	b	.L96
.L99:
	ldr	r1, [fp, #-8]
	ldr	r0, [fp, #-16]
	bl	equal_nodes
	mov	r3, r0
	cmp	r3, #0
	beq	.L97
	mov	r3, #0
	b	.L98
.L97:
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #76]
	str	r3, [fp, #-8]
.L96:
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L99
	mov	r3, #1
.L98:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	check_with_parents, .-check_with_parents
	.align	2
	.global	freecells_count
	.syntax unified
	.arm
	.fpu softvfp
	.type	freecells_count, %function
freecells_count:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #32]
	cmn	r3, #1
	bne	.L101
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L101:
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #36]
	cmn	r3, #1
	bne	.L102
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L102:
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #40]
	cmn	r3, #1
	bne	.L103
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L103:
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #44]
	cmn	r3, #1
	bne	.L104
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L104:
	ldr	r3, [fp, #-8]
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	freecells_count, .-freecells_count
	.align	2
	.global	num_cards_at_foundations
	.syntax unified
	.arm
	.fpu softvfp
	.type	num_cards_at_foundations, %function
num_cards_at_foundations:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #48]
	cmn	r3, #1
	beq	.L107
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #48]
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L107:
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #52]
	cmn	r3, #1
	beq	.L108
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #52]
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L108:
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #56]
	cmn	r3, #1
	beq	.L109
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #56]
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L109:
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #60]
	cmn	r3, #1
	beq	.L110
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #60]
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L110:
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #1
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	num_cards_at_foundations, .-num_cards_at_foundations
	.align	2
	.global	freestacks_count
	.syntax unified
	.arm
	.fpu softvfp
	.type	freestacks_count, %function
freestacks_count:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L113
.L115:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-12]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-12]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	cmn	r3, #1
	bne	.L114
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L114:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L113:
	ldr	r3, [fp, #-12]
	cmp	r3, #7
	ble	.L115
	ldr	r2, [fp, #-8]
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	freestacks_count, .-freestacks_count
	.align	2
	.global	heuristic
	.syntax unified
	.arm
	.fpu softvfp
	.type	heuristic, %function
heuristic:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	str	r0, [fp, #-24]
	mov	r3, #0
	str	r3, [fp, #-20]
	ldr	r0, [fp, #-24]
	bl	freestacks_count
	str	r0, [fp, #-16]
	ldr	r0, [fp, #-24]
	bl	freecells_count
	str	r0, [fp, #-12]
	ldr	r0, [fp, #-24]
	bl	num_cards_at_foundations
	str	r0, [fp, #-8]
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-16]
	sub	r2, r2, r3
	ldr	r3, [fp, #-12]
	sub	r3, r2, r3
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-20]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	heuristic, .-heuristic
	.align	2
	.global	evaluate_child
	.syntax unified
	.arm
	.fpu softvfp
	.type	evaluate_child, %function
evaluate_child:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #12
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmp	r3, #3
	bne	.L120
	ldr	r0, [fp, #-16]
	bl	heuristic
	mov	r2, r0
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	str	r2, [r3, #72]
	b	.L123
.L120:
	ldr	r3, [fp, #-20]
	cmp	r3, #4
	bne	.L122
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r4, [r3, #68]
	ldr	r0, [fp, #-16]
	bl	heuristic
	mov	r3, r0
	add	r3, r4, r3
	ldr	r2, [fp, #-16]
	add	r2, r2, #4096
	str	r3, [r2, #72]
	b	.L123
.L122:
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #72]
.L123:
	nop
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
	.size	evaluate_child, .-evaluate_child
	.align	2
	.global	create_child
	.syntax unified
	.arm
	.fpu softvfp
	.type	create_child, %function
create_child:
	@ args = 8, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	str	r3, [fp, #-36]
	ldr	r0, .L139
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L125
	ldr	r3, .L139+4
	mvn	r2, #0
	str	r2, [r3]
	b	.L124
.L125:
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1040
	add	r3, r3, #8
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r2, [fp, #-8]
	str	r2, [r3, #4]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L127
.L128:
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1040
	add	r3, r3, #8
	lsl	r3, r3, #2
	add	r3, r2, r3
	mov	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L127:
	ldr	r3, [fp, #-16]
	cmp	r3, #19
	ble	.L128
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	mov	r2, r3
	ldr	r3, [fp, #-24]
	str	r3, [r2, #76]
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	mov	r2, r3
	ldr	r3, [fp, #-28]
	str	r3, [r2, #80]
	ldr	r3, [fp, #-24]
	add	r3, r3, #4096
	ldr	r3, [r3, #68]
	add	r3, r3, #1
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	str	r3, [r2, #68]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L129
.L132:
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L130
.L131:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	lsl	r1, r2, #5
	ldr	r2, [fp, #-12]
	add	r2, r1, r2
	ldr	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	lsl	r0, r2, #5
	ldr	r2, [fp, #-12]
	add	r2, r0, r2
	str	r1, [r3, r2, lsl #3]
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-16]
	lsl	r1, r3, #5
	ldr	r3, [fp, #-12]
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r1, [fp, #-8]
	ldr	r3, [fp, #-16]
	lsl	r0, r3, #5
	ldr	r3, [fp, #-12]
	add	r3, r0, r3
	lsl	r3, r3, #3
	add	r3, r1, r3
	str	r2, [r3, #4]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L130:
	ldr	r3, [fp, #-12]
	cmp	r3, #31
	ble	.L131
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L129:
	ldr	r3, [fp, #-16]
	cmp	r3, #15
	ble	.L132
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #4]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	mov	r0, r2
	ldr	r1, [fp, #-24]
	ldr	r2, [fp, #4]
	lsl	r2, r2, #5
	add	r3, r2, r3
	add	r2, r0, #84
	lsl	r3, r3, #3
	add	r3, r1, r3
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bne	.L133
	ldr	r3, [fp, #8]
	cmp	r3, #0
	bne	.L134
	ldr	r1, [fp, #4]
	ldr	r0, [fp, #-8]
	bl	move_to_empty_foundation
	b	.L135
.L134:
	ldr	r2, [fp, #8]
	ldr	r1, [fp, #4]
	ldr	r0, [fp, #-8]
	bl	move_to_foundation
	b	.L135
.L133:
	ldr	r3, [fp, #-28]
	cmp	r3, #1
	bne	.L136
	ldr	r1, [fp, #4]
	ldr	r0, [fp, #-8]
	bl	move_to_new_stack
	b	.L135
.L136:
	ldr	r3, [fp, #-28]
	cmp	r3, #2
	bne	.L137
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #8]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	mov	r0, r2
	ldr	r1, [fp, #-24]
	ldr	r2, [fp, #8]
	lsl	r2, r2, #5
	add	r3, r2, r3
	add	r2, r0, #92
	lsl	r3, r3, #3
	add	r3, r1, r3
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
	ldr	r2, [fp, #8]
	ldr	r1, [fp, #4]
	ldr	r0, [fp, #-8]
	bl	move_to_stack
	b	.L135
.L137:
	ldr	r1, [fp, #4]
	ldr	r0, [fp, #-8]
	bl	move_to_a_freecell
.L135:
	ldr	r0, [fp, #-8]
	bl	check_with_parents
	mov	r3, r0
	cmp	r3, #0
	bne	.L138
	ldr	r0, [fp, #-8]
	bl	free
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1040
	add	r3, r3, #8
	lsl	r3, r3, #2
	add	r3, r2, r3
	mov	r2, #0
	str	r2, [r3, #4]
	b	.L124
.L138:
	ldr	r1, [fp, #-36]
	ldr	r0, [fp, #-8]
	bl	evaluate_child
.L124:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L140:
	.align	2
.L139:
	.word	4276
	.word	mem_error
	.size	create_child, .-create_child
	.align	2
	.global	find_children
	.syntax unified
	.arm
	.fpu softvfp
	.type	find_children, %function
find_children:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	mov	r3, #0
	str	r3, [fp, #-12]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L142
.L162:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmn	r3, #1
	beq	.L143
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	cmp	r3, #0
	bne	.L144
	mov	r3, #0
	str	r3, [sp, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, [fp, #-28]
	ldr	r2, [fp, #-12]
	mov	r1, #0
	ldr	r0, [fp, #-24]
	bl	create_child
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	b	.L143
.L144:
	mov	r3, #12
	str	r3, [fp, #-8]
	b	.L145
.L147:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r2, [r3, r2, lsl #3]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-8]
	add	r1, r1, #1024
	ldr	r1, [r3, r1, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r0, [fp, #-8]
	lsl	r0, r0, #5
	add	r1, r0, r1
	ldr	r3, [r3, r1, lsl #3]
	cmp	r2, r3
	bne	.L146
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-8]
	add	r1, r1, #1024
	ldr	r3, [r3, r1, lsl #2]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-8]
	lsl	r0, r0, #5
	add	r3, r0, r3
	lsl	r3, r3, #3
	add	r3, r1, r3
	ldr	r3, [r3, #4]
	add	r3, r3, #1
	cmp	r2, r3
	bne	.L146
	ldr	r3, [fp, #-8]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, [fp, #-28]
	ldr	r2, [fp, #-12]
	mov	r1, #0
	ldr	r0, [fp, #-24]
	bl	create_child
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	mov	r3, #16
	str	r3, [fp, #-8]
.L146:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L145:
	ldr	r3, [fp, #-8]
	cmp	r3, #15
	ble	.L147
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L148
.L158:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #0
	beq	.L149
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #2
	bne	.L150
.L149:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-8]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #1
	beq	.L151
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-8]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #3
	bne	.L150
.L151:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-8]
	add	r1, r1, #1024
	ldr	r3, [r3, r1, lsl #2]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-8]
	lsl	r0, r0, #5
	add	r3, r0, r3
	lsl	r3, r3, #3
	add	r3, r1, r3
	ldr	r3, [r3, #4]
	sub	r3, r3, #1
	cmp	r2, r3
	bne	.L153
	ldr	r3, [fp, #-8]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, [fp, #-28]
	ldr	r2, [fp, #-12]
	mov	r1, #2
	ldr	r0, [fp, #-24]
	bl	create_child
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	b	.L153
.L150:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #1
	beq	.L154
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #3
	bne	.L155
.L154:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-8]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #0
	beq	.L156
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-8]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r3, [r3, r2, lsl #3]
	cmp	r3, #2
	bne	.L155
.L156:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-8]
	add	r1, r1, #1024
	ldr	r3, [r3, r1, lsl #2]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-8]
	lsl	r0, r0, #5
	add	r3, r0, r3
	lsl	r3, r3, #3
	add	r3, r1, r3
	ldr	r3, [r3, #4]
	sub	r3, r3, #1
	cmp	r2, r3
	bne	.L153
	ldr	r3, [fp, #-8]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, [fp, #-28]
	ldr	r2, [fp, #-12]
	mov	r1, #2
	ldr	r0, [fp, #-24]
	bl	create_child
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	b	.L153
.L155:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	cmn	r3, #1
	bne	.L153
	ldr	r3, [fp, #-8]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, [fp, #-28]
	ldr	r2, [fp, #-12]
	mov	r1, #1
	ldr	r0, [fp, #-24]
	bl	create_child
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	mov	r3, #16
	str	r3, [fp, #-8]
.L153:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L148:
	ldr	r3, [fp, #-8]
	cmp	r3, #7
	ble	.L158
	ldr	r3, [fp, #-16]
	cmp	r3, #8
	beq	.L143
	ldr	r3, [fp, #-16]
	cmp	r3, #9
	beq	.L143
	ldr	r3, [fp, #-16]
	cmp	r3, #10
	beq	.L143
	ldr	r3, [fp, #-16]
	cmp	r3, #11
	beq	.L143
	mov	r3, #8
	str	r3, [fp, #-8]
	b	.L159
.L161:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-8]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	cmn	r3, #1
	bne	.L160
	ldr	r3, [fp, #-8]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, [fp, #-28]
	ldr	r2, [fp, #-12]
	mov	r1, #3
	ldr	r0, [fp, #-24]
	bl	create_child
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	mov	r3, #12
	str	r3, [fp, #-8]
.L160:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L159:
	ldr	r3, [fp, #-8]
	cmp	r3, #11
	ble	.L161
.L143:
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L142:
	ldr	r3, [fp, #-16]
	cmp	r3, #11
	ble	.L162
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	find_children, .-find_children
	.align	2
	.global	initialize_search
	.syntax unified
	.arm
	.fpu softvfp
	.type	initialize_search, %function
initialize_search:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	mov	r3, #0
	str	r3, [fp, #-8]
	ldr	r0, .L177
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #76]
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	mov	r2, r3
	mvn	r3, #0
	str	r3, [r2, #80]
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L164
.L165:
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1040
	add	r3, r3, #8
	lsl	r3, r3, #2
	add	r3, r2, r3
	mov	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L164:
	ldr	r3, [fp, #-12]
	cmp	r3, #19
	ble	.L165
	mov	r3, #0
	str	r3, [fp, #-20]
	b	.L166
.L169:
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L167
.L168:
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	lsl	r1, r2, #5
	ldr	r2, [fp, #-16]
	add	r2, r1, r2
	mvn	r1, #0
	str	r1, [r3, r2, lsl #3]
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-20]
	lsl	r1, r3, #5
	ldr	r3, [fp, #-16]
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	mvn	r2, #0
	str	r2, [r3, #4]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L167:
	ldr	r3, [fp, #-16]
	cmp	r3, #31
	ble	.L168
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	mvn	r1, #0
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L166:
	ldr	r3, [fp, #-20]
	cmp	r3, #15
	ble	.L169
	mov	r3, #0
	str	r3, [fp, #-20]
	b	.L170
.L173:
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L171
.L172:
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-24]
	add	r3, r2, r3
	ldr	r2, [fp, #-16]
	ldr	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	lsl	r0, r2, #5
	ldr	r2, [fp, #-16]
	add	r2, r0, r2
	str	r1, [r3, r2, lsl #3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #8
	ldr	r2, [fp, #-24]
	add	r2, r2, r3
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r1, [fp, #-8]
	ldr	r3, [fp, #-20]
	lsl	r0, r3, #5
	ldr	r3, [fp, #-16]
	add	r3, r0, r3
	lsl	r3, r3, #3
	add	r3, r1, r3
	str	r2, [r3, #4]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L171:
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldr	r3, [r3]
	ldr	r2, [fp, #-16]
	cmp	r2, r3
	ble	.L172
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldr	r1, [r3]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	add	r2, r2, #1024
	str	r1, [r3, r2, lsl #2]
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L170:
	ldr	r3, [fp, #-20]
	cmp	r3, #7
	ble	.L173
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #68]
	ldr	r0, [fp, #-8]
	bl	heuristic
	mov	r2, r0
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	str	r2, [r3, #64]
	ldr	r3, [fp, #-32]
	cmp	r3, #3
	bne	.L174
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #64]
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	str	r3, [r2, #72]
	b	.L175
.L174:
	ldr	r3, [fp, #-32]
	cmp	r3, #4
	bne	.L176
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r2, [r3, #68]
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #64]
	add	r3, r2, r3
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	str	r3, [r2, #72]
	b	.L175
.L176:
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #72]
.L175:
	ldr	r0, [fp, #-8]
	bl	add_frontier_front
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L178:
	.align	2
.L177:
	.word	4276
	.size	initialize_search, .-initialize_search
	.align	2
	.global	complete_solution
	.syntax unified
	.arm
	.fpu softvfp
	.type	complete_solution, %function
complete_solution:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	ldr	r3, [fp, #-24]
	str	r3, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L180
.L186:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	cmp	r3, #0
	bne	.L181
	mov	r3, #0
	str	r3, [sp, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, [fp, #-28]
	mov	r2, #0
	mov	r1, #0
	ldr	r0, [fp, #-24]
	bl	create_child
	ldr	r3, [fp, #-24]
	add	r3, r3, #4096
	ldr	r3, [r3, #100]
	ldr	r1, [fp, #-28]
	mov	r0, r3
	bl	complete_solution
	str	r0, [fp, #-8]
	b	.L182
.L181:
	mov	r3, #12
	str	r3, [fp, #-12]
	b	.L183
.L185:
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r2, [r3, r2, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r2, r1, r2
	ldr	r2, [r3, r2, lsl #3]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-12]
	add	r1, r1, #1024
	ldr	r1, [r3, r1, lsl #2]
	ldr	r3, [fp, #-24]
	ldr	r0, [fp, #-12]
	lsl	r0, r0, #5
	add	r1, r0, r1
	ldr	r3, [r3, r1, lsl #3]
	cmp	r2, r3
	bne	.L184
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-16]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-24]
	ldr	r1, [fp, #-16]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r2, [r3, #4]
	ldr	r3, [fp, #-24]
	ldr	r1, [fp, #-12]
	add	r1, r1, #1024
	ldr	r3, [r3, r1, lsl #2]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-12]
	lsl	r0, r0, #5
	add	r3, r0, r3
	lsl	r3, r3, #3
	add	r3, r1, r3
	ldr	r3, [r3, #4]
	add	r3, r3, #1
	cmp	r2, r3
	bne	.L184
	ldr	r3, [fp, #-12]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, [fp, #-28]
	mov	r2, #0
	mov	r1, #0
	ldr	r0, [fp, #-24]
	bl	create_child
	ldr	r3, [fp, #-24]
	add	r3, r3, #4096
	ldr	r3, [r3, #100]
	ldr	r1, [fp, #-28]
	mov	r0, r3
	bl	complete_solution
	str	r0, [fp, #-8]
.L184:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L183:
	ldr	r3, [fp, #-12]
	cmp	r3, #15
	ble	.L185
.L182:
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L180:
	ldr	r3, [fp, #-16]
	cmp	r3, #11
	ble	.L186
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	complete_solution, .-complete_solution
	.section	.rodata
	.align	2
.LC15:
	.ascii	"Timeout\000"
	.align	2
.LC16:
	.ascii	"Memory exhausted while creating new child node. Sea"
	.ascii	"rch is terminated...\000"
	.align	2
.LC17:
	.ascii	"Memory exhausted while creating new frontier node. "
	.ascii	"Search is terminated...\000"
	.text
	.align	2
	.global	search
	.syntax unified
	.arm
	.fpu softvfp
	.type	search, %function
search:
	@ args = 0, pretend = 0, frame = 40
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #40
	str	r0, [fp, #-40]
	b	.L189
.L207:
	bl	clock
	str	r0, [fp, #-20]
	ldr	r3, .L208
	ldr	r3, [r3]
	ldr	r2, [fp, #-20]
	sub	r3, r2, r3
	ldr	r2, .L208+4
	cmp	r3, r2
	ble	.L190
	ldr	r0, .L208+8
	bl	puts
	mov	r3, #0
	b	.L191
.L190:
	ldr	r3, .L208+12
	ldr	r3, [r3]
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-24]
	mov	r3, #12
	str	r3, [fp, #-32]
	b	.L192
.L194:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-32]
	add	r2, r2, #1024
	ldr	r3, [r3, r2, lsl #2]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-32]
	lsl	r1, r1, #5
	add	r3, r1, r3
	lsl	r3, r3, #3
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	cmp	r3, #7
	bne	.L193
	ldr	r3, [fp, #-24]
	add	r3, r3, #1
	str	r3, [fp, #-24]
.L193:
	ldr	r3, [fp, #-32]
	add	r3, r3, #1
	str	r3, [fp, #-32]
.L192:
	ldr	r3, [fp, #-32]
	cmp	r3, #15
	ble	.L194
	ldr	r3, [fp, #-24]
	cmp	r3, #3
	bne	.L195
	ldr	r1, [fp, #-40]
	ldr	r0, [fp, #-16]
	bl	complete_solution
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	b	.L191
.L195:
	ldr	r3, .L208+12
	ldr	r3, [r3]
	str	r3, [fp, #-12]
	ldr	r3, .L208+12
	ldr	r3, [r3]
	ldr	r3, [r3, #8]
	ldr	r2, .L208+12
	str	r3, [r2]
	ldr	r0, [fp, #-12]
	bl	free
	ldr	r3, .L208+12
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L196
	ldr	r3, .L208+16
	mov	r2, #0
	str	r2, [r3]
	b	.L197
.L196:
	ldr	r3, .L208+12
	ldr	r3, [r3]
	mov	r2, #0
	str	r2, [r3, #4]
.L197:
	ldr	r1, [fp, #-40]
	ldr	r0, [fp, #-16]
	bl	find_children
	ldr	r3, .L208+20
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L198
	ldr	r0, .L208+24
	bl	puts
	mov	r3, #0
	b	.L191
.L198:
	mov	r3, #0
	str	r3, [fp, #-32]
	b	.L199
.L206:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1040
	add	r3, r3, #8
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	cmp	r3, #0
	beq	.L200
	ldr	r3, [fp, #-40]
	cmp	r3, #2
	bne	.L201
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1040
	add	r3, r3, #8
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	mov	r0, r3
	bl	add_frontier_front
	str	r0, [fp, #-28]
	b	.L202
.L201:
	ldr	r3, [fp, #-40]
	cmp	r3, #1
	bne	.L203
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1040
	add	r3, r3, #8
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	mov	r0, r3
	bl	add_frontier_back
	str	r0, [fp, #-28]
	b	.L202
.L203:
	ldr	r3, [fp, #-40]
	cmp	r3, #3
	beq	.L204
	ldr	r3, [fp, #-40]
	cmp	r3, #4
	bne	.L202
.L204:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1040
	add	r3, r3, #8
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	mov	r0, r3
	bl	add_frontier_in_order
	str	r0, [fp, #-28]
.L202:
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bge	.L205
	ldr	r0, .L208+28
	bl	puts
	mov	r3, #0
	b	.L191
.L200:
	mov	r3, #20
	str	r3, [fp, #-32]
.L205:
	ldr	r3, [fp, #-32]
	add	r3, r3, #1
	str	r3, [fp, #-32]
.L199:
	ldr	r3, [fp, #-32]
	cmp	r3, #19
	ble	.L206
.L189:
	ldr	r3, .L208+12
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L207
	mov	r3, #0
.L191:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L209:
	.align	2
.L208:
	.word	t1
	.word	300000000
	.word	.LC15
	.word	frontier_head
	.word	frontier_tail
	.word	mem_error
	.word	.LC16
	.word	.LC17
	.size	search, .-search
	.align	2
	.global	extract_solution
	.syntax unified
	.arm
	.fpu softvfp
	.type	extract_solution, %function
extract_solution:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-16]
	add	r3, r3, #4096
	ldr	r3, [r3, #68]
	ldr	r2, .L217
	str	r3, [r2]
	ldr	r3, .L217
	ldr	r3, [r3]
	lsl	r3, r3, #2
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L217+4
	str	r2, [r3]
	ldr	r3, .L217
	ldr	r3, [r3]
	lsl	r3, r3, #3
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L217+8
	str	r2, [r3]
	ldr	r3, .L217
	ldr	r3, [r3]
	lsl	r3, r3, #3
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	mov	r2, r3
	ldr	r3, .L217+12
	str	r2, [r3]
	ldr	r3, .L217+4
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L211
	ldr	r3, .L217+8
	ldr	r3, [r3]
	cmp	r3, #0
	beq	.L211
	ldr	r3, .L217+12
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L212
.L211:
	ldr	r3, .L217+16
	mvn	r2, #0
	str	r2, [r3]
	b	.L210
.L212:
	ldr	r3, [fp, #-16]
	str	r3, [fp, #-8]
	ldr	r3, .L217
	ldr	r3, [r3]
	str	r3, [fp, #-12]
	b	.L214
.L216:
	ldr	r3, [fp, #-12]
	sub	r3, r3, #1
	str	r3, [fp, #-12]
	ldr	r3, .L217+4
	ldr	r2, [r3]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #2
	add	r3, r2, r3
	ldr	r2, [fp, #-8]
	add	r2, r2, #4096
	ldr	r2, [r2, #80]
	str	r2, [r3]
	ldr	r3, .L217+8
	ldr	r2, [r3]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #3
	add	r2, r2, r3
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	add	r3, r3, #84
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #80]
	cmp	r3, #2
	bne	.L215
	ldr	r3, .L217+12
	ldr	r2, [r3]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #3
	add	r2, r2, r3
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	add	r3, r3, #92
	ldm	r3, {r0, r1}
	stm	r2, {r0, r1}
.L215:
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #76]
	str	r3, [fp, #-8]
.L214:
	ldr	r3, [fp, #-8]
	add	r3, r3, #4096
	ldr	r3, [r3, #76]
	cmp	r3, #0
	bne	.L216
.L210:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L218:
	.align	2
.L217:
	.word	solution_length
	.word	solution
	.word	sol_moved0
	.word	sol_moved1
	.word	mem_error
	.size	extract_solution, .-extract_solution
	.section	.rodata
	.align	2
.LC18:
	.ascii	"w\000"
	.align	2
.LC19:
	.ascii	"Cannot open output file to write solution.\000"
	.align	2
.LC20:
	.ascii	"Now exiting...\000"
	.align	2
.LC21:
	.ascii	"K = %d\012\000"
	.align	2
.LC22:
	.ascii	"foundation \000"
	.align	2
.LC23:
	.ascii	"newstack \000"
	.align	2
.LC24:
	.ascii	"stack \000"
	.align	2
.LC25:
	.ascii	"freecell \000"
	.align	2
.LC26:
	.ascii	"%d\012\000"
	.text
	.align	2
	.global	write_solution_to_file
	.syntax unified
	.arm
	.fpu softvfp
	.type	write_solution_to_file, %function
write_solution_to_file:
	@ args = 4, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	str	r3, [fp, #-36]
	ldr	r1, .L238
	ldr	r0, [fp, #-24]
	bl	fopen
	str	r0, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	bne	.L220
	ldr	r0, .L238+4
	bl	puts
	ldr	r0, .L238+8
	bl	printf
	b	.L219
.L220:
	ldr	r2, [fp, #-28]
	ldr	r1, .L238+12
	ldr	r0, [fp, #-12]
	bl	fprintf
	mov	r3, #0
	str	r3, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L222
.L237:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-32]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L223
	ldr	r3, [fp, #-12]
	mov	r2, #11
	mov	r1, #1
	ldr	r0, .L238+16
	bl	fwrite
	b	.L224
.L223:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-32]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #1
	bne	.L225
	ldr	r3, [fp, #-12]
	mov	r2, #9
	mov	r1, #1
	ldr	r0, .L238+20
	bl	fwrite
	b	.L224
.L225:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-32]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #2
	bne	.L226
	ldr	r3, [fp, #-12]
	mov	r2, #6
	mov	r1, #1
	ldr	r0, .L238+24
	bl	fwrite
	b	.L224
.L226:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-32]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #3
	bne	.L224
	ldr	r3, [fp, #-12]
	mov	r2, #9
	mov	r1, #1
	ldr	r0, .L238+28
	bl	fwrite
.L224:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L227
	ldr	r1, [fp, #-12]
	mov	r0, #72
	bl	fputc
	b	.L228
.L227:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #1
	bne	.L229
	ldr	r1, [fp, #-12]
	mov	r0, #83
	bl	fputc
	b	.L228
.L229:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #2
	bne	.L230
	ldr	r1, [fp, #-12]
	mov	r0, #68
	bl	fputc
	b	.L228
.L230:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #3
	bne	.L228
	ldr	r1, [fp, #-12]
	mov	r0, #67
	bl	fputc
.L228:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #-36]
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	mov	r2, r3
	ldr	r1, .L238+32
	ldr	r0, [fp, #-12]
	bl	fprintf
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-32]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #2
	bne	.L231
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #4]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L232
	ldr	r1, [fp, #-12]
	mov	r0, #72
	bl	fputc
	b	.L233
.L232:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #4]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #1
	bne	.L234
	ldr	r1, [fp, #-12]
	mov	r0, #83
	bl	fputc
	b	.L233
.L234:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #4]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #2
	bne	.L235
	ldr	r1, [fp, #-12]
	mov	r0, #68
	bl	fputc
	b	.L233
.L235:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #4]
	add	r3, r2, r3
	ldr	r3, [r3]
	cmp	r3, #3
	bne	.L233
	ldr	r1, [fp, #-12]
	mov	r0, #67
	bl	fputc
.L233:
	ldr	r3, [fp, #-16]
	lsl	r3, r3, #3
	ldr	r2, [fp, #4]
	add	r3, r2, r3
	ldr	r3, [r3, #4]
	mov	r2, r3
	ldr	r1, .L238+36
	ldr	r0, [fp, #-12]
	bl	fprintf
	b	.L236
.L231:
	ldr	r1, [fp, #-12]
	mov	r0, #10
	bl	fputc
.L236:
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L222:
	ldr	r2, [fp, #-16]
	ldr	r3, [fp, #-28]
	cmp	r2, r3
	blt	.L237
.L219:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L239:
	.align	2
.L238:
	.word	.LC18
	.word	.LC19
	.word	.LC20
	.word	.LC21
	.word	.LC22
	.word	.LC23
	.word	.LC24
	.word	.LC25
	.word	.LC10
	.word	.LC26
	.size	write_solution_to_file, .-write_solution_to_file
	.section	.rodata
	.align	2
.LC27:
	.ascii	"Wrong method. Use correct syntax:\000"
	.align	2
.LC28:
	.ascii	"Solving %s using %s...\012\000"
	.align	2
.LC29:
	.ascii	"Memory exhausted while creating solution path...\000"
	.align	2
.LC30:
	.ascii	"Solution found! (%d steps)\012\000"
	.global	__aeabi_i2f
	.global	__aeabi_fsub
	.global	__aeabi_fdiv
	.global	__aeabi_f2d
	.align	2
.LC31:
	.ascii	"Time spent: %f secs\012\000"
	.align	2
.LC32:
	.ascii	"No solution found.\000"
	.align	2
.LC33:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 4184
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #4160
	sub	sp, sp, #36
	sub	r3, fp, #4096
	sub	r3, r3, #12
	str	r0, [r3, #-84]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	str	r1, [r3, #-88]
	ldr	r3, .L249
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	add	r3, r3, #4
	ldr	r3, [r3]
	sub	r2, fp, #4096
	sub	r2, r2, #12
	mov	r4, r2
	mov	r0, r3
	bl	get_method
	str	r0, [r4, #-80]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-80]
	cmp	r3, #0
	bge	.L241
	ldr	r0, .L249+4
	bl	puts
	bl	syntax_message
	mvn	r3, #0
	b	.L247
.L241:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	add	r3, r3, #8
	ldr	r0, [r3]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r2, fp, #4160
	sub	r2, r2, #12
	sub	r2, r2, #4
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r1, r3
	bl	read_puzzle
	str	r0, [r4, #-76]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-76]
	cmp	r3, #0
	bge	.L243
	mvn	r3, #0
	b	.L247
.L243:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	add	r3, r3, #8
	ldr	r1, [r3]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	add	r3, r3, #4
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r0, .L249+8
	bl	printf
	bl	clock
	mov	r3, r0
	ldr	r2, .L249+12
	str	r3, [r2]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r2, r3
	sub	r1, fp, #4160
	sub	r1, r1, #12
	sub	r1, r1, #4
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r2, [r2, #-80]
	mov	r0, r3
	bl	initialize_search
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r0, [r3, #-80]
	bl	search
	str	r0, [r4, #-72]
	bl	clock
	mov	r3, r0
	ldr	r2, .L249+16
	str	r3, [r2]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-72]
	cmp	r3, #0
	beq	.L244
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r0, [r3, #-72]
	bl	extract_solution
	ldr	r3, .L249+20
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L245
	ldr	r0, .L249+24
	bl	puts
	b	.L246
.L245:
	ldr	r3, .L249+28
	ldr	r3, [r3]
	cmp	r3, #0
	ble	.L246
	ldr	r3, .L249+28
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L249+32
	bl	printf
	ldr	r3, .L249+16
	ldr	r3, [r3]
	mov	r0, r3
	bl	__aeabi_i2f
	mov	r4, r0
	ldr	r3, .L249+12
	ldr	r3, [r3]
	mov	r0, r3
	bl	__aeabi_i2f
	mov	r3, r0
	mov	r1, r3
	mov	r0, r4
	bl	__aeabi_fsub
	mov	r3, r0
	ldr	r1, .L249+36
	mov	r0, r3
	bl	__aeabi_fdiv
	mov	r3, r0
	mov	r0, r3
	bl	__aeabi_f2d
	mov	r2, r0
	mov	r3, r1
	ldr	r0, .L249+40
	bl	printf
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	add	r3, r3, #12
	ldr	r0, [r3]
	ldr	r3, .L249+28
	ldr	r1, [r3]
	ldr	r3, .L249+44
	ldr	r2, [r3]
	ldr	r3, .L249+48
	ldr	ip, [r3]
	ldr	r3, .L249+52
	ldr	r3, [r3]
	str	r3, [sp]
	mov	r3, ip
	bl	write_solution_to_file
	b	.L246
.L244:
	ldr	r0, .L249+56
	bl	puts
.L246:
	mov	r3, #0
.L247:
	ldr	r2, .L249
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L248
	bl	__stack_chk_fail
.L248:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L250:
	.align	2
.L249:
	.word	.LC33
	.word	.LC27
	.word	.LC28
	.word	t1
	.word	t2
	.word	mem_error
	.word	.LC29
	.word	solution_length
	.word	.LC30
	.word	1232348160
	.word	.LC31
	.word	solution
	.word	sol_moved0
	.word	sol_moved1
	.word	.LC32
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
