	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_atf_fs_eaccess                 ## -- Begin function atf_fs_eaccess
	.p2align	4, 0x90
_atf_fs_eaccess:                        ## @atf_fs_eaccess
	.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
	subq	$32, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movq	_atf_fs_access_f@GOTPCREL(%rip), %r12
	movl	$1, %edi
	testl	%esi, (%r12)
	jne	LBB0_4
## %bb.1:
	movq	_atf_fs_access_r@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	jne	LBB0_4
## %bb.2:
	movq	_atf_fs_access_w@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	jne	LBB0_4
## %bb.3:
	movq	_atf_fs_access_x@GOTPCREL(%rip), %rax
	xorl	%edi, %edi
	testl	%r15d, (%rax)
	setne	%dil
LBB0_4:
	callq	_PRE
	movq	%rbx, %rdi
	callq	_atf_fs_path_cstring
	leaq	-56(%rbp), %rsi
	movl	%eax, %edi
	callq	_lstat
	cmpl	$-1, %eax
	je	LBB0_5
## %bb.6:
	xorl	%eax, %eax
	callq	_atf_no_error
	movl	%eax, %r14d
	testl	%r15d, (%r12)
	jne	LBB0_34
## %bb.7:
	xorl	%eax, %eax
	callq	_atf_user_is_root
	testq	%rax, %rax
	je	LBB0_10
## %bb.8:
	movq	_atf_fs_access_x@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	je	LBB0_34
## %bb.9:
	movq	_S_IXUSR@GOTPCREL(%rip), %rax
	movq	_S_IXGRP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movq	_S_IXOTH@GOTPCREL(%rip), %rax
	orl	(%rax), %ecx
	testl	%ecx, -56(%rbp)
	jne	LBB0_34
	jmp	LBB0_32
LBB0_5:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movq	%rbx, %rdi
	callq	_atf_fs_path_cstring
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_atf_libc_error
LBB0_33:
	movl	%eax, %r14d
LBB0_34:
	movl	%r14d, %eax
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	xorl	%eax, %eax
	callq	_atf_user_euid
	cmpq	-48(%rbp), %rax
	jne	LBB0_17
## %bb.11:
	movq	_atf_fs_access_r@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	je	LBB0_13
## %bb.12:
	movq	_S_IRUSR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -56(%rbp)
	jne	LBB0_34
LBB0_13:
	movq	_atf_fs_access_w@GOTPCREL(%rip), %rcx
	movl	-56(%rbp), %eax
	testl	%r15d, (%rcx)
	je	LBB0_15
## %bb.14:
	movq	_S_IWUSR@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_34
LBB0_15:
	movq	_atf_fs_access_x@GOTPCREL(%rip), %rcx
	testl	%r15d, (%rcx)
	je	LBB0_17
## %bb.16:
	movq	_S_IXUSR@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	jne	LBB0_34
LBB0_17:
	movl	-40(%rbp), %edi
	callq	_atf_user_is_member_of_group
	testq	%rax, %rax
	je	LBB0_24
## %bb.18:
	movq	_atf_fs_access_r@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	je	LBB0_20
## %bb.19:
	movq	_S_IRGRP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -56(%rbp)
	jne	LBB0_34
LBB0_20:
	movq	_atf_fs_access_w@GOTPCREL(%rip), %rcx
	movl	-56(%rbp), %eax
	testl	%r15d, (%rcx)
	je	LBB0_22
## %bb.21:
	movq	_S_IWGRP@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_34
LBB0_22:
	movq	_atf_fs_access_x@GOTPCREL(%rip), %rcx
	testl	%r15d, (%rcx)
	je	LBB0_24
## %bb.23:
	movq	_S_IXGRP@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	jne	LBB0_34
LBB0_24:
	xorl	%eax, %eax
	callq	_atf_user_euid
	cmpq	-48(%rbp), %rax
	je	LBB0_32
## %bb.25:
	movl	-40(%rbp), %edi
	callq	_atf_user_is_member_of_group
	testq	%rax, %rax
	je	LBB0_26
LBB0_32:
	movq	_EACCES@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_atf_libc_error
	jmp	LBB0_33
LBB0_26:
	movq	_atf_fs_access_r@GOTPCREL(%rip), %rax
	testl	%r15d, (%rax)
	je	LBB0_28
## %bb.27:
	movq	_S_IROTH@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, -56(%rbp)
	jne	LBB0_34
