	.file	"565689.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"Usage: %s <file>\n"
	.align 8
.LC1:
	.string	"Error: Size exceeding 7 digits"
.LC2:
	.string	"r+b"
	.align 8
.LC3:
	.string	"Error: Unable to open %s for reading and writing"
.LC4:
	.string	"%7li"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 256
	mov	DWORD PTR -244[rbp], edi
	mov	QWORD PTR -256[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	movabs	rax, 8461530464948676692
	movabs	rdx, 8675375933067387244
	mov	QWORD PTR -64[rbp], rax
	mov	QWORD PTR -56[rbp], rdx
	movabs	rax, 7308324466020672357
	movabs	rdx, 8295737305619064864
	mov	QWORD PTR -48[rbp], rax
	mov	QWORD PTR -40[rbp], rdx
	movabs	rax, 5629612161684044393
	mov	QWORD PTR -32[rbp], rax
	mov	BYTE PTR -24[rbp], 0
	mov	rax, QWORD PTR -256[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rdx, -224[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	stat@PLT
	cmp	eax, -1
	jne	.L2
	mov	rax, QWORD PTR -256[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, -1
	jmp	.L11
.L2:
	mov	rax, QWORD PTR -176[rbp]
	cmp	rax, 9999999
	jle	.L4
	lea	rdi, .LC1[rip]
	call	puts@PLT
	mov	eax, -1
	jmp	.L11
.L4:
	mov	rax, QWORD PTR -256[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -232[rbp], rax
	cmp	QWORD PTR -232[rbp], 0
	jne	.L5
	mov	rax, QWORD PTR -256[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, -1
	jmp	.L11
.L5:
	mov	rdx, QWORD PTR -176[rbp]
	lea	rax, -72[rbp]
	lea	rsi, .LC4[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	mov	DWORD PTR -236[rbp], 0
	mov	rax, QWORD PTR -232[rbp]
	mov	rdi, rax
	call	getc@PLT
	mov	DWORD PTR -240[rbp], eax
	jmp	.L6
.L10:
	mov	eax, DWORD PTR -236[rbp]
	cdqe
	movzx	eax, BYTE PTR -64[rbp+rax]
	movsx	eax, al
	cmp	DWORD PTR -240[rbp], eax
	jne	.L7
	add	DWORD PTR -236[rbp], 1
	jmp	.L8
.L7:
	mov	DWORD PTR -236[rbp], 0
.L8:
	mov	eax, DWORD PTR -236[rbp]
	cdqe
	movzx	eax, BYTE PTR -64[rbp+rax]
	cmp	al, 78
	jne	.L9
	mov	rax, QWORD PTR -232[rbp]
	mov	edx, 1
	mov	esi, 0
	mov	rdi, rax
	call	fseek@PLT
	mov	rdx, QWORD PTR -232[rbp]
	lea	rax, -72[rbp]
	mov	rcx, rdx
	mov	edx, 7
	mov	esi, 1
	mov	rdi, rax
	call	fwrite@PLT
	mov	rax, QWORD PTR -232[rbp]
	mov	rdi, rax
	call	fflush@PLT
.L9:
	mov	rax, QWORD PTR -232[rbp]
	mov	rdi, rax
	call	getc@PLT
	mov	DWORD PTR -240[rbp], eax
.L6:
	cmp	DWORD PTR -240[rbp], -1
	jne	.L10
	mov	rax, QWORD PTR -232[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	eax, 0
.L11:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L12
	call	__stack_chk_fail@PLT
.L12:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.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	"565689.c"
	.text
	.section	.rodata
	.align	2
.LC1:
	.ascii	"Usage: %s <file>\012\000"
	.align	2
.LC2:
	.ascii	"Error: Size exceeding 7 digits\000"
	.align	2
.LC3:
	.ascii	"r+b\000"
	.align	2
.LC4:
	.ascii	"Error: Unable to open %s for reading and writing\000"
	.align	2
.LC5:
	.ascii	"%7li\000"
	.align	2
.LC0:
	.ascii	"This emulator executable has a size of N\000"
	.align	2
.LC6:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 168
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #168
	str	r0, [fp, #-168]
	str	r1, [fp, #-172]
	ldr	r3, .L13
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, .L13+4
	sub	ip, fp, #52
	mov	lr, r3
	ldmia	lr!, {r0, r1, r2, r3}
	stmia	ip!, {r0, r1, r2, r3}
	ldmia	lr!, {r0, r1, r2, r3}
	stmia	ip!, {r0, r1, r2, r3}
	ldm	lr, {r0, r1, r2}
	stmia	ip!, {r0, r1}
	strb	r2, [ip]
	ldr	r3, [fp, #-172]
	add	r3, r3, #4
	ldr	r3, [r3]
	sub	r2, fp, #148
	mov	r1, r2
	mov	r0, r3
	bl	stat
	mov	r3, r0
	cmn	r3, #1
	bne	.L2
	ldr	r3, [fp, #-172]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L13+8
	bl	printf
	mvn	r3, #0
	b	.L11
.L2:
	ldr	r3, [fp, #-104]
	ldr	r2, .L13+12
	cmp	r3, r2
	ble	.L4
	ldr	r0, .L13+16
	bl	puts
	mvn	r3, #0
	b	.L11
.L4:
	ldr	r3, [fp, #-172]
	add	r3, r3, #4
	ldr	r3, [r3]
	ldr	r1, .L13+20
	mov	r0, r3
	bl	fopen
	str	r0, [fp, #-152]
	ldr	r3, [fp, #-152]
	cmp	r3, #0
	bne	.L5
	ldr	r3, [fp, #-172]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L13+24
	bl	printf
	mvn	r3, #0
	b	.L11
.L5:
	ldr	r2, [fp, #-104]
	sub	r3, fp, #60
	ldr	r1, .L13+28
	mov	r0, r3
	bl	sprintf
	mov	r3, #0
	str	r3, [fp, #-156]
	ldr	r0, [fp, #-152]
	bl	getc
	str	r0, [fp, #-160]
	b	.L6
.L10:
	sub	r2, fp, #52
	ldr	r3, [fp, #-156]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r2, r3
	ldr	r3, [fp, #-160]
	cmp	r3, r2
	bne	.L7
	ldr	r3, [fp, #-156]
	add	r3, r3, #1
	str	r3, [fp, #-156]
	b	.L8
.L7:
	mov	r3, #0
	str	r3, [fp, #-156]
.L8:
	sub	r2, fp, #52
	ldr	r3, [fp, #-156]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #78
	bne	.L9
	mov	r2, #1
	mov	r1, #0
	ldr	r0, [fp, #-152]
	bl	fseek
	sub	r0, fp, #60
	ldr	r3, [fp, #-152]
	mov	r2, #7
	mov	r1, #1
	bl	fwrite
	ldr	r0, [fp, #-152]
	bl	fflush
.L9:
	ldr	r0, [fp, #-152]
	bl	getc
	str	r0, [fp, #-160]
.L6:
	ldr	r3, [fp, #-160]
	cmn	r3, #1
	bne	.L10
	ldr	r0, [fp, #-152]
	bl	fclose
	mov	r3, #0
.L11:
	ldr	r2, .L13
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L12
	bl	__stack_chk_fail
.L12:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L14:
	.align	2
.L13:
	.word	.LC6
	.word	.LC0
	.word	.LC1
	.word	9999999
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
