	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function inflate_file
_inflate_file:                          ## @inflate_file
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	%rdi, %r15
	movq	$0, -96(%rbp)
	movl	$0, -88(%rbp)
	xorps	%xmm0, %xmm0
	movups	%xmm0, -64(%rbp)
	movq	$0, -48(%rbp)
	movq	%rdx, -80(%rbp)
	movl	%ecx, -72(%rbp)
	movq	_MAX_WBITS@GOTPCREL(%rip), %rax
	xorl	%esi, %esi
	subl	(%rax), %esi
	leaq	-96(%rbp), %rdi
	callq	_inflateInit2
	movq	_Z_OK@GOTPCREL(%rip), %r13
	cmpl	(%r13), %eax
	jne	LBB0_1
## %bb.2:
	movq	_INFLATE_INPUT_BUFFER_MAX@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	incq	%rdi
	callq	_malloc
	movq	%rax, %r14
	movl	$-1, %eax
	testq	%r14, %r14
	je	LBB0_17
## %bb.3:
	movq	_Z_STREAM_END@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	testl	%ebx, %ebx
	je	LBB0_5
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%r14, -96(%rbp)
	movq	_INFLATE_INPUT_BUFFER_MAX@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movl	%ebx, %edi
	callq	_MIN
	movq	%r14, %rdi
	movl	$1, %esi
	movl	%eax, %edx
	movq	%r15, %rcx
	callq	_fread
	xorl	%ecx, %ecx
	subl	%eax, %ebx
	sete	%cl
	addl	%eax, %ecx
	movl	%ecx, -88(%rbp)
	movq	_Z_NO_FLUSH@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-96(%rbp), %rdi
	callq	_inflate
	cmpl	(%r12), %eax
	je	LBB0_11
## %bb.8:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpl	(%r13), %eax
	je	LBB0_4
## %bb.9:
	leaq	L_.str.2(%rip), %rdi
	jmp	LBB0_10
LBB0_1:
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
LBB0_15:
	xorl	%eax, %eax
	callq	_logerror
	jmp	LBB0_16
LBB0_5:
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_logerror
	jmp	LBB0_6
LBB0_11:
	leaq	-96(%rbp), %rdi
	callq	_inflateEnd
	cmpl	(%r13), %eax
	jne	LBB0_12
## %bb.13:
	movq	%r14, %rdi
	callq	_free
	xorl	%eax, %eax
	movl	-72(%rbp), %ecx
	orl	%ebx, %ecx
	je	LBB0_17
## %bb.14:
	leaq	L_.str.4(%rip), %rdi
	movl	%ebx, %esi
	jmp	LBB0_15
LBB0_12:
	leaq	L_.str.3(%rip), %rdi
LBB0_10:
	movl	%eax, %esi
	xorl	%eax, %eax
	callq	_logerror
LBB0_6:
	movq	%r14, %rdi
	callq	_free
LBB0_16:
	movl	$-1, %eax
LBB0_17:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_WBITS,4,2                  ## @MAX_WBITS
	.comm	_Z_OK,4,2                       ## @Z_OK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"inflateInit error: %d\n"

	.comm	_INFLATE_INPUT_BUFFER_MAX,8,3   ## @INFLATE_INPUT_BUFFER_MAX
L_.str.1:                               ## @.str.1
	.asciz	"inflate error: compressed size too small\n"

	.comm	_Z_NO_FLUSH,4,2                 ## @Z_NO_FLUSH
	.comm	_Z_STREAM_END,4,2               ## @Z_STREAM_END
L_.str.2:                               ## @.str.2
	.asciz	"inflate error: %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"inflateEnd error: %d\n"

