	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_generic_openat                 ## -- Begin function generic_openat
	.p2align	4, 0x90
_generic_openat:                        ## @generic_openat
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r14d
	movl	%edx, %r12d
	movq	%rsi, %r15
	movq	%rdi, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_O_RDWR_@GOTPCREL(%rip), %rax
	testl	%edx, (%rax)
	je	LBB0_4
## %bb.1:
	movq	_O_WRONLY_@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	je	LBB0_4
## %bb.2:
	movq	__EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_35
## %bb.3:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_4:
	movq	%rsp, -56(%rbp)                 ## 8-byte Spill
	movq	_MAX_PATH@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rbx
	movq	_N_SYMLINK_FOLLOW@GOTPCREL(%rip), %rax
	movq	_O_CREAT_@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	andl	%r12d, %ecx
	je	LBB0_6
## %bb.5:
	movq	_N_PARENT_DIR_WRITE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
LBB0_6:
	orl	(%rax), %ecx
	movq	%r13, %rdi
	movq	%r15, %rsi
	movq	%rbx, %rdx
	callq	_path_normalize
	testl	%eax, %eax
	js	LBB0_9
## %bb.7:
	movq	%rbx, %rdi
	callq	_find_mount_and_trim_path
	movq	%rax, %r13
	movq	(%rax), %rax
	movq	%r13, %rdi
	movq	%rbx, %rsi
	movl	%r12d, %edx
	movl	%r14d, %ecx
	callq	*8(%rax)
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_10
## %bb.8:
	movq	%r13, %rdi
	callq	_mount_release
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	jmp	LBB0_33
LBB0_9:
	movl	%eax, %edi
	callq	_ERR_PTR
	movq	%rax, %r14
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	jmp	LBB0_33
LBB0_10:
	movq	%r13, 16(%r14)
	movq	(%r13), %rax
	leaq	-72(%rbp), %rsi
	movq	%r14, %rdi
	callq	*(%rax)
	testl	%eax, %eax
	js	LBB0_13
## %bb.11:
	movl	-64(%rbp), %esi
	movq	%r13, %rdi
	callq	_inode_get
	movl	%eax, 8(%r14)
	movq	_S_IFMT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	-72(%rbp), %eax
	movl	%eax, (%r14)
	movl	%r12d, 4(%r14)
	movq	_O_RDWR_@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	je	LBB0_14
## %bb.12:
	movq	_AC_R@GOTPCREL(%rip), %rax
	movq	_AC_W@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	(%rax), %esi
	jmp	LBB0_18
LBB0_13:
	movl	%eax, %r15d
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	jmp	LBB0_32
LBB0_14:
	movq	_O_WRONLY_@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	je	LBB0_16
## %bb.15:
	movq	_AC_W@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_16:
	movq	_AC_R@GOTPCREL(%rip), %rax
LBB0_17:
	movl	(%rax), %esi
LBB0_18:
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	leaq	-72(%rbp), %rdi
	callq	_access_check
	testl	%eax, %eax
	js	LBB0_31
## %bb.19:
	movl	(%r14), %edi
	callq	_S_ISLNK
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_assert
	movl	(%r14), %edi
	callq	_S_ISBLK
	testq	%rax, %rax
	jne	LBB0_21
## %bb.20:
	movl	(%r14), %edi
	callq	_S_ISCHR
	testq	%rax, %rax
	je	LBB0_26
LBB0_21:
	movl	(%r14), %edi
	callq	_S_ISBLK
	testq	%rax, %rax
	jne	LBB0_24
## %bb.22:
	movq	_DEV_CHAR@GOTPCREL(%rip), %rax
	jmp	LBB0_25
LBB0_24:
	movq	_DEV_BLOCK@GOTPCREL(%rip), %rax
LBB0_25:
	movl	(%rax), %r15d
	movl	-68(%rbp), %edi
	callq	_dev_major
	movl	%eax, %r13d
	movl	-68(%rbp), %edi
	callq	_dev_minor
	movl	%r13d, %edi
	movl	%eax, %esi
	movl	%r15d, %edx
	movq	%r14, %rcx
	callq	_dev_open
	testl	%eax, %eax
	js	LBB0_31
