	.file	"323994.c"
	.intel_syntax noprefix
	.text
	.globl	FN
	.section	.rodata
	.align 4
	.type	FN, @object
	.size	FN, 4
FN:
	.long	81585
.LC0:
	.string	"Invalid number of arguments!"
.LC1:
	.string	"Invalid open"
.LC2:
	.string	"Invalid lseek"
	.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
	lea	r11, -65536[rsp]
.LPSRL0:
	sub	rsp, 4096
	or	DWORD PTR [rsp], 0
	cmp	rsp, r11
	jne	.LPSRL0
	sub	rsp, 64
	mov	DWORD PTR -65588[rbp], edi
	mov	QWORD PTR -65600[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -65588[rbp], 4
	je	.L2
	lea	rdi, .LC0[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	mov	rax, QWORD PTR -65600[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR -65572[rbp], eax
	mov	rax, QWORD PTR -65600[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -65568[rbp], eax
	cmp	DWORD PTR -65568[rbp], -1
	jne	.L3
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L3:
	mov	rax, QWORD PTR -65600[rbp]
	add	rax, 24
	mov	rax, QWORD PTR [rax]
	mov	esi, 1
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -65564[rbp], eax
	cmp	DWORD PTR -65564[rbp], -1
	jne	.L4
	lea	rdi, .LC1[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L4:
	mov	ecx, 81585
	movsx	rax, ecx
	imul	rax, rax, -2078209981
	shr	rax, 32
	add	eax, ecx
	sar	eax, 4
	mov	esi, ecx
	sar	esi, 31
	sub	eax, esi
	mov	edx, eax
	mov	eax, edx
	sal	eax, 5
	sub	eax, edx
	mov	edx, ecx
	sub	edx, eax
	mov	eax, DWORD PTR -65572[rbp]
	add	eax, edx
	add	eax, 5
	mov	DWORD PTR -65560[rbp], eax
	mov	eax, DWORD PTR -65560[rbp]
	movsx	rcx, eax
	mov	eax, DWORD PTR -65564[rbp]
	mov	edx, 2
	mov	rsi, rcx
	mov	edi, eax
	call	lseek@PLT
	cmp	rax, -1
	jne	.L6
	lea	rdi, .LC2[rip]
	call	perror@PLT
	mov	edi, 1
	call	exit@PLT
.L7:
	mov	eax, DWORD PTR -65556[rbp]
	movsx	rdx, eax
	lea	rcx, -65552[rbp]
	mov	eax, DWORD PTR -65564[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
.L6:
	lea	rcx, -65552[rbp]
	mov	eax, DWORD PTR -65568[rbp]
	mov	edx, 8192
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -65556[rbp], eax
	cmp	DWORD PTR -65556[rbp], 0
	jg	.L7
	mov	eax, DWORD PTR -65568[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, DWORD PTR -65564[rbp]
	mov	edi, eax
	call	close@PLT
	mov	edi, 0
	call	exit@PLT
	.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	"323994.c"
	.text
	.global	FN
	.section	.rodata
	.align	2
	.type	FN, %object
	.size	FN, 4
FN:
	.word	81585
	.align	2
.LC0:
	.ascii	"Invalid number of arguments!\000"
	.align	2
.LC1:
	.ascii	"Invalid open\000"
	.align	2
.LC2:
	.ascii	"Invalid lseek\000"
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 32800
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #32768
	sub	sp, sp, #36
	sub	r3, fp, #32768
	sub	r3, r3, #12
	str	r0, [r3, #-28]
	sub	r3, fp, #32768
	sub	r3, r3, #12
	str	r1, [r3, #-32]
	ldr	r3, .L9
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r3, [r3, #-28]
	cmp	r3, #4
	beq	.L2
	ldr	r0, .L9+4
	bl	perror
	mov	r0, #1
	bl	exit
.L2:
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r3, [r3, #-32]
	add	r3, r3, #4
	ldr	r3, [r3]
	sub	r2, fp, #32768
	sub	r2, r2, #12
	mov	r4, r2
	mov	r0, r3
	bl	atoi
	str	r0, [r4, #-24]
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r3, [r3, #-32]
	add	r3, r3, #8
	ldr	r3, [r3]
	sub	r2, fp, #32768
	sub	r2, r2, #12
	mov	r4, r2
	mov	r1, #0
	mov	r0, r3
	bl	open
	str	r0, [r4, #-20]
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r3, [r3, #-20]
	cmn	r3, #1
	bne	.L3
	ldr	r0, .L9+8
	bl	perror
	mov	r0, #1
	bl	exit
.L3:
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r3, [r3, #-32]
	add	r3, r3, #12
	ldr	r3, [r3]
	sub	r2, fp, #32768
	sub	r2, r2, #12
	mov	r4, r2
	mov	r1, #1
	mov	r0, r3
	bl	open
	str	r0, [r4, #-16]
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r3, [r3, #-16]
	cmn	r3, #1
	bne	.L4
	ldr	r0, .L9+8
	bl	perror
	mov	r0, #1
	bl	exit
.L4:
	ldr	r2, .L9+12
	ldr	r3, .L9+16
	smull	r1, r3, r2, r3
	add	r3, r3, r2
	asr	r1, r3, #4
	asr	r3, r2, #31
	sub	r1, r1, r3
	mov	r3, r1
	lsl	r3, r3, #5
	sub	r3, r3, r1
	sub	r1, r2, r3
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r3, [r3, #-24]
	add	r3, r1, r3
	sub	r2, fp, #32768
	sub	r2, r2, #12
	add	r3, r3, #5
	str	r3, [r2, #-12]
	sub	r3, fp, #32768
	sub	r3, r3, #12
	mov	r1, r3
	sub	r3, fp, #32768
	sub	r3, r3, #12
	mov	r2, #2
	ldr	r1, [r1, #-12]
	ldr	r0, [r3, #-16]
	bl	lseek
	mov	r3, r0
	cmn	r3, #1
	bne	.L6
	ldr	r0, .L9+20
	bl	perror
	mov	r0, #1
	bl	exit
.L7:
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r2, [r3, #-8]
	sub	r3, fp, #32768
	sub	r3, r3, #12
	sub	r3, r3, #4
	sub	r1, fp, #32768
	sub	r1, r1, #12
	mov	r0, r1
	mov	r1, r3
	ldr	r0, [r0, #-16]
	bl	write
.L6:
	sub	r3, fp, #32768
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #32768
	sub	r3, r3, #12
	sub	r3, r3, #4
	sub	r2, fp, #32768
	sub	r2, r2, #12
	mov	r0, r2
	mov	r2, #8192
	mov	r1, r3
	ldr	r0, [r0, #-20]
	bl	read
	str	r0, [r4, #-8]
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r3, [r3, #-8]
	cmp	r3, #0
	bgt	.L7
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r0, [r3, #-20]
	bl	close
	sub	r3, fp, #32768
	sub	r3, r3, #12
	ldr	r0, [r3, #-16]
	bl	close
	mov	r0, #0
	bl	exit
.L10:
	.align	2
.L9:
	.word	.LC3
	.word	.LC0
	.word	.LC1
	.word	81585
	.word	-2078209981
	.word	.LC2
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