LBB0_28:
	movq	_atf_fs_access_w@GOTPCREL(%rip), %rcx
	movl	-56(%rbp), %eax
	testl	%r15d, (%rcx)
	je	LBB0_30
## %bb.29:
	movq	_S_IWOTH@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_34
LBB0_30:
	movq	_atf_fs_access_x@GOTPCREL(%rip), %rcx
	testl	%r15d, (%rcx)
	je	LBB0_32
## %bb.31:
	movq	_S_IXOTH@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	jne	LBB0_34
	jmp	LBB0_32
	.cfi_endproc
                                        ## -- End function
	.comm	_atf_fs_access_f,4,2            ## @atf_fs_access_f
	.comm	_atf_fs_access_r,4,2            ## @atf_fs_access_r
	.comm	_atf_fs_access_w,4,2            ## @atf_fs_access_w
	.comm	_atf_fs_access_x,4,2            ## @atf_fs_access_x
	.comm	_errno,4,2                      ## @errno
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Cannot get information from file %s"

	.comm	_S_IXUSR,4,2                    ## @S_IXUSR
	.comm	_S_IXGRP,4,2                    ## @S_IXGRP
	.comm	_S_IXOTH,4,2                    ## @S_IXOTH
	.comm	_S_IRUSR,4,2                    ## @S_IRUSR
	.comm	_S_IWUSR,4,2                    ## @S_IWUSR
	.comm	_S_IRGRP,4,2                    ## @S_IRGRP
	.comm	_S_IWGRP,4,2                    ## @S_IWGRP
	.comm	_S_IROTH,4,2                    ## @S_IROTH
	.comm	_S_IWOTH,4,2                    ## @S_IWOTH
	.comm	_EACCES,4,2                     ## @EACCES
L_.str.1:                               ## @.str.1
	.asciz	"Access check failed"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_atf_fs_eaccess                 ; -- Begin function atf_fs_eaccess
	.p2align	2
_atf_fs_eaccess:                        ; @atf_fs_eaccess
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x21, _atf_fs_access_f@GOTPAGE
Lloh1:
	ldr	x21, [x21, _atf_fs_access_f@GOTPAGEOFF]
	ldr	w8, [x21]
	tst	w8, w1
	b.ne	LBB0_3
; %bb.1:
Lloh2:
	adrp	x8, _atf_fs_access_r@GOTPAGE
