	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function archive_write_client_write
_archive_write_client_write:            ## @archive_write_client_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	$24, %rsp
	.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, %r14
	movq	(%rdi), %r13
	movq	8(%rdi), %r12
	movq	(%r13), %rcx
	testq	%rcx, %rcx
	je	LBB0_9
## %bb.1:
	movq	8(%r13), %r15
	cmpq	%rcx, %r15
	jae	LBB0_15
## %bb.2:
	cmpq	%rbx, %r15
	cmovaeq	%rbx, %r15
	movq	16(%r13), %rdi
	movq	%r14, %rsi
	movq	%r15, %rdx
	callq	_memcpy
	addq	%r15, 16(%r13)
	addq	%r15, %r14
	subq	%r15, %rbx
	subq	%r15, 8(%r13)
	jne	LBB0_14
## %bb.3:
	movq	(%r13), %r15
	testq	%r15, %r15
	je	LBB0_21
## %bb.4:
	movq	%r13, -56(%rbp)                 ## 8-byte Spill
	movq	24(%r13), %r13
	leaq	12(%r12), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	8(%r12), %esi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%r13, %rdx
	movq	%r15, %rcx
	callq	*(%r12)
	testq	%rax, %rax
	jle	LBB0_26
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	cmpq	%rax, %r15
	jb	LBB0_27
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	addq	%rax, %r13
	subq	%rax, %r15
	jne	LBB0_5
## %bb.8:
	movq	-56(%rbp), %r13                 ## 8-byte Reload
	movq	(%r13), %rcx
	jmp	LBB0_22
LBB0_9:
	movq	_ARCHIVE_OK@GOTPCREL(%rip), %r15
	testq	%rbx, %rbx
	jle	LBB0_25
## %bb.10:
	leaq	12(%r12), %r15
	movq	_ARCHIVE_FATAL@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movl	8(%r12), %esi
	movq	%r15, %rdi
	movq	%r14, %rdx
	movq	%rbx, %rcx
	callq	*(%r12)
	testq	%rax, %rax
	jle	LBB0_20
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	addq	%rax, %r14
	subq	%rax, %rbx
	jg	LBB0_11
## %bb.13:
	movq	_ARCHIVE_OK@GOTPCREL(%rip), %r15
	jmp	LBB0_25
LBB0_14:
	movq	(%r13), %rcx
LBB0_15:
	cmpq	%rcx, %rbx
	jb	LBB0_23
LBB0_16:
	leaq	12(%r12), %r15
	.p2align	4, 0x90
LBB0_17:                                ## =>This Inner Loop Header: Depth=1
	movl	8(%r12), %esi
	movq	%r15, %rdi
	movq	%r14, %rdx
	callq	*(%r12)
	testq	%rax, %rax
	jle	LBB0_26
## %bb.18:                              ##   in Loop: Header=BB0_17 Depth=1
	addq	%rax, %r14
	subq	%rax, %rbx
	movq	(%r13), %rcx
	cmpq	%rcx, %rbx
	jae	LBB0_17
	jmp	LBB0_23
LBB0_26:
	movq	_ARCHIVE_FATAL@GOTPCREL(%rip), %r15
	jmp	LBB0_25
LBB0_20:
	movq	%r13, %r15
	jmp	LBB0_25
LBB0_21:
	xorl	%ecx, %ecx
LBB0_22:
	movq	24(%r13), %rax
	movq	%rax, 16(%r13)
	movq	%rcx, 8(%r13)
	cmpq	%rcx, %rbx
	jae	LBB0_16
LBB0_23:
	movq	_ARCHIVE_OK@GOTPCREL(%rip), %r15
	testq	%rbx, %rbx
	jle	LBB0_25
## %bb.24:
	movq	16(%r13), %rdi
	movq	%r14, %rsi
	movq	%rbx, %rdx
	callq	_memcpy
	addq	%rbx, 16(%r13)
	subq	%rbx, 8(%r13)
LBB0_25:
	movl	(%r15), %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_27:
	leaq	L_.str(%rip), %rdx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	$-1, %esi
	callq	_archive_set_error
	movq	_ARCHIVE_FATAL@GOTPCREL(%rip), %r15
	jmp	LBB0_25
	.cfi_endproc
                                        ## -- End function
	.comm	_ARCHIVE_FATAL,4,2              ## @ARCHIVE_FATAL
	.comm	_ARCHIVE_OK,4,2                 ## @ARCHIVE_OK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"write overrun"

	.no_dead_strip	_archive_write_client_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function archive_write_client_write
_archive_write_client_write:            ; @archive_write_client_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, x2
	mov	x20, x1
	ldp	x25, x24, [x0]
	ldr	x3, [x25]
	cbz	x3, LBB0_9
