	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_atf_text_to_long               ## -- Begin function atf_text_to_long
	.p2align	4, 0x90
_atf_text_to_long:                      ## @atf_text_to_long
	.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
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	_errno@GOTPCREL(%rip), %r15
	movq	$0, (%r15)
	leaq	-32(%rbp), %rsi
	movl	$10, %edx
	callq	_strtol
	cmpb	$0, (%rbx)
	je	LBB0_2
## %bb.1:
	movq	-32(%rbp), %rcx
	cmpb	$0, (%rcx)
	je	LBB0_3
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	leaq	L_.str(%rip), %rsi
LBB0_7:
	movq	%rbx, %rdx
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_atf_libc_error                 ## TAILCALL
LBB0_3:
	movq	_ERANGE@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdi
	cmpq	%rdi, (%r15)
	je	LBB0_6
## %bb.4:
	movq	_LONG_MAX@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_6
## %bb.5:
	movq	_LONG_MIN@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_6
## %bb.8:
	movq	%rax, (%r14)
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_atf_no_error                   ## TAILCALL
LBB0_6:
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_7
	.cfi_endproc
                                        ## -- End function
	.comm	_errno,8,3                      ## @errno
	.comm	_EINVAL,8,3                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"'%s' is not a number"

	.comm	_ERANGE,8,3                     ## @ERANGE
	.comm	_LONG_MAX,8,3                   ## @LONG_MAX
	.comm	_LONG_MIN,8,3                   ## @LONG_MIN
L_.str.1:                               ## @.str.1
	.asciz	"'%s' is out of range"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_atf_text_to_long               ; -- Begin function atf_text_to_long
	.p2align	2
_atf_text_to_long:                      ; @atf_text_to_long
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x21, _errno@GOTPAGE
Lloh1:
	ldr	x21, [x21, _errno@GOTPAGEOFF]
	str	xzr, [x21]
	add	x1, sp, #8
	mov	w2, #10
	bl	_strtol
	ldrb	w8, [x19]
	cbz	w8, LBB0_2
; %bb.1:
	ldr	x8, [sp, #8]
	ldrb	w8, [x8]
	cbz	w8, LBB0_4
LBB0_2:
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh4:
	ldr	x0, [x8]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
LBB0_3:
	mov	x2, x19
	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
	add	sp, sp, #64
	b	_atf_libc_error
LBB0_4:
	ldr	x9, [x21]
Lloh7:
	adrp	x8, _ERANGE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ERANGE@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
Lloh10:
	adrp	x10, _LONG_MAX@GOTPAGE
Lloh11:
	ldr	x10, [x10, _LONG_MAX@GOTPAGEOFF]
Lloh12:
	ldr	x10, [x10]
Lloh13:
	adrp	x11, _LONG_MIN@GOTPAGE
Lloh14:
	ldr	x11, [x11, _LONG_MIN@GOTPAGEOFF]
Lloh15:
	ldr	x11, [x11]
	cmp	x9, x8
	ccmp	x0, x10, #4, ne
	ccmp	x0, x11, #4, ne
	b.ne	LBB0_6
; %bb.5:
Lloh16:
	adrp	x1, l_.str.1@PAGE
Lloh17:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x8
	b	LBB0_3
LBB0_6:
	str	x0, [x20]
	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
	add	sp, sp, #64
	b	_atf_no_error
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_errno,8,3                      ; @errno
	.comm	_EINVAL,8,3                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"'%s' is not a number"

	.comm	_ERANGE,8,3                     ; @ERANGE
	.comm	_LONG_MAX,8,3                   ; @LONG_MAX
	.comm	_LONG_MIN,8,3                   ; @LONG_MIN
l_.str.1:                               ; @.str.1
	.asciz	"'%s' is out of range"

.subsections_via_symbols
