	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	___archive_ensure_cloexec_flag  ## -- Begin function __archive_ensure_cloexec_flag
	.p2align	4, 0x90
___archive_ensure_cloexec_flag:         ## @__archive_ensure_cloexec_flag
	.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	%edi, %edi
	js	LBB0_3
## %bb.1:
	movl	%edi, %ebx
	movq	_F_GETFD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%eax, %eax
	callq	_fcntl
	cmpl	$-1, %eax
	je	LBB0_3
## %bb.2:
	movq	_FD_CLOEXEC@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	testl	%eax, %edx
	je	LBB0_4
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
LBB0_4:
	movq	_F_SETFD@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	%eax, %edx
	movl	%ebx, %edi
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_fcntl                          ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_F_GETFD,4,2                    ## @F_GETFD
	.comm	_FD_CLOEXEC,4,2                 ## @FD_CLOEXEC
	.comm	_F_SETFD,4,2                    ## @F_SETFD
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	___archive_ensure_cloexec_flag  ; -- Begin function __archive_ensure_cloexec_flag
	.p2align	2
___archive_ensure_cloexec_flag:         ; @__archive_ensure_cloexec_flag
	.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	w0, #31, LBB0_4
; %bb.1:
	mov	x19, x0
Lloh0:
	adrp	x8, _F_GETFD@GOTPAGE
Lloh1:
	ldr	x8, [x8, _F_GETFD@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_fcntl
	cmn	w0, #1
	b.eq	LBB0_4
; %bb.2:
Lloh3:
	adrp	x8, _FD_CLOEXEC@GOTPAGE
Lloh4:
	ldr	x8, [x8, _FD_CLOEXEC@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	tst	w8, w0
	b.ne	LBB0_4
; %bb.3:
Lloh6:
	adrp	x9, _F_SETFD@GOTPAGE
Lloh7:
	ldr	x9, [x9, _F_SETFD@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x9]
	orr	w8, w8, w0
	str	x8, [sp]
	mov	x0, x19
	bl	_fcntl
LBB0_4:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_F_GETFD,4,2                    ; @F_GETFD
	.comm	_FD_CLOEXEC,4,2                 ; @FD_CLOEXEC
	.comm	_F_SETFD,4,2                    ; @F_SETFD
.subsections_via_symbols
