	.file	"783908.c"
	.intel_syntax noprefix
	.text
	.globl	animdash
	.data
	.type	animdash, @object
	.size	animdash, 4
animdash:
	.ascii	"-/|\\"
	.globl	won_game
	.bss
	.type	won_game, @object
	.size	won_game, 1
won_game:
	.zero	1
	.globl	wincount
	.align 4
	.type	wincount, @object
	.size	wincount, 4
wincount:
	.zero	4
	.globl	curtheme
	.align 4
	.type	curtheme, @object
	.size	curtheme, 4
curtheme:
	.zero	4
	.globl	seed
	.align 4
	.type	seed, @object
	.size	seed, 4
seed:
	.zero	4
	.globl	use_automoves
	.data
	.type	use_automoves, @object
	.size	use_automoves, 1
use_automoves:
	.byte	1
	.globl	themes
	.align 32
	.type	themes, @object
	.size	themes, 216
themes:
	.long	7
	.long	0
	.long	7
	.long	0
	.long	7
	.long	0
	.long	1
	.long	0
	.long	2
	.long	0
	.long	4
	.long	0
	.long	5
	.long	0
	.long	5
	.long	0
	.long	7
	.long	4
	.long	7
	.long	3
	.long	7
	.long	1
	.zero	8
	.long	2097152
	.long	0
	.long	262144
	.long	7
	.long	6
	.long	0
	.long	6
	.long	0
	.long	7
	.long	1
	.long	7
	.long	2
	.long	7
	.long	4
	.long	7
	.long	5
	.long	7
	.long	0
	.long	6
	.long	7
	.long	4
	.long	7
	.long	3
	.long	7
	.long	1
	.zero	8
	.long	0
	.long	2097152
	.long	524288
	.globl	rows
	.align 32
	.type	rows, @object
	.size	rows, 60
rows:
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.long	-1
	.globl	selcard
	.align 4
	.type	selcard, @object
	.size	selcard, 4
selcard:
	.long	-1
	.globl	dbgmode
	.bss
	.align 4
	.type	dbgmode, @object
	.size	dbgmode, 4
dbgmode:
	.zero	4
	.globl	showcardnum
	.type	showcardnum, @object
	.size	showcardnum, 1
showcardnum:
	.zero	1
	.globl	cardvals
	.section	.rodata
.LC0:
	.string	"123456789****@"
	.section	.data.rel.local,"aw"
	.align 8
	.type	cardvals, @object
	.size	cardvals, 8
cardvals:
	.quad	.LC0
	.globl	cardsuits
	.section	.rodata
.LC1:
	.string	"OIX"
	.section	.data.rel.local
	.align 8
	.type	cardsuits, @object
	.size	cardsuits, 8
cardsuits:
	.quad	.LC1
	.globl	rowkeys
	.bss
	.align 8
	.type	rowkeys, @object
	.size	rowkeys, 8
rowkeys:
	.zero	8
	.globl	qwertykeys
	.section	.rodata
.LC2:
	.string	"wertyuio1237890"
	.section	.data.rel.local
	.align 8
	.type	qwertykeys, @object
	.size	qwertykeys, 8
qwertykeys:
	.quad	.LC2
	.globl	qwertzkeys
	.section	.rodata
.LC3:
	.string	"wertzuio1237890"
	.section	.data.rel.local
	.align 8
	.type	qwertzkeys, @object
	.size	qwertzkeys, 8
qwertzkeys:
	.quad	.LC3
	.globl	azertykeys
	.section	.rodata
.LC4:
	.string	"zertyuio1237890"
	.section	.data.rel.local
	.align 8
	.type	azertykeys, @object
	.size	azertykeys, 8
azertykeys:
	.quad	.LC4
	.section	.rodata
.LC5:
	.string	"HOME"
.LC6:
	.string	"wb"
	.text
	.globl	set_win_count
	.type	set_win_count, @function
