	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function confree
_confree:                               ## @confree
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %r14d
	movq	_maxfd@GOTPCREL(%rip), %rax
	cmpl	%edi, (%rax)
	jle	LBB0_1
## %bb.2:
	movq	_fdcon@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	%r14d, %rbx
	leaq	(%rbx,%rbx,2), %rcx
	shlq	$4, %rcx
	movq	(%rax,%rcx), %rcx
	movq	_CS_UNUSED@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	je	LBB0_3
	jmp	LBB0_4
LBB0_1:
	movslq	%r14d, %rbx
LBB0_3:
	leaq	L_.str(%rip), %rdi
	movl	%r14d, %esi
	callq	_fatal
	movq	_fdcon@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
LBB0_4:
	movq	%rbx, %rcx
	shlq	$4, %rcx
	leaq	(%rcx,%rcx,2), %r12
	movq	40(%rax,%r12), %rdi
	callq	_free
	movq	_fdcon@GOTPCREL(%rip), %r15
	movq	(%r15), %rax
	movq	32(%rax,%r12), %rdi
	callq	_free
	movq	(%r15), %rax
	movq	(%rax,%r12), %rcx
	movq	_CS_KEYS@GOTPCREL(%rip), %rdx
	leaq	(%rbx,%rbx,2), %rbx
	cmpq	(%rdx), %rcx
	jne	LBB0_6
## %bb.5:
	movq	%rbx, %rcx
	shlq	$4, %rcx
	movq	24(%rax,%rcx), %rdi
	callq	_free
	movq	(%r15), %rax
LBB0_6:
	movq	_CS_UNUSED@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	shlq	$4, %rbx
	movq	%rcx, (%rax,%rbx)
	movq	$0, 16(%rax,%rbx)
	movq	8(%rax,%rbx), %rdi
	testq	%rdi, %rdi
	je	LBB0_8
## %bb.7:
	callq	_ssh_packet_close
	movq	(%r15), %rax
	movq	8(%rax,%r12), %rdi
	callq	_free
	movq	(%r15), %rax
	movq	$0, 8(%rax,%r12)
	jmp	LBB0_9
LBB0_8:
	movl	%r14d, %edi
	callq	_close
LBB0_9:
	addq	(%r15), %rbx
	movq	_c_link@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_tq@GOTPCREL(%rip), %rdi
	movq	%rbx, %rsi
	callq	_TAILQ_REMOVE
	movq	_read_wait@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r14d, %edi
	callq	_FD_CLR
	movq	_ncon@GOTPCREL(%rip), %rax
	decl	(%rax)
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_maxfd,4,2                      ## @maxfd
	.comm	_fdcon,8,3                      ## @fdcon
	.comm	_CS_UNUSED,8,3                  ## @CS_UNUSED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"confree: attempt to free bad fdno %d"

	.comm	_CS_KEYS,8,3                    ## @CS_KEYS
	.comm	_tq,4,2                         ## @tq
	.comm	_c_link,4,2                     ## @c_link
	.comm	_read_wait,4,2                  ## @read_wait
	.comm	_ncon,4,2                       ## @ncon
	.no_dead_strip	_confree
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function confree
_confree:                               ; @confree
	.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, x0
Lloh0:
	adrp	x8, _maxfd@GOTPAGE
Lloh1:
	ldr	x8, [x8, _maxfd@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x20, _fdcon@GOTPAGE
Lloh4:
	ldr	x20, [x20, _fdcon@GOTPAGEOFF]
Lloh5:
	adrp	x22, _CS_UNUSED@GOTPAGE
Lloh6:
	ldr	x22, [x22, _CS_UNUSED@GOTPAGEOFF]
	cmp	w8, w0
	b.le	LBB0_2
; %bb.1:
	ldr	x8, [x20]
	sxtw	x21, w19
	mov	w9, #48
	smull	x9, w19, w9
	ldr	x9, [x8, x9]
	ldr	x10, [x22]
	cmp	x9, x10
	b.eq	LBB0_3
	b	LBB0_4
LBB0_2:
	mov	x8, x19
	sxtw	x21, w8
LBB0_3:
Lloh7:
	adrp	x0, l_.str@PAGE
Lloh8:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x19
	bl	_fatal
	ldr	x8, [x20]
LBB0_4:
	add	x9, x21, x21, lsl #1
	lsl	x23, x9, #4
	add	x8, x8, x23
	ldr	x0, [x8, #40]
	bl	_free
	ldr	x8, [x20]
	add	x8, x8, x23
	ldr	x0, [x8, #32]
	bl	_free
	ldr	x8, [x20]
	ldr	x9, [x8, x23]
Lloh9:
	adrp	x10, _CS_KEYS@GOTPAGE
Lloh10:
	ldr	x10, [x10, _CS_KEYS@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_6
; %bb.5:
	mov	w9, #48
	madd	x8, x21, x9, x8
	ldr	x0, [x8, #24]
	bl	_free
	ldr	x8, [x20]
LBB0_6:
	ldr	x9, [x22]
	mov	w10, #48
	madd	x8, x21, x10, x8
	str	x9, [x8]
	str	xzr, [x8, #16]
	ldr	x0, [x8, #8]
	cbz	x0, LBB0_8
; %bb.7:
	bl	_ssh_packet_close
	ldr	x8, [x20]
	add	x9, x21, x21, lsl #1
	lsl	x22, x9, #4
	add	x8, x8, x22
	ldr	x0, [x8, #8]
	bl	_free
	ldr	x8, [x20]
	add	x8, x8, x22
	str	xzr, [x8, #8]
	b	LBB0_9
LBB0_8:
	mov	x0, x19
	bl	_close
LBB0_9:
	ldr	x8, [x20]
	mov	w9, #48
	madd	x1, x21, x9, x8
Lloh12:
	adrp	x8, _c_link@GOTPAGE
Lloh13:
	ldr	x8, [x8, _c_link@GOTPAGEOFF]
Lloh14:
	ldr	w2, [x8]
Lloh15:
	adrp	x0, _tq@GOTPAGE
Lloh16:
	ldr	x0, [x0, _tq@GOTPAGEOFF]
	bl	_TAILQ_REMOVE
Lloh17:
	adrp	x8, _read_wait@GOTPAGE
Lloh18:
	ldr	x8, [x8, _read_wait@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_FD_CLR
Lloh20:
	adrp	x8, _ncon@GOTPAGE
Lloh21:
	ldr	x8, [x8, _ncon@GOTPAGEOFF]
	ldr	w9, [x8]
	sub	w9, w9, #1
	str	w9, [x8]
	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
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_maxfd,4,2                      ; @maxfd
	.comm	_fdcon,8,3                      ; @fdcon
	.comm	_CS_UNUSED,8,3                  ; @CS_UNUSED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"confree: attempt to free bad fdno %d"

	.comm	_CS_KEYS,8,3                    ; @CS_KEYS
	.comm	_tq,4,2                         ; @tq
	.comm	_c_link,4,2                     ; @c_link
	.comm	_read_wait,4,2                  ; @read_wait
	.comm	_ncon,4,2                       ; @ncon
	.no_dead_strip	_confree
.subsections_via_symbols