LBB0_26:
	movq	__ENXIO@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	(%r14), %edi
	callq	_S_ISSOCK
	testq	%rax, %rax
	jne	LBB0_32
## %bb.27:
	movq	__EISDIR@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	(%r14), %edi
	callq	_S_ISDIR
	testq	%rax, %rax
	je	LBB0_29
## %bb.28:
	movq	_O_WRONLY_@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_O_RDWR_@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	testl	%r12d, %eax
	jne	LBB0_32
LBB0_29:
	movq	__ENOTDIR@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movl	(%r14), %edi
	callq	_S_ISDIR
	testq	%rax, %rax
	jne	LBB0_33
## %bb.30:
	movq	_O_DIRECTORY_@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	jne	LBB0_32
	jmp	LBB0_33
LBB0_31:
	movl	%eax, %r15d
LBB0_32:
	movq	%r14, %rdi
	callq	_fd_close
	movl	%r15d, %edi
	callq	_ERR_PTR
	movq	%rax, %r14
LBB0_33:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_35
## %bb.34:
	movq	%rbx, %rsp
	movq	%r14, %rax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_35:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_O_RDWR_,4,2                    ## @O_RDWR_
	.comm	_O_WRONLY_,4,2                  ## @O_WRONLY_
	.comm	__EINVAL,4,2                    ## @_EINVAL
	.comm	_MAX_PATH,4,2                   ## @MAX_PATH
	.comm	_N_SYMLINK_FOLLOW,4,2           ## @N_SYMLINK_FOLLOW
	.comm	_O_CREAT_,4,2                   ## @O_CREAT_
	.comm	_N_PARENT_DIR_WRITE,4,2         ## @N_PARENT_DIR_WRITE
	.comm	_S_IFMT,4,2                     ## @S_IFMT
	.comm	_AC_R,4,2                       ## @AC_R
	.comm	_AC_W,4,2                       ## @AC_W
	.comm	_DEV_BLOCK,4,2                  ## @DEV_BLOCK
	.comm	_DEV_CHAR,4,2                   ## @DEV_CHAR
	.comm	__ENXIO,4,2                     ## @_ENXIO
	.comm	__EISDIR,4,2                    ## @_EISDIR
	.comm	__ENOTDIR,4,2                   ## @_ENOTDIR
	.comm	_O_DIRECTORY_,4,2               ## @O_DIRECTORY_
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_generic_openat                 ; -- Begin function generic_openat
	.p2align	2
_generic_openat:                        ; @generic_openat
	.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
	sub	sp, sp, #32
	mov	x20, x3
	mov	x19, x2
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
Lloh3:
	adrp	x24, _O_RDWR_@GOTPAGE
Lloh4:
	ldr	x24, [x24, _O_RDWR_@GOTPAGEOFF]
	ldr	w8, [x24]
	tst	w8, w2
	b.eq	LBB0_4
; %bb.1:
Lloh5:
	adrp	x8, _O_WRONLY_@GOTPAGE
