	.file	"25137169.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"Error allocating memory"
.LC1:
	.string	"disco.hdf"
.LC2:
	.string	"disco2.hdf"
.LC3:
	.string	"rb"
.LC4:
	.string	"Error opening %s\n"
.LC5:
	.string	"leidos: %d\n"
.LC6:
	.string	"wb"
	.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, 64
	mov	edi, 1073741824
	call	malloc@PLT
	mov	QWORD PTR -40[rbp], rax
	cmp	QWORD PTR -40[rbp], 0
	jne	.L2
	lea	rdi, .LC0[rip]
	call	puts@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	lea	rax, .LC1[rip]
	mov	QWORD PTR -32[rbp], rax
	lea	rax, .LC2[rip]
	mov	QWORD PTR -24[rbp], rax
	mov	rax, QWORD PTR -32[rbp]
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -16[rbp], rax
	cmp	QWORD PTR -16[rbp], 0
	jne	.L3
	mov	rax, QWORD PTR -32[rbp]
	mov	rsi, rax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 1
	call	exit@PLT
.L3:
	mov	rdx, QWORD PTR -16[rbp]
	mov	rax, QWORD PTR -40[rbp]
	mov	rcx, rdx
	mov	edx, 1073741824
	mov	esi, 1
	mov	rdi, rax
	call	fread@PLT
	mov	DWORD PTR -44[rbp], eax
	mov	eax, DWORD PTR -44[rbp]
	mov	esi, eax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	fclose@PLT
	mov	DWORD PTR -48[rbp], 128
	jmp	.L4
.L5:
	mov	eax, DWORD PTR -48[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -40[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	mov	BYTE PTR -50[rbp], al
	mov	eax, DWORD PTR -48[rbp]
	cdqe
	lea	rdx, 1[rax]
	mov	rax, QWORD PTR -40[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	mov	BYTE PTR -49[rbp], al
	mov	eax, DWORD PTR -48[rbp]
	movsx	rdx, eax
	mov	rax, QWORD PTR -40[rbp]
	add	rdx, rax
	movzx	eax, BYTE PTR -49[rbp]
	mov	BYTE PTR [rdx], al
	mov	eax, DWORD PTR -48[rbp]
	cdqe
	lea	rdx, 1[rax]
	mov	rax, QWORD PTR -40[rbp]
	add	rdx, rax
	movzx	eax, BYTE PTR -50[rbp]
	mov	BYTE PTR [rdx], al
	add	DWORD PTR -48[rbp], 2
.L4:
	mov	eax, DWORD PTR -48[rbp]
	cmp	eax, DWORD PTR -44[rbp]
	jl	.L5
	mov	rax, QWORD PTR -24[rbp]
	lea	rsi, .LC6[rip]
	mov	rdi, rax
	call	fopen@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	eax, DWORD PTR -44[rbp]
	add	eax, -128
	cdqe
	mov	rdx, QWORD PTR -40[rbp]
	lea	rdi, 128[rdx]
	mov	rdx, QWORD PTR -8[rbp]
	mov	rcx, rdx
	mov	rdx, rax
	mov	esi, 1
	call	fwrite@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	fclose@PLT
	nop
	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	"25137169.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Error allocating memory\000"
	.align	2
.LC1:
	.ascii	"disco.hdf\000"
	.align	2
.LC2:
	.ascii	"disco2.hdf\000"
	.align	2
.LC3:
	.ascii	"rb\000"
	.align	2
.LC4:
	.ascii	"Error opening %s\012\000"
	.align	2
.LC5:
	.ascii	"leidos: %d\012\000"
	.align	2
.LC6:
	.ascii	"wb\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 32
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	mov	r0, #1073741824
	bl	malloc
	mov	r3, r0
	str	r3, [fp, #-28]
	ldr	r3, [fp, #-28]
	cmp	r3, #0
	bne	.L2
	ldr	r0, .L6
	bl	puts
	mov	r0, #1
	bl	exit
.L2:
	ldr	r3, .L6+4
	str	r3, [fp, #-24]
	ldr	r3, .L6+8
	str	r3, [fp, #-20]
	ldr	r1, .L6+12
	ldr	r0, [fp, #-24]
	bl	fopen
	str	r0, [fp, #-16]
	ldr	r3, [fp, #-16]
	cmp	r3, #0
	bne	.L3
	ldr	r1, [fp, #-24]
	ldr	r0, .L6+16
	bl	printf
	mov	r0, #1
	bl	exit
.L3:
	ldr	r3, [fp, #-16]
	mov	r2, #1073741824
	mov	r1, #1
	ldr	r0, [fp, #-28]
	bl	fread
	mov	r3, r0
	str	r3, [fp, #-12]
	ldr	r1, [fp, #-12]
	ldr	r0, .L6+20
	bl	printf
	ldr	r0, [fp, #-16]
	bl	fclose
	mov	r3, #128
	str	r3, [fp, #-32]
	b	.L4
.L5:
	ldr	r3, [fp, #-32]
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldrb	r3, [r3]
	strb	r3, [fp, #-34]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldrb	r3, [r3]
	strb	r3, [fp, #-33]
	ldr	r3, [fp, #-32]
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldrb	r2, [fp, #-33]
	strb	r2, [r3]
	ldr	r3, [fp, #-32]
	add	r3, r3, #1
	ldr	r2, [fp, #-28]
	add	r3, r2, r3
	ldrb	r2, [fp, #-34]
	strb	r2, [r3]
	ldr	r3, [fp, #-32]
	add	r3, r3, #2
	str	r3, [fp, #-32]
.L4:
	ldr	r2, [fp, #-32]
	ldr	r3, [fp, #-12]
	cmp	r2, r3
	blt	.L5
	ldr	r1, .L6+24
	ldr	r0, [fp, #-20]
	bl	fopen
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-28]
	add	r0, r3, #128
	ldr	r3, [fp, #-12]
	sub	r3, r3, #128
	mov	r2, r3
	ldr	r3, [fp, #-8]
	mov	r1, #1
	bl	fwrite
	ldr	r0, [fp, #-8]
	bl	fclose
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L7:
	.align	2
.L6:
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