; %bb.1:
	ldr	x8, [x25, #8]
	cmp	x8, x3
	b.hs	LBB0_15
; %bb.2:
	cmp	x8, x19
	csel	x21, x8, x19, lo
	ldr	x0, [x25, #16]
	mov	x1, x20
	mov	x2, x21
	bl	_memcpy
	ldp	x9, x8, [x25, #8]
	add	x8, x8, x21
	sub	x19, x19, x21
	add	x20, x20, x21
	subs	x9, x9, x21
	stp	x9, x8, [x25, #8]
	b.ne	LBB0_14
; %bb.3:
	ldr	x21, [x25]
	cbz	x21, LBB0_19
; %bb.4:
	ldr	x23, [x25, #24]
	add	x22, x24, #12
Lloh0:
	adrp	x26, _ARCHIVE_FATAL@GOTPAGE
Lloh1:
	ldr	x26, [x26, _ARCHIVE_FATAL@GOTPAGEOFF]
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x24]
	ldr	w1, [x24, #8]
	mov	x0, x22
	mov	x2, x23
	mov	x3, x21
	blr	x8
	cmp	x0, #1
	b.lt	LBB0_24
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	subs	x21, x21, x0
	b.lo	LBB0_25
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	add	x23, x23, x0
	b.ne	LBB0_5
; %bb.8:
	ldr	x3, [x25]
	b	LBB0_20
LBB0_9:
	cmp	x19, #1
	b.lt	LBB0_23
; %bb.10:
	add	x21, x24, #12
Lloh2:
	adrp	x26, _ARCHIVE_FATAL@GOTPAGE
Lloh3:
	ldr	x26, [x26, _ARCHIVE_FATAL@GOTPAGEOFF]
Lloh4:
	adrp	x22, _ARCHIVE_OK@GOTPAGE
Lloh5:
	ldr	x22, [x22, _ARCHIVE_OK@GOTPAGEOFF]
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x24]
	ldr	w1, [x24, #8]
	mov	x0, x21
	mov	x2, x20
	mov	x3, x19
	blr	x8
	cmp	x0, #1
	b.lt	LBB0_24
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	sub	x19, x19, x0
	add	x20, x20, x0
	cmp	x19, #0
	b.gt	LBB0_11
; %bb.13:
	mov	x26, x22
	b	LBB0_24
LBB0_14:
	ldr	x3, [x25]
LBB0_15:
	cmp	x19, x3
	b.lo	LBB0_21
LBB0_16:
	add	x21, x24, #12
Lloh6:
	adrp	x26, _ARCHIVE_FATAL@GOTPAGE
Lloh7:
	ldr	x26, [x26, _ARCHIVE_FATAL@GOTPAGEOFF]
LBB0_17:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x24]
	ldr	w1, [x24, #8]
	mov	x0, x21
	mov	x2, x20
	blr	x8
	cmp	x0, #1
	b.lt	LBB0_24
; %bb.18:                               ;   in Loop: Header=BB0_17 Depth=1
	add	x20, x20, x0
	ldr	x3, [x25]
	sub	x19, x19, x0
	cmp	x19, x3
	b.hs	LBB0_17
	b	LBB0_21
LBB0_19:
	mov	x3, #0
LBB0_20:
	ldr	x8, [x25, #24]
	stp	x3, x8, [x25, #8]
	cmp	x19, x3
	b.hs	LBB0_16
LBB0_21:
	cmp	x19, #1
	b.lt	LBB0_23
; %bb.22:
	ldr	x0, [x25, #16]
	mov	x1, x20
	mov	x2, x19
	bl	_memcpy
	ldp	x9, x8, [x25, #8]
	add	x8, x8, x19
	sub	x9, x9, x19
	stp	x9, x8, [x25, #8]
LBB0_23:
Lloh8:
	adrp	x26, _ARCHIVE_OK@GOTPAGE
Lloh9:
	ldr	x26, [x26, _ARCHIVE_OK@GOTPAGEOFF]
LBB0_24:
	ldr	w0, [x26]
	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
LBB0_25:
Lloh10:
	adrp	x2, l_.str@PAGE
Lloh11:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x22
	mov	w1, #-1
	bl	_archive_set_error
Lloh12:
	adrp	x26, _ARCHIVE_FATAL@GOTPAGE
Lloh13:
	ldr	x26, [x26, _ARCHIVE_FATAL@GOTPAGEOFF]
	b	LBB0_24
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_ARCHIVE_FATAL,4,2              ; @ARCHIVE_FATAL
	.comm	_ARCHIVE_OK,4,2                 ; @ARCHIVE_OK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"write overrun"

	.no_dead_strip	_archive_write_client_write
.subsections_via_symbols
