	.file	"extr_gzread.c_gzread.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"requested length does not fit in int"
	.text
	.p2align 4
	.globl	gzread
	.type	gzread, @function
gzread:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	sub	rsp, 16
	.cfi_def_cfa_offset 64
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	test	rdi, rdi
	je	.L34
	mov	rax, QWORD PTR GZ_READ[rip]
	mov	rbp, rdi
	cmp	QWORD PTR [rdi], rax
	jne	.L34
	mov	rax, QWORD PTR 8[rdi]
	cmp	rax, QWORD PTR Z_OK[rip]
	mov	rbx, rsi
	mov	r14d, edx
	je	.L5
	cmp	rax, QWORD PTR Z_BUF_ERROR[rip]
	jne	.L34
.L5:
	test	r14d, r14d
	js	.L36
	mov	eax, 0
	je	.L1
	cmp	QWORD PTR 64[rbp], 0
	jne	.L7
.L9:
	mov	DWORD PTR 4[rsp], 0
	xor	r12d, r12d
	lea	r13, 4[rsp]
	.p2align 4,,10
	.p2align 3
.L8:
	mov	edx, DWORD PTR 36[rbp]
	test	edx, edx
	jne	.L37
	cmp	QWORD PTR 48[rbp], 0
	je	.L12
	cmp	QWORD PTR 72[rbp], 0
	je	.L38
.L12:
	mov	rdx, QWORD PTR 24[rbp]
	cmp	rdx, QWORD PTR LOOK[rip]
	je	.L14
	mov	eax, DWORD PTR 32[rbp]
	add	eax, eax
	cmp	eax, r14d
	ja	.L14
	cmp	rdx, QWORD PTR MODE_COPY[rip]
	je	.L39
	mov	DWORD PTR 80[rbp], r14d
	mov	rdi, rbp
	mov	QWORD PTR 88[rbp], rbx
	call	gz_decomp@PLT
	cmp	eax, -1
	je	.L34
	mov	eax, DWORD PTR 36[rbp]
	mov	DWORD PTR 36[rbp], 0
	mov	DWORD PTR 4[rsp], eax
.L11:
	mov	edx, eax
	add	DWORD PTR 44[rbp], eax
	add	r12d, eax
	add	rbx, rdx
	sub	r14d, eax
	jne	.L8
	mov	eax, r12d
.L1:
	mov	rcx, QWORD PTR 8[rsp]
	xor	rcx, QWORD PTR fs:40
	jne	.L40
	add	rsp, 16
	.cfi_remember_state
	.cfi_def_cfa_offset 48
	pop	rbx
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L14:
	.cfi_restore_state
	mov	rdi, rbp
	call	gz_fetch@PLT
	cmp	eax, -1
	jne	.L8
.L34:
	mov	eax, -1
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L37:
	cmp	edx, r14d
	mov	esi, DWORD PTR 40[rbp]
	mov	rdi, rbx
	cmova	edx, r14d
	mov	DWORD PTR 4[rsp], edx
	call	memcpy@PLT
	mov	eax, DWORD PTR 4[rsp]
	add	DWORD PTR 40[rbp], eax
	sub	DWORD PTR 36[rbp], eax
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L39:
	mov	rcx, r13
	mov	edx, r14d
	mov	rsi, rbx
	mov	rdi, rbp
	call	gz_load@PLT
	cmp	eax, -1
	je	.L34
	mov	eax, DWORD PTR 4[rsp]
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L7:
	mov	QWORD PTR 64[rbp], 0
	mov	esi, DWORD PTR 56[rbp]
	mov	rdi, rbp
	call	gz_skip@PLT
	cmp	eax, -1
	jne	.L9
	jmp	.L34
	.p2align 4,,10
	.p2align 3
.L38:
	mov	DWORD PTR 16[rbp], 1
	mov	eax, r12d
	jmp	.L1
.L36:
	mov	esi, DWORD PTR Z_DATA_ERROR[rip]
	lea	rdx, .LC0[rip]
	mov	rdi, rbp
	call	gz_error@PLT
	jmp	.L34
.L40:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	gzread, .-gzread
	.comm	Z_OK,8,8
	.comm	Z_DATA_ERROR,4,4
	.comm	Z_BUF_ERROR,8,8
	.comm	MODE_COPY,8,8
	.comm	LOOK,8,8
	.comm	GZ_READ,8,8
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.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, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_gzread.c_gzread.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"requested length does not fit in int\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	gzread
	.syntax unified
	.arm
	.fpu softvfp
	.type	gzread, %function
