	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function file_read_buffered
_file_read_buffered:                    ## @file_read_buffered
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movq	%rsi, %r15
	movq	%rdi, %r13
	movslq	(%rdx), %r14
	cmpl	$1, (%rdi)
	jne	LBB0_3
## %bb.1:
	movq	%r13, %rdi
	callq	_apr_file_flush_locked
	testq	%rax, %rax
	jne	LBB0_17
## %bb.2:
	movl	$0, (%r13)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 8(%r13)
LBB0_3:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movl	24(%r13), %eax
	cmpl	$-1, %eax
	je	LBB0_4
## %bb.5:
	movb	%al, (%r15)
	leaq	1(%r15), %r12
	decq	%r14
	movl	$-1, 24(%r13)
	testq	%r14, %r14
	jg	LBB0_7
	jmp	LBB0_15
LBB0_4:
	movq	%r15, %r12
	testq	%r14, %r14
	jle	LBB0_15
LBB0_7:
	movq	8(%r13), %rsi
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_8 Depth=1
	subq	%rsi, %rbx
	cmpq	%rbx, %r14
	cmovlq	%r14, %rbx
	addq	32(%r13), %rsi
	movq	%r12, %rdi
	movq	%rbx, %rdx
	callq	_memcpy
	movq	8(%r13), %rsi
	addq	%rbx, %rsi
	movq	%rsi, 8(%r13)
	addq	%rbx, %r12
	subq	%rbx, %r14
	jle	LBB0_15
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	16(%r13), %rbx
	cmpq	%rbx, %rsi
	jl	LBB0_14
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movl	52(%r13), %edi
	movq	32(%r13), %rsi
	movl	48(%r13), %edx
	callq	_read
	cmpl	$-1, %eax
	je	LBB0_12
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=1
	testl	%eax, %eax
	je	LBB0_11
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=1
	movslq	%eax, %rbx
	movq	%rbx, 16(%r13)
	addl	%eax, 40(%r13)
	movq	$0, 8(%r13)
	xorl	%esi, %esi
	jmp	LBB0_14
LBB0_15:
	xorl	%edx, %edx
LBB0_16:
	xorl	%eax, %eax
	subl	%r15d, %r12d
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	%r12d, (%rcx)
	cmoveq	%rdx, %rax
LBB0_17:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	movq	_TRUE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 44(%r13)
	movq	_APR_EOF@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	jmp	LBB0_16
LBB0_12:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	jmp	LBB0_16
	.cfi_endproc
                                        ## -- End function
	.comm	_TRUE,4,2                       ## @TRUE
	.comm	_APR_EOF,8,3                    ## @APR_EOF
	.comm	_errno,8,3                      ## @errno
	.no_dead_strip	_file_read_buffered
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function file_read_buffered
_file_read_buffered:                    ; @file_read_buffered
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
	ldrsw	x24, [x2]
	ldr	w8, [x0]
	cmp	w8, #1
	b.ne	LBB0_3
; %bb.1:
	mov	x0, x21
	bl	_apr_file_flush_locked
	cbnz	x0, LBB0_14
; %bb.2:
	str	wzr, [x21]
	stp	xzr, xzr, [x21, #8]
LBB0_3:
	ldr	w8, [x21, #24]
	mov	x22, x20
	cmn	w8, #1
	b.eq	LBB0_5
; %bb.4:
	strb	w8, [x22], #1
	sub	x24, x24, #1
	mov	w8, #-1
	str	w8, [x21, #24]
LBB0_5:
	cmp	x24, #1
	b.lt	LBB0_12
; %bb.6:
	ldr	x8, [x21, #8]
	b	LBB0_8
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	sub	x9, x9, x8
	cmp	x24, x9
	csel	x23, x24, x9, lt
	ldr	x9, [x21, #32]
	add	x1, x9, x8
	mov	x0, x22
	mov	x2, x23
	bl	_memcpy
	ldr	x8, [x21, #8]
	add	x8, x8, x23
	str	x8, [x21, #8]
	add	x22, x22, x23
	sub	x24, x24, x23
	cmp	x24, #0
	b.le	LBB0_12
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x21, #16]
	cmp	x8, x9
	b.lt	LBB0_7
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	ldr	x1, [x21, #32]
	ldp	w2, w0, [x21, #48]
	bl	_read
                                        ; kill: def $w0 killed $w0 def $x0
	cmn	w0, #1
	b.eq	LBB0_16
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	cbz	w0, LBB0_15
; %bb.11:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x8, #0
	sxtw	x9, w0
	ldr	w10, [x21, #40]
	add	w10, w10, w0
	str	w10, [x21, #40]
	stp	xzr, x9, [x21, #8]
	b	LBB0_7
LBB0_12:
	mov	x8, #0
LBB0_13:
	subs	w9, w22, w20
	str	w9, [x19]
	csel	x0, x8, xzr, eq
LBB0_14:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_15:
Lloh0:
	adrp	x8, _TRUE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x21, #44]
Lloh3:
	adrp	x8, _APR_EOF@GOTPAGE
Lloh4:
	ldr	x8, [x8, _APR_EOF@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	b	LBB0_13
LBB0_16:
Lloh6:
	adrp	x8, _errno@GOTPAGE
Lloh7:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	b	LBB0_13
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_TRUE,4,2                       ; @TRUE
	.comm	_APR_EOF,8,3                    ; @APR_EOF
	.comm	_errno,8,3                      ; @errno
	.no_dead_strip	_file_read_buffered
.subsections_via_symbols
