	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function buf_copy_excess
_buf_copy_excess:                       ## @buf_copy_excess
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	testl	%edx, %edx
	js	LBB0_5
## %bb.1:
	movl	(%rsi), %ecx
	movl	$1, %eax
	cmpl	%edx, %ecx
	jle	LBB0_6
## %bb.2:
	movq	%rdi, %rbx
	movl	%ecx, -16(%rbp)
	movl	%edx, (%rsi)
	leaq	-16(%rbp), %rdi
	movl	%edx, %esi
	callq	_buf_advance
	testl	%eax, %eax
	je	LBB0_5
## %bb.3:
	leaq	-16(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_buf_copy
	jmp	LBB0_6
LBB0_5:
	xorl	%eax, %eax
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_buf_copy_excess
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function buf_copy_excess
_buf_copy_excess:                       ; @buf_copy_excess
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	tbnz	w2, #31, LBB0_4
; %bb.1:
	ldr	w8, [x1]
	cmp	w8, w2
	b.le	LBB0_5
; %bb.2:
	mov	x19, x0
	str	w8, [sp, #8]
	str	w2, [x1]
	add	x0, sp, #8
	mov	x1, x2
	bl	_buf_advance
	cbz	w0, LBB0_6
; %bb.3:
	add	x1, sp, #8
	mov	x0, x19
	bl	_buf_copy
	b	LBB0_6
LBB0_4:
	mov	w0, #0
	b	LBB0_6
LBB0_5:
	mov	w0, #1
LBB0_6:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_buf_copy_excess
.subsections_via_symbols
