	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function modifier_progressive_read
_modifier_progressive_read:             ## @modifier_progressive_read
	.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	$2072, %rsp                     ## imm = 0x818
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	%rsi, -2104(%rbp)               ## 8-byte Spill
	cmpq	%rsi, 16(%rdi)
	jne	LBB0_3
## %bb.1:
	cmpq	$0, 32(%rbx)
	je	LBB0_3
## %bb.2:
	cmpq	$0, 40(%rbx)
	jne	LBB0_4
LBB0_3:
	leaq	L_.str(%rip), %rsi
	movq	-2104(%rbp), %rdi               ## 8-byte Reload
	callq	_png_error
LBB0_4:
	leaq	16(%rbx), %r12
	leaq	-2096(%rbp), %r13
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	%rbx, %rdi
	movq	%r13, %rsi
	movl	%r14d, %edx
	callq	_modifier_read_imp
	movq	-2104(%rbp), %rdi               ## 8-byte Reload
	movl	%r15d, %esi
	movq	%r13, %rdx
	movl	%r14d, %ecx
	callq	_png_process_data
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	_modifier_progressive_read.noise(%rip), %eax
	movl	%eax, %r14d
	shrl	$4, %r14d
	xorl	%eax, %r14d
	shll	$9, %eax
	andl	$511, %r14d                     ## imm = 0x1FF
	orl	%r14d, %eax
	movl	%eax, _modifier_progressive_read.noise(%rip)
	movq	%r12, %rdi
	callq	_store_read_buffer_avail
	movq	(%rbx), %rcx
	movq	8(%rbx), %rdx
	movl	%ecx, %esi
	subl	%edx, %esi
	cmpq	%rdx, %rcx
	movl	$0, %edi
	cmovlel	%edi, %esi
	addl	%eax, %esi
	cmpl	%esi, %r14d
	jle	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	%esi, %r14d
	testl	%esi, %esi
	jne	LBB0_7
## %bb.8:
	cmpq	%rdx, %rcx
	jg	LBB0_11
## %bb.9:
	movq	32(%rbx), %rax
	leaq	8(%rax), %rcx
	cmpq	%rcx, 40(%rbx)
	jne	LBB0_11
## %bb.10:
	movq	24(%rbx), %rcx
	cmpq	(%rax), %rcx
	jge	LBB0_12
LBB0_11:
	leaq	L_.str.1(%rip), %rsi
	movq	-2104(%rbp), %rdi               ## 8-byte Reload
	callq	_png_error
LBB0_12:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_14
## %bb.13:
	addq	$2072, %rsp                     ## imm = 0x818
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"store state damaged (progressive)"

	.section	__DATA,__data
	.p2align	2                               ## @modifier_progressive_read.noise
_modifier_progressive_read.noise:
	.long	1                               ## 0x1

	.section	__TEXT,__cstring,cstring_literals
L_.str.1:                               ## @.str.1
	.asciz	"progressive read implementation error"

	.no_dead_strip	_modifier_progressive_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function modifier_progressive_read
_modifier_progressive_read:             ; @modifier_progressive_read
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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 w27, -72
	.cfi_offset w28, -80
	sub	sp, sp, #2064
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
	mov	x22, x0
	ldr	x8, [x22, #16]!
	cmp	x8, x1
	b.ne	LBB0_3
; %bb.1:
	ldr	x8, [x20, #32]
	cbz	x8, LBB0_3
; %bb.2:
	ldr	x8, [x20, #40]
	cbnz	x8, LBB0_4
LBB0_3:
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_png_error
LBB0_4:
	adrp	x24, _modifier_progressive_read.noise@PAGE
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x1, sp, #8
	mov	x0, x20
	mov	x2, x23
	bl	_modifier_read_imp
	add	x2, sp, #8
	mov	x0, x19
	mov	x1, x21
	mov	x3, x23
	bl	_png_process_data
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x24, _modifier_progressive_read.noise@PAGEOFF]
	eor	w9, w8, w8, lsr #4
	and	w23, w9, #0x1ff
	bfi	w9, w8, #9, #23
	str	w9, [x24, _modifier_progressive_read.noise@PAGEOFF]
	mov	x0, x22
	bl	_store_read_buffer_avail
	ldp	x8, x9, [x20]
	sub	w10, w8, w9
	cmp	x8, x9
	csel	w10, w10, wzr, gt
	add	w10, w10, w0
	cmp	w23, w10
	b.le	LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x23, x10
	cbnz	w10, LBB0_5
; %bb.8:
	cmp	x8, x9
	b.gt	LBB0_11
; %bb.9:
	ldp	x8, x9, [x20, #32]
	add	x10, x8, #8
	cmp	x9, x10
	b.ne	LBB0_11
; %bb.10:
	ldr	x9, [x20, #24]
	ldr	x8, [x8]
	cmp	x9, x8
	b.ge	LBB0_12
LBB0_11:
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_png_error
LBB0_12:
	ldur	x8, [x29, #-72]
Lloh7:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh8:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.13:
	add	sp, sp, #2064
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"store state damaged (progressive)"

	.section	__DATA,__data
	.p2align	2                               ; @modifier_progressive_read.noise
_modifier_progressive_read.noise:
	.long	1                               ; 0x1

	.section	__TEXT,__cstring,cstring_literals
l_.str.1:                               ; @.str.1
	.asciz	"progressive read implementation error"

	.no_dead_strip	_modifier_progressive_read
.subsections_via_symbols
