	.file	"864852.c"
	.intel_syntax noprefix
	.section	.rodata
.LC0:
	.string	"1000\n"
.LC1:
	.string	"0100\n"
.LC2:
	.string	"0001\n"
.LC3:
	.string	"0010\n"
.LC4:
	.string	"0020\n"
.LC5:
	.string	"0000\n"
.LC6:
	.string	"0030\n"
	.text
	.section	.rodata
.LC9:
	.string	"Usage : %s stepfile\n"
.LC10:
	.string	"r"
.LC11:
	.string	"w"
.LC12:
	.string	"output.sm"
.LC13:
	.string	"dance-double"
.LC14:
	.string	"0000"
.LC15:
	.string	"%s"
	.data
	.align 32
.LC8:
	.quad	.LC0
	.quad	.LC1
	.quad	.LC0
	.quad	.LC1
	.quad	.LC2
	.quad	.LC1
	.quad	.LC2
	.quad	.LC1
	.quad	.LC0
	.quad	.LC1
	.quad	.LC0
	.quad	.LC1
	.quad	.LC0
	.quad	.LC3
	.quad	.LC0
	.quad	.LC3
	.quad	.LC2
	.quad	.LC3
	.quad	.LC2
	.quad	.LC3
	.quad	.LC0
	.quad	.LC3
	.quad	.LC0
	.quad	.LC1
	.quad	.LC0
	.quad	.LC1
	.quad	.LC0
	.quad	.LC3
	.quad	.LC1
	.quad	.LC2
	.quad	.LC0
	.quad	.LC1
	.quad	.LC4
	.quad	.LC5
	.quad	.LC5
	.quad	.LC5
	.quad	.LC5
	.quad	.LC5
	.quad	.LC5
	.quad	.LC5
	.quad	.LC5
	.quad	.LC5
	.quad	.LC5
	.quad	.LC6
	.text
	.globl	main
	.type	main, @function
