	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_checkDataDir                   ## -- Begin function checkDataDir
	.p2align	4, 0x90
_checkDataDir:                          ## @checkDataDir
	.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	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_DataDir@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	callq	_Assert
	movl	(%r15), %edi
	leaq	-40(%rbp), %rsi
	callq	_stat
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_ENOENT@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	movq	_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	leaq	L_.str(%rip), %rax
	leaq	L_.str.1(%rip), %rbx
	cmoveq	%rax, %rbx
	xorl	%eax, %eax
	callq	_errcode_for_file_access
	movl	(%r15), %esi
	movq	%rbx, %rdi
	callq	_errmsg
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_2:
	movl	-40(%rbp), %edi
	callq	_S_ISDIR
	testl	%eax, %eax
	jne	LBB0_4
## %bb.3:
	movq	_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	movl	(%r15), %esi
	leaq	L_.str.2(%rip), %rdi
	callq	_errmsg
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_4:
	movq	-32(%rbp), %rbx
	xorl	%eax, %eax
	callq	_geteuid
	cmpq	%rax, %rbx
	je	LBB0_6
## %bb.5:
	movq	_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	movl	(%r15), %esi
	leaq	L_.str.3(%rip), %rdi
	callq	_errmsg
	leaq	L_.str.4(%rip), %rdi
	callq	_errhint
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_ereport
LBB0_6:
	movl	-40(%rbp), %edi
	movq	_PG_MODE_MASK_GROUP@GOTPCREL(%rip), %rax
	testl	%edi, (%rax)
	je	LBB0_8
## %bb.7:
	movq	_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_errcode
	movl	(%r15), %esi
	leaq	L_.str.5(%rip), %rdi
	callq	_errmsg
	leaq	L_.str.6(%rip), %rdi
	callq	_errdetail
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_ereport
	movl	-40(%rbp), %edi
LBB0_8:
	callq	_SetDataDirectoryCreatePerm
	movq	_pg_mode_mask@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_umask
	movq	_pg_dir_create_mode@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_data_directory_mode@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movl	(%r15), %edi
	callq	_ValidatePgVersion
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DataDir,4,2                    ## @DataDir
	.comm	_errno,8,3                      ## @errno
	.comm	_ENOENT,8,3                     ## @ENOENT
	.comm	_FATAL,4,2                      ## @FATAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"data directory \"%s\" does not exist"

L_.str.1:                               ## @.str.1
	.asciz	"could not read permissions of directory \"%s\": %m"

	.comm	_ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE,4,2 ## @ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE
L_.str.2:                               ## @.str.2
	.asciz	"specified data directory \"%s\" is not a directory"

L_.str.3:                               ## @.str.3
	.asciz	"data directory \"%s\" has wrong ownership"

L_.str.4:                               ## @.str.4
	.asciz	"The server must be started by the user that owns the data directory."

	.comm	_PG_MODE_MASK_GROUP,4,2         ## @PG_MODE_MASK_GROUP
L_.str.5:                               ## @.str.5
	.asciz	"data directory \"%s\" has invalid permissions"

L_.str.6:                               ## @.str.6
	.asciz	"Permissions should be u=rwx (0700) or u=rwx,g=rx (0750)."

	.comm	_pg_mode_mask,4,2               ## @pg_mode_mask
	.comm	_pg_dir_create_mode,4,2         ## @pg_dir_create_mode
	.comm	_data_directory_mode,4,2        ## @data_directory_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_checkDataDir                   ; -- Begin function checkDataDir
	.p2align	2
_checkDataDir:                          ; @checkDataDir
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
Lloh0:
	adrp	x20, _DataDir@GOTPAGE
Lloh1:
	ldr	x20, [x20, _DataDir@GOTPAGEOFF]
	ldr	w0, [x20]
	bl	_Assert
	ldr	w0, [x20]
	mov	x1, sp
	bl	_stat
Lloh2:
	adrp	x21, _FATAL@GOTPAGE
Lloh3:
	ldr	x21, [x21, _FATAL@GOTPAGEOFF]
	cbz	x0, LBB0_2
; %bb.1:
Lloh4:
	adrp	x8, _errno@GOTPAGE
Lloh5:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh6:
	ldr	x22, [x8]
Lloh7:
	adrp	x8, _ENOENT@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh9:
	ldr	x23, [x8]
	ldr	w19, [x21]
	bl	_errcode_for_file_access
	ldr	w1, [x20]
Lloh10:
	adrp	x8, l_.str.1@PAGE
