	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Platform_getProcessEnv         ## -- Begin function Platform_getProcessEnv
	.p2align	4, 0x90
_Platform_getProcessEnv:                ## @Platform_getProcessEnv
	.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	$48, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %ecx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -40(%rbp)
	leaq	L_.str(%rip), %rdx
	leaq	-80(%rbp), %rbx
	movq	%rbx, %rdi
	movl	$32, %esi
	callq	_xSnprintf
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_fopen
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	movl	$4096, %r12d                    ## imm = 0x1000
	movl	$4096, %edi                     ## imm = 0x1000
	callq	_xMalloc
	testq	%rax, %rax
	je	LBB0_15
## %bb.3:
	movq	%rax, %r14
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	leaq	(%r14,%rbx), %rdi
	movq	%r12, %rdx
	subq	%rbx, %rdx
	movl	$1, %esi
	movq	%r15, %rcx
	callq	_fread
	testq	%rax, %rax
	je	LBB0_7
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	addq	%rax, %rbx
	addq	%r12, %r12
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_xRealloc
	movq	%rax, %r14
	testq	%rax, %rax
	jne	LBB0_4
## %bb.6:
	xorl	%r14d, %r14d
LBB0_7:
	movq	%r15, %rdi
	callq	_fclose
	cmpq	$2, %rbx
	jb	LBB0_10
## %bb.8:
	cmpb	$0, -1(%rbx,%r14)
	jne	LBB0_10
## %bb.9:
	cmpb	$0, -2(%rbx,%r14)
	jne	LBB0_10
	jmp	LBB0_13
LBB0_1:
	xorl	%r14d, %r14d
	jmp	LBB0_13
LBB0_15:
	movq	%r15, %rdi
	callq	_fclose
	movl	$4096, %r12d                    ## imm = 0x1000
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
LBB0_10:
	leaq	2(%rbx), %rax
	cmpq	%r12, %rax
	jae	LBB0_12
## %bb.11:
	orq	$2, %r12
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_xRealloc
	movq	%rax, %r14
LBB0_12:
	movw	$0, (%r14,%rbx)
LBB0_13:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-40(%rbp), %rax
	jne	LBB0_16
## %bb.14:
	movq	%r14, %rax
	addq	$48, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_16:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"/proc/%d/environ"

L_.str.1:                               ## @.str.1
	.asciz	"r"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Platform_getProcessEnv         ; -- Begin function Platform_getProcessEnv
	.p2align	2
_Platform_getProcessEnv:                ; @Platform_getProcessEnv
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x3, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	add	x0, sp, #7
	mov	w1, #32
	bl	_xSnprintf
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x0, sp, #7
	bl	_fopen
	cbz	x0, LBB0_8
; %bb.1:
	mov	x21, x0
	mov	w0, #4096
	bl	_xMalloc
	mov	x19, x0
	cbz	x0, LBB0_9
; %bb.2:
	mov	x22, #0
	mov	w20, #4096
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	add	x0, x19, x22
	sub	x2, x20, x22
	mov	w1, #1
	mov	x3, x21
	bl	_fread
	cbz	x0, LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x22, x0, x22
	lsl	x20, x20, #1
	mov	x0, x19
	mov	x1, x20
	bl	_xRealloc
	mov	x19, x0
	cbnz	x0, LBB0_3
LBB0_5:
	mov	x0, x21
	bl	_fclose
	cmp	x22, #2
	b.lo	LBB0_10
; %bb.6:
	add	x8, x22, x19
	ldurb	w9, [x8, #-1]
	cbnz	w9, LBB0_10
; %bb.7:
	ldurb	w8, [x8, #-2]
	cbnz	w8, LBB0_10
	b	LBB0_13
LBB0_8:
	mov	x19, #0
	b	LBB0_13
LBB0_9:
	mov	x0, x21
	bl	_fclose
	mov	x22, #0
	mov	w20, #4096
LBB0_10:
	add	x8, x22, #2
	cmp	x8, x20
	b.hs	LBB0_12
; %bb.11:
	orr	x1, x20, #0x2
	mov	x0, x19
	bl	_xRealloc
	mov	x19, x0
LBB0_12:
	strh	wzr, [x19, x22]
LBB0_13:
	ldr	x8, [sp, #40]
Lloh7:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh8:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_15
; %bb.14:
	mov	x0, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_15:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"/proc/%d/environ"

l_.str.1:                               ; @.str.1
	.asciz	"r"

.subsections_via_symbols
