	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dmz_handle_buffered_write
_dmz_handle_buffered_write:             ## @dmz_handle_buffered_write
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, -44(%rbp)                 ## 4-byte Spill
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	movq	%rdx, %r12
	movq	%rsi, %r13
	movq	%rdi, %r15
	movq	(%rdi), %r14
	movq	%r14, %rdi
	callq	_dmz_get_chunk_buffer
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_1
## %bb.7:
	movq	%rbx, %rdi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_PTR_ERR                        ## TAILCALL
LBB0_1:
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	movq	%r13, -56(%rbp)                 ## 8-byte Spill
	movq	-72(%rbp), %r13                 ## 8-byte Reload
	movl	-44(%rbp), %r14d                ## 4-byte Reload
	movq	%rbx, %rdi
	callq	_dmz_is_readonly
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_EROFS@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_6
LBB0_3:
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movq	%r12, %rdx
	movq	%r13, %r15
	movq	%r13, %rcx
	movl	%r14d, %r8d
	callq	_dmz_submit_bio
	testl	%eax, %eax
	jne	LBB0_6
## %bb.4:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	movq	%r15, %rdx
	movl	%r14d, %ecx
	callq	_dmz_validate_blocks
	testl	%eax, %eax
	jne	LBB0_6
## %bb.5:
	xorl	%eax, %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	cmpq	%r15, (%rcx)
	jle	LBB0_6
## %bb.8:
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movq	%r15, %rdx
	movl	%r14d, %ecx
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_dmz_invalidate_blocks          ## TAILCALL
LBB0_6:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EROFS,4,2                      ## @EROFS
	.no_dead_strip	_dmz_handle_buffered_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dmz_handle_buffered_write
_dmz_handle_buffered_write:             ; @dmz_handle_buffered_write
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [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 w25, -72
	.cfi_offset w26, -80
	mov	x19, x4
	mov	x20, x3
	mov	x24, x2
	mov	x21, x1
	mov	x25, x0
	ldr	x22, [x0]
	mov	x0, x22
	bl	_dmz_get_chunk_buffer
	mov	x23, x0
	bl	_IS_ERR
	cbz	x0, LBB0_2
; %bb.1:
	mov	x0, x23
	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	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_PTR_ERR
LBB0_2:
	mov	x0, x23
	bl	_dmz_is_readonly
	cbz	x0, LBB0_4
; %bb.3:
Lloh0:
	adrp	x8, _EROFS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EROFS@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_9
LBB0_4:
	mov	x0, x25
	mov	x1, x23
	mov	x2, x24
	mov	x3, x20
	mov	x4, x19
	bl	_dmz_submit_bio
	cbnz	w0, LBB0_9
; %bb.5:
	mov	x0, x22
	mov	x1, x23
	mov	x2, x20
	mov	x3, x19
	bl	_dmz_validate_blocks
	cbnz	w0, LBB0_9
; %bb.6:
	ldr	x8, [x21]
	cmp	x8, x20
	b.le	LBB0_8
; %bb.7:
	mov	x0, x22
	mov	x1, x21
	mov	x2, x20
	mov	x3, x19
	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	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_dmz_invalidate_blocks
LBB0_8:
	mov	w0, #0
LBB0_9:
	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	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_EROFS,4,2                      ; @EROFS
	.no_dead_strip	_dmz_handle_buffered_write
.subsections_via_symbols
