	.file	"378182.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"r"
.LC1:
	.string	"I can't open the file: %s\n"
	.text
	.globl	readfile
	.type	readfile, @function
readfile:
.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 -40[rbp], rdi
	mov	QWORD PTR -48[rbp], rsi
	mov	DWORD PTR -20[rbp], 0
	mov	rax, QWORD PTR -40[rbp]
	lea	rsi, .LC0[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -16[rbp], rax
	cmp	QWORD PTR -16[rbp], 0
	jne	.L2
	mov	rax, QWORD PTR stderr[rip]
	mov	rdx, QWORD PTR -40[rbp]
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	mov	rax, QWORD PTR -16[rbp]
	mov	edx, 2
	mov	esi, 0
	mov	rdi, rax
	call	fseek@PLT
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	ftell@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -16[rbp]
	mov	edx, 0
	mov	esi, 0
	mov	rdi, rax
	call	fseek@PLT
	mov	rax, QWORD PTR -8[rbp]
	add	rax, 1
	mov	rdi, rax
	call	malloc@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR -48[rbp]
	mov	QWORD PTR [rax], rdx
	jmp	.L3
.L5:
	cmp	BYTE PTR -21[rbp], 97
	je	.L4
	cmp	BYTE PTR -21[rbp], 99
	je	.L4
	cmp	BYTE PTR -21[rbp], 103
	je	.L4
	cmp	BYTE PTR -21[rbp], 116
	je	.L4
	cmp	BYTE PTR -21[rbp], 65
	je	.L4
	cmp	BYTE PTR -21[rbp], 67
	je	.L4
	cmp	BYTE PTR -21[rbp], 71
	je	.L4
	cmp	BYTE PTR -21[rbp], 84
	jne	.L3
.L4:
	mov	rax, QWORD PTR -48[rbp]
	mov	rdx, QWORD PTR [rax]
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	add	rdx, rax
	movzx	eax, BYTE PTR -21[rbp]
	mov	BYTE PTR [rdx], al
	add	DWORD PTR -20[rbp], 1
.L3:
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	fgetc@PLT
	mov	BYTE PTR -21[rbp], al
	cmp	BYTE PTR -21[rbp], -1
	jne	.L5
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	readfile, .-readfile
	.globl	BF
	.type	BF, @function
BF:
.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, 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	QWORD PTR -16[rbp], 0
	mov	rax, QWORD PTR -40[rbp]
	mov	QWORD PTR -8[rbp], rax
	jmp	.L8
.L10:
	mov	edx, DWORD PTR -28[rbp]
	mov	rcx, QWORD PTR -40[rbp]
	mov	rax, QWORD PTR -24[rbp]
	mov	rsi, rcx
	mov	rdi, rax
	call	memcmp@PLT
	test	eax, eax
	jne	.L9
	add	QWORD PTR -16[rbp], 1
.L9:
	add	QWORD PTR -40[rbp], 1
.L8:
	mov	rax, QWORD PTR -40[rbp]
	movzx	eax, BYTE PTR [rax]
	test	al, al
	jne	.L10
	nop
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	BF, .-BF
	.section	.rodata
.LC2:
	.string	"%s"
.LC3:
	.string	"pattern: %s \n"
.LC5:
	.string	"Nombre de segons: %f s\n"
	.text
	.globl	main
	.type	main, @function
main:
.LFB8:
	.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, 584
	.cfi_offset 3, -24
	mov	DWORD PTR -580[rbp], edi
	mov	QWORD PTR -592[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -592[rbp]
	add	rax, 16
	mov	rdx, QWORD PTR [rax]
	lea	rax, -544[rbp]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	mov	rax, QWORD PTR -592[rbp]
	add	rax, 8
	mov	rdx, QWORD PTR [rax]
	lea	rax, -288[rbp]
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rax, -544[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rdx, -560[rbp]
	lea	rax, -288[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	readfile
	mov	DWORD PTR -564[rbp], eax
	call	clock@PLT
	mov	QWORD PTR -552[rbp], rax
	mov	rbx, QWORD PTR -560[rbp]
	lea	rax, -544[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	esi, eax
	mov	edx, DWORD PTR -564[rbp]
	lea	rax, -544[rbp]
	mov	ecx, edx
	mov	rdx, rbx
	mov	rdi, rax
	call	BF
	call	clock@PLT
	sub	rax, QWORD PTR -552[rbp]
	pxor	xmm0, xmm0
	cvtsi2sd	xmm0, rax
	movsd	xmm1, QWORD PTR .LC4[rip]
	divsd	xmm0, xmm1
	movq	rax, xmm0
	movq	xmm0, rax
	lea	rdi, .LC5[rip]
	mov	eax, 1
	call	printf@PLT
	mov	rax, QWORD PTR -560[rbp]
	mov	rdi, rax
	call	free@PLT
	mov	eax, 0
	mov	rcx, QWORD PTR -24[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	main, .-main
	.section	.rodata
	.align 8
.LC4:
	.long	0
	.long	1093567616
	.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	"378182.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"r\000"
	.align	2
.LC1:
	.ascii	"I can't open the file: %s\012\000"
	.text
	.align	2
	.global	readfile
	.syntax unified
	.arm
	.fpu softvfp
	.type	readfile, %function
readfile:
	@ 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, #-24]
	str	r1, [fp, #-28]
	mov	r3, #0
	str	r3, [fp, #-16]
	ldr	r1, .L7
	ldr	r0, [fp, #-24]
	bl	fopen
	str	r0, [fp, #-12]
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	bne	.L2
	ldr	r3, .L7+4
	ldr	r3, [r3]
	ldr	r2, [fp, #-24]
	ldr	r1, .L7+8
	mov	r0, r3
	bl	fprintf
	mov	r0, #1
	bl	exit
.L2:
	mov	r2, #2
	mov	r1, #0
	ldr	r0, [fp, #-12]
	bl	fseek
	ldr	r0, [fp, #-12]
	bl	ftell
	str	r0, [fp, #-8]
	mov	r2, #0
	mov	r1, #0
	ldr	r0, [fp, #-12]
	bl	fseek
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	mov	r0, r3
	bl	malloc
	mov	r3, r0
	mov	r2, r3
	ldr	r3, [fp, #-28]
	str	r2, [r3]
	b	.L3
.L6:
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #99
	beq	.L4
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #103
	beq	.L4
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #116
	beq	.L4
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #65
	beq	.L4
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #67
	beq	.L4
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #71
	beq	.L4
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #84
	bne	.L3
.L4:
	ldr	r3, [fp, #-28]
	ldr	r2, [r3]
	ldr	r3, [fp, #-16]
	add	r3, r2, r3
	ldrb	r2, [fp, #-17]
	strb	r2, [r3]
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L3:
	ldr	r0, [fp, #-12]
	bl	fgetc
	mov	r3, r0
	strb	r3, [fp, #-17]
	ldrb	r3, [fp, #-17]	@ zero_extendqisi2
	cmp	r3, #97
	beq	.L4
	b	.L6
.L8:
	.align	2
.L7:
	.word	.LC0
	.word	stderr
	.word	.LC1
	.size	readfile, .-readfile
	.align	2
	.global	BF
	.syntax unified
	.arm
	.fpu softvfp
	.type	BF, %function
BF:
	@ 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]
	str	r3, [fp, #-28]
	mov	r3, #0
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-24]
	str	r3, [fp, #-8]
	b	.L10
.L12:
	ldr	r2, [fp, #-20]
	ldr	r1, [fp, #-24]
	ldr	r0, [fp, #-16]
	bl	memcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L11
	ldr	r3, [fp, #-12]
	add	r3, r3, #1
	str	r3, [fp, #-12]
.L11:
	ldr	r3, [fp, #-24]
	add	r3, r3, #1
	str	r3, [fp, #-24]
.L10:
	ldr	r3, [fp, #-24]
	ldrb	r3, [r3]	@ zero_extendqisi2
	cmp	r3, #0
	bne	.L12
	nop
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
	.size	BF, .-BF
	.section	.rodata
	.align	2
.LC2:
	.ascii	"%s\000"
	.align	2
.LC3:
	.ascii	"pattern: %s \012\000"
	.global	__aeabi_i2d
	.global	__aeabi_ddiv
	.align	2
.LC4:
	.ascii	"Nombre de segons: %f s\012\000"
	.align	2
.LC5:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 536
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #536
	str	r0, [fp, #-536]
	str	r1, [fp, #-540]
	ldr	r3, .L16
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-540]
	add	r3, r3, #8
	ldr	r2, [r3]
	sub	r3, fp, #520
	ldr	r1, .L16+4
	mov	r0, r3
	bl	sprintf
	ldr	r3, [fp, #-540]
	add	r3, r3, #4
	ldr	r2, [r3]
	sub	r3, fp, #264
	ldr	r1, .L16+4
	mov	r0, r3
	bl	sprintf
	sub	r3, fp, #520
	mov	r1, r3
	ldr	r0, .L16+8
	bl	printf
	sub	r2, fp, #532
	sub	r3, fp, #264
	mov	r1, r2
	mov	r0, r3
	bl	readfile
	str	r0, [fp, #-528]
	bl	clock
	str	r0, [fp, #-524]
	sub	r3, fp, #520
	mov	r0, r3
	bl	strlen
	mov	r3, r0
	mov	r1, r3
	ldr	r2, [fp, #-532]
	sub	r0, fp, #520
	ldr	r3, [fp, #-528]
	bl	BF
	bl	clock
	mov	r2, r0
	ldr	r3, [fp, #-524]
	sub	r3, r2, r3
	mov	r0, r3
	bl	__aeabi_i2d
	mov	r2, #0
	ldr	r3, .L16+12
	bl	__aeabi_ddiv
	mov	r2, r0
	mov	r3, r1
	ldr	r0, .L16+16
	bl	printf
	ldr	r3, [fp, #-532]
	mov	r0, r3
	bl	free
	mov	r3, #0
	ldr	r2, .L16
	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}
.L17:
	.align	2
.L16:
	.word	.LC5
	.word	.LC2
	.word	.LC3
	.word	1093567616
	.word	.LC4
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