L_.str.4:                               ## @.str.4
	.asciz	"zip size mismatch. %i\n"

	.no_dead_strip	_inflate_file
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function inflate_file
_inflate_file:                          ; @inflate_file
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x1
	mov	x21, x0
	str	xzr, [sp, #8]
	str	wzr, [sp, #16]
	stp	xzr, xzr, [sp, #48]
	str	xzr, [sp, #40]
	str	x2, [sp, #24]
	str	w3, [sp, #32]
Lloh0:
	adrp	x8, _MAX_WBITS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MAX_WBITS@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w1, w8
	add	x0, sp, #8
	bl	_inflateInit2
                                        ; kill: def $w0 killed $w0 def $x0
Lloh3:
	adrp	x22, _Z_OK@GOTPAGE
Lloh4:
	ldr	x22, [x22, _Z_OK@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w0, w8
	b.ne	LBB0_7
; %bb.1:
Lloh5:
	adrp	x23, _INFLATE_INPUT_BUFFER_MAX@GOTPAGE
Lloh6:
	ldr	x23, [x23, _INFLATE_INPUT_BUFFER_MAX@GOTPAGEOFF]
	ldr	x8, [x23]
	add	x0, x8, #1
	bl	_malloc
	cbz	x0, LBB0_15
; %bb.2:
	mov	x20, x0
Lloh7:
	adrp	x24, _Z_NO_FLUSH@GOTPAGE
Lloh8:
	ldr	x24, [x24, _Z_NO_FLUSH@GOTPAGEOFF]
Lloh9:
	adrp	x25, _Z_STREAM_END@GOTPAGE
Lloh10:
	ldr	x25, [x25, _Z_STREAM_END@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	cbz	w19, LBB0_9
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	str	x20, [sp, #8]
	ldr	x1, [x23]
	mov	x0, x19
	bl	_MIN
	mov	x2, x0
	mov	x0, x20
	mov	w1, #1
	mov	x3, x21
	bl	_fread
	subs	w19, w19, w0
	cinc	w8, w0, eq
	str	w8, [sp, #16]
	ldr	w1, [x24]
	add	x0, sp, #8
	bl	_inflate
                                        ; kill: def $w0 killed $w0 def $x0
	ldr	w8, [x25]
	cmp	w0, w8
	b.eq	LBB0_10
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x22]
	cmp	w0, w8
	b.eq	LBB0_3
; %bb.6:
	str	x0, [sp]
Lloh11:
	adrp	x0, l_.str.2@PAGE
Lloh12:
	add	x0, x0, l_.str.2@PAGEOFF
	b	LBB0_14
LBB0_7:
	str	x0, [sp]
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
LBB0_8:
	bl	_logerror
	b	LBB0_15
LBB0_9:
Lloh15:
	adrp	x0, l_.str.1@PAGE
Lloh16:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_14
LBB0_10:
	add	x0, sp, #8
	bl	_inflateEnd
                                        ; kill: def $w0 killed $w0 def $x0
	ldr	w8, [x22]
	cmp	w0, w8
	b.ne	LBB0_13
; %bb.11:
	mov	x0, x20
	bl	_free
	ldr	w8, [sp, #32]
	orr	w8, w8, w19
	cbz	w8, LBB0_17
; %bb.12:
	str	x19, [sp]
Lloh17:
	adrp	x0, l_.str.4@PAGE
Lloh18:
	add	x0, x0, l_.str.4@PAGEOFF
	b	LBB0_8
LBB0_13:
	str	x0, [sp]
Lloh19:
	adrp	x0, l_.str.3@PAGE
Lloh20:
	add	x0, x0, l_.str.3@PAGEOFF
LBB0_14:
	bl	_logerror
	mov	x0, x20
	bl	_free
LBB0_15:
	mov	w0, #-1
LBB0_16:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
LBB0_17:
	mov	w0, #0
	b	LBB0_16
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_WBITS,4,2                  ; @MAX_WBITS
	.comm	_Z_OK,4,2                       ; @Z_OK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"inflateInit error: %d\n"

	.comm	_INFLATE_INPUT_BUFFER_MAX,8,3   ; @INFLATE_INPUT_BUFFER_MAX
l_.str.1:                               ; @.str.1
	.asciz	"inflate error: compressed size too small\n"

	.comm	_Z_NO_FLUSH,4,2                 ; @Z_NO_FLUSH
	.comm	_Z_STREAM_END,4,2               ; @Z_STREAM_END
l_.str.2:                               ; @.str.2
	.asciz	"inflate error: %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"inflateEnd error: %d\n"

l_.str.4:                               ; @.str.4
	.asciz	"zip size mismatch. %i\n"

	.no_dead_strip	_inflate_file
.subsections_via_symbols
