	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_archive_write_open_fd          ## -- Begin function archive_write_open_fd
	.p2align	4, 0x90
_archive_write_open_fd:                 ## @archive_write_open_fd
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%esi, %ebx
	movq	%rdi, %r14
	movl	$4, %edi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movl	%ebx, (%rax)
	movq	_file_open@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	_file_write@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	_file_close@GOTPCREL(%rip), %rsi
	movl	(%rsi), %r8d
	movq	%r14, %rdi
	movq	%rax, %rsi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_archive_write_open             ## TAILCALL
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	callq	_archive_set_error
	movq	_ARCHIVE_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"No memory"

	.comm	_ARCHIVE_FATAL,4,2              ## @ARCHIVE_FATAL
	.comm	_file_open,4,2                  ## @file_open
	.comm	_file_write,4,2                 ## @file_write
	.comm	_file_close,4,2                 ## @file_close
	.comm	_O_BINARY,4,2                   ## @O_BINARY
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_archive_write_open_fd          ; -- Begin function archive_write_open_fd
	.p2align	2
_archive_write_open_fd:                 ; @archive_write_open_fd
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x20, x1
	mov	x19, x0
	mov	w0, #4
	bl	_malloc
	cbz	x0, LBB0_2
; %bb.1:
	mov	x1, x0
	str	w20, [x0]
Lloh0:
	adrp	x8, _file_open@GOTPAGE
Lloh1:
	ldr	x8, [x8, _file_open@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
Lloh3:
	adrp	x8, _file_write@GOTPAGE
Lloh4:
	ldr	x8, [x8, _file_write@GOTPAGEOFF]
Lloh5:
	ldr	w3, [x8]
Lloh6:
	adrp	x8, _file_close@GOTPAGE
Lloh7:
	ldr	x8, [x8, _file_close@GOTPAGEOFF]
Lloh8:
	ldr	w4, [x8]
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_archive_write_open
LBB0_2:
Lloh9:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x2, l_.str@PAGE
Lloh13:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_archive_set_error
Lloh14:
	adrp	x8, _ARCHIVE_FATAL@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ARCHIVE_FATAL@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"No memory"

	.comm	_ARCHIVE_FATAL,4,2              ; @ARCHIVE_FATAL
	.comm	_file_open,4,2                  ; @file_open
	.comm	_file_write,4,2                 ; @file_write
	.comm	_file_close,4,2                 ; @file_close
	.comm	_O_BINARY,4,2                   ; @O_BINARY
.subsections_via_symbols
