	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_atf_utils_fork                 ## -- Begin function atf_utils_fork
	.p2align	4, 0x90
_atf_utils_fork:                        ## @atf_utils_fork
	.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	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%eax, %eax
	callq	_fork
	movl	%eax, %ebx
	testl	%eax, %eax
	je	LBB0_3
## %bb.1:
	cmpl	$-1, %ebx
	jne	LBB0_4
## %bb.2:
	leaq	L_.str(%rip), %rdi
	callq	_atf_tc_fail
	jmp	LBB0_4
LBB0_3:
	xorl	%eax, %eax
	callq	_getpid
	leaq	L_.str.1(%rip), %rdx
	leaq	-40(%rbp), %r14
	movq	%r14, %rdi
	movl	%eax, %esi
	xorl	%ecx, %ecx
	callq	_init_out_filename
	xorl	%eax, %eax
	callq	_getpid
	leaq	L_.str.2(%rip), %rdx
	leaq	-36(%rbp), %r15
	movq	%r15, %rdi
	movl	%eax, %esi
	xorl	%ecx, %ecx
	callq	_init_out_filename
	movq	_STDOUT_FILENO@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	%r14, %rdi
	callq	_atf_dynstr_cstring
	movl	%r12d, %edi
	movl	%eax, %esi
	callq	_atf_utils_redirect
	movq	_STDERR_FILENO@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movq	%r15, %rdi
	callq	_atf_dynstr_cstring
	movl	%r12d, %edi
	movl	%eax, %esi
	callq	_atf_utils_redirect
	movq	%r15, %rdi
	callq	_atf_dynstr_fini
	movq	%r14, %rdi
	callq	_atf_dynstr_fini
LBB0_4:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"fork failed"

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

L_.str.2:                               ## @.str.2
	.asciz	"err"

	.comm	_STDOUT_FILENO,4,2              ## @STDOUT_FILENO
	.comm	_STDERR_FILENO,4,2              ## @STDERR_FILENO
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_atf_utils_fork                 ; -- Begin function atf_utils_fork
	.p2align	2
_atf_utils_fork:                        ; @atf_utils_fork
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	bl	_fork
	mov	x19, x0
	cbz	w0, LBB0_3
; %bb.1:
	cmn	w19, #1
	b.ne	LBB0_4
; %bb.2:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_atf_tc_fail
	b	LBB0_4
LBB0_3:
	bl	_getpid
	mov	x1, x0
Lloh2:
	adrp	x2, l_.str.1@PAGE
Lloh3:
	add	x2, x2, l_.str.1@PAGEOFF
	add	x0, sp, #12
	mov	w3, #0
	bl	_init_out_filename
	bl	_getpid
	mov	x1, x0
Lloh4:
	adrp	x2, l_.str.2@PAGE
Lloh5:
	add	x2, x2, l_.str.2@PAGEOFF
	add	x0, sp, #8
	mov	w3, #0
	bl	_init_out_filename
Lloh6:
	adrp	x8, _STDOUT_FILENO@GOTPAGE
Lloh7:
	ldr	x8, [x8, _STDOUT_FILENO@GOTPAGEOFF]
Lloh8:
	ldr	w20, [x8]
	add	x0, sp, #12
	bl	_atf_dynstr_cstring
	mov	x1, x0
	mov	x0, x20
	bl	_atf_utils_redirect
Lloh9:
	adrp	x8, _STDERR_FILENO@GOTPAGE
Lloh10:
	ldr	x8, [x8, _STDERR_FILENO@GOTPAGEOFF]
Lloh11:
	ldr	w20, [x8]
	add	x0, sp, #8
	bl	_atf_dynstr_cstring
	mov	x1, x0
	mov	x0, x20
	bl	_atf_utils_redirect
	add	x0, sp, #8
	bl	_atf_dynstr_fini
	add	x0, sp, #12
	bl	_atf_dynstr_fini
LBB0_4:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"fork failed"

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

l_.str.2:                               ; @.str.2
	.asciz	"err"

	.comm	_STDOUT_FILENO,4,2              ; @STDOUT_FILENO
	.comm	_STDERR_FILENO,4,2              ; @STDERR_FILENO
.subsections_via_symbols