main:
.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, 432
	mov	DWORD PTR -420[rbp], edi
	mov	QWORD PTR -432[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -400[rbp], 0
	mov	DWORD PTR -408[rbp], 0
	mov	edi, 100000
	call	malloc@PLT
	mov	QWORD PTR -392[rbp], rax
	lea	rax, -368[rbp]
	lea	rdx, .LC8[rip]
	mov	ecx, 44
	mov	rdi, rax
	mov	rsi, rdx
	rep movsq
	cmp	DWORD PTR -420[rbp], 1
	jg	.L2
	mov	rax, QWORD PTR -432[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC9[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	mov	rax, QWORD PTR -432[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC10[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -384[rbp], rax
	mov	rax, QWORD PTR -384[rbp]
	mov	edx, 2
	mov	esi, 0
	mov	rdi, rax
	call	fseek@PLT
	mov	rax, QWORD PTR -384[rbp]
	mov	rdi, rax
	call	ftell@PLT
	mov	DWORD PTR -396[rbp], eax
	mov	rax, QWORD PTR -384[rbp]
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	call	fseek@PLT
	mov	rdx, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 100000
	mov	rdi, rax
	call	fgets@PLT
	lea	rsi, .LC11[rip]
	lea	rdi, .LC12[rip]
	call	fopen@PLT
	mov	QWORD PTR -376[rbp], rax
	jmp	.L3
.L4:
	mov	rdx, QWORD PTR -376[rbp]
	mov	rax, QWORD PTR -392[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	fputs@PLT
	mov	rdx, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 100000
	mov	rdi, rax
	call	fgets@PLT
.L3:
	mov	rax, QWORD PTR -392[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 35
	je	.L4
	mov	rax, QWORD PTR -392[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 47
	jne	.L5
	mov	DWORD PTR -404[rbp], 0
	jmp	.L6
.L7:
	mov	rdx, QWORD PTR -376[rbp]
	mov	rax, QWORD PTR -392[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	fputs@PLT
	mov	rdx, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 100000
	mov	rdi, rax
	call	fgets@PLT
	add	DWORD PTR -404[rbp], 1
.L6:
	cmp	DWORD PTR -404[rbp], 6
	jle	.L7
.L5:
	mov	rax, QWORD PTR -392[rbp]
	mov	rdi, rax
	call	strlen@PLT
	neg	rax
	mov	rcx, rax
	mov	rax, QWORD PTR -384[rbp]
	mov	edx, 1
	mov	rsi, rcx
	mov	rdi, rax
	call	fseek@PLT
	jmp	.L8
.L13:
	mov	rax, QWORD PTR -392[rbp]
	lea	rsi, .LC13[rip]
	mov	rdi, rax
	call	strstr@PLT
	test	rax, rax
	jne	.L16
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 77
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 75
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 76
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 70
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 48
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 49
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 50
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 51
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	jne	.L11
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 52
	mov	rdi, rax
	call	strchr@PLT
	test	rax, rax
	je	.L12
.L11:
	mov	rax, QWORD PTR -392[rbp]
	mov	rdi, rax
	call	strlen@PLT
	cmp	rax, 6
	jne	.L12
	mov	rax, QWORD PTR -392[rbp]
	mov	edx, 4
	lea	rsi, .LC14[rip]
	mov	rdi, rax
	call	strncmp@PLT
	test	eax, eax
	je	.L12
	mov	eax, DWORD PTR -408[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 780903145
	shr	rdx, 32
	sar	edx, 3
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	imul	ecx, edx, 44
	sub	eax, ecx
	mov	edx, eax
	movsx	rax, edx
	mov	rax, QWORD PTR -368[rbp+rax*8]
	mov	rsi, rax
	lea	rdi, .LC15[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, DWORD PTR -408[rbp]
	movsx	rdx, eax
	imul	rdx, rdx, 780903145
	shr	rdx, 32
	sar	edx, 3
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	imul	ecx, edx, 44
	sub	eax, ecx
	mov	edx, eax
	movsx	rax, edx
	mov	rax, QWORD PTR -368[rbp+rax*8]
	mov	rdx, QWORD PTR -376[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	fputs@PLT
	add	DWORD PTR -408[rbp], 1
	jmp	.L8
.L12:
	mov	rax, QWORD PTR -392[rbp]
	mov	rsi, rax
	lea	rdi, .LC15[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rdx, QWORD PTR -376[rbp]
	mov	rax, QWORD PTR -392[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	fputs@PLT
	mov	rax, QWORD PTR -392[rbp]
	movzx	eax, BYTE PTR [rax]
	cmp	al, 59
	jne	.L8
	mov	DWORD PTR -408[rbp], 0
.L8:
	mov	rdx, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -392[rbp]
	mov	esi, 100000
	mov	rdi, rax
	call	fgets@PLT
	test	rax, rax
	jne	.L13
	jmp	.L10
.L16:
	nop
.L10:
	mov	rax, QWORD PTR -376[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	rax, QWORD PTR -384[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L15
	call	__stack_chk_fail@PLT
.L15:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.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	"864852.c"
	.section	.rodata
	.align	2
.LC0:
	.ascii	"1000\012\000"
	.align	2
.LC1:
	.ascii	"0100\012\000"
	.align	2
.LC2:
	.ascii	"0001\012\000"
	.align	2
.LC3:
	.ascii	"0010\012\000"
	.align	2
.LC4:
	.ascii	"0020\012\000"
	.align	2
.LC5:
	.ascii	"0000\012\000"
	.align	2
.LC6:
	.ascii	"0030\012\000"
	.text
	.section	.rodata
	.align	2
.LC9:
	.ascii	"Usage : %s stepfile\012\000"
	.align	2
.LC10:
	.ascii	"r\000"
	.align	2
.LC11:
	.ascii	"w\000"
	.align	2
.LC12:
	.ascii	"output.sm\000"
	.align	2
.LC13:
	.ascii	"dance-double\000"
	.align	2
.LC14:
	.ascii	"0000\000"
	.align	2
.LC15:
	.ascii	"%s\000"
	.align	2
.LC8:
	.word	.LC0
	.word	.LC1
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC1
	.word	.LC2
	.word	.LC1
	.word	.LC0
	.word	.LC1
	.word	.LC0
	.word	.LC1
	.word	.LC0
	.word	.LC3
	.word	.LC0
	.word	.LC3
	.word	.LC2
	.word	.LC3
	.word	.LC2
	.word	.LC3
	.word	.LC0
	.word	.LC3
	.word	.LC0
	.word	.LC1
	.word	.LC0
	.word	.LC1
	.word	.LC0
	.word	.LC3
	.word	.LC1
	.word	.LC2
	.word	.LC0
	.word	.LC1
	.word	.LC4
	.word	.LC5
	.word	.LC5
	.word	.LC5
	.word	.LC5
	.word	.LC5
	.word	.LC5
	.word	.LC5
	.word	.LC5
	.word	.LC5
	.word	.LC5
	.word	.LC6
	.align	2
.LC16:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 216
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #216
	str	r0, [fp, #-216]
	str	r1, [fp, #-220]
	ldr	r3, .L17
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-204]
	mov	r3, #0
	str	r3, [fp, #-212]
	ldr	r0, .L17+4
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-200]
	ldr	r2, .L17+8
	sub	r3, fp, #184
	mov	r1, r2
	mov	r2, #176
	mov	r0, r3
	bl	memcpy
	ldr	r3, [fp, #-216]
	cmp	r3, #1
	bgt	.L2
	ldr	r3, [fp, #-220]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L17+12
	bl	printf
	mov	r0, #1
	bl	exit
.L2:
	ldr	r3, [fp, #-220]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldr	r1, .L17+16
	mov	r0, r3
	bl	fopen
	str	r0, [fp, #-196]
	mov	r2, #2
	mov	r1, #0
	ldr	r0, [fp, #-196]
	bl	fseek
	ldr	r0, [fp, #-196]
	bl	ftell
	str	r0, [fp, #-192]
	mov	r2, #0
	mov	r1, #0
	ldr	r0, [fp, #-196]
	bl	fseek
	ldr	r2, [fp, #-196]
	ldr	r1, .L17+4
	ldr	r0, [fp, #-200]
	bl	fgets
	ldr	r1, .L17+20
	ldr	r0, .L17+24
	bl	fopen
	str	r0, [fp, #-188]
	b	.L3
.L4:
	ldr	r1, [fp, #-188]
	ldr	r0, [fp, #-200]
	bl	fputs
	ldr	r2, [fp, #-196]
	ldr	r1, .L17+4
	ldr	r0, [fp, #-200]
	bl	fgets
.L3:
	ldr	r3, [fp, #-200]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #35
	beq	.L4
	ldr	r3, [fp, #-200]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #47
	bne	.L5
	mov	r3, #0
	str	r3, [fp, #-208]
	b	.L6
.L7:
	ldr	r1, [fp, #-188]
	ldr	r0, [fp, #-200]
	bl	fputs
	ldr	r2, [fp, #-196]
	ldr	r1, .L17+4
	ldr	r0, [fp, #-200]
	bl	fgets
	ldr	r3, [fp, #-208]
	add	r3, r3, #1
	str	r3, [fp, #-208]
.L6:
	ldr	r3, [fp, #-208]
	cmp	r3, #6
	ble	.L7
.L5:
	ldr	r0, [fp, #-200]
	bl	strlen
	mov	r3, r0
	rsb	r3, r3, #0
	mov	r2, #1
	mov	r1, r3
	ldr	r0, [fp, #-196]
	bl	fseek
	b	.L8
.L13:
	ldr	r1, .L17+28
	ldr	r0, [fp, #-200]
	bl	strstr
	mov	r3, r0
	cmp	r3, #0
	bne	.L16
	mov	r1, #77
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r1, #75
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r1, #76
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r1, #70
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r1, #48
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r1, #49
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r1, #50
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r1, #51
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	mov	r1, #52
	ldr	r0, [fp, #-200]
	bl	strchr
	mov	r3, r0
	cmp	r3, #0
	beq	.L12
.L11:
	ldr	r0, [fp, #-200]
	bl	strlen
	mov	r3, r0
	cmp	r3, #6
	bne	.L12
	mov	r2, #4
	ldr	r1, .L17+32
	ldr	r0, [fp, #-200]
	bl	strncmp
	mov	r3, r0
	cmp	r3, #0
	beq	.L12
	ldr	r1, [fp, #-212]
	ldr	r3, .L17+36
	smull	r2, r3, r1, r3
	asr	r2, r3, #3
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	sub	r2, r1, r3
	lsl	r3, r2, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-180]
	mov	r1, r3
	ldr	r0, .L17+40
	bl	printf
	ldr	r1, [fp, #-212]
	ldr	r3, .L17+36
	smull	r2, r3, r1, r3
	asr	r2, r3, #3
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #1
	add	r3, r3, r2
	lsl	r3, r3, #2
	sub	r2, r1, r3
	lsl	r3, r2, #2
	sub	r2, fp, #4
	add	r3, r2, r3
	ldr	r3, [r3, #-180]
	ldr	r1, [fp, #-188]
	mov	r0, r3
	bl	fputs
	ldr	r3, [fp, #-212]
	add	r3, r3, #1
	str	r3, [fp, #-212]
	b	.L8
.L12:
	ldr	r1, [fp, #-200]
	ldr	r0, .L17+40
	bl	printf
	ldr	r1, [fp, #-188]
	ldr	r0, [fp, #-200]
	bl	fputs
	ldr	r3, [fp, #-200]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #59
	bne	.L8
	mov	r3, #0
	str	r3, [fp, #-212]
.L8:
	ldr	r2, [fp, #-196]
	ldr	r1, .L17+4
	ldr	r0, [fp, #-200]
	bl	fgets
	mov	r3, r0
	cmp	r3, #0
	bne	.L13
	b	.L10
.L16:
	nop
.L10:
	ldr	r0, [fp, #-188]
	bl	fclose
	ldr	r0, [fp, #-196]
	bl	fclose
	mov	r3, #0
	ldr	r2, .L17
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L15
	bl	__stack_chk_fail
.L15:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L18:
	.align	2
.L17:
	.word	.LC16
	.word	100000
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.word	780903145
	.word	.LC15
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
