	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cleanup
_cleanup:                               ## @cleanup
	.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	_errno@GOTPCREL(%rip), %r15
	movl	(%r15), %r12d
	movl	(%rdi), %ebx
	testl	%ebx, %ebx
	js	LBB0_4
## %bb.1:
	movq	%rdi, %r13
	leaq	-56(%rbp), %r14
	movq	%r14, %rdi
	movl	$12, %esi
	callq	_bzero
	movq	_G_GATE_VERSION@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)
	movl	%ebx, -56(%rbp)
	movl	$1, -52(%rbp)
	movl	8(%r13), %edi
	movq	_G_GATE_CMD_DESTROY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdx
	callq	_ioctl
	cmpl	$-1, %eax
	jne	LBB0_3
## %bb.2:
	movq	_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	4(%r13), %edx
	leaq	L_.str(%rip), %rsi
	callq	_pjdlog_errno
LBB0_3:
	movl	$-1, (%r13)
LBB0_4:
	movl	%r12d, (%r15)
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_errno,4,2                      ## @errno
	.comm	_G_GATE_VERSION,4,2             ## @G_GATE_VERSION
	.comm	_G_GATE_CMD_DESTROY,4,2         ## @G_GATE_CMD_DESTROY
	.comm	_LOG_WARNING,4,2                ## @LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Unable to destroy hast/%s device"

	.no_dead_strip	_cleanup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cleanup
_cleanup:                               ; @cleanup
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
Lloh0:
	adrp	x20, _errno@GOTPAGE
Lloh1:
	ldr	x20, [x20, _errno@GOTPAGEOFF]
	ldr	w21, [x20]
	ldr	w22, [x0]
	tbnz	w22, #31, LBB0_4
; %bb.1:
	mov	x19, x0
	mov	x0, sp
	mov	w1, #12
	bl	_bzero
Lloh2:
	adrp	x8, _G_GATE_VERSION@GOTPAGE
Lloh3:
	ldr	x8, [x8, _G_GATE_VERSION@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x8]
	mov	w8, #1
	str	w22, [sp]
	stp	w8, w9, [sp, #4]
	ldr	w0, [x19, #8]
Lloh5:
	adrp	x8, _G_GATE_CMD_DESTROY@GOTPAGE
Lloh6:
	ldr	x8, [x8, _G_GATE_CMD_DESTROY@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	x2, sp
	bl	_ioctl
	cmn	w0, #1
	b.ne	LBB0_3
; %bb.2:
Lloh8:
	adrp	x8, _LOG_WARNING@GOTPAGE
Lloh9:
	ldr	x8, [x8, _LOG_WARNING@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	ldr	w2, [x19, #4]
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	bl	_pjdlog_errno
LBB0_3:
	mov	w8, #-1
	str	w8, [x19]
LBB0_4:
	str	w21, [x20]
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_errno,4,2                      ; @errno
	.comm	_G_GATE_VERSION,4,2             ; @G_GATE_VERSION
	.comm	_G_GATE_CMD_DESTROY,4,2         ; @G_GATE_CMD_DESTROY
	.comm	_LOG_WARNING,4,2                ; @LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Unable to destroy hast/%s device"

	.no_dead_strip	_cleanup
.subsections_via_symbols
