	.file	"13793.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"stop"
.LC1:
	.string	"save"
.LC2:
	.string	"w"
.LC3:
	.string	"gnugo.dat"
.LC4:
	.string	"%d %d %d "
.LC5:
	.string	"%d "
.LC6:
	.string	"pass"
.LC7:
	.string	"illegal move !"
.LC8:
	.string	"your move? "
.LC9:
	.string	"%s"
	.text
	.globl	getmove
	.type	getmove, @function
getmove:
.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, 48
	mov	QWORD PTR -24[rbp], rdi
	mov	QWORD PTR -32[rbp], rsi
	mov	QWORD PTR -40[rbp], rdx
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L2
	mov	DWORD PTR play[rip], 0
	jmp	.L14
.L2:
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L4
	lea	rsi, .LC2[rip]
	lea	rdi, .LC3[rip]
	call	fopen@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	DWORD PTR -16[rbp], 0
	jmp	.L5
.L8:
	mov	DWORD PTR -12[rbp], 0
	jmp	.L6
.L7:
	mov	eax, DWORD PTR -12[rbp]
	movsx	rcx, eax
	mov	eax, DWORD PTR -16[rbp]
	movsx	rdx, eax
	mov	rax, rdx
	sal	rax, 3
	add	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, [rax+rcx]
	lea	rax, p[rip]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movzx	eax, al
	mov	rdx, QWORD PTR -8[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	fputc@PLT
	add	DWORD PTR -12[rbp], 1
.L6:
	cmp	DWORD PTR -12[rbp], 18
	jle	.L7
	add	DWORD PTR -16[rbp], 1
.L5:
	cmp	DWORD PTR -16[rbp], 18
	jle	.L8
	mov	esi, DWORD PTR uk[rip]
	mov	ecx, DWORD PTR mk[rip]
	mov	edx, DWORD PTR mymove[rip]
	mov	rax, QWORD PTR -8[rbp]
	mov	r8d, esi
	lea	rsi, .LC4[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	DWORD PTR -16[rbp], 0
	jmp	.L9
.L10:
	mov	eax, DWORD PTR -16[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, opn[rip]
	mov	edx, DWORD PTR [rdx+rax]
	mov	rax, QWORD PTR -8[rbp]
	lea	rsi, .LC5[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	add	DWORD PTR -16[rbp], 1
.L9:
	cmp	DWORD PTR -16[rbp], 8
	jle	.L10
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	DWORD PTR play[rip], -1
	jmp	.L14
.L4:
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, .LC6[rip]
	mov	rdi, rax
	call	strcmp@PLT
	test	eax, eax
	jne	.L11
	mov	eax, DWORD PTR pass[rip]
	add	eax, 1
	mov	DWORD PTR pass[rip], eax
	mov	rax, QWORD PTR -32[rbp]
	mov	DWORD PTR [rax], -1
	jmp	.L14
.L11:
	mov	DWORD PTR pass[rip], 0
	mov	rdx, QWORD PTR -40[rbp]
	mov	rcx, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	getij@PLT
	test	eax, eax
	je	.L12
	mov	rax, QWORD PTR -32[rbp]
	mov	edx, DWORD PTR [rax]
	mov	rax, QWORD PTR -40[rbp]
	mov	eax, DWORD PTR [rax]
	movsx	rcx, eax
	movsx	rdx, edx
	mov	rax, rdx
	sal	rax, 3
	add	rax, rdx
	add	rax, rax
	add	rax, rdx
	lea	rdx, [rax+rcx]
	lea	rax, p[rip]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L12
	mov	rax, QWORD PTR -40[rbp]
	mov	edx, DWORD PTR [rax]
	mov	rax, QWORD PTR -32[rbp]
	mov	eax, DWORD PTR [rax]
	mov	esi, edx
	mov	edi, eax
	call	suicide@PLT
	test	eax, eax
	je	.L14
.L12:
	mov	rax, QWORD PTR stdin[rip]
	mov	rdi, rax
	call	feof@PLT
	test	eax, eax
	je	.L13
	mov	edi, 1
	call	exit@PLT
.L13:
	lea	rdi, .LC7[rip]
	call	puts@PLT
	lea	rdi, .LC8[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rax
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	rdx, QWORD PTR -40[rbp]
	mov	rcx, QWORD PTR -32[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	getmove
.L14:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	getmove, .-getmove
	.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	"13793.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"stop\000"
	.align	2
.LC1:
	.ascii	"save\000"
	.align	2
.LC2:
	.ascii	"w\000"
	.align	2
.LC3:
	.ascii	"gnugo.dat\000"
	.align	2
.LC4:
	.ascii	"%d %d %d \000"
	.align	2
.LC5:
	.ascii	"%d \000"
	.align	2
.LC6:
	.ascii	"pass\000"
	.align	2
.LC7:
	.ascii	"illegal move !\000"
	.align	2
.LC8:
	.ascii	"your move? \000"
	.align	2
.LC9:
	.ascii	"%s\000"
	.text
	.align	2
	.global	getmove
	.syntax unified
	.arm
	.fpu softvfp
	.type	getmove, %function
getmove:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #40
	str	r0, [fp, #-24]
	str	r1, [fp, #-28]
	str	r2, [fp, #-32]
	ldr	r1, .L15
	ldr	r0, [fp, #-24]
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L2
	ldr	r3, .L15+4
	mov	r2, #0
	str	r2, [r3]
	b	.L14
.L2:
	ldr	r1, .L15+8
	ldr	r0, [fp, #-24]
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L4
	ldr	r1, .L15+12
	ldr	r0, .L15+16
	bl	fopen
	str	r0, [fp, #-8]
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L5
.L8:
	mov	r3, #0
	str	r3, [fp, #-12]
	b	.L6
.L7:
	ldr	r1, .L15+20
	ldr	r2, [fp, #-16]
	mov	r3, r2
	lsl	r3, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	add	r2, r1, r3
	ldr	r3, [fp, #-12]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	ldr	r1, [fp, #-8]
	mov	r0, r3
	bl	fputc
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L6:
	ldr	r3, [fp, #-12]
	cmp	r3, #18
	ble	.L7
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L5:
	ldr	r3, [fp, #-16]
	cmp	r3, #18
	ble	.L8
	ldr	r3, .L15+24
	ldr	r2, [r3]
	ldr	r3, .L15+28
	ldr	r1, [r3]
	ldr	r3, .L15+32
	ldr	r3, [r3]
	str	r3, [sp]
	mov	r3, r1
	ldr	r1, .L15+36
	ldr	r0, [fp, #-8]
	bl	fprintf
	mov	r3, #0
	str	r3, [fp, #-16]
	b	.L9
.L10:
	ldr	r2, .L15+40
	ldr	r3, [fp, #-16]
	ldr	r3, [r2, r3, lsl #2]
	mov	r2, r3
	ldr	r1, .L15+44
	ldr	r0, [fp, #-8]
	bl	fprintf
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L9:
	ldr	r3, [fp, #-16]
	cmp	r3, #8
	ble	.L10
	ldr	r0, [fp, #-8]
	bl	fclose
	ldr	r3, .L15+4
	mvn	r2, #0
	str	r2, [r3]
	b	.L14
.L4:
	ldr	r1, .L15+48
	ldr	r0, [fp, #-24]
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	ldr	r3, .L15+52
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L15+52
	str	r3, [r2]
	ldr	r3, [fp, #-28]
	mvn	r2, #0
	str	r2, [r3]
	b	.L14
.L11:
	ldr	r3, .L15+52
	mov	r2, #0
	str	r2, [r3]
	ldr	r2, [fp, #-32]
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	bl	getij
	mov	r3, r0
	cmp	r3, #0
	beq	.L12
	ldr	r3, [fp, #-28]
	ldr	r2, [r3]
	ldr	r3, [fp, #-32]
	ldr	r1, [r3]
	ldr	r0, .L15+20
	mov	r3, r2
	lsl	r3, r3, #3
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	add	r3, r0, r3
	add	r3, r3, r1
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L12
	ldr	r3, [fp, #-28]
	ldr	r2, [r3]
	ldr	r3, [fp, #-32]
	ldr	r3, [r3]
	mov	r1, r3
	mov	r0, r2
	bl	suicide
	mov	r3, r0
	cmp	r3, #0
	beq	.L14
.L12:
	ldr	r3, .L15+56
	ldr	r3, [r3]
	mov	r0, r3
	bl	feof
	mov	r3, r0
	cmp	r3, #0
	beq	.L13
	mov	r0, #1
	bl	exit
.L13:
	ldr	r0, .L15+60
	bl	puts
	ldr	r0, .L15+64
	bl	printf
	ldr	r1, [fp, #-24]
	ldr	r0, .L15+68
	bl	__isoc99_scanf
	ldr	r2, [fp, #-32]
	ldr	r1, [fp, #-28]
	ldr	r0, [fp, #-24]
	bl	getmove
.L14:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L16:
	.align	2
.L15:
	.word	.LC0
	.word	play
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	p
	.word	mymove
	.word	mk
	.word	uk
	.word	.LC4
	.word	opn
	.word	.LC5
	.word	.LC6
	.word	pass
	.word	stdin
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.size	getmove, .-getmove
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
