	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function filesys_unlink
_filesys_unlink:                        ## @filesys_unlink
	.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
	movq	%rdi, %rbx
	leaq	L_.str(%rip), %rsi
	movl	$2, %edi
	movq	%rbx, %rdx
	callq	_vkprintf
	movq	_lf_unlink@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_filesys_lookup_file
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movq	%rax, %rbx
	movl	(%rax), %edi
	movl	$-1, %esi
	callq	_get_inode_f
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	cmpq	$0, (%rax)
	jg	LBB0_7
## %bb.6:
	movq	%rax, %rdi
	callq	_free_inode
LBB0_7:
	movq	%rbx, %rdi
	callq	_filesys_directory_node_free
	xorl	%eax, %eax
	jmp	LBB0_8
LBB0_1:
	movq	_ENOENT@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_4:
	movq	_EFAULT@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"filesys_unlink (%s)\n"

	.comm	_lf_unlink,4,2                  ## @lf_unlink
	.comm	_ENOENT,4,2                     ## @ENOENT
	.comm	_EFAULT,4,2                     ## @EFAULT
	.no_dead_strip	_filesys_unlink
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function filesys_unlink
_filesys_unlink:                        ; @filesys_unlink
	.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	x19, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #2
	mov	x2, x19
	bl	_vkprintf
Lloh2:
	adrp	x8, _lf_unlink@GOTPAGE
Lloh3:
	ldr	x8, [x8, _lf_unlink@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_filesys_lookup_file
	cbz	x0, LBB0_5
; %bb.1:
	mov	x19, x0
	ldr	w0, [x0]
	mov	w1, #-1
	bl	_get_inode_f
	cbz	x0, LBB0_6
; %bb.2:
	ldr	x8, [x0]
	cmp	x8, #0
	b.gt	LBB0_4
; %bb.3:
	bl	_free_inode
LBB0_4:
	mov	x0, x19
	bl	_filesys_directory_node_free
	mov	w0, #0
	b	LBB0_8
LBB0_5:
Lloh5:
	adrp	x8, _ENOENT@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
	b	LBB0_7
LBB0_6:
Lloh7:
	adrp	x8, _EFAULT@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
LBB0_7:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_8:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"filesys_unlink (%s)\n"

	.comm	_lf_unlink,4,2                  ; @lf_unlink
	.comm	_ENOENT,4,2                     ; @ENOENT
	.comm	_EFAULT,4,2                     ; @EFAULT
	.no_dead_strip	_filesys_unlink
.subsections_via_symbols