gzread:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r3, .L43
	sub	sp, sp, #8
	subs	r4, r0, #0
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	beq	.L36
	ldr	r3, .L43+4
	mov	r5, r2
	ldr	r3, [r3]
	ldr	r2, [r4]
	cmp	r2, r3
	bne	.L36
	ldr	r2, .L43+8
	ldr	r3, [r4, #4]
	ldr	r2, [r2]
	mov	r6, r1
	cmp	r3, r2
	beq	.L5
	ldr	r2, .L43+12
	ldr	r2, [r2]
	cmp	r3, r2
	bne	.L36
.L5:
	cmp	r5, #0
	blt	.L38
	moveq	r0, r5
	beq	.L1
	ldr	r3, [r4, #40]
	cmp	r3, #0
	bne	.L7
.L9:
	mov	r3, #0
	mov	r7, r3
	mov	r10, r3
	ldr	r8, .L43+16
	ldr	r9, .L43+20
	str	r3, [sp]
.L8:
	ldr	r2, [r4, #20]
	cmp	r2, #0
	bne	.L39
	ldr	r3, [r4, #32]
	cmp	r3, #0
	beq	.L12
	ldr	r3, [r4, #44]
	cmp	r3, #0
	beq	.L40
.L12:
	ldr	r3, [r4, #12]
	ldr	r2, [r8]
	cmp	r3, r2
	beq	.L14
	ldr	r2, [r4, #16]
	cmp	r5, r2, lsl #1
	bcc	.L14
	ldr	r2, [r9]
	cmp	r3, r2
	beq	.L41
	mov	r0, r4
	str	r5, [r4, #48]
	str	r6, [r4, #52]
	bl	gz_decomp
	cmn	r0, #1
	beq	.L36
	ldr	r3, [r4, #20]
	str	r10, [r4, #20]
	str	r3, [sp]
.L11:
	ldr	r2, [r4, #28]
	subs	r5, r5, r3
	add	r2, r2, r3
	add	r6, r6, r3
	add	r7, r7, r3
	str	r2, [r4, #28]
	bne	.L8
	mov	r0, r7
.L1:
	ldr	r3, .L43
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L42
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L14:
	mov	r0, r4
	bl	gz_fetch
	cmn	r0, #1
	bne	.L8
.L36:
	mvn	r0, #0
	b	.L1
.L39:
	cmp	r2, r5
	movcs	r2, r5
	ldr	r1, [r4, #24]
	mov	r0, r6
	str	r2, [sp]
	bl	memcpy
	ldr	r3, [sp]
	ldr	r1, [r4, #24]
	ldr	r2, [r4, #20]
	add	r1, r1, r3
	sub	r2, r2, r3
	str	r1, [r4, #24]
	str	r2, [r4, #20]
	b	.L11
.L41:
	mov	r3, sp
	mov	r2, r5
	mov	r1, r6
	mov	r0, r4
	bl	gz_load
	cmn	r0, #1
	beq	.L36
	ldr	r3, [sp]
	b	.L11
.L7:
	mov	r3, #0
	mov	r0, r4
	ldr	r1, [r4, #36]
	str	r3, [r4, #40]
	bl	gz_skip
	cmn	r0, #1
	bne	.L9
	b	.L36
.L40:
	mov	r3, #1
	mov	r0, r7
	str	r3, [r4, #8]
	b	.L1
.L38:
	ldr	r3, .L43+24
	mov	r0, r4
	ldr	r1, [r3]
	ldr	r2, .L43+28
	bl	gz_error
	b	.L36
.L42:
	bl	__stack_chk_fail
.L44:
	.align	2
.L43:
	.word	.LC1
	.word	GZ_READ
	.word	Z_OK
	.word	Z_BUF_ERROR
	.word	LOOK
	.word	MODE_COPY
	.word	Z_DATA_ERROR
	.word	.LC0
	.size	gzread, .-gzread
	.comm	Z_OK,4,4
	.comm	Z_DATA_ERROR,4,4
	.comm	Z_BUF_ERROR,4,4
	.comm	MODE_COPY,4,4
	.comm	LOOK,4,4
	.comm	GZ_READ,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