Lloh11:
	add	x8, x8, l_.str.1@PAGEOFF
Lloh12:
	adrp	x9, l_.str@PAGE
Lloh13:
	add	x9, x9, l_.str@PAGEOFF
	cmp	x22, x23
	csel	x0, x9, x8, eq
	bl	_errmsg
	mov	x1, x0
	mov	x0, x19
	bl	_ereport
LBB0_2:
	ldr	w0, [sp]
	bl	_S_ISDIR
Lloh14:
	adrp	x22, _ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE@GOTPAGE
Lloh15:
	ldr	x22, [x22, _ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE@GOTPAGEOFF]
	cbnz	w0, LBB0_4
; %bb.3:
	ldr	w19, [x21]
	ldr	w0, [x22]
	bl	_errcode
	ldr	w1, [x20]
Lloh16:
	adrp	x0, l_.str.2@PAGE
Lloh17:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_errmsg
	mov	x1, x0
	mov	x0, x19
	bl	_ereport
LBB0_4:
	ldr	x19, [sp, #8]
	bl	_geteuid
	cmp	x19, x0
	b.eq	LBB0_6
; %bb.5:
	ldr	w19, [x21]
	ldr	w0, [x22]
	bl	_errcode
	ldr	w1, [x20]
Lloh18:
	adrp	x0, l_.str.3@PAGE
Lloh19:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_errmsg
Lloh20:
	adrp	x0, l_.str.4@PAGE
Lloh21:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_errhint
	mov	x1, x0
	mov	x0, x19
	bl	_ereport
LBB0_6:
	ldr	w0, [sp]
Lloh22:
	adrp	x8, _PG_MODE_MASK_GROUP@GOTPAGE
Lloh23:
	ldr	x8, [x8, _PG_MODE_MASK_GROUP@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_8
; %bb.7:
	ldr	w19, [x21]
	ldr	w0, [x22]
	bl	_errcode
	ldr	w1, [x20]
Lloh25:
	adrp	x0, l_.str.5@PAGE
Lloh26:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_errmsg
Lloh27:
	adrp	x0, l_.str.6@PAGE
Lloh28:
	add	x0, x0, l_.str.6@PAGEOFF
	bl	_errdetail
	mov	x1, x0
	mov	x0, x19
	bl	_ereport
	ldr	w0, [sp]
LBB0_8:
	bl	_SetDataDirectoryCreatePerm
Lloh29:
	adrp	x8, _pg_mode_mask@GOTPAGE
Lloh30:
	ldr	x8, [x8, _pg_mode_mask@GOTPAGEOFF]
Lloh31:
	ldr	w0, [x8]
	bl	_umask
Lloh32:
	adrp	x8, _pg_dir_create_mode@GOTPAGE
Lloh33:
	ldr	x8, [x8, _pg_dir_create_mode@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
Lloh35:
	adrp	x9, _data_directory_mode@GOTPAGE
Lloh36:
	ldr	x9, [x9, _data_directory_mode@GOTPAGEOFF]
Lloh37:
	str	w8, [x9]
	ldr	w0, [x20]
	bl	_ValidatePgVersion
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotStr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_DataDir,4,2                    ; @DataDir
	.comm	_errno,8,3                      ; @errno
	.comm	_ENOENT,8,3                     ; @ENOENT
	.comm	_FATAL,4,2                      ; @FATAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"data directory \"%s\" does not exist"

l_.str.1:                               ; @.str.1
	.asciz	"could not read permissions of directory \"%s\": %m"

	.comm	_ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE,4,2 ; @ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE
l_.str.2:                               ; @.str.2
	.asciz	"specified data directory \"%s\" is not a directory"

l_.str.3:                               ; @.str.3
	.asciz	"data directory \"%s\" has wrong ownership"

l_.str.4:                               ; @.str.4
	.asciz	"The server must be started by the user that owns the data directory."

	.comm	_PG_MODE_MASK_GROUP,4,2         ; @PG_MODE_MASK_GROUP
l_.str.5:                               ; @.str.5
	.asciz	"data directory \"%s\" has invalid permissions"

l_.str.6:                               ; @.str.6
	.asciz	"Permissions should be u=rwx (0700) or u=rwx,g=rx (0750)."

	.comm	_pg_mode_mask,4,2               ; @pg_mode_mask
	.comm	_pg_dir_create_mode,4,2         ; @pg_dir_create_mode
	.comm	_data_directory_mode,4,2        ; @data_directory_mode
.subsections_via_symbols