set_win_count:
.LFB6:
	.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, 208
	mov	DWORD PTR -4292[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rdi, .LC5[rip]
	call	getenv@PLT
	mov	QWORD PTR -4272[rbp], rax
	cmp	QWORD PTR -4272[rbp], 0
	jne	.L2
	mov	eax, 0
	jmp	.L8
.L2:
	mov	rdx, QWORD PTR -4272[rbp]
	lea	rax, -4112[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcpy@PLT
	lea	rax, -4112[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rax, -4112[rbp]
	add	rax, rdx
	movabs	rcx, 30521839251041839
	mov	QWORD PTR [rax], rcx
	lea	rdx, -4256[rbp]
	lea	rax, -4112[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	stat@PLT
	mov	DWORD PTR -4276[rbp], eax
	cmp	DWORD PTR -4276[rbp], -1
	jne	.L4
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	cmp	eax, 2
	jne	.L5
	lea	rax, -4112[rbp]
	mov	esi, 493
	mov	rdi, rax
	call	mkdir@PLT
	mov	DWORD PTR -4276[rbp], eax
	cmp	DWORD PTR -4276[rbp], -1
	jne	.L5
	mov	eax, 0
	jmp	.L8
.L4:
	mov	eax, DWORD PTR -4232[rbp]
	and	eax, 61440
	cmp	eax, 16384
	je	.L5
	mov	eax, 0
	jmp	.L8
.L5:
	lea	rax, -4112[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rax, -4112[rbp]
	add	rax, rdx
	movabs	rcx, 7959390389292070703
	mov	QWORD PTR [rax], rcx
	mov	WORD PTR 8[rax], 116
	lea	rax, -4112[rbp]
	lea	rsi, .LC6[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -4264[rbp], rax
	cmp	QWORD PTR -4264[rbp], 0
	jne	.L6
	mov	eax, 0
	jmp	.L8
.L6:
	mov	rdx, QWORD PTR -4264[rbp]
	lea	rax, -4292[rbp]
	mov	rcx, rdx
	mov	edx, 1
	mov	esi, 4
	mov	rdi, rax
	call	fwrite@PLT
	mov	DWORD PTR -4276[rbp], eax
	mov	rax, QWORD PTR -4264[rbp]
	mov	rdi, rax
	call	fclose@PLT
	cmp	DWORD PTR -4276[rbp], 0
	jne	.L7
	mov	eax, 0
	jmp	.L8
.L7:
	mov	eax, DWORD PTR wincount[rip]
.L8:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L9
	call	__stack_chk_fail@PLT
.L9:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	set_win_count, .-set_win_count
	.section	.rodata
.LC7:
	.string	"rb"
	.text
	.globl	get_win_count
	.type	get_win_count, @function
get_win_count:
.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, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 48
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rdi, .LC5[rip]
	call	getenv@PLT
	mov	QWORD PTR -4128[rbp], rax
	cmp	QWORD PTR -4128[rbp], 0
	jne	.L11
	mov	eax, 0
	jmp	.L15
.L11:
	mov	rdx, QWORD PTR -4128[rbp]
	lea	rax, -4112[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcpy@PLT
	lea	rax, -4112[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rax, -4112[rbp]
	add	rax, rdx
	movabs	rsi, 3417228759033654831
	movabs	rdi, 8389772277107812727
	mov	QWORD PTR [rax], rsi
	mov	QWORD PTR 8[rax], rdi
	mov	BYTE PTR 16[rax], 0
	lea	rax, -4112[rbp]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -4120[rbp], rax
	cmp	QWORD PTR -4120[rbp], 0
	jne	.L13
	mov	eax, 0
	jmp	.L15
.L13:
	mov	DWORD PTR -4136[rbp], 0
	mov	rdx, QWORD PTR -4120[rbp]
	lea	rax, -4136[rbp]
	mov	rcx, rdx
	mov	edx, 1
	mov	esi, 4
	mov	rdi, rax
	call	fread@PLT
	mov	DWORD PTR -4132[rbp], eax
	mov	rax, QWORD PTR -4120[rbp]
	mov	rdi, rax
	call	fclose@PLT
	cmp	DWORD PTR -4132[rbp], 0
	jne	.L14
	mov	eax, 0
	jmp	.L15
.L14:
	mov	eax, DWORD PTR -4136[rbp]
.L15:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L16
	call	__stack_chk_fail@PLT
.L16:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	get_win_count, .-get_win_count
	.globl	screen
	.bss
	.align 8
	.type	screen, @object
	.size	screen, 8
screen:
	.zero	8
	.globl	statusbar
	.align 8
	.type	statusbar, @object
	.size	statusbar, 8
statusbar:
	.zero	8
	.globl	cards
	.align 32
	.type	cards, @object
	.size	cards, 160
cards:
	.zero	160
	.text
	.globl	lastcard
	.type	lastcard, @function
lastcard:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -4[rbp], eax
	jmp	.L18
.L20:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -4[rbp], eax
.L18:
	cmp	DWORD PTR -4[rbp], 0
	js	.L19
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, -1
	jne	.L20
.L19:
	mov	eax, DWORD PTR -4[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	lastcard, .-lastcard
	.globl	add_to_row
	.type	add_to_row, @function
add_to_row:
.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, 24
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -24[rbp], esi
	mov	eax, DWORD PTR -20[rbp]
	mov	edi, eax
	call	lastcard
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	jne	.L23
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rcx, 0[0+rax*4]
	lea	rdx, rows[rip]
	mov	eax, DWORD PTR -24[rbp]
	mov	DWORD PTR [rcx+rdx], eax
	jmp	.L24
.L23:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rcx, 0[0+rax*4]
	lea	rdx, cards[rip]
	mov	eax, DWORD PTR -24[rbp]
	mov	DWORD PTR [rcx+rdx], eax
.L24:
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.size	add_to_row, .-add_to_row
	.globl	card_can_be_stacked
	.type	card_can_be_stacked, @function
card_can_be_stacked:
.LFB10:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -4[rbp], edi
	mov	DWORD PTR -8[rbp], esi
	cmp	DWORD PTR -4[rbp], -1
	jne	.L27
	mov	eax, 1
	jmp	.L28
.L27:
	cmp	DWORD PTR -4[rbp], -2
	jne	.L29
	mov	eax, 0
	jmp	.L28
.L29:
	cmp	DWORD PTR -8[rbp], -1
	jne	.L30
	mov	eax, 0
	jmp	.L28
.L30:
	cmp	DWORD PTR -8[rbp], -2
	jne	.L31
	mov	eax, 0
	jmp	.L28
.L31:
	cmp	DWORD PTR -4[rbp], 26
	jle	.L32
	mov	eax, 0
	jmp	.L28
.L32:
	cmp	DWORD PTR -8[rbp], 26
	jle	.L33
	mov	eax, 0
	jmp	.L28
.L33:
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 1431655766
	shr	rdx, 32
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	mov	ecx, edx
	add	ecx, ecx
	add	ecx, edx
	sub	eax, ecx
	mov	edx, eax
	mov	ecx, DWORD PTR -8[rbp]
	movsx	rax, ecx
	imul	rax, rax, 1431655766
	shr	rax, 32
	mov	esi, ecx
	sar	esi, 31
	sub	eax, esi
	mov	esi, eax
	add	esi, esi
	add	esi, eax
	mov	eax, ecx
	sub	eax, esi
	cmp	edx, eax
	je	.L34
	mov	eax, DWORD PTR -4[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 1431655766
	shr	rdx, 32
	sar	eax, 31
	mov	ecx, edx
	sub	ecx, eax
	mov	eax, DWORD PTR -8[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 1431655766
	shr	rdx, 32
	sar	eax, 31
	mov	esi, eax
	mov	eax, edx
	sub	eax, esi
	add	eax, 1
	cmp	ecx, eax
	jne	.L34
	mov	eax, 1
	jmp	.L28
.L34:
	mov	eax, 0
.L28:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE10:
	.size	card_can_be_stacked, .-card_can_be_stacked
	.globl	find_parent
	.type	find_parent, @function
find_parent:
.LFB11:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -8[rbp], 0
	jmp	.L36
.L44:
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	cmp	eax, DWORD PTR -20[rbp]
	jne	.L37
	mov	eax, -1
	jmp	.L38
.L37:
	cmp	DWORD PTR -4[rbp], -1
	je	.L45
	jmp	.L41
.L43:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	DWORD PTR -20[rbp], eax
	jne	.L42
	mov	eax, DWORD PTR -4[rbp]
	jmp	.L38
.L42:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -4[rbp], eax
.L41:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	test	eax, eax
	jns	.L43
	jmp	.L40
.L45:
	nop
.L40:
	add	DWORD PTR -8[rbp], 1
.L36:
	cmp	DWORD PTR -8[rbp], 7
	jle	.L44
	mov	eax, -1
.L38:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE11:
	.size	find_parent, .-find_parent
	.globl	stacklen
	.type	stacklen, @function
stacklen:
.LFB12:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -8[rbp], 0
	mov	eax, DWORD PTR -20[rbp]
	mov	DWORD PTR -4[rbp], eax
	jmp	.L47
.L48:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -4[rbp], eax
	add	DWORD PTR -8[rbp], 1
.L47:
	cmp	DWORD PTR -4[rbp], 0
	jns	.L48
	mov	eax, DWORD PTR -8[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE12:
	.size	stacklen, .-stacklen
	.globl	remove_card
	.type	remove_card, @function
remove_card:
.LFB13:
	.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	DWORD PTR -20[rbp], edi
	cmp	DWORD PTR -20[rbp], 0
	js	.L51
	cmp	DWORD PTR -20[rbp], 39
	jle	.L52
.L51:
	mov	eax, 0
	jmp	.L53
.L52:
	mov	eax, DWORD PTR -20[rbp]
	mov	edi, eax
	call	find_parent
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], -1
	je	.L54
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	DWORD PTR [rdx+rax], -1
.L54:
	mov	DWORD PTR -8[rbp], 0
	jmp	.L55
.L57:
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	DWORD PTR -20[rbp], eax
	jne	.L56
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	DWORD PTR [rdx+rax], -1
.L56:
	add	DWORD PTR -8[rbp], 1
.L55:
	cmp	DWORD PTR -8[rbp], 10
	jle	.L57
	mov	eax, 1
.L53:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE13:
	.size	remove_card, .-remove_card
	.globl	move_card
	.type	move_card, @function
move_card:
.LFB14:
	.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	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -24[rbp], esi
	mov	DWORD PTR -28[rbp], edx
	cmp	DWORD PTR -20[rbp], -1
	jne	.L59
	mov	eax, 0
	jmp	.L60
.L59:
	cmp	DWORD PTR -20[rbp], 10
	jle	.L61
	mov	eax, 0
	jmp	.L60
.L61:
	cmp	DWORD PTR -24[rbp], 0
	jns	.L62
	mov	eax, 0
	jmp	.L60
.L62:
	cmp	DWORD PTR -28[rbp], 7
	jle	.L63
	cmp	DWORD PTR -28[rbp], 10
	jg	.L63
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, -1
	je	.L63
	mov	eax, 0
	jmp	.L60
.L63:
	cmp	DWORD PTR -28[rbp], 7
	jle	.L64
	mov	eax, DWORD PTR -24[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, -1
	je	.L64
	mov	eax, 0
	jmp	.L60
.L64:
	cmp	DWORD PTR -28[rbp], 11
	jne	.L65
	cmp	DWORD PTR -24[rbp], 39
	je	.L65
	mov	eax, 0
	jmp	.L60
.L65:
	cmp	DWORD PTR -28[rbp], 7
	jg	.L66
	mov	eax, DWORD PTR -28[rbp]
	mov	edi, eax
	call	lastcard
	mov	edx, eax
	mov	eax, DWORD PTR -24[rbp]
	mov	esi, eax
	mov	edi, edx
	call	card_can_be_stacked
	xor	eax, 1
	test	al, al
	je	.L66
	mov	eax, 0
	jmp	.L60
.L66:
	cmp	DWORD PTR -28[rbp], 11
	jle	.L67
	cmp	DWORD PTR -24[rbp], 26
	jle	.L67
	mov	eax, 0
	jmp	.L60
.L67:
	cmp	DWORD PTR -28[rbp], 11
	jle	.L68
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, -1
	jne	.L68
	cmp	DWORD PTR -24[rbp], 2
	jle	.L68
	mov	eax, 0
	jmp	.L60
.L68:
	cmp	DWORD PTR -28[rbp], 11
	jle	.L69
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, -1
	je	.L69
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edx, DWORD PTR -24[rbp]
	sub	edx, 3
	cmp	eax, edx
	je	.L69
	mov	eax, 0
	jmp	.L60
.L69:
	mov	eax, DWORD PTR -24[rbp]
	mov	edi, eax
	call	find_parent
	mov	DWORD PTR -8[rbp], eax
	cmp	DWORD PTR -8[rbp], -1
	je	.L70
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	DWORD PTR [rdx+rax], -1
.L70:
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	DWORD PTR -24[rbp], eax
	jne	.L71
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	DWORD PTR [rdx+rax], -1
.L71:
	mov	eax, DWORD PTR -28[rbp]
	mov	edi, eax
	call	lastcard
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -28[rbp], 11
	jg	.L72
	cmp	DWORD PTR -4[rbp], -1
	jne	.L73
.L72:
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rcx, 0[0+rax*4]
	lea	rdx, rows[rip]
	mov	eax, DWORD PTR -24[rbp]
	mov	DWORD PTR [rcx+rdx], eax
	mov	eax, 1
	jmp	.L60
.L73:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rcx, 0[0+rax*4]
	lea	rdx, cards[rip]
	mov	eax, DWORD PTR -24[rbp]
	mov	DWORD PTR [rcx+rdx], eax
	mov	eax, 1
.L60:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE14:
	.size	move_card, .-move_card
	.globl	clear_row
	.type	clear_row, @function
clear_row:
.LFB15:
	.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	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -24[rbp], esi
	mov	DWORD PTR -28[rbp], edx
	mov	DWORD PTR -12[rbp], 0
	mov	DWORD PTR -8[rbp], 0
	cmp	DWORD PTR -20[rbp], 7
	jg	.L75
	mov	edx, DWORD PTR -20[rbp]
	mov	eax, edx
	sal	eax, 3
	add	eax, edx
	add	eax, 6
	mov	DWORD PTR -12[rbp], eax
	mov	DWORD PTR -8[rbp], 5
.L75:
	cmp	DWORD PTR -20[rbp], 7
	jle	.L76
	cmp	DWORD PTR -20[rbp], 10
	jg	.L76
	mov	eax, DWORD PTR -20[rbp]
	lea	edx, -8[rax]
	mov	eax, edx
	sal	eax, 3
	sub	eax, edx
	add	eax, 2
	mov	DWORD PTR -12[rbp], eax
	mov	DWORD PTR -8[rbp], 2
.L76:
	cmp	DWORD PTR -20[rbp], 11
	jne	.L77
	mov	DWORD PTR -12[rbp], 38
	mov	DWORD PTR -8[rbp], 2
.L77:
	cmp	DWORD PTR -20[rbp], 11
	jle	.L78
	mov	eax, DWORD PTR -20[rbp]
	lea	edx, -12[rax]
	mov	eax, edx
	sal	eax, 3
	sub	eax, edx
	add	eax, 58
	mov	DWORD PTR -12[rbp], eax
	mov	DWORD PTR -8[rbp], 2
.L78:
	mov	DWORD PTR -4[rbp], 0
	jmp	.L79
.L82:
	mov	edx, DWORD PTR -8[rbp]
	mov	eax, DWORD PTR -24[rbp]
	add	edx, eax
	mov	eax, DWORD PTR -4[rbp]
	lea	ecx, [rdx+rax]
	mov	rax, QWORD PTR screen[rip]
	mov	edx, DWORD PTR -12[rbp]
	mov	esi, ecx
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L81
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 5
	mov	esi, 32
	mov	rdi, rax
	call	whline@PLT
.L81:
	add	DWORD PTR -4[rbp], 1
.L79:
	mov	eax, DWORD PTR -4[rbp]
	cmp	eax, DWORD PTR -28[rbp]
	jl	.L82
	mov	rax, QWORD PTR screen[rip]
	mov	rdi, rax
	call	wrefresh@PLT
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE15:
	.size	clear_row, .-clear_row
	.section	.rodata
.LC8:
	.string	"[   ]"
.LC9:
	.string	"%3d"
.LC10:
	.string	"-*-"
.LC11:
	.string	"%c%c"
.LC12:
	.string	"-%c-"
.LC13:
	.string	" @ "
	.text
	.globl	draw_card
	.type	draw_card, @function
draw_card:
.LFB16:
	.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	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -24[rbp], esi
	mov	DWORD PTR -28[rbp], edx
	mov	eax, DWORD PTR selcard[rip]
	cmp	eax, -1
	je	.L85
	mov	eax, DWORD PTR selcard[rip]
	cmp	DWORD PTR -20[rbp], eax
	jne	.L85
	mov	eax, 1
	jmp	.L86
.L85:
	mov	eax, 0
.L86:
	mov	BYTE PTR -5[rbp], al
	and	BYTE PTR -5[rbp], 1
	mov	eax, DWORD PTR curtheme[rip]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, 0[0+rax*8]
	add	rax, rdx
	sal	rax, 2
	mov	rdx, rax
	lea	rax, themes[rip+96]
	mov	eax, DWORD PTR [rdx+rax]
	mov	esi, eax
	cmp	DWORD PTR -20[rbp], 39
	je	.L87
	cmp	DWORD PTR -20[rbp], -2
	je	.L87
	mov	edx, DWORD PTR -20[rbp]
	movsx	rax, edx
	imul	rax, rax, 1431655766
	shr	rax, 32
	mov	ecx, edx
	sar	ecx, 31
	sub	eax, ecx
	mov	ecx, eax
	add	ecx, ecx
	add	ecx, eax
	mov	eax, edx
	sub	eax, ecx
	add	eax, 4
	sal	eax, 8
	movzx	eax, ax
	jmp	.L88
.L87:
	mov	eax, 1792
.L88:
	or	eax, esi
	mov	DWORD PTR -4[rbp], eax
	cmp	BYTE PTR -5[rbp], 0
	je	.L89
	mov	eax, DWORD PTR curtheme[rip]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, 0[0+rax*8]
	add	rax, rdx
	sal	rax, 2
	mov	rdx, rax
	lea	rax, themes[rip+104]
	mov	eax, DWORD PTR [rdx+rax]
	or	eax, DWORD PTR -4[rbp]
	mov	ecx, eax
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_on@PLT
	jmp	.L90
.L89:
	cmp	DWORD PTR -20[rbp], -1
	jne	.L91
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_on@PLT
	jmp	.L90
.L91:
	mov	eax, DWORD PTR curtheme[rip]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, 0[0+rax*8]
	add	rax, rdx
	sal	rax, 2
	mov	rdx, rax
	lea	rax, themes[rip+100]
	mov	eax, DWORD PTR [rdx+rax]
	or	ah, 3
	mov	ecx, eax
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_on@PLT
.L90:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, DWORD PTR -24[rbp]
	mov	esi, DWORD PTR -28[rbp]
	lea	rcx, .LC8[rip]
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	cmp	DWORD PTR -20[rbp], -1
	jne	.L92
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_off@PLT
	jmp	.L93
.L92:
	cmp	BYTE PTR -5[rbp], 0
	je	.L94
	mov	eax, DWORD PTR curtheme[rip]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, 0[0+rax*8]
	add	rax, rdx
	sal	rax, 2
	mov	rdx, rax
	lea	rax, themes[rip+104]
	mov	eax, DWORD PTR [rdx+rax]
	or	eax, DWORD PTR -4[rbp]
	mov	ecx, eax
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_off@PLT
	jmp	.L93
.L94:
	mov	eax, DWORD PTR curtheme[rip]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, 0[0+rax*8]
	add	rax, rdx
	sal	rax, 2
	mov	rdx, rax
	lea	rax, themes[rip+100]
	mov	eax, DWORD PTR [rdx+rax]
	or	ah, 3
	mov	ecx, eax
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_off@PLT
.L93:
	cmp	DWORD PTR -20[rbp], -1
	je	.L106
	cmp	BYTE PTR -5[rbp], 0
	je	.L97
	mov	eax, DWORD PTR curtheme[rip]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, 0[0+rax*8]
	add	rax, rdx
	sal	rax, 2
	mov	rdx, rax
	lea	rax, themes[rip+104]
	mov	eax, DWORD PTR [rdx+rax]
	jmp	.L98
.L97:
	mov	eax, 0
.L98:
	or	eax, DWORD PTR -4[rbp]
	mov	ecx, eax
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_on@PLT
	movzx	eax, BYTE PTR showcardnum[rip]
	test	al, al
	je	.L99
	mov	eax, DWORD PTR -24[rbp]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	ecx, DWORD PTR -20[rbp]
	mov	esi, DWORD PTR -28[rbp]
	mov	r8d, ecx
	lea	rcx, .LC9[rip]
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	jmp	.L100
.L99:
	cmp	DWORD PTR -20[rbp], -2
	jne	.L101
	mov	eax, DWORD PTR -24[rbp]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, DWORD PTR -28[rbp]
	lea	rcx, .LC10[rip]
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	jmp	.L100
.L101:
	cmp	DWORD PTR -20[rbp], 26
	jg	.L102
	mov	rsi, QWORD PTR cardsuits[rip]
	mov	edx, DWORD PTR -20[rbp]
	movsx	rax, edx
	imul	rax, rax, 1431655766
	shr	rax, 32
	mov	ecx, edx
	sar	ecx, 31
	sub	eax, ecx
	mov	ecx, eax
	add	ecx, ecx
	add	ecx, eax
	mov	eax, edx
	sub	eax, ecx
	cdqe
	add	rax, rsi
	movzx	eax, BYTE PTR [rax]
	movsx	edi, al
	mov	rcx, QWORD PTR cardvals[rip]
	mov	eax, DWORD PTR -20[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 1431655766
	shr	rdx, 32
	sar	eax, 31
	mov	esi, eax
	mov	eax, edx
	sub	eax, esi
	cdqe
	add	rax, rcx
	movzx	eax, BYTE PTR [rax]
	movsx	ecx, al
	mov	eax, DWORD PTR -24[rbp]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, DWORD PTR -28[rbp]
	mov	r9d, edi
	mov	r8d, ecx
	lea	rcx, .LC11[rip]
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	jmp	.L100
.L102:
	cmp	DWORD PTR -20[rbp], 38
	jg	.L103
	mov	rsi, QWORD PTR cardsuits[rip]
	mov	edx, DWORD PTR -20[rbp]
	movsx	rax, edx
	imul	rax, rax, 1431655766
	shr	rax, 32
	mov	ecx, edx
	sar	ecx, 31
	sub	eax, ecx
	mov	ecx, eax
	add	ecx, ecx
	add	ecx, eax
	mov	eax, edx
	sub	eax, ecx
	cdqe
	add	rax, rsi
	movzx	eax, BYTE PTR [rax]
	movsx	ecx, al
	mov	eax, DWORD PTR -24[rbp]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, DWORD PTR -28[rbp]
	mov	r8d, ecx
	lea	rcx, .LC12[rip]
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	jmp	.L100
.L103:
	mov	eax, DWORD PTR -24[rbp]
	lea	edx, 1[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, DWORD PTR -28[rbp]
	lea	rcx, .LC13[rip]
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
.L100:
	cmp	BYTE PTR -5[rbp], 0
	je	.L104
	mov	eax, DWORD PTR curtheme[rip]
	movsx	rdx, eax
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, 0[0+rax*8]
	add	rax, rdx
	sal	rax, 2
	mov	rdx, rax
	lea	rax, themes[rip+104]
	mov	eax, DWORD PTR [rdx+rax]
	jmp	.L105
.L104:
	mov	eax, 0
.L105:
	or	eax, DWORD PTR -4[rbp]
	mov	ecx, eax
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_off@PLT
	jmp	.L84
.L106:
	nop
.L84:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE16:
	.size	draw_card, .-draw_card
	.globl	find_freecell
	.type	find_freecell, @function
find_freecell:
.LFB17:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -4[rbp], 8
	jmp	.L108
.L111:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, -1
	jne	.L109
	mov	eax, DWORD PTR -4[rbp]
	jmp	.L110
.L109:
	add	DWORD PTR -4[rbp], 1
.L108:
	cmp	DWORD PTR -4[rbp], 10
	jle	.L111
	mov	eax, -1
.L110:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE17:
	.size	find_freecell, .-find_freecell
	.globl	find_foundation
	.type	find_foundation, @function
find_foundation:
.LFB18:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -4[rbp], 12
	jmp	.L113
.L116:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	DWORD PTR -20[rbp], eax
	jne	.L114
	mov	eax, DWORD PTR -4[rbp]
	jmp	.L115
.L114:
	add	DWORD PTR -4[rbp], 1
.L113:
	cmp	DWORD PTR -4[rbp], 14
	jle	.L116
	mov	eax, -1
.L115:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE18:
	.size	find_foundation, .-find_foundation
	.globl	exposed_dragons
	.type	exposed_dragons, @function
exposed_dragons:
.LFB19:
	.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	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, -20[rbp]
	mov	edx, 12
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	lea	rax, -23[rbp]
	mov	edx, 3
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	mov	DWORD PTR -40[rbp], 0
	jmp	.L118
.L120:
	mov	eax, DWORD PTR -40[rbp]
	mov	edi, eax
	call	lastcard
	mov	DWORD PTR -28[rbp], eax
	cmp	DWORD PTR -28[rbp], 26
	jle	.L119
	cmp	DWORD PTR -28[rbp], 38
	jg	.L119
	mov	edx, DWORD PTR -28[rbp]
	movsx	rax, edx
	imul	rax, rax, 1431655766
	shr	rax, 32
	mov	ecx, edx
	sar	ecx, 31
	sub	eax, ecx
	mov	ecx, eax
	add	ecx, ecx
	add	ecx, eax
	mov	eax, edx
	sub	eax, ecx
	movsx	rdx, eax
	mov	edx, DWORD PTR -20[rbp+rdx*4]
	add	edx, 1
	cdqe
	mov	DWORD PTR -20[rbp+rax*4], edx
	cmp	DWORD PTR -40[rbp], 7
	jle	.L119
	mov	edx, DWORD PTR -28[rbp]
	movsx	rax, edx
	imul	rax, rax, 1431655766
	shr	rax, 32
	mov	ecx, edx
	sar	ecx, 31
	sub	eax, ecx
	mov	ecx, eax
	add	ecx, ecx
	add	ecx, eax
	mov	eax, edx
	sub	eax, ecx
	cdqe
	mov	BYTE PTR -23[rbp+rax], 1
.L119:
	add	DWORD PTR -40[rbp], 1
.L118:
	cmp	DWORD PTR -40[rbp], 10
	jle	.L120
	mov	DWORD PTR -36[rbp], 0
	mov	DWORD PTR -32[rbp], 0
	jmp	.L121
.L124:
	mov	eax, 0
	call	find_freecell
	cmp	eax, -1
	jne	.L122
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	movzx	eax, BYTE PTR -23[rbp+rax]
	test	al, al
	je	.L123
.L122:
	mov	eax, DWORD PTR -32[rbp]
	cdqe
	mov	eax, DWORD PTR -20[rbp+rax*4]
	cmp	eax, 4
	jne	.L123
	mov	eax, DWORD PTR -32[rbp]
	mov	edx, 1
	mov	ecx, eax
	sal	edx, cl
	mov	eax, edx
	or	DWORD PTR -36[rbp], eax
.L123:
	add	DWORD PTR -32[rbp], 1
.L121:
	cmp	DWORD PTR -32[rbp], 2
	jle	.L124
	mov	eax, DWORD PTR -36[rbp]
	mov	rsi, QWORD PTR -8[rbp]
	sub	rsi, QWORD PTR fs:40
	je	.L126
	call	__stack_chk_fail@PLT
.L126:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE19:
	.size	exposed_dragons, .-exposed_dragons
	.globl	remove_exposed_dragons
	.type	remove_exposed_dragons, @function
remove_exposed_dragons:
.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, 32
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -8[rbp], 0
	jmp	.L128
.L130:
	mov	eax, DWORD PTR -8[rbp]
	mov	edi, eax
	call	lastcard
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 26
	jle	.L129
	cmp	DWORD PTR -4[rbp], 38
	jg	.L129
	mov	edx, DWORD PTR -4[rbp]
	movsx	rax, edx
	imul	rax, rax, 1431655766
	shr	rax, 32
	mov	ecx, edx
	sar	ecx, 31
	sub	eax, ecx
	mov	ecx, eax
	add	ecx, ecx
	add	ecx, eax
	mov	eax, edx
	sub	eax, ecx
	cmp	DWORD PTR -20[rbp], eax
	jne	.L129
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	remove_card
	mov	eax, DWORD PTR -8[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	mov	ecx, eax
	mov	eax, DWORD PTR -8[rbp]
	mov	edx, 1
	mov	esi, ecx
	mov	edi, eax
	call	clear_row
.L129:
	add	DWORD PTR -8[rbp], 1
.L128:
	cmp	DWORD PTR -8[rbp], 10
	jle	.L130
	mov	eax, 0
	call	find_freecell
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	DWORD PTR [rdx+rax], -2
	mov	eax, 1
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE20:
	.size	remove_exposed_dragons, .-remove_exposed_dragons
	.section	.rodata
.LC14:
	.string	"%d"
.LC15:
	.string	"(%c)"
.LC16:
	.string	"Y O U   W I N !"
.LC17:
	.string	"%5d win%c"
	.text
	.globl	draw_cards
	.type	draw_cards, @function
draw_cards:
.LFB21:
	.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	DWORD PTR -24[rbp], 0
	jmp	.L133
.L140:
	mov	edx, DWORD PTR -24[rbp]
	mov	eax, edx
	sal	eax, 3
	sub	eax, edx
	lea	ecx, 2[rax]
	mov	eax, DWORD PTR -24[rbp]
	add	eax, 8
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edx, 2
	mov	esi, ecx
	mov	edi, eax
	call	draw_card
	mov	edx, DWORD PTR -24[rbp]
	mov	eax, edx
	sal	eax, 3
	sub	eax, edx
	lea	ecx, 58[rax]
	mov	eax, DWORD PTR -24[rbp]
	add	eax, 12
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edx, 2
	mov	esi, ecx
	mov	edi, eax
	call	draw_card
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_on@PLT
	mov	edx, DWORD PTR -24[rbp]
	mov	eax, edx
	sal	eax, 3
	sub	eax, edx
	lea	edx, 4[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, 1
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L135
	mov	rdx, QWORD PTR rowkeys[rip]
	mov	eax, DWORD PTR -24[rbp]
	add	eax, 8
	cdqe
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	edx, al
	mov	rax, QWORD PTR screen[rip]
	mov	esi, edx
	mov	rdi, rax
	call	waddch@PLT
.L135:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 40
	mov	esi, 1
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L137
	mov	rax, QWORD PTR rowkeys[rip]
	add	rax, 11
	movzx	eax, BYTE PTR [rax]
	movsx	edx, al
	mov	rax, QWORD PTR screen[rip]
	mov	esi, edx
	mov	rdi, rax
	call	waddch@PLT
.L137:
	mov	edx, DWORD PTR -24[rbp]
	mov	eax, edx
	sal	eax, 3
	sub	eax, edx
	lea	edx, 60[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, 1
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L139
	mov	rdx, QWORD PTR rowkeys[rip]
	mov	eax, DWORD PTR -24[rbp]
	add	eax, 12
	cdqe
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	edx, al
	mov	rax, QWORD PTR screen[rip]
	mov	esi, edx
	mov	rdi, rax
	call	waddch@PLT
.L139:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_off@PLT
	add	DWORD PTR -24[rbp], 1
.L133:
	cmp	DWORD PTR -24[rbp], 2
	jle	.L140
	mov	eax, DWORD PTR rows[rip+44]
	mov	edx, 2
	mov	esi, 38
	mov	edi, eax
	call	draw_card
	mov	eax, 0
	call	exposed_dragons
	mov	DWORD PTR -4[rbp], eax
	mov	DWORD PTR -20[rbp], 0
	jmp	.L141
.L144:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_on@PLT
	mov	eax, DWORD PTR -20[rbp]
	lea	ecx, 4[rax]
	mov	eax, DWORD PTR -20[rbp]
	sal	eax, 2
	lea	edx, 23[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	r8d, ecx
	lea	rcx, .LC14[rip]
	mov	esi, 1
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_off@PLT
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, DWORD PTR -4[rbp]
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	sal	eax, 21
	and	eax, 2097152
	mov	edx, eax
	mov	eax, DWORD PTR -20[rbp]
	add	eax, 4
	sal	eax, 8
	movzx	eax, ax
	mov	ecx, edx
	or	ecx, eax
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_on@PLT
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, DWORD PTR -4[rbp]
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L142
	mov	rdx, QWORD PTR cardsuits[rip]
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	ecx, al
	jmp	.L143
.L142:
	mov	ecx, 32
.L143:
	mov	eax, DWORD PTR -20[rbp]
	sal	eax, 2
	lea	edx, 22[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	r8d, ecx
	lea	rcx, .LC15[rip]
	mov	esi, 2
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, DWORD PTR -4[rbp]
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	sal	eax, 21
	and	eax, 2097152
	mov	edx, eax
	mov	eax, DWORD PTR -20[rbp]
	add	eax, 4
	sal	eax, 8
	movzx	eax, ax
	mov	ecx, edx
	or	ecx, eax
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_off@PLT
	add	DWORD PTR -20[rbp], 1
.L141:
	cmp	DWORD PTR -20[rbp], 2
	jle	.L144
	mov	DWORD PTR -16[rbp], 0
	jmp	.L145
.L150:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_on@PLT
	mov	edx, DWORD PTR -16[rbp]
	mov	eax, edx
	sal	eax, 3
	add	eax, edx
	lea	edx, 8[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, 4
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L147
	mov	rdx, QWORD PTR rowkeys[rip]
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	edx, al
	mov	rax, QWORD PTR screen[rip]
	mov	esi, edx
	mov	rdi, rax
	call	waddch@PLT
.L147:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_off@PLT
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -12[rbp], eax
	mov	DWORD PTR -8[rbp], 0
.L149:
	mov	eax, DWORD PTR -8[rbp]
	lea	edx, 5[rax]
	mov	ecx, DWORD PTR -16[rbp]
	mov	eax, ecx
	sal	eax, 3
	add	eax, ecx
	lea	ecx, 6[rax]
	mov	eax, DWORD PTR -12[rbp]
	mov	esi, ecx
	mov	edi, eax
	call	draw_card
	add	DWORD PTR -8[rbp], 1
	cmp	DWORD PTR -12[rbp], 0
	js	.L148
	mov	eax, DWORD PTR -12[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -12[rbp], eax
.L148:
	cmp	DWORD PTR -12[rbp], 0
	jns	.L149
	add	DWORD PTR -16[rbp], 1
.L145:
	cmp	DWORD PTR -16[rbp], 7
	jle	.L150
	mov	eax, DWORD PTR rows[rip+32]
	cmp	eax, -2
	jne	.L151
	mov	eax, DWORD PTR rows[rip+36]
	cmp	eax, -2
	jne	.L151
	mov	eax, DWORD PTR rows[rip+40]
	cmp	eax, -2
	jne	.L151
	mov	eax, DWORD PTR rows[rip+48]
	cmp	eax, 23
	jle	.L151
	mov	eax, DWORD PTR rows[rip+52]
	cmp	eax, 23
	jle	.L151
	mov	eax, DWORD PTR rows[rip+56]
	cmp	eax, 23
	jle	.L151
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2099200
	mov	rdi, rax
	call	wattr_on@PLT
	mov	rax, QWORD PTR screen[rip]
	lea	rcx, .LC16[rip]
	mov	edx, 32
	mov	esi, 13
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	movzx	eax, BYTE PTR won_game[rip]
	xor	eax, 1
	test	al, al
	je	.L152
	mov	eax, DWORD PTR seed[rip]
	test	eax, eax
	js	.L153
	mov	eax, DWORD PTR wincount[rip]
	add	eax, 1
	mov	DWORD PTR wincount[rip], eax
	mov	eax, DWORD PTR wincount[rip]
	mov	edi, eax
	call	set_win_count
.L153:
	mov	BYTE PTR won_game[rip], 1
.L152:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2099200
	mov	rdi, rax
	call	wattr_on@PLT
.L151:
	movzx	eax, BYTE PTR won_game[rip]
	test	al, al
	je	.L154
	mov	ecx, 2099200
	jmp	.L155
.L154:
	mov	ecx, 2048
.L155:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_on@PLT
	mov	ecx, DWORD PTR wincount[rip]
	mov	edx, ecx
	mov	eax, 3435973837
	imul	rax, rdx
	shr	rax, 32
	mov	edx, eax
	shr	edx, 3
	mov	eax, edx
	sal	eax, 2
	add	eax, edx
	add	eax, eax
	sub	ecx, eax
	mov	edx, ecx
	cmp	edx, 1
	jne	.L156
	mov	eax, DWORD PTR wincount[rip]
	cmp	eax, 11
	jne	.L157
.L156:
	mov	ecx, 115
	jmp	.L158
.L157:
	mov	ecx, 32
.L158:
	mov	edx, DWORD PTR wincount[rip]
	mov	rax, QWORD PTR screen[rip]
	mov	r9d, ecx
	mov	r8d, edx
	lea	rcx, .LC17[rip]
	mov	edx, 68
	mov	esi, 21
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	movzx	eax, BYTE PTR won_game[rip]
	test	al, al
	je	.L159
	mov	ecx, 2099200
	jmp	.L160
.L159:
	mov	ecx, 2048
.L160:
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_off@PLT
	mov	rax, QWORD PTR screen[rip]
	mov	rdi, rax
	call	wrefresh@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE21:
	.size	draw_cards, .-draw_cards
	.globl	get_card
	.type	get_card, @function
get_card:
.LFB22:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -24[rbp], esi
	mov	QWORD PTR -32[rbp], rdx
	cmp	DWORD PTR -20[rbp], 14
	jle	.L162
	mov	eax, -1
	jmp	.L163
.L162:
	cmp	DWORD PTR -20[rbp], 7
	jle	.L164
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	jmp	.L163
.L164:
	mov	DWORD PTR -8[rbp], 0
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -4[rbp], eax
	jmp	.L165
.L167:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	DWORD PTR -4[rbp], eax
	add	DWORD PTR -8[rbp], 1
.L165:
	cmp	DWORD PTR -4[rbp], 0
	js	.L166
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, -1
	je	.L166
	mov	eax, DWORD PTR -8[rbp]
	cmp	eax, DWORD PTR -24[rbp]
	jne	.L167
.L166:
	cmp	QWORD PTR -32[rbp], 0
	je	.L168
	mov	rax, QWORD PTR -32[rbp]
	mov	edx, DWORD PTR -8[rbp]
	mov	DWORD PTR [rax], edx
.L168:
	mov	eax, DWORD PTR -4[rbp]
.L163:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE22:
	.size	get_card, .-get_card
	.globl	auto_move
	.type	auto_move, @function
auto_move:
.LFB23:
	.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	DWORD PTR -28[rbp], 0
	jmp	.L170
.L181:
	mov	eax, DWORD PTR -28[rbp]
	mov	edi, eax
	call	lastcard
	mov	DWORD PTR -20[rbp], eax
	mov	DWORD PTR -16[rbp], -1
	cmp	DWORD PTR -20[rbp], 39
	jne	.L171
	mov	eax, DWORD PTR -28[rbp]
	mov	edx, 11
	mov	esi, 39
	mov	edi, eax
	call	move_card
	movzx	eax, al
	mov	DWORD PTR -4[rbp], eax
	cmp	DWORD PTR -4[rbp], 0
	je	.L172
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	mov	ecx, eax
	mov	eax, DWORD PTR -28[rbp]
	mov	edx, 1
	mov	esi, ecx
	mov	edi, eax
	call	clear_row
.L172:
	mov	eax, DWORD PTR -4[rbp]
	jmp	.L173
.L171:
	cmp	DWORD PTR -20[rbp], 0
	js	.L174
	cmp	DWORD PTR -20[rbp], 2
	jg	.L174
	mov	edi, -1
	call	find_foundation
	mov	DWORD PTR -16[rbp], eax
	cmp	DWORD PTR -16[rbp], -1
	je	.L174
	mov	edx, DWORD PTR -16[rbp]
	mov	ecx, DWORD PTR -20[rbp]
	mov	eax, DWORD PTR -28[rbp]
	mov	esi, ecx
	mov	edi, eax
	call	move_card
	movzx	eax, al
	mov	DWORD PTR -12[rbp], eax
	cmp	DWORD PTR -12[rbp], 0
	je	.L175
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	mov	ecx, eax
	mov	eax, DWORD PTR -28[rbp]
	mov	edx, 1
	mov	esi, ecx
	mov	edi, eax
	call	clear_row
.L175:
	mov	eax, DWORD PTR -12[rbp]
	jmp	.L173
.L174:
	cmp	DWORD PTR -20[rbp], 2
	jle	.L176
	cmp	DWORD PTR -20[rbp], 26
	jg	.L176
	mov	eax, DWORD PTR -20[rbp]
	sub	eax, 3
	mov	edi, eax
	call	find_foundation
	mov	DWORD PTR -16[rbp], eax
	cmp	DWORD PTR -16[rbp], -1
	je	.L176
	mov	BYTE PTR -29[rbp], 1
	mov	DWORD PTR -24[rbp], 0
	jmp	.L177
.L179:
	mov	eax, DWORD PTR -24[rbp]
	add	eax, 12
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	movsx	rdx, eax
	imul	rdx, rdx, 1431655766
	shr	rdx, 32
	sar	eax, 31
	mov	ecx, edx
	sub	ecx, eax
	mov	eax, DWORD PTR -20[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 1431655766
	shr	rdx, 32
	sar	eax, 31
	mov	esi, eax
	mov	eax, edx
	sub	eax, esi
	sub	eax, 1
	cmp	ecx, eax
	jge	.L178
	mov	BYTE PTR -29[rbp], 0
.L178:
	add	DWORD PTR -24[rbp], 1
.L177:
	cmp	DWORD PTR -24[rbp], 2
	jle	.L179
	cmp	BYTE PTR -29[rbp], 0
	je	.L176
	mov	edx, DWORD PTR -16[rbp]
	mov	ecx, DWORD PTR -20[rbp]
	mov	eax, DWORD PTR -28[rbp]
	mov	esi, ecx
	mov	edi, eax
	call	move_card
	movzx	eax, al
	mov	DWORD PTR -8[rbp], eax
	cmp	DWORD PTR -8[rbp], 0
	je	.L180
	mov	eax, DWORD PTR -28[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	mov	ecx, eax
	mov	eax, DWORD PTR -28[rbp]
	mov	edx, 1
	mov	esi, ecx
	mov	edi, eax
	call	clear_row
.L180:
	mov	eax, DWORD PTR -8[rbp]
	jmp	.L173
.L176:
	add	DWORD PTR -28[rbp], 1
.L170:
	cmp	DWORD PTR -28[rbp], 10
	jle	.L181
	mov	eax, 0
.L173:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE23:
	.size	auto_move, .-auto_move
	.globl	update_status
	.type	update_status, @function
update_status:
.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, 16
	mov	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	eax, DWORD PTR -12[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	ecx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_on@PLT
	mov	eax, DWORD PTR -12[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	edx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	esi, edx
	mov	rdi, rax
	call	wbkgd@PLT
	mov	rax, QWORD PTR statusbar[rip]
	mov	rdi, rax
	call	werase@PLT
	mov	rax, QWORD PTR statusbar[rip]
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L184
	mov	rax, QWORD PTR statusbar[rip]
	mov	rcx, QWORD PTR -8[rbp]
	mov	edx, -1
	mov	rsi, rcx
	mov	rdi, rax
	call	waddnstr@PLT
.L184:
	mov	eax, DWORD PTR -12[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	ecx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_off@PLT
	mov	rax, QWORD PTR statusbar[rip]
	mov	rdi, rax
	call	wrefresh@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE24:
	.size	update_status, .-update_status
	.section	.rodata
.LC18:
	.string	"%s: >"
	.text
	.globl	ask_string
	.type	ask_string, @function
ask_string:
.LFB25:
	.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	QWORD PTR -40[rbp], rdx
	mov	DWORD PTR -32[rbp], ecx
	mov	eax, DWORD PTR -28[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	ecx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_on@PLT
	mov	rax, QWORD PTR statusbar[rip]
	mov	rdi, rax
	call	werase@PLT
	mov	eax, DWORD PTR -28[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	edx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	esi, edx
	mov	rdi, rax
	call	wbkgd@PLT
	mov	rax, QWORD PTR statusbar[rip]
	mov	rdx, QWORD PTR -24[rbp]
	mov	r8, rdx
	lea	rcx, .LC18[rip]
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	call	echo@PLT
	mov	edx, DWORD PTR -32[rbp]
	mov	rax, QWORD PTR statusbar[rip]
	mov	rcx, QWORD PTR -40[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	wgetnstr@PLT
	mov	DWORD PTR -4[rbp], eax
	call	noecho@PLT
	mov	eax, DWORD PTR -28[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	ecx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_off@PLT
	cmp	DWORD PTR -4[rbp], 0
	jne	.L186
	mov	eax, 1
	jmp	.L187
.L186:
	mov	eax, 0
.L187:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE25:
	.size	ask_string, .-ask_string
	.globl	ask_integer
	.type	ask_integer, @function
ask_integer:
.LFB26:
	.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, 88
	.cfi_offset 3, -24
	mov	QWORD PTR -72[rbp], rdi
	mov	DWORD PTR -76[rbp], esi
	mov	QWORD PTR -88[rbp], rdx
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	mov	BYTE PTR -48[rbp], 0
.L194:
	call	__errno_location@PLT
	mov	DWORD PTR [rax], 0
	lea	rdx, -48[rbp]
	mov	esi, DWORD PTR -76[rbp]
	mov	rax, QWORD PTR -72[rbp]
	mov	ecx, 20
	mov	rdi, rax
	call	ask_string
	movzx	eax, al
	mov	DWORD PTR -64[rbp], eax
	cmp	DWORD PTR -64[rbp], 0
	jne	.L189
	mov	eax, 0
	jmp	.L195
.L189:
	lea	rax, -48[rbp]
	mov	QWORD PTR -56[rbp], rax
	lea	rcx, -56[rbp]
	lea	rax, -48[rbp]
	mov	edx, 0
	mov	rsi, rcx
	mov	rdi, rax
	call	strtol@PLT
	mov	DWORD PTR -60[rbp], eax
	lea	rax, -48[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L191
	mov	eax, 0
	jmp	.L195
.L191:
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	test	eax, eax
	jne	.L192
	mov	rax, QWORD PTR -56[rbp]
	lea	rdx, -48[rbp]
	sub	rax, rdx
	mov	rbx, rax
	lea	rax, -48[rbp]
	mov	rdi, rax
	call	strlen@PLT
	cmp	rbx, rax
	jnb	.L193
.L192:
	call	beep@PLT
	jmp	.L194
.L193:
	mov	rax, QWORD PTR -88[rbp]
	mov	edx, DWORD PTR -60[rbp]
	mov	DWORD PTR [rax], edx
	mov	eax, 1
.L195:
	mov	rbx, QWORD PTR -24[rbp]
	sub	rbx, QWORD PTR fs:40
	je	.L196
	call	__stack_chk_fail@PLT
.L196:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE26:
	.size	ask_integer, .-ask_integer
	.section	.rodata
.LC19:
	.string	"%s (y/n)? "
.LC20:
	.string	"OK."
	.text
	.globl	yes_or_no
	.type	yes_or_no, @function
yes_or_no:
.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	eax, DWORD PTR -28[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	ecx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_on@PLT
	mov	rax, QWORD PTR statusbar[rip]
	mov	rdi, rax
	call	werase@PLT
	mov	eax, DWORD PTR -28[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	edx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	esi, edx
	mov	rdi, rax
	call	wbkgd@PLT
	mov	rax, QWORD PTR statusbar[rip]
	mov	rdx, QWORD PTR -24[rbp]
	mov	r8, rdx
	lea	rcx, .LC19[rip]
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	mov	eax, DWORD PTR -28[rbp]
	sal	eax, 8
	movzx	eax, ax
	or	eax, 2097152
	mov	ecx, eax
	mov	rax, QWORD PTR statusbar[rip]
	mov	edx, 0
	mov	esi, ecx
	mov	rdi, rax
	call	wattr_off@PLT
.L201:
	mov	rax, QWORD PTR statusbar[rip]
	mov	rdi, rax
	call	wgetch@PLT
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	tolower@PLT
	cmp	eax, 121
	jne	.L198
	mov	esi, 9
	lea	rdi, .LC20[rip]
	call	update_status
	mov	eax, 1
	jmp	.L199
.L198:
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	tolower@PLT
	cmp	eax, 110
	jne	.L201
	mov	esi, 9
	lea	rdi, .LC20[rip]
	call	update_status
	mov	eax, 0
.L199:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE27:
	.size	yes_or_no, .-yes_or_no
	.globl	new_seed
	.type	new_seed, @function
new_seed:
.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, 16
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	edi, 0
	call	time@PLT
	mov	DWORD PTR -12[rbp], eax
	lea	rax, -12[rbp]
	mov	rdi, rax
	call	rand_r@PLT
	mov	rdx, QWORD PTR -8[rbp]
	sub	rdx, QWORD PTR fs:40
	je	.L204
	call	__stack_chk_fail@PLT
.L204:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE28:
	.size	new_seed, .-new_seed
	.globl	init_board
	.type	init_board, @function
init_board:
.LFB29:
	.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, 312
	.cfi_offset 3, -24
	mov	DWORD PTR -308[rbp], edi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -292[rbp], 0
	jmp	.L206
.L207:
	mov	eax, DWORD PTR -292[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	mov	edx, DWORD PTR -292[rbp]
	movsx	rdx, edx
	mov	DWORD PTR -256[rbp+rdx*4], eax
	add	DWORD PTR -292[rbp], 1
.L206:
	cmp	DWORD PTR -292[rbp], 14
	jle	.L207
	mov	DWORD PTR -288[rbp], 0
	jmp	.L208
.L209:
	mov	eax, DWORD PTR -288[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	DWORD PTR [rdx+rax], -1
	add	DWORD PTR -288[rbp], 1
.L208:
	cmp	DWORD PTR -288[rbp], 39
	jle	.L209
	mov	DWORD PTR -284[rbp], 0
	jmp	.L210
.L211:
	mov	eax, DWORD PTR -284[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	DWORD PTR [rdx+rax], -1
	add	DWORD PTR -284[rbp], 1
.L210:
	cmp	DWORD PTR -284[rbp], 14
	jle	.L211
	mov	eax, DWORD PTR -308[rbp]
	mov	edi, eax
	call	srand@PLT
	mov	DWORD PTR -280[rbp], 0
	jmp	.L212
.L213:
	mov	eax, 39
	sub	eax, DWORD PTR -280[rbp]
	mov	edx, eax
	mov	eax, DWORD PTR -280[rbp]
	cdqe
	mov	DWORD PTR -192[rbp+rax*4], edx
	add	DWORD PTR -280[rbp], 1
.L212:
	cmp	DWORD PTR -280[rbp], 39
	jle	.L213
	cmp	DWORD PTR -308[rbp], -1
	je	.L214
	mov	DWORD PTR -276[rbp], 0
	jmp	.L215
.L216:
	call	rand@PLT
	mov	edx, 40
	mov	ecx, edx
	sub	ecx, DWORD PTR -276[rbp]
	cdq
	idiv	ecx
	mov	eax, DWORD PTR -276[rbp]
	add	eax, edx
	mov	DWORD PTR -264[rbp], eax
	mov	eax, DWORD PTR -276[rbp]
	cdqe
	mov	eax, DWORD PTR -192[rbp+rax*4]
	mov	DWORD PTR -260[rbp], eax
	mov	eax, DWORD PTR -264[rbp]
	cdqe
	mov	edx, DWORD PTR -192[rbp+rax*4]
	mov	eax, DWORD PTR -276[rbp]
	cdqe
	mov	DWORD PTR -192[rbp+rax*4], edx
	mov	eax, DWORD PTR -264[rbp]
	cdqe
	mov	edx, DWORD PTR -260[rbp]
	mov	DWORD PTR -192[rbp+rax*4], edx
	add	DWORD PTR -276[rbp], 1
.L215:
	cmp	DWORD PTR -276[rbp], 38
	jle	.L216
.L214:
	mov	DWORD PTR -272[rbp], 0
	jmp	.L217
.L218:
	mov	eax, DWORD PTR -272[rbp]
	cdqe
	mov	edx, DWORD PTR -192[rbp+rax*4]
	mov	eax, DWORD PTR -272[rbp]
	mov	ecx, eax
	sar	ecx, 31
	shr	ecx, 29
	add	eax, ecx
	and	eax, 7
	sub	eax, ecx
	mov	esi, edx
	mov	edi, eax
	call	add_to_row
	add	DWORD PTR -272[rbp], 1
.L217:
	cmp	DWORD PTR -272[rbp], 39
	jle	.L218
	mov	DWORD PTR -268[rbp], 0
	jmp	.L219
.L221:
	mov	eax, DWORD PTR -268[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	mov	edx, DWORD PTR -268[rbp]
	movsx	rdx, edx
	mov	edx, DWORD PTR -256[rbp+rdx*4]
	cmp	eax, edx
	jge	.L220
	mov	eax, DWORD PTR -268[rbp]
	cdqe
	mov	ebx, DWORD PTR -256[rbp+rax*4]
	mov	eax, DWORD PTR -268[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	sub	ebx, eax
	mov	eax, DWORD PTR -268[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	mov	ecx, eax
	mov	eax, DWORD PTR -268[rbp]
	mov	edx, ebx
	mov	esi, ecx
	mov	edi, eax
	call	clear_row
.L220:
	add	DWORD PTR -268[rbp], 1
.L219:
	cmp	DWORD PTR -268[rbp], 14
	jle	.L221
	mov	eax, 0
	mov	rsi, QWORD PTR -24[rbp]
	sub	rsi, QWORD PTR fs:40
	je	.L223
	call	__stack_chk_fail@PLT
.L223:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE29:
	.size	init_board, .-init_board
	.section	.rodata
.LC21:
	.string	"Welcome to szsol!"
.LC22:
	.string	"Game #%d"
	.text
	.globl	draw_initial_screen
	.type	draw_initial_screen, @function
draw_initial_screen:
.LFB30:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	rax, QWORD PTR screen[rip]
	mov	esi, 256
	mov	rdi, rax
	call	wbkgdset@PLT
	mov	rax, QWORD PTR screen[rip]
	mov	rdi, rax
	call	wclear@PLT
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 512
	mov	rdi, rax
	call	wattr_on@PLT
	mov	rax, QWORD PTR screen[rip]
	sub	rsp, 8
	push	0
	push	0
	push	0
	mov	r9d, 0
	mov	r8d, 0
	mov	ecx, 0
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	call	wborder@PLT
	add	rsp, 32
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 512
	mov	rdi, rax
	call	wattr_off@PLT
	mov	esi, 9
	lea	rdi, .LC21[rip]
	call	update_status
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_on@PLT
	mov	edx, DWORD PTR seed[rip]
	mov	rax, QWORD PTR screen[rip]
	mov	r8d, edx
	lea	rcx, .LC22[rip]
	mov	edx, 2
	mov	esi, 21
	mov	rdi, rax
	mov	eax, 0
	call	mvwprintw@PLT
	mov	rax, QWORD PTR screen[rip]
	mov	edx, 0
	mov	esi, 2048
	mov	rdi, rax
	call	wattr_off@PLT
	mov	rax, QWORD PTR screen[rip]
	mov	rdi, rax
	call	wrefresh@PLT
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE30:
	.size	draw_initial_screen, .-draw_initial_screen
	.section	.rodata
	.align 8
.LC23:
	.string	"Press ENTER to start (feel free to attach a debugger to this process at this moment)."
	.align 8
.LC24:
	.ascii	"szsol v0.1 -- a quick and dirty ncurses clone of @zachtronic"
	.ascii	"s'\nS"
	.string	"HENZHEN SOLITAIRE, a solitaire game provided with SHENZHEN I/O\n(also available as a separate game for Windows, Mac OS, Linux and iOS)\n\nSend any bug reports, comments and legal threats regarding this clone to\n@usr_local_share or at github.com/usrshare/szsol"
	.align 8
.LC25:
	.ascii	"Usage: %s [-d] [-D | -F] [-n number] [-v]\n\t-d : Debug mode"
	.ascii	".\n\t-D : Use the QWERTZ keyboard layout.\n\t-F : Use the AZ"
	.ascii	"ERTY keyboard layout.\n\t-n [number] : Start with a predeter"
	.ascii	"mined card layout based on a seed number. \n\t-v : Version /"
	.ascii	" credits.\n\nHow to play:\nThe goal is to clear the tableau "
	.ascii	"by moving all the cards onto\nthe foundations and the free c"
	.ascii	"ells.\n\nCards valued 1 to 9 stack on the foundations by sui"
	.ascii	"t in increasing\norder (1->2->3). They can also be stacked o"
	.ascii	"n the tableau in decreasing\norder (9->8->7), but only if th"
	.ascii	"e suits alternate.\nDragons (labeled '*') can't be stacked -"
	.ascii	"- but when all four dragons\nof a single color are exposed, "
	.ascii	"they can be moved into a single free cell.\nOtherwise, each "
	.ascii	"free cell can only store one card.\n\nControls:\n1,2,3 -- se"
	.ascii	"lect free cells\nW,E,R,T,Y,U,I,O -- select tableau rows\nShi"
	.ascii	"ft-W,E,R,T,Y,U,I,"
	.string	"O -- select highest possible card in that tableau row\n(press multiple times to move more than one card from a row\n8,9,0 -- select foundations\n[space bar] -- remove selection\n4,5,6 -- move dragons onto a free cell (when available)\nShift+Q or Ctrl+C -- exit\n"
.LC26:
	.string	"dvn:t:DF"
	.align 8
.LC27:
	.string	"Terminal window is too small.\nMinimum terminal window size: 80x24.\n"
.LC28:
	.string	"Can't go further in this row."
	.align 8
.LC29:
	.string	"Can't move the cards into this row."
.LC30:
	.string	"Can't select an empty row."
.LC31:
	.string	"Dragons removed."
	.align 8
.LC32:
	.string	"Can't remove these dragons yet."
.LC33:
	.string	"Quit?"
.LC34:
	.string	"Restart this game?"
	.align 8
.LC35:
	.string	"Winning this exact game once again won't increase your win count."
.LC36:
	.string	"Start a new game?"
	.align 8
.LC37:
	.string	"Input game # for a new game or empty string to cancel"
.LC38:
	.string	"Continuing existing game."
.LC39:
	.string	"Automatic moves enabled."
.LC40:
	.string	"Automatic moves disabled."
	.text
	.globl	main
	.type	main, @function
main:
.LFB31:
	.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, 120
	.cfi_offset 3, -24
	mov	DWORD PTR -116[rbp], edi
	mov	QWORD PTR -128[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -68[rbp], -1
	call	new_seed
	mov	DWORD PTR seed[rip], eax
	jmp	.L227
.L238:
	cmp	DWORD PTR -68[rbp], 118
	je	.L228
	cmp	DWORD PTR -68[rbp], 118
	jg	.L229
	cmp	DWORD PTR -68[rbp], 116
	je	.L230
	cmp	DWORD PTR -68[rbp], 116
	jg	.L229
	cmp	DWORD PTR -68[rbp], 110
	je	.L231
	cmp	DWORD PTR -68[rbp], 110
	jg	.L229
	cmp	DWORD PTR -68[rbp], 100
	je	.L232
	cmp	DWORD PTR -68[rbp], 100
	jg	.L229
	cmp	DWORD PTR -68[rbp], 68
	je	.L233
	cmp	DWORD PTR -68[rbp], 70
	je	.L234
	jmp	.L229
.L232:
	mov	DWORD PTR dbgmode[rip], 1
	lea	rdi, .LC23[rip]
	call	puts@PLT
	mov	rax, QWORD PTR stdin[rip]
	mov	rdi, rax
	call	getc@PLT
	jmp	.L227
.L233:
	mov	rax, QWORD PTR qwertzkeys[rip]
	mov	QWORD PTR rowkeys[rip], rax
	jmp	.L227
.L234:
	mov	rax, QWORD PTR azertykeys[rip]
	mov	QWORD PTR rowkeys[rip], rax
	jmp	.L227
.L231:
	mov	rax, QWORD PTR optarg[rip]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR seed[rip], eax
	jmp	.L227
.L230:
	mov	rax, QWORD PTR optarg[rip]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR curtheme[rip], eax
	mov	eax, DWORD PTR curtheme[rip]
	test	eax, eax
	js	.L235
	mov	eax, DWORD PTR curtheme[rip]
	cmp	eax, 1
	jbe	.L227
.L235:
	mov	DWORD PTR curtheme[rip], 0
	jmp	.L227
.L228:
	lea	rdi, .LC24[rip]
	call	puts@PLT
	mov	eax, 0
	jmp	.L287
.L229:
	mov	rax, QWORD PTR -128[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	rax, QWORD PTR stderr[rip]
	lea	rsi, .LC25[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, 0
	jmp	.L287
.L227:
	mov	rcx, QWORD PTR -128[rbp]
	mov	eax, DWORD PTR -116[rbp]
	lea	rdx, .LC26[rip]
	mov	rsi, rcx
	mov	edi, eax
	call	getopt@PLT
	mov	DWORD PTR -68[rbp], eax
	cmp	DWORD PTR -68[rbp], -1
	jne	.L238
	mov	rax, QWORD PTR rowkeys[rip]
	test	rax, rax
	jne	.L239
	mov	rax, QWORD PTR qwertykeys[rip]
	mov	QWORD PTR rowkeys[rip], rax
.L239:
	call	initscr@PLT
	mov	edi, 100
	call	set_escdelay@PLT
	call	cbreak@PLT
	call	noecho@PLT
	call	start_color@PLT
	mov	DWORD PTR -92[rbp], 0
	jmp	.L240
.L241:
	mov	edx, DWORD PTR curtheme[rip]
	mov	eax, DWORD PTR -92[rbp]
	cdqe
	movsx	rdx, edx
	lea	rcx, 0[0+rax*8]
	mov	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, 0[0+rax*8]
	add	rax, rdx
	sal	rax, 2
	lea	rdx, [rcx+rax]
	lea	rax, themes[rip+4]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	movsx	edx, ax
	mov	ecx, DWORD PTR curtheme[rip]
	mov	eax, DWORD PTR -92[rbp]
	cdqe
	movsx	rcx, ecx
	lea	rsi, 0[0+rax*8]
	mov	rax, rcx
	add	rax, rax
	add	rax, rcx
	lea	rcx, 0[0+rax*8]
	add	rax, rcx
	sal	rax, 2
	lea	rcx, [rsi+rax]
	lea	rax, themes[rip]
	add	rax, rcx
	mov	eax, DWORD PTR [rax]
	movsx	ecx, ax
	mov	eax, DWORD PTR -92[rbp]
	add	eax, 1
	cwde
	mov	esi, ecx
	mov	edi, eax
	call	init_pair@PLT
	add	DWORD PTR -92[rbp], 1
.L240:
	cmp	DWORD PTR -92[rbp], 10
	jle	.L241
	mov	eax, DWORD PTR LINES[rip]
	cmp	eax, 23
	jle	.L242
	mov	eax, DWORD PTR COLS[rip]
	cmp	eax, 79
	jg	.L243
.L242:
	call	endwin@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 67
	mov	esi, 1
	lea	rdi, .LC27[rip]
	call	fwrite@PLT
	mov	eax, -1
	jmp	.L287
.L243:
	mov	eax, DWORD PTR COLS[rip]
	sub	eax, 80
	mov	edx, eax
	shr	edx, 31
	add	eax, edx
	sar	eax
	mov	edx, eax
	mov	eax, DWORD PTR LINES[rip]
	sub	eax, 24
	mov	ecx, eax
	shr	ecx, 31
	add	eax, ecx
	sar	eax
	mov	ecx, edx
	mov	edx, eax
	mov	esi, 80
	mov	edi, 23
	call	newwin@PLT
	mov	QWORD PTR screen[rip], rax
	mov	eax, DWORD PTR COLS[rip]
	sub	eax, 80
	mov	edx, eax
	shr	edx, 31
	add	eax, edx
	sar	eax
	mov	edx, eax
	mov	eax, DWORD PTR LINES[rip]
	sub	eax, 24
	mov	ecx, eax
	shr	ecx, 31
	add	eax, ecx
	sar	eax
	add	eax, 23
	mov	ecx, edx
	mov	edx, eax
	mov	esi, 80
	mov	edi, 1
	call	newwin@PLT
	mov	QWORD PTR statusbar[rip], rax
	mov	rax, QWORD PTR screen[rip]
	mov	esi, 1
	mov	rdi, rax
	call	keypad@PLT
	mov	eax, 0
	call	get_win_count
	mov	DWORD PTR wincount[rip], eax
	mov	DWORD PTR -88[rbp], 0
	jmp	.L244
.L245:
	mov	eax, DWORD PTR -88[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, cards[rip]
	mov	DWORD PTR [rdx+rax], -1
	add	DWORD PTR -88[rbp], 1
.L244:
	cmp	DWORD PTR -88[rbp], 39
	jle	.L245
	mov	DWORD PTR -84[rbp], 0
	jmp	.L246
.L247:
	mov	eax, DWORD PTR -84[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	DWORD PTR [rdx+rax], -1
	add	DWORD PTR -84[rbp], 1
.L246:
	cmp	DWORD PTR -84[rbp], 14
	jle	.L247
	mov	eax, DWORD PTR seed[rip]
	mov	edi, eax
	call	init_board
	mov	DWORD PTR -64[rbp], 0
	mov	DWORD PTR -80[rbp], -1
	mov	DWORD PTR -100[rbp], -1
	call	draw_initial_screen
	mov	eax, 0
	call	draw_cards
	mov	BYTE PTR -102[rbp], 1
	mov	DWORD PTR -76[rbp], 0
.L286:
	cmp	DWORD PTR -80[rbp], -1
	jne	.L248
	mov	eax, DWORD PTR -100[rbp]
	cmp	eax, -1
	jne	.L248
	mov	eax, DWORD PTR selcard[rip]
	cmp	eax, -1
	jne	.L248
	jmp	.L249
.L252:
	add	DWORD PTR -76[rbp], 1
	mov	eax, DWORD PTR COLS[rip]
	lea	edx, -2[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, 1
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L251
	mov	eax, DWORD PTR -76[rbp]
	cdq
	shr	edx, 30
	add	eax, edx
	and	eax, 3
	sub	eax, edx
	cdqe
	lea	rdx, animdash[rip]
	movzx	eax, BYTE PTR [rax+rdx]
	movsx	edx, al
	mov	rax, QWORD PTR screen[rip]
	mov	esi, edx
	mov	rdi, rax
	call	waddch@PLT
.L251:
	mov	eax, 0
	call	draw_cards
	cmp	DWORD PTR -76[rbp], 1
	jle	.L249
	mov	edi, 250000
	call	usleep@PLT
.L249:
	movzx	eax, BYTE PTR use_automoves[rip]
	test	al, al
	je	.L248
	call	auto_move
	test	eax, eax
	jne	.L252
.L248:
	mov	DWORD PTR -76[rbp], 0
	mov	eax, DWORD PTR COLS[rip]
	lea	edx, -2[rax]
	mov	rax, QWORD PTR screen[rip]
	mov	esi, 1
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L254
	mov	rax, QWORD PTR screen[rip]
	mov	esi, 32
	mov	rdi, rax
	call	waddch@PLT
.L254:
	mov	eax, 0
	call	draw_cards
	mov	rax, QWORD PTR screen[rip]
	mov	rdi, rax
	call	wgetch@PLT
	mov	DWORD PTR -64[rbp], eax
	mov	eax, DWORD PTR -64[rbp]
	movsx	edx, al
	mov	rax, QWORD PTR rowkeys[rip]
	mov	esi, edx
	mov	rdi, rax
	call	strchr@PLT
	mov	QWORD PTR -32[rbp], rax
	cmp	QWORD PTR -32[rbp], 0
	je	.L255
	mov	rdx, QWORD PTR rowkeys[rip]
	mov	rax, QWORD PTR -32[rbp]
	sub	rax, rdx
	mov	DWORD PTR -52[rbp], eax
	mov	eax, DWORD PTR -52[rbp]
	cmp	eax, DWORD PTR -80[rbp]
	jne	.L256
	mov	eax, DWORD PTR -100[rbp]
	lea	ecx, -1[rax]
	lea	rdx, -100[rbp]
	mov	eax, DWORD PTR -80[rbp]
	mov	esi, ecx
	mov	edi, eax
	call	get_card
	mov	DWORD PTR -44[rbp], eax
	mov	edx, DWORD PTR selcard[rip]
	mov	eax, DWORD PTR -44[rbp]
	mov	esi, edx
	mov	edi, eax
	call	card_can_be_stacked
	test	al, al
	je	.L257
	mov	eax, DWORD PTR -44[rbp]
	mov	DWORD PTR selcard[rip], eax
	jmp	.L258
.L257:
	mov	esi, 11
	lea	rdi, .LC28[rip]
	call	update_status
	call	beep@PLT
	mov	DWORD PTR -80[rbp], -1
	mov	DWORD PTR -100[rbp], -1
	mov	DWORD PTR selcard[rip], -1
	jmp	.L258
.L256:
	lea	rdx, -100[rbp]
	mov	eax, DWORD PTR -52[rbp]
	mov	esi, -1
	mov	edi, eax
	call	get_card
	mov	DWORD PTR -48[rbp], eax
	cmp	DWORD PTR -80[rbp], -1
	je	.L259
	mov	ecx, DWORD PTR selcard[rip]
	mov	edx, DWORD PTR -52[rbp]
	mov	eax, DWORD PTR -80[rbp]
	mov	esi, ecx
	mov	edi, eax
	call	move_card
	mov	BYTE PTR -101[rbp], al
	movzx	eax, BYTE PTR -101[rbp]
	xor	eax, 1
	test	al, al
	je	.L260
	mov	esi, 11
	lea	rdi, .LC29[rip]
	call	update_status
	call	beep@PLT
.L260:
	cmp	BYTE PTR -101[rbp], 0
	je	.L261
	mov	esi, 9
	lea	rdi, .LC20[rip]
	call	update_status
	mov	eax, DWORD PTR selcard[rip]
	mov	edi, eax
	call	stacklen
	mov	ebx, eax
	mov	eax, DWORD PTR -80[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, rows[rip]
	mov	eax, DWORD PTR [rdx+rax]
	mov	edi, eax
	call	stacklen
	mov	ecx, eax
	mov	eax, DWORD PTR -80[rbp]
	mov	edx, ebx
	mov	esi, ecx
	mov	edi, eax
	call	clear_row
.L261:
	mov	DWORD PTR -80[rbp], -1
	mov	DWORD PTR -100[rbp], -1
	mov	DWORD PTR selcard[rip], -1
	jmp	.L258
.L259:
	cmp	DWORD PTR -48[rbp], -1
	jne	.L262
	mov	esi, 11
	lea	rdi, .LC30[rip]
	call	update_status
	call	beep@PLT
	jmp	.L258
.L262:
	mov	eax, DWORD PTR -52[rbp]
	mov	DWORD PTR -80[rbp], eax
	mov	eax, DWORD PTR -48[rbp]
	mov	DWORD PTR selcard[rip], eax
	jmp	.L258
.L255:
	mov	eax, DWORD PTR -64[rbp]
	mov	edi, eax
	call	tolower@PLT
	movsx	edx, al
	mov	rax, QWORD PTR rowkeys[rip]
	mov	esi, edx
	mov	rdi, rax
	call	strchr@PLT
	mov	QWORD PTR -32[rbp], rax
	cmp	QWORD PTR -32[rbp], 0
	je	.L258
	mov	rdx, QWORD PTR rowkeys[rip]
	mov	rax, QWORD PTR -32[rbp]
	sub	rax, rdx
	mov	DWORD PTR -60[rbp], eax
	lea	rdx, -100[rbp]
	mov	eax, DWORD PTR -60[rbp]
	mov	esi, -1
	mov	edi, eax
	call	get_card
	mov	DWORD PTR -72[rbp], eax
	mov	DWORD PTR -56[rbp], -1
	mov	eax, DWORD PTR -100[rbp]
	mov	DWORD PTR -96[rbp], eax
	jmp	.L263
.L265:
	mov	eax, DWORD PTR -56[rbp]
	mov	DWORD PTR -72[rbp], eax
	mov	eax, DWORD PTR -96[rbp]
	mov	DWORD PTR -100[rbp], eax
.L263:
	mov	eax, DWORD PTR -100[rbp]
	test	eax, eax
	jle	.L264
	mov	eax, DWORD PTR -96[rbp]
	lea	ecx, -1[rax]
	lea	rdx, -96[rbp]
	mov	eax, DWORD PTR -60[rbp]
	mov	esi, ecx
	mov	edi, eax
	call	get_card
	mov	DWORD PTR -56[rbp], eax
	cmp	DWORD PTR -56[rbp], -1
	je	.L264
	mov	edx, DWORD PTR -72[rbp]
	mov	eax, DWORD PTR -56[rbp]
	mov	esi, edx
	mov	edi, eax
	call	card_can_be_stacked
	test	al, al
	jne	.L265
.L264:
	mov	eax, DWORD PTR -60[rbp]
	mov	DWORD PTR -80[rbp], eax
	mov	eax, DWORD PTR -72[rbp]
	mov	DWORD PTR selcard[rip], eax
.L258:
	cmp	DWORD PTR -64[rbp], 51
	jle	.L266
	cmp	DWORD PTR -64[rbp], 54
	jg	.L266
	mov	eax, 0
	call	exposed_dragons
	mov	DWORD PTR -40[rbp], eax
	mov	eax, DWORD PTR -64[rbp]
	sub	eax, 52
	mov	DWORD PTR -36[rbp], eax
	mov	eax, DWORD PTR -36[rbp]
	mov	edx, DWORD PTR -40[rbp]
	mov	ecx, eax
	sar	edx, cl
	mov	eax, edx
	and	eax, 1
	test	eax, eax
	je	.L267
	mov	eax, DWORD PTR -36[rbp]
	mov	edi, eax
	call	remove_exposed_dragons
	mov	esi, 9
	lea	rdi, .LC31[rip]
	call	update_status
	jmp	.L268
.L267:
	mov	esi, 11
	lea	rdi, .LC32[rip]
	call	update_status
.L268:
	mov	DWORD PTR -80[rbp], -1
	mov	DWORD PTR -100[rbp], -1
	mov	DWORD PTR selcard[rip], -1
.L266:
	cmp	DWORD PTR -64[rbp], 32
	jne	.L269
	mov	esi, 9
	lea	rdi, .LC20[rip]
	call	update_status
	mov	DWORD PTR -80[rbp], -1
	mov	DWORD PTR -100[rbp], -1
	mov	DWORD PTR selcard[rip], -1
.L269:
	cmp	DWORD PTR -64[rbp], 110
	jne	.L270
	mov	eax, DWORD PTR dbgmode[rip]
	cmp	eax, 1
	jne	.L270
	movzx	eax, BYTE PTR showcardnum[rip]
	movzx	eax, al
	test	eax, eax
	setne	al
	xor	eax, 1
	movzx	eax, al
	and	eax, 1
	mov	BYTE PTR showcardnum[rip], al
.L270:
	cmp	DWORD PTR -64[rbp], 81
	je	.L271
	cmp	DWORD PTR -64[rbp], 27
	jne	.L272
.L271:
	mov	esi, 10
	lea	rdi, .LC33[rip]
	call	yes_or_no
	test	al, al
	je	.L272
	mov	BYTE PTR -102[rbp], 0
.L272:
	mov	rdx, QWORD PTR rowkeys[rip]
	mov	rax, QWORD PTR qwertykeys[rip]
	cmp	rdx, rax
	jne	.L273
	cmp	DWORD PTR -64[rbp], 122
	je	.L274
.L273:
	cmp	DWORD PTR -64[rbp], 267
	jne	.L275
.L274:
	mov	esi, 10
	lea	rdi, .LC34[rip]
	call	yes_or_no
	test	al, al
	je	.L275
	mov	DWORD PTR -80[rbp], -1
	mov	DWORD PTR -100[rbp], -1
	mov	DWORD PTR selcard[rip], -1
	mov	eax, DWORD PTR seed[rip]
	mov	edi, eax
	call	init_board
	call	draw_initial_screen
	movzx	eax, BYTE PTR won_game[rip]
	test	al, al
	je	.L275
	mov	esi, 10
	lea	rdi, .LC35[rip]
	call	update_status
.L275:
	cmp	DWORD PTR -64[rbp], 110
	je	.L276
	cmp	DWORD PTR -64[rbp], 266
	jne	.L277
.L276:
	mov	esi, 10
	lea	rdi, .LC36[rip]
	call	yes_or_no
	test	al, al
	je	.L277
	mov	BYTE PTR won_game[rip], 0
	call	new_seed
	mov	DWORD PTR seed[rip], eax
	mov	DWORD PTR -80[rbp], -1
	mov	DWORD PTR -100[rbp], -1
	mov	DWORD PTR selcard[rip], -1
	mov	eax, DWORD PTR seed[rip]
	mov	edi, eax
	call	init_board
	call	draw_initial_screen
.L277:
	cmp	DWORD PTR -64[rbp], 78
	je	.L278
	cmp	DWORD PTR -64[rbp], 268
	jne	.L279
.L278:
	lea	rdx, seed[rip]
	mov	esi, 10
	lea	rdi, .LC37[rip]
	call	ask_integer
	test	al, al
	je	.L280
	mov	DWORD PTR -80[rbp], -1
	mov	DWORD PTR -100[rbp], -1
	mov	DWORD PTR selcard[rip], -1
	mov	eax, DWORD PTR seed[rip]
	mov	edi, eax
	call	init_board
	call	draw_initial_screen
	jmp	.L279
.L280:
	mov	esi, 9
	lea	rdi, .LC38[rip]
	call	update_status
.L279:
	mov	rdx, QWORD PTR rowkeys[rip]
	mov	rax, QWORD PTR qwertykeys[rip]
	cmp	rdx, rax
	jne	.L281
	cmp	DWORD PTR -64[rbp], 97
	je	.L282
	cmp	DWORD PTR -64[rbp], 65
	je	.L282
.L281:
	cmp	DWORD PTR -64[rbp], 269
	jne	.L283
.L282:
	movzx	eax, BYTE PTR use_automoves[rip]
	movzx	eax, al
	test	eax, eax
	setne	al
	xor	eax, 1
	movzx	eax, al
	and	eax, 1
	mov	BYTE PTR use_automoves[rip], al
	movzx	eax, BYTE PTR use_automoves[rip]
	test	al, al
	je	.L284
	lea	rax, .LC39[rip]
	jmp	.L285
.L284:
	lea	rax, .LC40[rip]
.L285:
	mov	esi, 9
	mov	rdi, rax
	call	update_status
.L283:
	cmp	BYTE PTR -102[rbp], 0
	jne	.L286
	call	endwin@PLT
	mov	eax, 0
.L287:
	mov	rbx, QWORD PTR -24[rbp]
	sub	rbx, QWORD PTR fs:40
	je	.L288
	call	__stack_chk_fail@PLT
.L288:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE31:
	.size	main, .-main
	.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	"783908.c"
	.text
	.global	animdash
	.data
	.align	2
	.type	animdash, %object
	.size	animdash, 4
animdash:
	.ascii	"-/|\\"
	.global	won_game
	.bss
	.type	won_game, %object
	.size	won_game, 1
won_game:
	.space	1
	.global	wincount
	.align	2
	.type	wincount, %object
	.size	wincount, 4
wincount:
	.space	4
	.global	curtheme
	.align	2
	.type	curtheme, %object
	.size	curtheme, 4
curtheme:
	.space	4
	.global	seed
	.align	2
	.type	seed, %object
	.size	seed, 4
seed:
	.space	4
	.global	use_automoves
	.data
	.type	use_automoves, %object
	.size	use_automoves, 1
use_automoves:
	.byte	1
	.global	themes
	.align	2
	.type	themes, %object
	.size	themes, 216
themes:
	.word	7
	.word	0
	.word	7
	.word	0
	.word	7
	.word	0
	.word	1
	.word	0
	.word	2
	.word	0
	.word	4
	.word	0
	.word	5
	.word	0
	.word	5
	.word	0
	.word	7
	.word	4
	.word	7
	.word	3
	.word	7
	.word	1
	.space	8
	.word	2097152
	.word	0
	.word	262144
	.word	7
	.word	6
	.word	0
	.word	6
	.word	0
	.word	7
	.word	1
	.word	7
	.word	2
	.word	7
	.word	4
	.word	7
	.word	5
	.word	7
	.word	0
	.word	6
	.word	7
	.word	4
	.word	7
	.word	3
	.word	7
	.word	1
	.space	8
	.word	0
	.word	2097152
	.word	524288
	.global	rows
	.align	2
	.type	rows, %object
	.size	rows, 60
rows:
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.word	-1
	.global	selcard
	.align	2
	.type	selcard, %object
	.size	selcard, 4
selcard:
	.word	-1
	.global	dbgmode
	.bss
	.align	2
	.type	dbgmode, %object
	.size	dbgmode, 4
dbgmode:
	.space	4
	.global	showcardnum
	.type	showcardnum, %object
	.size	showcardnum, 1
showcardnum:
	.space	1
	.global	cardvals
	.section	.rodata
	.align	2
.LC0:
	.ascii	"123456789****@\000"
	.data
	.align	2
	.type	cardvals, %object
	.size	cardvals, 4
cardvals:
	.word	.LC0
	.global	cardsuits
	.section	.rodata
	.align	2
.LC1:
	.ascii	"OIX\000"
	.data
	.align	2
	.type	cardsuits, %object
	.size	cardsuits, 4
cardsuits:
	.word	.LC1
	.global	rowkeys
	.bss
	.align	2
	.type	rowkeys, %object
	.size	rowkeys, 4
rowkeys:
	.space	4
	.global	qwertykeys
	.section	.rodata
	.align	2
.LC2:
	.ascii	"wertyuio1237890\000"
	.data
	.align	2
	.type	qwertykeys, %object
	.size	qwertykeys, 4
qwertykeys:
	.word	.LC2
	.global	qwertzkeys
	.section	.rodata
	.align	2
.LC3:
	.ascii	"wertzuio1237890\000"
	.data
	.align	2
	.type	qwertzkeys, %object
	.size	qwertzkeys, 4
qwertzkeys:
	.word	.LC3
	.global	azertykeys
	.section	.rodata
	.align	2
.LC4:
	.ascii	"zertyuio1237890\000"
	.data
	.align	2
	.type	azertykeys, %object
	.size	azertykeys, 4
azertykeys:
	.word	.LC4
	.section	.rodata
	.align	2
.LC5:
	.ascii	"HOME\000"
	.align	2
.LC6:
	.ascii	"/.szsol\000"
	.align	2
.LC7:
	.ascii	"/wincount\000"
	.align	2
.LC8:
	.ascii	"wb\000"
	.align	2
.LC9:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	set_win_count
	.syntax unified
	.arm
	.fpu softvfp
	.type	set_win_count, %function
set_win_count:
	@ args = 0, pretend = 0, frame = 4216
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #4160
	sub	sp, sp, #60
	sub	r3, fp, #4096
	sub	r3, r3, #12
	str	r0, [r3, #-116]
	ldr	r3, .L10
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	ldr	r0, .L10+4
	bl	getenv
	str	r0, [r4, #-108]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-108]
	cmp	r3, #0
	bne	.L2
	mov	r3, #0
	b	.L8
.L2:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r2, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, [r2, #-108]
	mov	r0, r3
	bl	strcpy
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	mov	r2, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	add	r3, r3, r2
	ldr	r2, .L10+8
	mov	r0, r3
	mov	r1, r2
	mov	r3, #8
	mov	r2, r3
	bl	memcpy
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r2, fp, #4160
	sub	r2, r2, #12
	sub	r2, r2, #32
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r1, r2
	mov	r0, r3
	bl	stat
	str	r0, [r4, #-104]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-104]
	cmn	r3, #1
	bne	.L4
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #2
	bne	.L5
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, .L10+12
	mov	r0, r3
	bl	mkdir
	str	r0, [r4, #-104]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-104]
	cmn	r3, #1
	bne	.L5
	mov	r3, #0
	b	.L8
.L4:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-80]
	and	r3, r3, #61440
	cmp	r3, #16384
	beq	.L5
	mov	r3, #0
	b	.L8
.L5:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	mov	r2, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	add	r3, r3, r2
	ldr	r2, .L10+16
	mov	r0, r3
	mov	r1, r2
	mov	r3, #10
	mov	r2, r3
	bl	memcpy
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, .L10+20
	mov	r0, r3
	bl	fopen
	str	r0, [r4, #-100]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-100]
	cmp	r3, #0
	bne	.L6
	mov	r3, #0
	b	.L8
.L6:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r0, fp, #4160
	sub	r0, r0, #12
	sub	r0, r0, #52
	ldr	r3, [r3, #-100]
	mov	r2, #1
	mov	r1, #4
	bl	fwrite
	mov	r3, r0
	sub	r2, fp, #4096
	sub	r2, r2, #12
	str	r3, [r2, #-104]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r0, [r3, #-100]
	bl	fclose
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-104]
	cmp	r3, #0
	bne	.L7
	mov	r3, #0
	b	.L8
.L7:
	ldr	r3, .L10+24
	ldr	r3, [r3]
.L8:
	ldr	r2, .L10
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L9
	bl	__stack_chk_fail
.L9:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L11:
	.align	2
.L10:
	.word	.LC9
	.word	.LC5
	.word	.LC6
	.word	493
	.word	.LC7
	.word	.LC8
	.word	wincount
	.size	set_win_count, .-set_win_count
	.section	.rodata
	.align	2
.LC10:
	.ascii	"/.szsol/wincount\000"
	.align	2
.LC11:
	.ascii	"rb\000"
	.align	2
.LC12:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	get_win_count
	.syntax unified
	.arm
	.fpu softvfp
	.type	get_win_count, %function
get_win_count:
	@ args = 0, pretend = 0, frame = 4120
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #4096
	sub	sp, sp, #28
	ldr	r3, .L19
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	ldr	r0, .L19+4
	bl	getenv
	str	r0, [r4, #-16]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-16]
	cmp	r3, #0
	bne	.L13
	mov	r3, #0
	b	.L17
.L13:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r2, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, [r2, #-16]
	mov	r0, r3
	bl	strcpy
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	mov	r2, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	add	r3, r3, r2
	ldr	r2, .L19+8
	mov	r0, r3
	mov	r1, r2
	mov	r3, #17
	mov	r2, r3
	bl	memcpy
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r3, r3, #4
	ldr	r1, .L19+12
	mov	r0, r3
	bl	fopen
	str	r0, [r4, #-12]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-12]
	cmp	r3, #0
	bne	.L15
	mov	r3, #0
	b	.L17
.L15:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #-20]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	sub	r0, fp, #4096
	sub	r0, r0, #12
	sub	r0, r0, #20
	ldr	r3, [r3, #-12]
	mov	r2, #1
	mov	r1, #4
	bl	fread
	mov	r3, r0
	sub	r2, fp, #4096
	sub	r2, r2, #12
	str	r3, [r2, #-8]
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r0, [r3, #-12]
	bl	fclose
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-8]
	cmp	r3, #0
	bne	.L16
	mov	r3, #0
	b	.L17
.L16:
	sub	r3, fp, #4096
	sub	r3, r3, #12
	ldr	r3, [r3, #-20]
.L17:
	ldr	r2, .L19
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L18
	bl	__stack_chk_fail
.L18:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L20:
	.align	2
.L19:
	.word	.LC12
	.word	.LC5
	.word	.LC10
	.word	.LC11
	.size	get_win_count, .-get_win_count
	.global	screen
	.bss
	.align	2
	.type	screen, %object
	.size	screen, 4
screen:
	.space	4
	.global	statusbar
	.align	2
	.type	statusbar, %object
	.size	statusbar, 4
statusbar:
	.space	4
	.comm	cards,160,4
	.text
	.align	2
	.global	lastcard
	.syntax unified
	.arm
	.fpu softvfp
	.type	lastcard, %function
lastcard:
	@ 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]
	ldr	r2, .L26
	ldr	r3, [fp, #-16]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-8]
	b	.L22
.L24:
	ldr	r2, .L26+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-8]
.L22:
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	blt	.L23
	ldr	r2, .L26+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	cmn	r3, #1
	bne	.L24
.L23:
	ldr	r3, [fp, #-8]
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L27:
	.align	2
.L26:
	.word	rows
	.word	cards
	.size	lastcard, .-lastcard
	.align	2
	.global	add_to_row
	.syntax unified
	.arm
	.fpu softvfp
	.type	add_to_row, %function
add_to_row:
	@ 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]
	str	r1, [fp, #-20]
	ldr	r0, [fp, #-16]
	bl	lastcard
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	bne	.L29
	ldr	r1, .L32
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	str	r2, [r1, r3, lsl #2]
	b	.L30
.L29:
	ldr	r1, .L32+4
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	str	r2, [r1, r3, lsl #2]
.L30:
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L33:
	.align	2
.L32:
	.word	rows
	.word	cards
	.size	add_to_row, .-add_to_row
	.align	2
	.global	card_can_be_stacked
	.syntax unified
	.arm
	.fpu softvfp
	.type	card_can_be_stacked, %function
card_can_be_stacked:
	@ 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]
	cmn	r3, #1
	bne	.L35
	mov	r3, #1
	b	.L36
.L35:
	ldr	r3, [fp, #-8]
	cmn	r3, #2
	bne	.L37
	mov	r3, #0
	b	.L36
.L37:
	ldr	r3, [fp, #-12]
	cmn	r3, #1
	bne	.L38
	mov	r3, #0
	b	.L36
.L38:
	ldr	r3, [fp, #-12]
	cmn	r3, #2
	bne	.L39
	mov	r3, #0
	b	.L36
.L39:
	ldr	r3, [fp, #-8]
	cmp	r3, #26
	ble	.L40
	mov	r3, #0
	b	.L36
.L40:
	ldr	r3, [fp, #-12]
	cmp	r3, #26
	ble	.L41
	mov	r3, #0
	b	.L36
.L41:
	ldr	r2, [fp, #-8]
	ldr	r3, .L43
	smull	r0, r1, r3, r2
	asr	r3, r2, #31
	sub	r1, r1, r3
	mov	r3, r1
	lsl	r3, r3, #1
	add	r3, r3, r1
	sub	r1, r2, r3
	ldr	r0, [fp, #-12]
	ldr	r3, .L43
	smull	ip, r2, r3, r0
	asr	r3, r0, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	sub	r2, r0, r3
	cmp	r1, r2
	beq	.L42
	ldr	r3, [fp, #-8]
	ldr	r2, .L43
	smull	r1, r2, r3, r2
	asr	r3, r3, #31
	sub	r2, r2, r3
	ldr	r3, [fp, #-12]
	ldr	r1, .L43
	smull	r0, r1, r3, r1
	asr	r3, r3, #31
	sub	r3, r1, r3
	add	r3, r3, #1
	cmp	r2, r3
	bne	.L42
	mov	r3, #1
	b	.L36
.L42:
	mov	r3, #0
.L36:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L44:
	.align	2
.L43:
	.word	1431655766
	.size	card_can_be_stacked, .-card_can_be_stacked
	.align	2
	.global	find_parent
	.syntax unified
	.arm
	.fpu softvfp
	.type	find_parent, %function
find_parent:
	@ 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, #-12]
	b	.L46
.L54:
	ldr	r2, .L56
	ldr	r3, [fp, #-12]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-8]
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-16]
	cmp	r2, r3
	bne	.L47
	mvn	r3, #0
	b	.L48
.L47:
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	beq	.L55
	b	.L51
.L53:
	ldr	r2, .L56+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r2, [fp, #-16]
	cmp	r2, r3
	bne	.L52
	ldr	r3, [fp, #-8]
	b	.L48
.L52:
	ldr	r2, .L56+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-8]
.L51:
	ldr	r2, .L56+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #0
	bge	.L53
	b	.L50
.L55:
	nop
.L50:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L46:
	ldr	r3, [fp, #-12]
	cmp	r3, #7
	ble	.L54
	mvn	r3, #0
.L48:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L57:
	.align	2
.L56:
	.word	rows
	.word	cards
	.size	find_parent, .-find_parent
	.align	2
	.global	stacklen
	.syntax unified
	.arm
	.fpu softvfp
	.type	stacklen, %function
stacklen:
	@ 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, #-12]
	ldr	r3, [fp, #-16]
	str	r3, [fp, #-8]
	b	.L59
.L60:
	ldr	r2, .L62
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L59:
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bge	.L60
	ldr	r3, [fp, #-12]
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L63:
	.align	2
.L62:
	.word	cards
	.size	stacklen, .-stacklen
	.align	2
	.global	remove_card
	.syntax unified
	.arm
	.fpu softvfp
	.type	remove_card, %function
remove_card:
	@ 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]
	cmp	r3, #0
	blt	.L65
	ldr	r3, [fp, #-16]
	cmp	r3, #39
	ble	.L66
.L65:
	mov	r3, #0
	b	.L67
.L66:
	ldr	r0, [fp, #-16]
	bl	find_parent
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	beq	.L68
	ldr	r2, .L72
	ldr	r3, [fp, #-8]
	mvn	r1, #0
	str	r1, [r2, r3, lsl #2]
.L68:
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L69
.L71:
	ldr	r2, .L72+4
	ldr	r3, [fp, #-12]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r2, [fp, #-16]
	cmp	r2, r3
	bne	.L70
	ldr	r2, .L72+4
	ldr	r3, [fp, #-12]
	mvn	r1, #0
	str	r1, [r2, r3, lsl #2]
.L70:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L69:
	ldr	r3, [fp, #-12]
	cmp	r3, #10
	ble	.L71
	mov	r3, #1
.L67:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L73:
	.align	2
.L72:
	.word	cards
	.word	rows
	.size	remove_card, .-remove_card
	.align	2
	.global	move_card
	.syntax unified
	.arm
	.fpu softvfp
	.type	move_card, %function
move_card:
	@ 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, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	ldr	r3, [fp, #-16]
	cmn	r3, #1
	bne	.L75
	mov	r3, #0
	b	.L76
.L75:
	ldr	r3, [fp, #-16]
	cmp	r3, #10
	ble	.L77
	mov	r3, #0
	b	.L76
.L77:
	ldr	r3, [fp, #-20]
	cmp	r3, #0
	bge	.L78
	mov	r3, #0
	b	.L76
.L78:
	ldr	r3, [fp, #-24]
	cmp	r3, #7
	ble	.L79
	ldr	r3, [fp, #-24]
	cmp	r3, #10
	bgt	.L79
	ldr	r2, .L90
	ldr	r3, [fp, #-24]
	ldr	r3, [r2, r3, lsl #2]
	cmn	r3, #1
	beq	.L79
	mov	r3, #0
	b	.L76
.L79:
	ldr	r3, [fp, #-24]
	cmp	r3, #7
	ble	.L80
	ldr	r2, .L90+4
	ldr	r3, [fp, #-20]
	ldr	r3, [r2, r3, lsl #2]
	cmn	r3, #1
	beq	.L80
	mov	r3, #0
	b	.L76
.L80:
	ldr	r3, [fp, #-24]
	cmp	r3, #11
	bne	.L81
	ldr	r3, [fp, #-20]
	cmp	r3, #39
	beq	.L81
	mov	r3, #0
	b	.L76
.L81:
	ldr	r3, [fp, #-24]
	cmp	r3, #7
	bgt	.L82
	ldr	r0, [fp, #-24]
	bl	lastcard
	mov	r3, r0
	ldr	r1, [fp, #-20]
	mov	r0, r3
	bl	card_can_be_stacked
	mov	r3, r0
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L82
	mov	r3, #0
	b	.L76
.L82:
	ldr	r3, [fp, #-24]
	cmp	r3, #11
	ble	.L83
	ldr	r3, [fp, #-20]
	cmp	r3, #26
	ble	.L83
	mov	r3, #0
	b	.L76
.L83:
	ldr	r3, [fp, #-24]
	cmp	r3, #11
	ble	.L84
	ldr	r2, .L90
	ldr	r3, [fp, #-24]
	ldr	r3, [r2, r3, lsl #2]
	cmn	r3, #1
	bne	.L84
	ldr	r3, [fp, #-20]
	cmp	r3, #2
	ble	.L84
	mov	r3, #0
	b	.L76
.L84:
	ldr	r3, [fp, #-24]
	cmp	r3, #11
	ble	.L85
	ldr	r2, .L90
	ldr	r3, [fp, #-24]
	ldr	r3, [r2, r3, lsl #2]
	cmn	r3, #1
	beq	.L85
	ldr	r2, .L90
	ldr	r3, [fp, #-24]
	ldr	r2, [r2, r3, lsl #2]
	ldr	r3, [fp, #-20]
	sub	r3, r3, #3
	cmp	r2, r3
	beq	.L85
	mov	r3, #0
	b	.L76
.L85:
	ldr	r0, [fp, #-20]
	bl	find_parent
	str	r0, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmn	r3, #1
	beq	.L86
	ldr	r2, .L90+4
	ldr	r3, [fp, #-12]
	mvn	r1, #0
	str	r1, [r2, r3, lsl #2]
.L86:
	ldr	r2, .L90
	ldr	r3, [fp, #-16]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r2, [fp, #-20]
	cmp	r2, r3
	bne	.L87
	ldr	r2, .L90
	ldr	r3, [fp, #-16]
	mvn	r1, #0
	str	r1, [r2, r3, lsl #2]
.L87:
	ldr	r0, [fp, #-24]
	bl	lastcard
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-24]
	cmp	r3, #11
	bgt	.L88
	ldr	r3, [fp, #-8]
	cmn	r3, #1
	bne	.L89
.L88:
	ldr	r1, .L90
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-20]
	str	r2, [r1, r3, lsl #2]
	mov	r3, #1
	b	.L76
.L89:
	ldr	r1, .L90+4
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-20]
	str	r2, [r1, r3, lsl #2]
	mov	r3, #1
.L76:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L91:
	.align	2
.L90:
	.word	rows
	.word	cards
	.size	move_card, .-move_card
	.align	2
	.global	clear_row
	.syntax unified
	.arm
	.fpu softvfp
	.type	clear_row, %function
clear_row:
	@ 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, #-16]
	mov	r3, #0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-24]
	cmp	r3, #7
	bgt	.L93
	ldr	r2, [fp, #-24]
	mov	r3, r2
	lsl	r3, r3, #3
	add	r3, r3, r2
	add	r3, r3, #6
	str	r3, [fp, #-16]
	mov	r3, #5
	str	r3, [fp, #-12]
.L93:
	ldr	r3, [fp, #-24]
	cmp	r3, #7
	ble	.L94
	ldr	r3, [fp, #-24]
	cmp	r3, #10
	bgt	.L94
	ldr	r3, [fp, #-24]
	sub	r2, r3, #8
	mov	r3, r2
	lsl	r3, r3, #3
	sub	r3, r3, r2
	add	r3, r3, #2
	str	r3, [fp, #-16]
	mov	r3, #2
	str	r3, [fp, #-12]
.L94:
	ldr	r3, [fp, #-24]
	cmp	r3, #11
	bne	.L95
	mov	r3, #38
	str	r3, [fp, #-16]
	mov	r3, #2
	str	r3, [fp, #-12]
.L95:
	ldr	r3, [fp, #-24]
	cmp	r3, #11
	ble	.L96
	ldr	r3, [fp, #-24]
	sub	r2, r3, #12
	mov	r3, r2
	lsl	r3, r3, #3
	sub	r3, r3, r2
	add	r3, r3, #58
	str	r3, [fp, #-16]
	mov	r3, #2
	str	r3, [fp, #-12]
.L96:
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L97
.L100:
	ldr	r3, .L102
	ldr	r0, [r3]
	ldr	r2, [fp, #-12]
	ldr	r3, [fp, #-28]
	add	r2, r2, r3
	ldr	r3, [fp, #-8]
	add	r3, r2, r3
	ldr	r2, [fp, #-16]
	mov	r1, r3
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L99
	ldr	r3, .L102
	ldr	r3, [r3]
	mov	r2, #5
	mov	r1, #32
	mov	r0, r3
	bl	whline
.L99:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L97:
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-32]
	cmp	r2, r3
	blt	.L100
	ldr	r3, .L102
	ldr	r3, [r3]
	mov	r0, r3
	bl	wrefresh
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L103:
	.align	2
.L102:
	.word	screen
	.size	clear_row, .-clear_row
	.section	.rodata
	.align	2
.LC13:
	.ascii	"[   ]\000"
	.align	2
.LC14:
	.ascii	"%3d\000"
	.align	2
.LC15:
	.ascii	"-*-\000"
	.align	2
.LC16:
	.ascii	"%c%c\000"
	.align	2
.LC17:
	.ascii	"-%c-\000"
	.align	2
.LC18:
	.ascii	" @ \000"
	.text
	.align	2
	.global	draw_card
	.syntax unified
	.arm
	.fpu softvfp
	.type	draw_card, %function
draw_card:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #32
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	ldr	r3, .L127
	ldr	r3, [r3]
	cmn	r3, #1
	beq	.L105
	ldr	r3, .L127
	ldr	r3, [r3]
	ldr	r2, [fp, #-24]
	cmp	r2, r3
	bne	.L105
	mov	r3, #1
	b	.L106
.L105:
	mov	r3, #0
.L106:
	strb	r3, [fp, #-17]
	ldrb	r3, [fp, #-17]
	and	r3, r3, #1
	strb	r3, [fp, #-17]
	ldr	r3, .L127+4
	ldr	r2, [r3]
	ldr	r1, .L127+8
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, r3, #96
	ldr	r3, [r3]
	mov	r0, r3
	ldr	r3, [fp, #-24]
	cmp	r3, #39
	beq	.L107
	ldr	r3, [fp, #-24]
	cmn	r3, #2
	beq	.L107
	ldr	r1, [fp, #-24]
	ldr	r3, .L127+12
	smull	ip, r2, r3, r1
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	sub	r2, r1, r3
	add	r3, r2, #4
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	b	.L108
.L107:
	mov	r3, #1792
.L108:
	orr	r3, r3, r0
	str	r3, [fp, #-16]
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L109
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldr	r3, .L127+4
	ldr	r2, [r3]
	ldr	r1, .L127+8
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, r3, #104
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	orr	r3, r2, r3
	mov	r2, #0
	mov	r1, r3
	bl	wattr_on
	b	.L110
.L109:
	ldr	r3, [fp, #-24]
	cmn	r3, #1
	bne	.L111
	ldr	r3, .L127+16
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_on
	b	.L110
.L111:
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldr	r3, .L127+4
	ldr	r2, [r3]
	ldr	r1, .L127+8
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, r3, #100
	ldr	r3, [r3]
	orr	r3, r3, #768
	mov	r2, #0
	mov	r1, r3
	bl	wattr_on
.L110:
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldr	r3, .L127+20
	ldr	r2, [fp, #-28]
	ldr	r1, [fp, #-32]
	bl	mvwprintw
	ldr	r3, [fp, #-24]
	cmn	r3, #1
	bne	.L112
	ldr	r3, .L127+16
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_off
	b	.L113
.L112:
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L114
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldr	r3, .L127+4
	ldr	r2, [r3]
	ldr	r1, .L127+8
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, r3, #104
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	orr	r3, r2, r3
	mov	r2, #0
	mov	r1, r3
	bl	wattr_off
	b	.L113
.L114:
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldr	r3, .L127+4
	ldr	r2, [r3]
	ldr	r1, .L127+8
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, r3, #100
	ldr	r3, [r3]
	orr	r3, r3, #768
	mov	r2, #0
	mov	r1, r3
	bl	wattr_off
.L113:
	ldr	r3, [fp, #-24]
	cmn	r3, #1
	beq	.L126
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L117
	ldr	r3, .L127+4
	ldr	r2, [r3]
	ldr	r1, .L127+8
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, r3, #104
	ldr	r3, [r3]
	b	.L118
.L117:
	mov	r3, #0
.L118:
	ldr	r2, [fp, #-16]
	orr	r3, r3, r2
	mov	r2, #0
	mov	r1, r3
	bl	wattr_on
	ldr	r3, .L127+24
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L119
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldr	r3, [fp, #-28]
	add	r2, r3, #1
	ldr	r3, [fp, #-24]
	str	r3, [sp]
	ldr	r3, .L127+28
	ldr	r1, [fp, #-32]
	bl	mvwprintw
	b	.L120
.L119:
	ldr	r3, [fp, #-24]
	cmn	r3, #2
	bne	.L121
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldr	r3, [fp, #-28]
	add	r2, r3, #1
	ldr	r3, .L127+32
	ldr	r1, [fp, #-32]
	bl	mvwprintw
	b	.L120
.L121:
	ldr	r3, [fp, #-24]
	cmp	r3, #26
	bgt	.L122
	ldr	r3, .L127+16
	ldr	ip, [r3]
	ldr	r3, [fp, #-28]
	add	lr, r3, #1
	ldr	r3, .L127+36
	ldr	r2, [r3]
	ldr	r3, [fp, #-24]
	ldr	r1, .L127+12
	smull	r0, r1, r3, r1
	asr	r3, r3, #31
	sub	r3, r1, r3
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r4, r3
	ldr	r3, .L127+40
	ldr	r0, [r3]
	ldr	r2, [fp, #-24]
	ldr	r3, .L127+12
	smull	r5, r1, r3, r2
	asr	r3, r2, #31
	sub	r1, r1, r3
	mov	r3, r1
	lsl	r3, r3, #1
	add	r3, r3, r1
	sub	r1, r2, r3
	mov	r3, r1
	add	r3, r0, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	str	r3, [sp, #4]
	str	r4, [sp]
	ldr	r3, .L127+44
	mov	r2, lr
	ldr	r1, [fp, #-32]
	mov	r0, ip
	bl	mvwprintw
	b	.L120
.L122:
	ldr	r3, [fp, #-24]
	cmp	r3, #38
	bgt	.L123
	ldr	r3, .L127+16
	ldr	ip, [r3]
	ldr	r3, [fp, #-28]
	add	lr, r3, #1
	ldr	r3, .L127+40
	ldr	r0, [r3]
	ldr	r2, [fp, #-24]
	ldr	r3, .L127+12
	smull	r4, r1, r3, r2
	asr	r3, r2, #31
	sub	r1, r1, r3
	mov	r3, r1
	lsl	r3, r3, #1
	add	r3, r3, r1
	sub	r1, r2, r3
	mov	r3, r1
	add	r3, r0, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	str	r3, [sp]
	ldr	r3, .L127+48
	mov	r2, lr
	ldr	r1, [fp, #-32]
	mov	r0, ip
	bl	mvwprintw
	b	.L120
.L123:
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldr	r3, [fp, #-28]
	add	r2, r3, #1
	ldr	r3, .L127+52
	ldr	r1, [fp, #-32]
	bl	mvwprintw
.L120:
	ldr	r3, .L127+16
	ldr	r0, [r3]
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L124
	ldr	r3, .L127+4
	ldr	r2, [r3]
	ldr	r1, .L127+8
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, r3, #104
	ldr	r3, [r3]
	b	.L125
.L124:
	mov	r3, #0
.L125:
	ldr	r2, [fp, #-16]
	orr	r3, r3, r2
	mov	r2, #0
	mov	r1, r3
	bl	wattr_off
	b	.L104
.L126:
	nop
.L104:
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L128:
	.align	2
.L127:
	.word	selcard
	.word	curtheme
	.word	themes
	.word	1431655766
	.word	screen
	.word	.LC13
	.word	showcardnum
	.word	.LC14
	.word	.LC15
	.word	cardvals
	.word	cardsuits
	.word	.LC16
	.word	.LC17
	.word	.LC18
	.size	draw_card, .-draw_card
	.align	2
	.global	find_freecell
	.syntax unified
	.arm
	.fpu softvfp
	.type	find_freecell, %function
find_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
	mov	r3, #8
	str	r3, [fp, #-8]
	b	.L130
.L133:
	ldr	r2, .L134
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	cmn	r3, #1
	bne	.L131
	ldr	r3, [fp, #-8]
	b	.L132
.L131:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L130:
	ldr	r3, [fp, #-8]
	cmp	r3, #10
	ble	.L133
	mvn	r3, #0
.L132:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L135:
	.align	2
.L134:
	.word	rows
	.size	find_freecell, .-find_freecell
	.align	2
	.global	find_foundation
	.syntax unified
	.arm
	.fpu softvfp
	.type	find_foundation, %function
find_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]
	mov	r3, #12
	str	r3, [fp, #-8]
	b	.L137
.L140:
	ldr	r2, .L141
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	ldr	r2, [fp, #-16]
	cmp	r2, r3
	bne	.L138
	ldr	r3, [fp, #-8]
	b	.L139
.L138:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L137:
	ldr	r3, [fp, #-8]
	cmp	r3, #14
	ble	.L140
	mvn	r3, #0
.L139:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L142:
	.align	2
.L141:
	.word	rows
	.size	find_foundation, .-find_foundation
	.section	.rodata
	.align	2
.LC19:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	exposed_dragons
	.syntax unified
	.arm
	.fpu softvfp
	.type	exposed_dragons, %function
exposed_dragons:
	@ args = 0, pretend = 0, frame = 40
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #40
	ldr	r3, .L153
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	sub	r3, fp, #20
	mov	r2, #12
	mov	r1, #0
	mov	r0, r3
	bl	memset
	sub	r3, fp, #24
	mov	r2, #3
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r3, #0
	str	r3, [fp, #-40]
	b	.L144
.L146:
	ldr	r0, [fp, #-40]
	bl	lastcard
	str	r0, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #26
	ble	.L145
	ldr	r3, [fp, #-28]
	cmp	r3, #38
	bgt	.L145
	ldr	r1, [fp, #-28]
	ldr	r3, .L153+4
	smull	r0, r2, r3, r1
	asr	r3, r1, #31
	sub	r3, r2, r3
	mov	r2, r3
	lsl	r2, r2, #1
	add	r2, r2, r3
	sub	r3, r1, r2
	lsl	r2, r3, #2
	sub	r1, fp, #4
	add	r2, r1, r2
	ldr	r2, [r2, #-16]
	add	r2, r2, #1
	lsl	r3, r3, #2
	sub	r1, fp, #4
	add	r3, r1, r3
	str	r2, [r3, #-16]
	ldr	r3, [fp, #-40]
	cmp	r3, #7
	ble	.L145
	ldr	r1, [fp, #-28]
	ldr	r3, .L153+4
	smull	r0, r2, r3, r1
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	sub	r2, r1, r3
	sub	r3, fp, #4
	add	r3, r3, r2
	mov	r2, #1
	strb	r2, [r3, #-20]
.L145:
	ldr	r3, [fp, #-40]
	add	r3, r3, #1
	str	r3, [fp, #-40]
.L144:
	ldr	r3, [fp, #-40]
	cmp	r3, #10
	ble	.L146
	mov	r3, #0
	str	r3, [fp, #-36]
	mov	r3, #0
	str	r3, [fp, #-32]
	b	.L147
.L150:
	bl	find_freecell
	mov	r3, r0
	cmn	r3, #1
	bne	.L148
	sub	r2, fp, #24
	ldr	r3, [fp, #-32]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L149
.L148:
	ldr	r3, [fp, #-32]
	lsl	r3, r3, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-16]
	cmp	r3, #4
	bne	.L149
	mov	r2, #1
	ldr	r3, [fp, #-32]
	lsl	r3, r2, r3
	ldr	r2, [fp, #-36]
	orr	r3, r2, r3
	str	r3, [fp, #-36]
.L149:
	ldr	r3, [fp, #-32]
	add	r3, r3, #1
	str	r3, [fp, #-32]
.L147:
	ldr	r3, [fp, #-32]
	cmp	r3, #2
	ble	.L150
	ldr	r3, [fp, #-36]
	ldr	r2, .L153
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L152
	bl	__stack_chk_fail
.L152:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L154:
	.align	2
.L153:
	.word	.LC19
	.word	1431655766
	.size	exposed_dragons, .-exposed_dragons
	.align	2
	.global	remove_exposed_dragons
	.syntax unified
	.arm
	.fpu softvfp
	.type	remove_exposed_dragons, %function
remove_exposed_dragons:
	@ 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	.L156
.L158:
	ldr	r0, [fp, #-12]
	bl	lastcard
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #26
	ble	.L157
	ldr	r3, [fp, #-8]
	cmp	r3, #38
	bgt	.L157
	ldr	r1, [fp, #-8]
	ldr	r3, .L160
	smull	r0, r2, r3, r1
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	sub	r2, r1, r3
	ldr	r3, [fp, #-16]
	cmp	r3, r2
	bne	.L157
	ldr	r0, [fp, #-8]
	bl	remove_card
	ldr	r2, .L160+4
	ldr	r3, [fp, #-12]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r3, r0
	mov	r2, #1
	mov	r1, r3
	ldr	r0, [fp, #-12]
	bl	clear_row
.L157:
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L156:
	ldr	r3, [fp, #-12]
	cmp	r3, #10
	ble	.L158
	bl	find_freecell
	mov	r3, r0
	ldr	r2, .L160+4
	mvn	r1, #1
	str	r1, [r2, r3, lsl #2]
	mov	r3, #1
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L161:
	.align	2
.L160:
	.word	1431655766
	.word	rows
	.size	remove_exposed_dragons, .-remove_exposed_dragons
	.section	.rodata
	.align	2
.LC20:
	.ascii	"%d\000"
	.align	2
.LC21:
	.ascii	"(%c)\000"
	.align	2
.LC22:
	.ascii	"Y O U   W I N !\000"
	.align	2
.LC23:
	.ascii	"%5d win%c\000"
	.text
	.align	2
	.global	draw_cards
	.syntax unified
	.arm
	.fpu softvfp
	.type	draw_cards, %function
draw_cards:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	mov	r3, #0
	str	r3, [fp, #-28]
	b	.L163
.L170:
	ldr	r3, [fp, #-28]
	add	r3, r3, #8
	ldr	r2, .L191
	ldr	r0, [r2, r3, lsl #2]
	ldr	r2, [fp, #-28]
	mov	r3, r2
	lsl	r3, r3, #3
	sub	r3, r3, r2
	add	r3, r3, #2
	mov	r2, #2
	mov	r1, r3
	bl	draw_card
	ldr	r3, [fp, #-28]
	add	r3, r3, #12
	ldr	r2, .L191
	ldr	r0, [r2, r3, lsl #2]
	ldr	r2, [fp, #-28]
	mov	r3, r2
	lsl	r3, r3, #3
	sub	r3, r3, r2
	add	r3, r3, #58
	mov	r2, #2
	mov	r1, r3
	bl	draw_card
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_on
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r2, [fp, #-28]
	mov	r3, r2
	lsl	r3, r3, #3
	sub	r3, r3, r2
	add	r3, r3, #4
	mov	r2, r3
	mov	r1, #1
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L165
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r3, .L191+8
	ldr	r3, [r3]
	ldr	r2, [fp, #-28]
	add	r2, r2, #8
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	bl	waddch
.L165:
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #40
	mov	r1, #1
	mov	r0, r3
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L167
	ldr	r3, .L191+4
	ldr	r2, [r3]
	ldr	r3, .L191+8
	ldr	r3, [r3]
	add	r3, r3, #11
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	mov	r0, r2
	bl	waddch
.L167:
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r2, [fp, #-28]
	mov	r3, r2
	lsl	r3, r3, #3
	sub	r3, r3, r2
	add	r3, r3, #60
	mov	r2, r3
	mov	r1, #1
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L169
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r3, .L191+8
	ldr	r3, [r3]
	ldr	r2, [fp, #-28]
	add	r2, r2, #12
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	bl	waddch
.L169:
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_off
	ldr	r3, [fp, #-28]
	add	r3, r3, #1
	str	r3, [fp, #-28]
.L163:
	ldr	r3, [fp, #-28]
	cmp	r3, #2
	ble	.L170
	ldr	r3, .L191
	ldr	r3, [r3, #44]
	mov	r2, #2
	mov	r1, #38
	mov	r0, r3
	bl	draw_card
	bl	exposed_dragons
	str	r0, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-24]
	b	.L171
.L174:
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_on
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #2
	add	r2, r3, #23
	ldr	r3, [fp, #-24]
	add	r3, r3, #4
	str	r3, [sp]
	ldr	r3, .L191+12
	mov	r1, #1
	bl	mvwprintw
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_off
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-24]
	asr	r3, r2, r3
	lsl	r3, r3, #21
	and	r2, r3, #2097152
	ldr	r3, [fp, #-24]
	add	r3, r3, #4
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r2, r3
	mov	r2, #0
	mov	r1, r3
	bl	wattr_on
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r3, [fp, #-24]
	lsl	r3, r3, #2
	add	r1, r3, #22
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-24]
	asr	r3, r2, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L172
	ldr	r3, .L191+16
	ldr	r2, [r3]
	ldr	r3, [fp, #-24]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	b	.L173
.L172:
	mov	r3, #32
.L173:
	str	r3, [sp]
	ldr	r3, .L191+20
	mov	r2, r1
	mov	r1, #2
	bl	mvwprintw
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-24]
	asr	r3, r2, r3
	lsl	r3, r3, #21
	and	r2, r3, #2097152
	ldr	r3, [fp, #-24]
	add	r3, r3, #4
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r2, r3
	mov	r2, #0
	mov	r1, r3
	bl	wattr_off
	ldr	r3, [fp, #-24]
	add	r3, r3, #1
	str	r3, [fp, #-24]
.L171:
	ldr	r3, [fp, #-24]
	cmp	r3, #2
	ble	.L174
	mov	r3, #0
	str	r3, [fp, #-20]
	b	.L175
.L180:
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_on
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r2, [fp, #-20]
	mov	r3, r2
	lsl	r3, r3, #3
	add	r3, r3, r2
	add	r3, r3, #8
	mov	r2, r3
	mov	r1, #4
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L177
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r3, .L191+8
	ldr	r2, [r3]
	ldr	r3, [fp, #-20]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r1, r3
	bl	waddch
.L177:
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_off
	ldr	r2, .L191
	ldr	r3, [fp, #-20]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-16]
	mov	r3, #0
	str	r3, [fp, #-12]
.L179:
	ldr	r2, [fp, #-20]
	mov	r3, r2
	lsl	r3, r3, #3
	add	r3, r3, r2
	add	r1, r3, #6
	ldr	r3, [fp, #-12]
	add	r3, r3, #5
	mov	r2, r3
	ldr	r0, [fp, #-16]
	bl	draw_card
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	blt	.L178
	ldr	r2, .L191+24
	ldr	r3, [fp, #-16]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-16]
.L178:
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bge	.L179
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L175:
	ldr	r3, [fp, #-20]
	cmp	r3, #7
	ble	.L180
	ldr	r3, .L191
	ldr	r3, [r3, #32]
	cmn	r3, #2
	bne	.L181
	ldr	r3, .L191
	ldr	r3, [r3, #36]
	cmn	r3, #2
	bne	.L181
	ldr	r3, .L191
	ldr	r3, [r3, #40]
	cmn	r3, #2
	bne	.L181
	ldr	r3, .L191
	ldr	r3, [r3, #48]
	cmp	r3, #23
	ble	.L181
	ldr	r3, .L191
	ldr	r3, [r3, #52]
	cmp	r3, #23
	ble	.L181
	ldr	r3, .L191
	ldr	r3, [r3, #56]
	cmp	r3, #23
	ble	.L181
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #0
	ldr	r1, .L191+28
	mov	r0, r3
	bl	wattr_on
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r3, .L191+32
	mov	r2, #32
	mov	r1, #13
	bl	mvwprintw
	ldr	r3, .L191+36
	ldrb	r3, [r3]	@ zero_extendqisi2
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L182
	ldr	r3, .L191+40
	ldr	r3, [r3]
	cmp	r3, #0
	blt	.L183
	ldr	r3, .L191+44
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L191+44
	str	r3, [r2]
	ldr	r3, .L191+44
	ldr	r3, [r3]
	mov	r0, r3
	bl	set_win_count
.L183:
	ldr	r3, .L191+36
	mov	r2, #1
	strb	r2, [r3]
.L182:
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r2, #0
	ldr	r1, .L191+28
	mov	r0, r3
	bl	wattr_on
.L181:
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r3, .L191+36
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L184
	ldr	r3, .L191+28
	b	.L185
.L184:
	mov	r3, #2048
.L185:
	mov	r2, #0
	mov	r1, r3
	bl	wattr_on
	ldr	r3, .L191+4
	ldr	ip, [r3]
	ldr	r3, .L191+44
	ldr	r0, [r3]
	ldr	r3, .L191+44
	ldr	r1, [r3]
	ldr	r3, .L191+48
	umull	r2, r3, r1, r3
	lsr	r2, r3, #3
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #1
	sub	r2, r1, r3
	cmp	r2, #1
	bne	.L186
	ldr	r3, .L191+44
	ldr	r3, [r3]
	cmp	r3, #11
	bne	.L187
.L186:
	mov	r3, #115
	b	.L188
.L187:
	mov	r3, #32
.L188:
	str	r3, [sp, #4]
	str	r0, [sp]
	ldr	r3, .L191+52
	mov	r2, #68
	mov	r1, #21
	mov	r0, ip
	bl	mvwprintw
	ldr	r3, .L191+4
	ldr	r0, [r3]
	ldr	r3, .L191+36
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L189
	ldr	r3, .L191+28
	b	.L190
.L189:
	mov	r3, #2048
.L190:
	mov	r2, #0
	mov	r1, r3
	bl	wattr_off
	ldr	r3, .L191+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	wrefresh
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L192:
	.align	2
.L191:
	.word	rows
	.word	screen
	.word	rowkeys
	.word	.LC20
	.word	cardsuits
	.word	.LC21
	.word	cards
	.word	2099200
	.word	.LC22
	.word	won_game
	.word	seed
	.word	wincount
	.word	-858993459
	.word	.LC23
	.size	draw_cards, .-draw_cards
	.align	2
	.global	get_card
	.syntax unified
	.arm
	.fpu softvfp
	.type	get_card, %function
get_card:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #28
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	ldr	r3, [fp, #-16]
	cmp	r3, #14
	ble	.L194
	mvn	r3, #0
	b	.L195
.L194:
	ldr	r3, [fp, #-16]
	cmp	r3, #7
	ble	.L196
	ldr	r2, .L201
	ldr	r3, [fp, #-16]
	ldr	r3, [r2, r3, lsl #2]
	b	.L195
.L196:
	mov	r3, #0
	str	r3, [fp, #-12]
	ldr	r2, .L201
	ldr	r3, [fp, #-16]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-8]
	b	.L197
.L199:
	ldr	r2, .L201+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L197:
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	blt	.L198
	ldr	r2, .L201+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	cmn	r3, #1
	beq	.L198
	ldr	r2, [fp, #-12]
	ldr	r3, [fp, #-20]
	cmp	r2, r3
	bne	.L199
.L198:
	ldr	r3, [fp, #-24]
	cmp	r3, #0
	beq	.L200
	ldr	r3, [fp, #-24]
	ldr	r2, [fp, #-12]
	str	r2, [r3]
.L200:
	ldr	r3, [fp, #-8]
.L195:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L202:
	.align	2
.L201:
	.word	rows
	.word	cards
	.size	get_card, .-get_card
	.align	2
	.global	auto_move
	.syntax unified
	.arm
	.fpu softvfp
	.type	auto_move, %function
auto_move:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	mov	r3, #0
	str	r3, [fp, #-32]
	b	.L204
.L215:
	ldr	r0, [fp, #-32]
	bl	lastcard
	str	r0, [fp, #-24]
	mvn	r3, #0
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-24]
	cmp	r3, #39
	bne	.L205
	mov	r2, #11
	mov	r1, #39
	ldr	r0, [fp, #-32]
	bl	move_card
	mov	r3, r0
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L206
	ldr	r2, .L216
	ldr	r3, [fp, #-32]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r3, r0
	mov	r2, #1
	mov	r1, r3
	ldr	r0, [fp, #-32]
	bl	clear_row
.L206:
	ldr	r3, [fp, #-8]
	b	.L207
.L205:
	ldr	r3, [fp, #-24]
	cmp	r3, #0
	blt	.L208
	ldr	r3, [fp, #-24]
	cmp	r3, #2
	bgt	.L208
	mvn	r0, #0
	bl	find_foundation
	str	r0, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmn	r3, #1
	beq	.L208
	ldr	r2, [fp, #-20]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-32]
	bl	move_card
	mov	r3, r0
	str	r3, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	beq	.L209
	ldr	r2, .L216
	ldr	r3, [fp, #-32]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r3, r0
	mov	r2, #1
	mov	r1, r3
	ldr	r0, [fp, #-32]
	bl	clear_row
.L209:
	ldr	r3, [fp, #-16]
	b	.L207
.L208:
	ldr	r3, [fp, #-24]
	cmp	r3, #2
	ble	.L210
	ldr	r3, [fp, #-24]
	cmp	r3, #26
	bgt	.L210
	ldr	r3, [fp, #-24]
	sub	r3, r3, #3
	mov	r0, r3
	bl	find_foundation
	str	r0, [fp, #-20]
	ldr	r3, [fp, #-20]
	cmn	r3, #1
	beq	.L210
	mov	r3, #1
	strb	r3, [fp, #-33]
	mov	r3, #0
	str	r3, [fp, #-28]
	b	.L211
.L213:
	ldr	r3, [fp, #-28]
	add	r3, r3, #12
	ldr	r2, .L216
	ldr	r3, [r2, r3, lsl #2]
	ldr	r2, .L216+4
	smull	r1, r2, r3, r2
	asr	r3, r3, #31
	sub	r2, r2, r3
	ldr	r3, [fp, #-24]
	ldr	r1, .L216+4
	smull	r0, r1, r3, r1
	asr	r3, r3, #31
	sub	r3, r1, r3
	sub	r3, r3, #1
	cmp	r2, r3
	bge	.L212
	mov	r3, #0
	strb	r3, [fp, #-33]
.L212:
	ldr	r3, [fp, #-28]
	add	r3, r3, #1
	str	r3, [fp, #-28]
.L211:
	ldr	r3, [fp, #-28]
	cmp	r3, #2
	ble	.L213
	ldrb	r3, [fp, #-33]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L210
	ldr	r2, [fp, #-20]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-32]
	bl	move_card
	mov	r3, r0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	beq	.L214
	ldr	r2, .L216
	ldr	r3, [fp, #-32]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r3, r0
	mov	r2, #1
	mov	r1, r3
	ldr	r0, [fp, #-32]
	bl	clear_row
.L214:
	ldr	r3, [fp, #-12]
	b	.L207
.L210:
	ldr	r3, [fp, #-32]
	add	r3, r3, #1
	str	r3, [fp, #-32]
.L204:
	ldr	r3, [fp, #-32]
	cmp	r3, #10
	ble	.L215
	mov	r3, #0
.L207:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L217:
	.align	2
.L216:
	.word	rows
	.word	1431655766
	.size	auto_move, .-auto_move
	.align	2
	.global	update_status
	.syntax unified
	.arm
	.fpu softvfp
	.type	update_status, %function
update_status:
	@ 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]
	str	r1, [fp, #-12]
	ldr	r3, .L221
	ldr	r0, [r3]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r2, #0
	mov	r1, r3
	bl	wattr_on
	ldr	r3, .L221
	ldr	r2, [r3]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r1, r3
	mov	r0, r2
	bl	wbkgd
	ldr	r3, .L221
	ldr	r3, [r3]
	mov	r0, r3
	bl	werase
	ldr	r3, .L221
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #0
	mov	r0, r3
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L220
	ldr	r3, .L221
	ldr	r3, [r3]
	mvn	r2, #0
	ldr	r1, [fp, #-8]
	mov	r0, r3
	bl	waddnstr
.L220:
	ldr	r3, .L221
	ldr	r0, [r3]
	ldr	r3, [fp, #-12]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r2, #0
	mov	r1, r3
	bl	wattr_off
	ldr	r3, .L221
	ldr	r3, [r3]
	mov	r0, r3
	bl	wrefresh
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L222:
	.align	2
.L221:
	.word	statusbar
	.size	update_status, .-update_status
	.section	.rodata
	.align	2
.LC24:
	.ascii	"%s: >\000"
	.text
	.align	2
	.global	ask_string
	.syntax unified
	.arm
	.fpu softvfp
	.type	ask_string, %function
ask_string:
	@ 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, #-16]
	str	r1, [fp, #-20]
	str	r2, [fp, #-24]
	str	r3, [fp, #-28]
	ldr	r3, .L226
	ldr	r0, [r3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r2, #0
	mov	r1, r3
	bl	wattr_on
	ldr	r3, .L226
	ldr	r3, [r3]
	mov	r0, r3
	bl	werase
	ldr	r3, .L226
	ldr	r2, [r3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r1, r3
	mov	r0, r2
	bl	wbkgd
	ldr	r3, .L226
	ldr	r0, [r3]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, .L226+4
	mov	r2, #0
	mov	r1, #0
	bl	mvwprintw
	bl	echo
	ldr	r3, .L226
	ldr	r3, [r3]
	ldr	r2, [fp, #-28]
	ldr	r1, [fp, #-24]
	mov	r0, r3
	bl	wgetnstr
	str	r0, [fp, #-8]
	bl	noecho
	ldr	r3, .L226
	ldr	r0, [r3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r2, #0
	mov	r1, r3
	bl	wattr_off
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L224
	mov	r3, #1
	b	.L225
.L224:
	mov	r3, #0
.L225:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L227:
	.align	2
.L226:
	.word	statusbar
	.word	.LC24
	.size	ask_string, .-ask_string
	.section	.rodata
	.align	2
.LC25:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	ask_integer
	.syntax unified
	.arm
	.fpu softvfp
	.type	ask_integer, %function
ask_integer:
	@ args = 0, pretend = 0, frame = 56
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #60
	str	r0, [fp, #-56]
	str	r1, [fp, #-60]
	str	r2, [fp, #-64]
	ldr	r3, .L237
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #0
	strb	r3, [fp, #-40]
.L234:
	bl	__errno_location
	mov	r3, r0
	mov	r2, #0
	str	r2, [r3]
	sub	r2, fp, #40
	mov	r3, #20
	ldr	r1, [fp, #-60]
	ldr	r0, [fp, #-56]
	bl	ask_string
	mov	r3, r0
	str	r3, [fp, #-48]
	ldr	r3, [fp, #-48]
	cmp	r3, #0
	bne	.L229
	mov	r3, #0
	b	.L235
.L229:
	sub	r3, fp, #40
	str	r3, [fp, #-52]
	sub	r1, fp, #52
	sub	r3, fp, #40
	mov	r2, #0
	mov	r0, r3
	bl	strtol
	str	r0, [fp, #-44]
	sub	r3, fp, #40
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L231
	mov	r3, #0
	b	.L235
.L231:
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L232
	ldr	r2, [fp, #-52]
	sub	r3, fp, #40
	sub	r3, r2, r3
	mov	r4, r3
	sub	r3, fp, #40
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	cmp	r4, r3
	bcs	.L233
.L232:
	bl	beep
	b	.L234
.L233:
	ldr	r3, [fp, #-64]
	ldr	r2, [fp, #-44]
	str	r2, [r3]
	mov	r3, #1
.L235:
	ldr	r2, .L237
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L236
	bl	__stack_chk_fail
.L236:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L238:
	.align	2
.L237:
	.word	.LC25
	.size	ask_integer, .-ask_integer
	.section	.rodata
	.align	2
.LC26:
	.ascii	"%s (y/n)? \000"
	.align	2
.LC27:
	.ascii	"OK.\000"
	.text
	.align	2
	.global	yes_or_no
	.syntax unified
	.arm
	.fpu softvfp
	.type	yes_or_no, %function
yes_or_no:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	ldr	r3, .L244
	ldr	r0, [r3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r2, #0
	mov	r1, r3
	bl	wattr_on
	ldr	r3, .L244
	ldr	r3, [r3]
	mov	r0, r3
	bl	werase
	ldr	r3, .L244
	ldr	r2, [r3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r1, r3
	mov	r0, r2
	bl	wbkgd
	ldr	r3, .L244
	ldr	r0, [r3]
	ldr	r3, [fp, #-16]
	str	r3, [sp]
	ldr	r3, .L244+4
	mov	r2, #0
	mov	r1, #0
	bl	mvwprintw
	ldr	r3, .L244
	ldr	r0, [r3]
	ldr	r3, [fp, #-20]
	lsl	r3, r3, #8
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	orr	r3, r3, #2097152
	mov	r2, #0
	mov	r1, r3
	bl	wattr_off
.L243:
	ldr	r3, .L244
	ldr	r3, [r3]
	mov	r0, r3
	bl	wgetch
	str	r0, [fp, #-8]
	ldr	r0, [fp, #-8]
	bl	tolower
	mov	r3, r0
	cmp	r3, #121
	bne	.L240
	mov	r1, #9
	ldr	r0, .L244+8
	bl	update_status
	mov	r3, #1
	b	.L241
.L240:
	ldr	r0, [fp, #-8]
	bl	tolower
	mov	r3, r0
	cmp	r3, #110
	bne	.L243
	mov	r1, #9
	ldr	r0, .L244+8
	bl	update_status
	mov	r3, #0
.L241:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L245:
	.align	2
.L244:
	.word	statusbar
	.word	.LC26
	.word	.LC27
	.size	yes_or_no, .-yes_or_no
	.section	.rodata
	.align	2
.LC28:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	new_seed
	.syntax unified
	.arm
	.fpu softvfp
	.type	new_seed, %function
new_seed:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	ldr	r3, .L249
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r0, #0
	bl	time
	mov	r3, r0
	str	r3, [fp, #-12]
	sub	r3, fp, #12
	mov	r0, r3
	bl	rand_r
	mov	r3, r0
	ldr	r2, .L249
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L248
	bl	__stack_chk_fail
.L248:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L250:
	.align	2
.L249:
	.word	.LC28
	.size	new_seed, .-new_seed
	.global	__aeabi_idivmod
	.section	.rodata
	.align	2
.LC29:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	init_board
	.syntax unified
	.arm
	.fpu softvfp
	.type	init_board, %function
init_board:
	@ args = 0, pretend = 0, frame = 272
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #272
	str	r0, [fp, #-280]
	ldr	r3, .L270
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-272]
	b	.L252
.L253:
	ldr	r2, .L270+4
	ldr	r3, [fp, #-272]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r2, r0
	ldr	r3, [fp, #-272]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	str	r2, [r3, #-224]
	ldr	r3, [fp, #-272]
	add	r3, r3, #1
	str	r3, [fp, #-272]
.L252:
	ldr	r3, [fp, #-272]
	cmp	r3, #14
	ble	.L253
	mov	r3, #0
	str	r3, [fp, #-268]
	b	.L254
.L255:
	ldr	r2, .L270+8
	ldr	r3, [fp, #-268]
	mvn	r1, #0
	str	r1, [r2, r3, lsl #2]
	ldr	r3, [fp, #-268]
	add	r3, r3, #1
	str	r3, [fp, #-268]
.L254:
	ldr	r3, [fp, #-268]
	cmp	r3, #39
	ble	.L255
	mov	r3, #0
	str	r3, [fp, #-264]
	b	.L256
.L257:
	ldr	r2, .L270+4
	ldr	r3, [fp, #-264]
	mvn	r1, #0
	str	r1, [r2, r3, lsl #2]
	ldr	r3, [fp, #-264]
	add	r3, r3, #1
	str	r3, [fp, #-264]
.L256:
	ldr	r3, [fp, #-264]
	cmp	r3, #14
	ble	.L257
	ldr	r3, [fp, #-280]
	mov	r0, r3
	bl	srand
	mov	r3, #0
	str	r3, [fp, #-260]
	b	.L258
.L259:
	ldr	r3, [fp, #-260]
	rsb	r2, r3, #39
	ldr	r3, [fp, #-260]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	str	r2, [r3, #-164]
	ldr	r3, [fp, #-260]
	add	r3, r3, #1
	str	r3, [fp, #-260]
.L258:
	ldr	r3, [fp, #-260]
	cmp	r3, #39
	ble	.L259
	ldr	r3, [fp, #-280]
	cmn	r3, #1
	beq	.L260
	mov	r3, #0
	str	r3, [fp, #-256]
	b	.L261
.L262:
	bl	rand
	mov	r2, r0
	ldr	r3, [fp, #-256]
	rsb	r3, r3, #40
	mov	r1, r3
	mov	r0, r2
	bl	__aeabi_idivmod
	mov	r3, r1
	mov	r2, r3
	ldr	r3, [fp, #-256]
	add	r3, r3, r2
	str	r3, [fp, #-244]
	ldr	r3, [fp, #-256]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r3, [r3, #-164]
	str	r3, [fp, #-240]
	ldr	r3, [fp, #-244]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r2, [r3, #-164]
	ldr	r3, [fp, #-256]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	str	r2, [r3, #-164]
	ldr	r3, [fp, #-244]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r2, [fp, #-240]
	str	r2, [r3, #-164]
	ldr	r3, [fp, #-256]
	add	r3, r3, #1
	str	r3, [fp, #-256]
.L261:
	ldr	r3, [fp, #-256]
	cmp	r3, #38
	ble	.L262
.L260:
	mov	r3, #0
	str	r3, [fp, #-252]
	b	.L263
.L264:
	ldr	r3, [fp, #-252]
	rsbs	r1, r3, #0
	and	r2, r3, #7
	and	r3, r1, #7
	rsbpl	r2, r3, #0
	ldr	r3, [fp, #-252]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	ldr	r3, [r3, #-164]
	mov	r1, r3
	mov	r0, r2
	bl	add_to_row
	ldr	r3, [fp, #-252]
	add	r3, r3, #1
	str	r3, [fp, #-252]
.L263:
	ldr	r3, [fp, #-252]
	cmp	r3, #39
	ble	.L264
	mov	r3, #0
	str	r3, [fp, #-248]
	b	.L265
.L267:
	ldr	r2, .L270+4
	ldr	r3, [fp, #-248]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r2, r0
	ldr	r3, [fp, #-248]
	lsl	r3, r3, #2
	sub	r1, fp, #12
	add	r3, r1, r3
	ldr	r3, [r3, #-224]
	cmp	r2, r3
	bge	.L266
	ldr	r2, .L270+4
	ldr	r3, [fp, #-248]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r5, r0
	ldr	r3, [fp, #-248]
	lsl	r3, r3, #2
	sub	r2, fp, #12
	add	r3, r2, r3
	ldr	r4, [r3, #-224]
	ldr	r2, .L270+4
	ldr	r3, [fp, #-248]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r3, r0
	sub	r3, r4, r3
	mov	r2, r3
	mov	r1, r5
	ldr	r0, [fp, #-248]
	bl	clear_row
.L266:
	ldr	r3, [fp, #-248]
	add	r3, r3, #1
	str	r3, [fp, #-248]
.L265:
	ldr	r3, [fp, #-248]
	cmp	r3, #14
	ble	.L267
	mov	r3, #0
	ldr	r2, .L270
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L269
	bl	__stack_chk_fail
.L269:
	mov	r0, r3
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L271:
	.align	2
.L270:
	.word	.LC29
	.word	rows
	.word	cards
	.size	init_board, .-init_board
	.section	.rodata
	.align	2
.LC30:
	.ascii	"Welcome to szsol!\000"
	.align	2
.LC31:
	.ascii	"Game #%d\000"
	.text
	.align	2
	.global	draw_initial_screen
	.syntax unified
	.arm
	.fpu softvfp
	.type	draw_initial_screen, %function
draw_initial_screen:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	ldr	r3, .L274
	ldr	r3, [r3]
	mov	r1, #256
	mov	r0, r3
	bl	wbkgdset
	ldr	r3, .L274
	ldr	r3, [r3]
	mov	r0, r3
	bl	wclear
	ldr	r3, .L274
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #512
	mov	r0, r3
	bl	wattr_on
	ldr	r3, .L274
	ldr	r0, [r3]
	mov	r3, #0
	str	r3, [sp, #16]
	mov	r3, #0
	str	r3, [sp, #12]
	mov	r3, #0
	str	r3, [sp, #8]
	mov	r3, #0
	str	r3, [sp, #4]
	mov	r3, #0
	str	r3, [sp]
	mov	r3, #0
	mov	r2, #0
	mov	r1, #0
	bl	wborder
	ldr	r3, .L274
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #512
	mov	r0, r3
	bl	wattr_off
	mov	r1, #9
	ldr	r0, .L274+4
	bl	update_status
	ldr	r3, .L274
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_on
	ldr	r3, .L274
	ldr	r0, [r3]
	ldr	r3, .L274+8
	ldr	r3, [r3]
	str	r3, [sp]
	ldr	r3, .L274+12
	mov	r2, #2
	mov	r1, #21
	bl	mvwprintw
	ldr	r3, .L274
	ldr	r3, [r3]
	mov	r2, #0
	mov	r1, #2048
	mov	r0, r3
	bl	wattr_off
	ldr	r3, .L274
	ldr	r3, [r3]
	mov	r0, r3
	bl	wrefresh
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L275:
	.align	2
.L274:
	.word	screen
	.word	.LC30
	.word	seed
	.word	.LC31
	.size	draw_initial_screen, .-draw_initial_screen
	.section	.rodata
	.align	2
.LC32:
	.ascii	"Press ENTER to start (feel free to attach a debugge"
	.ascii	"r to this process at this moment).\000"
	.align	2
.LC33:
	.ascii	"szsol v0.1 -- a quick and dirty ncurses clone of @z"
	.ascii	"achtronics'\012SHENZHEN SOLITAIRE, a solitaire game"
	.ascii	" provided with SHENZHEN I/O\012(also available as a"
	.ascii	" separate game for Windows, Mac OS, Linux and iOS)\012"
	.ascii	"\012Send any bug reports, comments and legal threat"
	.ascii	"s regarding this clone to\012@usr_local_share or at"
	.ascii	" github.com/usrshare/szsol\000"
	.align	2
.LC34:
	.ascii	"Usage: %s [-d] [-D | -F] [-n number] [-v]\012\011-d"
	.ascii	" : Debug mode.\012\011-D : Use the QWERTZ keyboard "
	.ascii	"layout.\012\011-F : Use the AZERTY keyboard layout."
	.ascii	"\012\011-n [number] : Start with a predetermined ca"
	.ascii	"rd layout based on a seed number. \012\011-v : Vers"
	.ascii	"ion / credits.\012\012How to play:\012The goal is t"
	.ascii	"o clear the tableau by moving all the cards onto\012"
	.ascii	"the foundations and the free cells.\012\012Cards va"
	.ascii	"lued 1 to 9 stack on the foundations by suit in inc"
	.ascii	"reasing\012order (1->2->3). They can also be stacke"
	.ascii	"d on the tableau in decreasing\012order (9->8->7), "
	.ascii	"but only if the suits alternate.\012Dragons (labele"
	.ascii	"d '*') can't be stacked -- but when all four dragon"
	.ascii	"s\012of a single color are exposed, they can be mov"
	.ascii	"ed into a single free cell.\012Otherwise, each free"
	.ascii	" cell can only store one card.\012\012Controls:\012"
	.ascii	"1,2,3 -- select free cells\012W,E,R,T,Y,U,I,O -- se"
	.ascii	"lect tableau rows\012Shift-W,E,R,T,Y,U,I,O -- selec"
	.ascii	"t highest possible card in that tableau row\012(pre"
	.ascii	"ss multiple times to move more than one card from a"
	.ascii	" row\0128,9,0 -- select foundations\012[space bar] "
	.ascii	"-- remove selection\0124,5,6 -- move dragons onto a"
	.ascii	" free cell (when available)\012Shift+Q or Ctrl+C --"
	.ascii	" exit\012\000"
	.align	2
.LC35:
	.ascii	"dvn:t:DF\000"
	.align	2
.LC36:
	.ascii	"Terminal window is too small.\012Minimum terminal w"
	.ascii	"indow size: 80x24.\012\000"
	.align	2
.LC37:
	.ascii	"Can't go further in this row.\000"
	.align	2
.LC38:
	.ascii	"Can't move the cards into this row.\000"
	.align	2
.LC39:
	.ascii	"Can't select an empty row.\000"
	.align	2
.LC40:
	.ascii	"Dragons removed.\000"
	.align	2
.LC41:
	.ascii	"Can't remove these dragons yet.\000"
	.align	2
.LC42:
	.ascii	"Quit?\000"
	.align	2
.LC43:
	.ascii	"Restart this game?\000"
	.align	2
.LC44:
	.ascii	"Winning this exact game once again won't increase y"
	.ascii	"our win count.\000"
	.align	2
.LC45:
	.ascii	"Start a new game?\000"
	.align	2
.LC46:
	.ascii	"Input game # for a new game or empty string to canc"
	.ascii	"el\000"
	.align	2
.LC47:
	.ascii	"Continuing existing game.\000"
	.align	2
.LC48:
	.ascii	"Automatic moves enabled.\000"
	.align	2
.LC49:
	.ascii	"Automatic moves disabled.\000"
	.align	2
.LC50:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 88
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #92
	str	r0, [fp, #-96]
	str	r1, [fp, #-100]
	ldr	r3, .L341
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mvn	r3, #0
	str	r3, [fp, #-56]
	bl	new_seed
	mov	r3, r0
	ldr	r2, .L341+4
	str	r3, [r2]
	b	.L277
.L290:
	ldr	r3, [fp, #-56]
	cmp	r3, #118
	bgt	.L278
	ldr	r3, [fp, #-56]
	cmp	r3, #100
	bge	.L279
	ldr	r3, [fp, #-56]
	cmp	r3, #68
	beq	.L280
	ldr	r3, [fp, #-56]
	cmp	r3, #70
	beq	.L281
	b	.L278
.L279:
	ldr	r3, [fp, #-56]
	sub	r3, r3, #100
	cmp	r3, #18
	ldrls	pc, [pc, r3, asl #2]
	b	.L278
.L283:
	.word	.L286
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L285
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L278
	.word	.L284
	.word	.L278
	.word	.L282
.L286:
	ldr	r3, .L341+8
	mov	r2, #1
	str	r2, [r3]
	ldr	r0, .L341+12
	bl	puts
	ldr	r3, .L341+16
	ldr	r3, [r3]
	mov	r0, r3
	bl	getc
	b	.L277
.L280:
	ldr	r3, .L341+20
	ldr	r3, [r3]
	ldr	r2, .L341+24
	str	r3, [r2]
	b	.L277
.L281:
	ldr	r3, .L341+28
	ldr	r3, [r3]
	ldr	r2, .L341+24
	str	r3, [r2]
	b	.L277
.L285:
	ldr	r3, .L341+32
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	mov	r3, r0
	ldr	r2, .L341+4
	str	r3, [r2]
	b	.L277
.L284:
	ldr	r3, .L341+32
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	mov	r3, r0
	ldr	r2, .L341+36
	str	r3, [r2]
	ldr	r3, .L341+36
	ldr	r3, [r3]
	cmp	r3, #0
	blt	.L287
	ldr	r3, .L341+36
	ldr	r3, [r3]
	cmp	r3, #1
	bls	.L277
.L287:
	ldr	r3, .L341+36
	mov	r2, #0
	str	r2, [r3]
	b	.L277
.L282:
	ldr	r0, .L341+40
	bl	puts
	mov	r3, #0
	b	.L339
.L278:
	ldr	r3, .L341+44
	ldr	r0, [r3]
	ldr	r3, [fp, #-100]
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, .L341+48
	bl	fprintf
	mov	r3, #0
	b	.L339
.L277:
	ldr	r2, .L341+52
	ldr	r1, [fp, #-100]
	ldr	r0, [fp, #-96]
	bl	getopt
	str	r0, [fp, #-56]
	ldr	r3, [fp, #-56]
	cmn	r3, #1
	bne	.L290
	ldr	r3, .L341+24
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L291
	ldr	r3, .L341+56
	ldr	r3, [r3]
	ldr	r2, .L341+24
	str	r3, [r2]
.L291:
	bl	initscr
	mov	r0, #100
	bl	set_escdelay
	bl	cbreak
	bl	noecho
	bl	start_color
	mov	r3, #0
	str	r3, [fp, #-80]
	b	.L292
.L293:
	ldr	r3, [fp, #-80]
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	add	r3, r3, #1
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	lsl	r3, r3, #16
	asr	r0, r3, #16
	ldr	r3, .L341+36
	ldr	r2, [r3]
	ldr	ip, .L341+60
	ldr	r3, [fp, #-80]
	lsl	r1, r3, #3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, ip, r3
	ldr	r3, [r3]
	lsl	r3, r3, #16
	asr	ip, r3, #16
	ldr	r3, .L341+36
	ldr	r2, [r3]
	ldr	lr, .L341+60
	ldr	r3, [fp, #-80]
	lsl	r1, r3, #3
	mov	r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r2, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #2
	add	r3, r1, r3
	add	r3, lr, r3
	add	r3, r3, #4
	ldr	r3, [r3]
	lsl	r3, r3, #16
	asr	r3, r3, #16
	mov	r2, r3
	mov	r1, ip
	bl	init_pair
	ldr	r3, [fp, #-80]
	add	r3, r3, #1
	str	r3, [fp, #-80]
.L292:
	ldr	r3, [fp, #-80]
	cmp	r3, #10
	ble	.L293
	ldr	r3, .L341+64
	ldr	r3, [r3]
	cmp	r3, #23
	ble	.L294
	ldr	r3, .L341+68
	ldr	r3, [r3]
	cmp	r3, #79
	bgt	.L295
.L294:
	bl	endwin
	ldr	r3, .L341+44
	ldr	r3, [r3]
	mov	r2, #67
	mov	r1, #1
	ldr	r0, .L341+72
	bl	fwrite
	mvn	r3, #0
	b	.L339
.L295:
	ldr	r3, .L341+64
	ldr	r3, [r3]
	sub	r3, r3, #24
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r1, r3
	ldr	r3, .L341+68
	ldr	r3, [r3]
	sub	r3, r3, #80
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r2, r1
	mov	r1, #80
	mov	r0, #23
	bl	newwin
	mov	r3, r0
	ldr	r2, .L341+76
	str	r3, [r2]
	ldr	r3, .L341+64
	ldr	r3, [r3]
	sub	r3, r3, #24
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	add	r1, r3, #23
	ldr	r3, .L341+68
	ldr	r3, [r3]
	sub	r3, r3, #80
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r2, r1
	mov	r1, #80
	mov	r0, #1
	bl	newwin
	mov	r3, r0
	ldr	r2, .L341+80
	str	r3, [r2]
	ldr	r3, .L341+76
	ldr	r3, [r3]
	mov	r1, #1
	mov	r0, r3
	bl	keypad
	bl	get_win_count
	mov	r3, r0
	ldr	r2, .L341+84
	str	r3, [r2]
	mov	r3, #0
	str	r3, [fp, #-76]
	b	.L296
.L297:
	ldr	r2, .L341+88
	ldr	r3, [fp, #-76]
	mvn	r1, #0
	str	r1, [r2, r3, lsl #2]
	ldr	r3, [fp, #-76]
	add	r3, r3, #1
	str	r3, [fp, #-76]
.L296:
	ldr	r3, [fp, #-76]
	cmp	r3, #39
	ble	.L297
	mov	r3, #0
	str	r3, [fp, #-72]
	b	.L298
.L299:
	ldr	r2, .L341+92
	ldr	r3, [fp, #-72]
	mvn	r1, #0
	str	r1, [r2, r3, lsl #2]
	ldr	r3, [fp, #-72]
	add	r3, r3, #1
	str	r3, [fp, #-72]
.L298:
	ldr	r3, [fp, #-72]
	cmp	r3, #14
	ble	.L299
	ldr	r3, .L341+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	init_board
	mov	r3, #0
	str	r3, [fp, #-52]
	mvn	r3, #0
	str	r3, [fp, #-68]
	mvn	r3, #0
	str	r3, [fp, #-88]
	bl	draw_initial_screen
	bl	draw_cards
	mov	r3, #1
	strb	r3, [fp, #-90]
	mov	r3, #0
	str	r3, [fp, #-64]
.L338:
	ldr	r3, [fp, #-68]
	cmn	r3, #1
	bne	.L300
	ldr	r3, [fp, #-88]
	cmn	r3, #1
	bne	.L300
	ldr	r3, .L341+96
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L300
	b	.L301
.L304:
	ldr	r3, [fp, #-64]
	add	r3, r3, #1
	str	r3, [fp, #-64]
	ldr	r3, .L341+76
	ldr	r0, [r3]
	ldr	r3, .L341+68
	ldr	r3, [r3]
	sub	r3, r3, #2
	mov	r2, r3
	mov	r1, #1
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L303
	ldr	r3, .L341+76
	ldr	r0, [r3]
	ldr	r3, [fp, #-64]
	rsbs	r2, r3, #0
	and	r3, r3, #3
	and	r2, r2, #3
	rsbpl	r3, r2, #0
	ldr	r2, .L341+100
	ldrb	r3, [r2, r3]	@ zero_extendqisi2
	mov	r1, r3
	bl	waddch
.L303:
	bl	draw_cards
	ldr	r3, [fp, #-64]
	cmp	r3, #1
	ble	.L301
	ldr	r0, .L341+104
	bl	usleep
.L301:
	ldr	r3, .L341+108
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L300
	bl	auto_move
	mov	r3, r0
	cmp	r3, #0
	bne	.L304
.L300:
	mov	r3, #0
	str	r3, [fp, #-64]
	ldr	r3, .L341+76
	ldr	r0, [r3]
	ldr	r3, .L341+68
	ldr	r3, [r3]
	sub	r3, r3, #2
	mov	r2, r3
	mov	r1, #1
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L306
	ldr	r3, .L341+76
	ldr	r3, [r3]
	mov	r1, #32
	mov	r0, r3
	bl	waddch
.L306:
	bl	draw_cards
	ldr	r3, .L341+76
	ldr	r3, [r3]
	mov	r0, r3
	bl	wgetch
	str	r0, [fp, #-52]
	ldr	r3, .L341+24
	ldr	r2, [r3]
	ldr	r3, [fp, #-52]
	and	r3, r3, #255
	mov	r1, r3
	mov	r0, r2
	bl	strchr
	str	r0, [fp, #-48]
	ldr	r3, [fp, #-48]
	cmp	r3, #0
	beq	.L307
	ldr	r3, .L341+24
	ldr	r3, [r3]
	ldr	r2, [fp, #-48]
	sub	r3, r2, r3
	str	r3, [fp, #-36]
	ldr	r2, [fp, #-36]
	ldr	r3, [fp, #-68]
	cmp	r2, r3
	bne	.L308
	ldr	r3, [fp, #-88]
	sub	r3, r3, #1
	sub	r2, fp, #88
	mov	r1, r3
	ldr	r0, [fp, #-68]
	bl	get_card
	str	r0, [fp, #-28]
	ldr	r3, .L341+96
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, [fp, #-28]
	bl	card_can_be_stacked
	mov	r3, r0
	cmp	r3, #0
	beq	.L309
	ldr	r2, .L341+96
	ldr	r3, [fp, #-28]
	str	r3, [r2]
	b	.L310
.L309:
	mov	r1, #11
	ldr	r0, .L341+112
	bl	update_status
	bl	beep
	mvn	r3, #0
	str	r3, [fp, #-68]
	mvn	r3, #0
	str	r3, [fp, #-88]
	ldr	r3, .L341+96
	mvn	r2, #0
	str	r2, [r3]
	b	.L310
.L308:
	sub	r3, fp, #88
	mov	r2, r3
	mvn	r1, #0
	ldr	r0, [fp, #-36]
	bl	get_card
	str	r0, [fp, #-32]
	ldr	r3, [fp, #-68]
	cmn	r3, #1
	beq	.L311
	ldr	r3, .L341+96
	ldr	r3, [r3]
	ldr	r2, [fp, #-36]
	mov	r1, r3
	ldr	r0, [fp, #-68]
	bl	move_card
	mov	r3, r0
	strb	r3, [fp, #-89]
	ldrb	r3, [fp, #-89]
	eor	r3, r3, #1
	and	r3, r3, #255
	cmp	r3, #0
	beq	.L312
	mov	r1, #11
	ldr	r0, .L341+116
	bl	update_status
	bl	beep
.L312:
	ldrb	r3, [fp, #-89]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L313
	mov	r1, #9
	ldr	r0, .L341+120
	bl	update_status
	ldr	r2, .L341+92
	ldr	r3, [fp, #-68]
	ldr	r3, [r2, r3, lsl #2]
	mov	r0, r3
	bl	stacklen
	mov	r4, r0
	ldr	r3, .L341+96
	ldr	r3, [r3]
	mov	r0, r3
	bl	stacklen
	mov	r3, r0
	mov	r2, r3
	mov	r1, r4
	ldr	r0, [fp, #-68]
	bl	clear_row
.L313:
	mvn	r3, #0
	str	r3, [fp, #-68]
	mvn	r3, #0
	str	r3, [fp, #-88]
	ldr	r3, .L341+96
	mvn	r2, #0
	str	r2, [r3]
	b	.L310
.L311:
	ldr	r3, [fp, #-32]
	cmn	r3, #1
	bne	.L314
	mov	r1, #11
	ldr	r0, .L341+124
	bl	update_status
	bl	beep
	b	.L310
.L314:
	ldr	r3, [fp, #-36]
	str	r3, [fp, #-68]
	ldr	r2, .L341+96
	ldr	r3, [fp, #-32]
	str	r3, [r2]
	b	.L310
.L307:
	ldr	r3, .L341+24
	ldr	r4, [r3]
	ldr	r0, [fp, #-52]
	bl	tolower
	mov	r3, r0
	and	r3, r3, #255
	mov	r1, r3
	mov	r0, r4
	bl	strchr
	str	r0, [fp, #-48]
	ldr	r3, [fp, #-48]
	cmp	r3, #0
	beq	.L310
	ldr	r3, .L341+24
	ldr	r3, [r3]
	ldr	r2, [fp, #-48]
	sub	r3, r2, r3
	str	r3, [fp, #-44]
	sub	r3, fp, #88
	mov	r2, r3
	mvn	r1, #0
	ldr	r0, [fp, #-44]
	bl	get_card
	str	r0, [fp, #-60]
	mvn	r3, #0
	str	r3, [fp, #-40]
	ldr	r3, [fp, #-88]
	str	r3, [fp, #-84]
	b	.L315
.L317:
	ldr	r3, [fp, #-40]
	str	r3, [fp, #-60]
	ldr	r3, [fp, #-84]
	str	r3, [fp, #-88]
.L315:
	ldr	r3, [fp, #-88]
	cmp	r3, #0
	ble	.L316
	ldr	r3, [fp, #-84]
	sub	r3, r3, #1
	sub	r2, fp, #84
	mov	r1, r3
	ldr	r0, [fp, #-44]
	bl	get_card
	str	r0, [fp, #-40]
	ldr	r3, [fp, #-40]
	cmn	r3, #1
	beq	.L316
	ldr	r1, [fp, #-60]
	ldr	r0, [fp, #-40]
	bl	card_can_be_stacked
	mov	r3, r0
	cmp	r3, #0
	bne	.L317
.L316:
	ldr	r3, [fp, #-44]
	str	r3, [fp, #-68]
	ldr	r2, .L341+96
	ldr	r3, [fp, #-60]
	str	r3, [r2]
.L310:
	ldr	r3, [fp, #-52]
	cmp	r3, #51
	ble	.L318
	ldr	r3, [fp, #-52]
	cmp	r3, #54
	bgt	.L318
	bl	exposed_dragons
	str	r0, [fp, #-24]
	ldr	r3, [fp, #-52]
	sub	r3, r3, #52
	str	r3, [fp, #-20]
	ldr	r2, [fp, #-24]
	ldr	r3, [fp, #-20]
	asr	r3, r2, r3
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L319
	ldr	r0, [fp, #-20]
	bl	remove_exposed_dragons
	mov	r1, #9
	ldr	r0, .L341+128
	bl	update_status
	b	.L320
.L319:
	mov	r1, #11
	ldr	r0, .L341+132
	bl	update_status
.L320:
	mvn	r3, #0
	str	r3, [fp, #-68]
	mvn	r3, #0
	str	r3, [fp, #-88]
	ldr	r3, .L341+96
	mvn	r2, #0
	str	r2, [r3]
.L318:
	ldr	r3, [fp, #-52]
	cmp	r3, #32
	bne	.L321
	mov	r1, #9
	ldr	r0, .L341+120
	bl	update_status
	mvn	r3, #0
	str	r3, [fp, #-68]
	mvn	r3, #0
	str	r3, [fp, #-88]
	ldr	r3, .L341+96
	mvn	r2, #0
	str	r2, [r3]
.L321:
	ldr	r3, [fp, #-52]
	cmp	r3, #110
	bne	.L322
	ldr	r3, .L341+8
	ldr	r3, [r3]
	cmp	r3, #1
	bne	.L322
	ldr	r3, .L341+136
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	movne	r3, #1
	moveq	r3, #0
	and	r3, r3, #255
	eor	r3, r3, #1
	and	r3, r3, #255
	and	r3, r3, #1
	and	r2, r3, #255
	ldr	r3, .L341+136
	strb	r2, [r3]
.L322:
	ldr	r3, [fp, #-52]
	cmp	r3, #81
	beq	.L323
	ldr	r3, [fp, #-52]
	cmp	r3, #27
	bne	.L324
.L323:
	mov	r1, #10
	ldr	r0, .L341+140
	bl	yes_or_no
	mov	r3, r0
	cmp	r3, #0
	beq	.L324
	mov	r3, #0
	strb	r3, [fp, #-90]
.L324:
	ldr	r3, .L341+24
	ldr	r2, [r3]
	ldr	r3, .L341+56
	ldr	r3, [r3]
	cmp	r2, r3
	bne	.L325
	ldr	r3, [fp, #-52]
	cmp	r3, #122
	beq	.L326
.L325:
	ldr	r3, [fp, #-52]
	ldr	r2, .L341+144
	cmp	r3, r2
	bne	.L327
.L326:
	mov	r1, #10
	ldr	r0, .L341+148
	bl	yes_or_no
	mov	r3, r0
	cmp	r3, #0
	beq	.L327
	mvn	r3, #0
	str	r3, [fp, #-68]
	mvn	r3, #0
	str	r3, [fp, #-88]
	ldr	r3, .L341+96
	mvn	r2, #0
	str	r2, [r3]
	ldr	r3, .L341+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	init_board
	bl	draw_initial_screen
	ldr	r3, .L341+152
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L327
	mov	r1, #10
	ldr	r0, .L341+156
	bl	update_status
.L327:
	ldr	r3, [fp, #-52]
	cmp	r3, #110
	beq	.L328
	ldr	r3, [fp, #-52]
	ldr	r2, .L341+160
	cmp	r3, r2
	bne	.L329
.L328:
	mov	r1, #10
	ldr	r0, .L341+164
	bl	yes_or_no
	mov	r3, r0
	cmp	r3, #0
	beq	.L329
	ldr	r3, .L341+152
	mov	r2, #0
	strb	r2, [r3]
	bl	new_seed
	mov	r3, r0
	ldr	r2, .L341+4
	str	r3, [r2]
	mvn	r3, #0
	str	r3, [fp, #-68]
	mvn	r3, #0
	str	r3, [fp, #-88]
	ldr	r3, .L341+96
	mvn	r2, #0
	str	r2, [r3]
	ldr	r3, .L341+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	init_board
	bl	draw_initial_screen
.L329:
	ldr	r3, [fp, #-52]
	cmp	r3, #78
	beq	.L330
	ldr	r3, [fp, #-52]
	cmp	r3, #268
	bne	.L331
.L330:
	ldr	r2, .L341+4
	mov	r1, #10
	ldr	r0, .L341+168
	bl	ask_integer
	mov	r3, r0
	cmp	r3, #0
	beq	.L332
	mvn	r3, #0
	str	r3, [fp, #-68]
	mvn	r3, #0
	str	r3, [fp, #-88]
	ldr	r3, .L341+96
	mvn	r2, #0
	str	r2, [r3]
	ldr	r3, .L341+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	init_board
	bl	draw_initial_screen
	b	.L331
.L332:
	mov	r1, #9
	ldr	r0, .L341+172
	bl	update_status
.L331:
	ldr	r3, .L341+24
	ldr	r2, [r3]
	ldr	r3, .L341+56
	ldr	r3, [r3]
	cmp	r2, r3
	bne	.L333
	ldr	r3, [fp, #-52]
	cmp	r3, #97
	beq	.L334
	ldr	r3, [fp, #-52]
	cmp	r3, #65
	beq	.L334
.L333:
	ldr	r3, [fp, #-52]
	ldr	r2, .L341+176
	cmp	r3, r2
	bne	.L335
.L334:
	ldr	r3, .L341+108
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	movne	r3, #1
	moveq	r3, #0
	and	r3, r3, #255
	eor	r3, r3, #1
	and	r3, r3, #255
	and	r3, r3, #1
	and	r2, r3, #255
	ldr	r3, .L341+108
	strb	r2, [r3]
	ldr	r3, .L341+108
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	beq	.L336
	ldr	r3, .L341+180
	b	.L337
.L336:
	ldr	r3, .L341+184
.L337:
	mov	r1, #9
	mov	r0, r3
	bl	update_status
.L335:
	ldrb	r3, [fp, #-90]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L338
	bl	endwin
	mov	r3, #0
.L339:
	ldr	r2, .L341
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L340
	bl	__stack_chk_fail
.L340:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L342:
	.align	2
.L341:
	.word	.LC50
	.word	seed
	.word	dbgmode
	.word	.LC32
	.word	stdin
	.word	qwertzkeys
	.word	rowkeys
	.word	azertykeys
	.word	optarg
	.word	curtheme
	.word	.LC33
	.word	stderr
	.word	.LC34
	.word	.LC35
	.word	qwertykeys
	.word	themes
	.word	LINES
	.word	COLS
	.word	.LC36
	.word	screen
	.word	statusbar
	.word	wincount
	.word	cards
	.word	rows
	.word	selcard
	.word	animdash
	.word	250000
	.word	use_automoves
	.word	.LC37
	.word	.LC38
	.word	.LC27
	.word	.LC39
	.word	.LC40
	.word	.LC41
	.word	showcardnum
	.word	.LC42
	.word	267
	.word	.LC43
	.word	won_game
	.word	.LC44
	.word	266
	.word	.LC45
	.word	.LC46
	.word	.LC47
	.word	269
	.word	.LC48
	.word	.LC49
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