Lloh3:
	ldr	x8, [x8, _atf_fs_access_r@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	tst	w8, w20
	b.ne	LBB0_3
; %bb.2:
Lloh5:
	adrp	x8, _atf_fs_access_w@GOTPAGE
Lloh6:
	ldr	x8, [x8, _atf_fs_access_w@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_29
LBB0_3:
	mov	w0, #1
LBB0_4:
	bl	_PRE
	mov	x0, x19
	bl	_atf_fs_path_cstring
	add	x1, sp, #8
	bl	_lstat
	cmn	w0, #1
	b.eq	LBB0_9
; %bb.5:
	bl	_atf_no_error
	mov	x19, x0
	ldr	w8, [x21]
	tst	w8, w20
	b.ne	LBB0_11
; %bb.6:
	bl	_atf_user_is_root
	cbz	x0, LBB0_12
; %bb.7:
Lloh8:
	adrp	x8, _atf_fs_access_x@GOTPAGE
Lloh9:
	ldr	x8, [x8, _atf_fs_access_x@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_11
; %bb.8:
	ldr	w8, [sp, #8]
Lloh11:
	adrp	x9, _S_IXUSR@GOTPAGE
Lloh12:
	ldr	x9, [x9, _S_IXUSR@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
Lloh14:
	adrp	x10, _S_IXGRP@GOTPAGE
Lloh15:
	ldr	x10, [x10, _S_IXGRP@GOTPAGEOFF]
Lloh16:
	ldr	w10, [x10]
	orr	w9, w10, w9
Lloh17:
	adrp	x10, _S_IXOTH@GOTPAGE
Lloh18:
	ldr	x10, [x10, _S_IXOTH@GOTPAGEOFF]
Lloh19:
	ldr	w10, [x10]
	orr	w9, w9, w10
	tst	w9, w8
	b.ne	LBB0_11
	b	LBB0_28
LBB0_9:
Lloh20:
	adrp	x8, _errno@GOTPAGE
Lloh21:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh22:
	ldr	w20, [x8]
	mov	x0, x19
	bl	_atf_fs_path_cstring
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh23:
	adrp	x1, l_.str@PAGE
Lloh24:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
LBB0_10:
	bl	_atf_libc_error
	mov	x19, x0
LBB0_11:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_12:
	bl	_atf_user_euid
	ldr	x8, [sp, #16]
	cmp	x0, x8
	b.ne	LBB0_19
; %bb.13:
Lloh25:
	adrp	x8, _atf_fs_access_r@GOTPAGE
Lloh26:
	ldr	x8, [x8, _atf_fs_access_r@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_15
; %bb.14:
	ldr	w8, [sp, #8]
Lloh28:
	adrp	x9, _S_IRUSR@GOTPAGE
Lloh29:
	ldr	x9, [x9, _S_IRUSR@GOTPAGEOFF]
Lloh30:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_11
LBB0_15:
Lloh31:
	adrp	x8, _atf_fs_access_w@GOTPAGE
Lloh32:
	ldr	x8, [x8, _atf_fs_access_w@GOTPAGEOFF]
Lloh33:
	ldr	w9, [x8]
	ldr	w8, [sp, #8]
	tst	w9, w20
	b.eq	LBB0_17
; %bb.16:
Lloh34:
	adrp	x9, _S_IWUSR@GOTPAGE
Lloh35:
	ldr	x9, [x9, _S_IWUSR@GOTPAGEOFF]
Lloh36:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_11
LBB0_17:
Lloh37:
	adrp	x9, _atf_fs_access_x@GOTPAGE
Lloh38:
	ldr	x9, [x9, _atf_fs_access_x@GOTPAGEOFF]
Lloh39:
	ldr	w9, [x9]
	tst	w9, w20
	b.eq	LBB0_19
; %bb.18:
Lloh40:
	adrp	x9, _S_IXUSR@GOTPAGE
Lloh41:
	ldr	x9, [x9, _S_IXUSR@GOTPAGEOFF]
Lloh42:
	ldr	w9, [x9]
	and	w8, w9, w8
	cbnz	w8, LBB0_11
LBB0_19:
	ldr	w0, [sp, #24]
	bl	_atf_user_is_member_of_group
	cbz	x0, LBB0_26
; %bb.20:
Lloh43:
	adrp	x8, _atf_fs_access_r@GOTPAGE
Lloh44:
	ldr	x8, [x8, _atf_fs_access_r@GOTPAGEOFF]
Lloh45:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_22
; %bb.21:
	ldr	w8, [sp, #8]
Lloh46:
	adrp	x9, _S_IRGRP@GOTPAGE
Lloh47:
	ldr	x9, [x9, _S_IRGRP@GOTPAGEOFF]
Lloh48:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_11
LBB0_22:
Lloh49:
	adrp	x8, _atf_fs_access_w@GOTPAGE
Lloh50:
	ldr	x8, [x8, _atf_fs_access_w@GOTPAGEOFF]
Lloh51:
	ldr	w9, [x8]
	ldr	w8, [sp, #8]
	tst	w9, w20
	b.eq	LBB0_24
; %bb.23:
Lloh52:
	adrp	x9, _S_IWGRP@GOTPAGE
Lloh53:
	ldr	x9, [x9, _S_IWGRP@GOTPAGEOFF]
Lloh54:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_11
LBB0_24:
Lloh55:
	adrp	x9, _atf_fs_access_x@GOTPAGE
Lloh56:
	ldr	x9, [x9, _atf_fs_access_x@GOTPAGEOFF]
Lloh57:
	ldr	w9, [x9]
	tst	w9, w20
	b.eq	LBB0_26
; %bb.25:
Lloh58:
	adrp	x9, _S_IXGRP@GOTPAGE
Lloh59:
	ldr	x9, [x9, _S_IXGRP@GOTPAGEOFF]
Lloh60:
	ldr	w9, [x9]
	and	w8, w9, w8
	cbnz	w8, LBB0_11
LBB0_26:
	bl	_atf_user_euid
	ldr	x8, [sp, #16]
	cmp	x0, x8
	b.eq	LBB0_28
; %bb.27:
	ldr	w0, [sp, #24]
	bl	_atf_user_is_member_of_group
	cbz	x0, LBB0_30
LBB0_28:
Lloh61:
	adrp	x8, _EACCES@GOTPAGE
Lloh62:
	ldr	x8, [x8, _EACCES@GOTPAGEOFF]
Lloh63:
	ldr	w0, [x8]
Lloh64:
	adrp	x1, l_.str.1@PAGE
Lloh65:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_10
LBB0_29:
Lloh66:
	adrp	x8, _atf_fs_access_x@GOTPAGE
Lloh67:
	ldr	x8, [x8, _atf_fs_access_x@GOTPAGEOFF]
Lloh68:
	ldr	w8, [x8]
	tst	w8, w20
	cset	w0, ne
	b	LBB0_4
LBB0_30:
Lloh69:
	adrp	x8, _atf_fs_access_r@GOTPAGE
Lloh70:
	ldr	x8, [x8, _atf_fs_access_r@GOTPAGEOFF]
Lloh71:
	ldr	w8, [x8]
	tst	w8, w20
	b.eq	LBB0_32
; %bb.31:
	ldr	w8, [sp, #8]
Lloh72:
	adrp	x9, _S_IROTH@GOTPAGE
Lloh73:
	ldr	x9, [x9, _S_IROTH@GOTPAGEOFF]
Lloh74:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_11
LBB0_32:
Lloh75:
	adrp	x8, _atf_fs_access_w@GOTPAGE
Lloh76:
	ldr	x8, [x8, _atf_fs_access_w@GOTPAGEOFF]
Lloh77:
	ldr	w9, [x8]
	ldr	w8, [sp, #8]
	tst	w9, w20
	b.eq	LBB0_34
; %bb.33:
Lloh78:
	adrp	x9, _S_IWOTH@GOTPAGE
Lloh79:
	ldr	x9, [x9, _S_IWOTH@GOTPAGEOFF]
Lloh80:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_11
LBB0_34:
Lloh81:
	adrp	x9, _atf_fs_access_x@GOTPAGE
Lloh82:
	ldr	x9, [x9, _atf_fs_access_x@GOTPAGEOFF]
Lloh83:
	ldr	w9, [x9]
	tst	w9, w20
	b.eq	LBB0_28
; %bb.35:
Lloh84:
	adrp	x9, _S_IXOTH@GOTPAGE
Lloh85:
	ldr	x9, [x9, _S_IXOTH@GOTPAGEOFF]
Lloh86:
	ldr	w9, [x9]
	and	w8, w9, w8
	cbnz	w8, LBB0_11
	b	LBB0_28
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.loh AdrpLdrGotLdr	Lloh49, Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh52, Lloh53, Lloh54
	.loh AdrpLdrGotLdr	Lloh55, Lloh56, Lloh57
	.loh AdrpLdrGotLdr	Lloh58, Lloh59, Lloh60
	.loh AdrpAdd	Lloh64, Lloh65
	.loh AdrpLdrGotLdr	Lloh61, Lloh62, Lloh63
	.loh AdrpLdrGotLdr	Lloh66, Lloh67, Lloh68
	.loh AdrpLdrGotLdr	Lloh69, Lloh70, Lloh71
	.loh AdrpLdrGotLdr	Lloh72, Lloh73, Lloh74
	.loh AdrpLdrGotLdr	Lloh75, Lloh76, Lloh77
	.loh AdrpLdrGotLdr	Lloh78, Lloh79, Lloh80
	.loh AdrpLdrGotLdr	Lloh81, Lloh82, Lloh83
	.loh AdrpLdrGotLdr	Lloh84, Lloh85, Lloh86
	.cfi_endproc
                                        ; -- End function
	.comm	_atf_fs_access_f,4,2            ; @atf_fs_access_f
	.comm	_atf_fs_access_r,4,2            ; @atf_fs_access_r
	.comm	_atf_fs_access_w,4,2            ; @atf_fs_access_w
	.comm	_atf_fs_access_x,4,2            ; @atf_fs_access_x
	.comm	_errno,4,2                      ; @errno
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Cannot get information from file %s"

	.comm	_S_IXUSR,4,2                    ; @S_IXUSR
	.comm	_S_IXGRP,4,2                    ; @S_IXGRP
	.comm	_S_IXOTH,4,2                    ; @S_IXOTH
	.comm	_S_IRUSR,4,2                    ; @S_IRUSR
	.comm	_S_IWUSR,4,2                    ; @S_IWUSR
	.comm	_S_IRGRP,4,2                    ; @S_IRGRP
	.comm	_S_IWGRP,4,2                    ; @S_IWGRP
	.comm	_S_IROTH,4,2                    ; @S_IROTH
	.comm	_S_IWOTH,4,2                    ; @S_IWOTH
	.comm	_EACCES,4,2                     ; @EACCES
l_.str.1:                               ; @.str.1
	.asciz	"Access check failed"

.subsections_via_symbols