Lloh6:
	ldr	x8, [x8, _O_WRONLY_@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	tst	w8, w19
	b.eq	LBB0_4
; %bb.2:
Lloh8:
	adrp	x8, __EINVAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, __EINVAL@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	ldur	x8, [x29, #-56]
Lloh11:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh12:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_28
; %bb.3:
	sub	sp, x29, #48
	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
	b	_ERR_PTR
LBB0_4:
	mov	x23, sp
Lloh14:
	adrp	x8, _MAX_PATH@GOTPAGE
Lloh15:
	ldr	x8, [x8, _MAX_PATH@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	mov	x9, x8
Lloh17:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh18:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x1fffffff0
	sub	x21, x9, x8
	mov	sp, x21
Lloh19:
	adrp	x8, _N_SYMLINK_FOLLOW@GOTPAGE
Lloh20:
	ldr	x8, [x8, _N_SYMLINK_FOLLOW@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
Lloh22:
	adrp	x9, _O_CREAT_@GOTPAGE
Lloh23:
	ldr	x9, [x9, _O_CREAT_@GOTPAGEOFF]
Lloh24:
	ldr	w9, [x9]
Lloh25:
	adrp	x10, _N_PARENT_DIR_WRITE@GOTPAGE
Lloh26:
	ldr	x10, [x10, _N_PARENT_DIR_WRITE@GOTPAGEOFF]
Lloh27:
	ldr	w10, [x10]
	tst	w9, w19
	csel	w9, wzr, w10, eq
	orr	w3, w9, w8
	mov	x2, x21
	bl	_path_normalize
	tbnz	w0, #31, LBB0_25
; %bb.5:
	mov	x0, x21
	bl	_find_mount_and_trim_path
	mov	x22, x0
	ldr	x8, [x0]
	ldr	x8, [x8, #8]
	mov	x1, x21
	mov	x2, x19
	mov	x3, x20
	blr	x8
	mov	x20, x0
	bl	_IS_ERR
	cbz	x0, LBB0_7
; %bb.6:
	mov	x0, x22
	bl	_mount_release
	b	LBB0_26
LBB0_7:
	str	x22, [x20, #16]
	ldr	x8, [x22]
	ldr	x8, [x8]
	sub	x1, x29, #72
	mov	x0, x20
	blr	x8
	tbnz	w0, #31, LBB0_23
; %bb.8:
	ldur	w1, [x29, #-64]
	mov	x0, x22
	bl	_inode_get
	str	w0, [x20, #8]
	ldur	w8, [x29, #-72]
Lloh28:
	adrp	x9, _S_IFMT@GOTPAGE
Lloh29:
	ldr	x9, [x9, _S_IFMT@GOTPAGEOFF]
Lloh30:
	ldr	w9, [x9]
	and	w8, w9, w8
	stp	w8, w19, [x20]
	ldr	w8, [x24]
	tst	w8, w19
	b.eq	LBB0_10
; %bb.9:
Lloh31:
	adrp	x8, _AC_R@GOTPAGE
Lloh32:
	ldr	x8, [x8, _AC_R@GOTPAGEOFF]
Lloh33:
	ldr	w8, [x8]
Lloh34:
	adrp	x9, _AC_W@GOTPAGE
Lloh35:
	ldr	x9, [x9, _AC_W@GOTPAGEOFF]
Lloh36:
	ldr	w9, [x9]
	orr	w1, w9, w8
	b	LBB0_14
LBB0_10:
Lloh37:
	adrp	x8, _O_WRONLY_@GOTPAGE
Lloh38:
	ldr	x8, [x8, _O_WRONLY_@GOTPAGEOFF]
Lloh39:
	ldr	w8, [x8]
	tst	w8, w19
	b.eq	LBB0_12
; %bb.11:
Lloh40:
	adrp	x8, _AC_W@GOTPAGE
Lloh41:
	ldr	x8, [x8, _AC_W@GOTPAGEOFF]
	b	LBB0_13
LBB0_12:
Lloh42:
	adrp	x8, _AC_R@GOTPAGE
Lloh43:
	ldr	x8, [x8, _AC_R@GOTPAGEOFF]
LBB0_13:
	ldr	w1, [x8]
LBB0_14:
	sub	x0, x29, #72
	bl	_access_check
	tbnz	w0, #31, LBB0_23
; %bb.15:
	ldr	w0, [x20]
	bl	_S_ISLNK
	cmp	w0, #0
	cset	w0, eq
	bl	_assert
	ldr	w0, [x20]
	bl	_S_ISBLK
	cbnz	x0, LBB0_17
; %bb.16:
	ldr	w0, [x20]
	bl	_S_ISCHR
	cbz	x0, LBB0_18
LBB0_17:
	ldr	w0, [x20]
	bl	_S_ISBLK
Lloh44:
	adrp	x8, _DEV_CHAR@GOTPAGE
Lloh45:
	ldr	x8, [x8, _DEV_CHAR@GOTPAGEOFF]
Lloh46:
	adrp	x9, _DEV_BLOCK@GOTPAGE
Lloh47:
	ldr	x9, [x9, _DEV_BLOCK@GOTPAGEOFF]
	cmp	x0, #0
	csel	x8, x8, x9, eq
	ldr	w21, [x8]
	ldur	w0, [x29, #-68]
	bl	_dev_major
	mov	x22, x0
	ldur	w0, [x29, #-68]
	bl	_dev_minor
	mov	x1, x0
	mov	x0, x22
	mov	x2, x21
	mov	x3, x20
	bl	_dev_open
	tbnz	w0, #31, LBB0_23
LBB0_18:
Lloh48:
	adrp	x8, __ENXIO@GOTPAGE
Lloh49:
	ldr	x8, [x8, __ENXIO@GOTPAGEOFF]
Lloh50:
	ldr	w21, [x8]
	ldr	w0, [x20]
	bl	_S_ISSOCK
	cbnz	x0, LBB0_24
; %bb.19:
Lloh51:
	adrp	x8, __EISDIR@GOTPAGE
Lloh52:
	ldr	x8, [x8, __EISDIR@GOTPAGEOFF]
Lloh53:
	ldr	w21, [x8]
	ldr	w0, [x20]
	bl	_S_ISDIR
	cbz	x0, LBB0_21
; %bb.20:
	ldr	w8, [x24]
Lloh54:
	adrp	x9, _O_WRONLY_@GOTPAGE
Lloh55:
	ldr	x9, [x9, _O_WRONLY_@GOTPAGEOFF]
Lloh56:
	ldr	w9, [x9]
	orr	w8, w9, w8
	tst	w8, w19
	b.ne	LBB0_24
LBB0_21:
Lloh57:
	adrp	x8, __ENOTDIR@GOTPAGE
Lloh58:
	ldr	x8, [x8, __ENOTDIR@GOTPAGEOFF]
Lloh59:
	ldr	w21, [x8]
	ldr	w0, [x20]
	bl	_S_ISDIR
	cbnz	x0, LBB0_26
; %bb.22:
Lloh60:
	adrp	x8, _O_DIRECTORY_@GOTPAGE
Lloh61:
	ldr	x8, [x8, _O_DIRECTORY_@GOTPAGEOFF]
Lloh62:
	ldr	w8, [x8]
	tst	w8, w19
	b.ne	LBB0_24
	b	LBB0_26
LBB0_23:
	mov	x21, x0
LBB0_24:
	mov	x0, x20
	bl	_fd_close
	mov	x0, x21
LBB0_25:
	bl	_ERR_PTR
	mov	x20, x0
LBB0_26:
	ldur	x8, [x29, #-56]
Lloh63:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh64:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh65:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_28
; %bb.27:
	mov	sp, x23
	mov	x0, x20
	sub	sp, x29, #48
	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
LBB0_28:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGot	Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpLdrGotLdr	Lloh54, Lloh55, Lloh56
	.loh AdrpLdrGotLdr	Lloh57, Lloh58, Lloh59
	.loh AdrpLdrGotLdr	Lloh60, Lloh61, Lloh62
	.loh AdrpLdrGotLdr	Lloh63, Lloh64, Lloh65
	.cfi_endproc
                                        ; -- End function
	.comm	_O_RDWR_,4,2                    ; @O_RDWR_
	.comm	_O_WRONLY_,4,2                  ; @O_WRONLY_
	.comm	__EINVAL,4,2                    ; @_EINVAL
	.comm	_MAX_PATH,4,2                   ; @MAX_PATH
	.comm	_N_SYMLINK_FOLLOW,4,2           ; @N_SYMLINK_FOLLOW
	.comm	_O_CREAT_,4,2                   ; @O_CREAT_
	.comm	_N_PARENT_DIR_WRITE,4,2         ; @N_PARENT_DIR_WRITE
	.comm	_S_IFMT,4,2                     ; @S_IFMT
	.comm	_AC_R,4,2                       ; @AC_R
	.comm	_AC_W,4,2                       ; @AC_W
	.comm	_DEV_BLOCK,4,2                  ; @DEV_BLOCK
	.comm	_DEV_CHAR,4,2                   ; @DEV_CHAR
	.comm	__ENXIO,4,2                     ; @_ENXIO
	.comm	__EISDIR,4,2                    ; @_EISDIR
	.comm	__ENOTDIR,4,2                   ; @_ENOTDIR
	.comm	_O_DIRECTORY_,4,2               ; @O_DIRECTORY_
.subsections_via_symbols
