	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_get_tty_line                   ## -- Begin function get_tty_line
	.p2align	4, 0x90
_get_tty_line:                          ## @get_tty_line
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_stdin@GOTPCREL(%rip), %r12
	movq	_ibuf@GOTPCREL(%rip), %r13
	xorl	%r15d, %r15d
LBB0_1:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_2 Depth 2
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_2:                                 ##   Parent Loop BB0_1 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	xorl	%eax, %eax
	callq	_getchar
	cmpl	$128, %eax
	jne	LBB0_3
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=2
	movl	(%r12), %edi
	callq	_ferror
	testl	%eax, %eax
	jne	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=2
	movl	(%r12), %edi
	callq	_clearerr
	movl	%r14d, %eax
	movq	%r15, %r14
	cmpq	%rax, %r15
	jne	LBB0_2
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	%eax, %ebx
	movq	(%r13), %rdi
	movq	_ibufsz@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leal	2(%r15), %edx
	callq	_REALLOC
	movq	(%r13), %rax
	movb	%bl, (%rax,%r15)
	testb	%bl, %bl
	jne	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	_isbinary@GOTPCREL(%rip), %rax
	movl	$1, (%rax)
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	incq	%r15
	cmpl	$10, %ebx
	jne	LBB0_1
## %bb.6:
	movq	_lineno@GOTPCREL(%rip), %rax
	incl	(%rax)
	jmp	LBB0_11
LBB0_8:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_strerror
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edi
	movq	%rax, %rdx
	callq	_fprintf
	leaq	L_.str.1(%rip), %rax
	movq	_errmsg@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	movl	(%r12), %edi
	callq	_clearerr
	movq	_ibufp@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	movq	_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	jmp	LBB0_13
LBB0_10:
	testl	%r15d, %r15d
	je	LBB0_12
LBB0_11:
	movq	(%r13), %rax
	movl	%r15d, %ecx
	movb	$0, (%rax,%rcx)
LBB0_12:
	movq	(%r13), %rax
	movq	_ibufp@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
LBB0_13:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ibuf,8,3                       ## @ibuf
	.comm	_ibufsz,4,2                     ## @ibufsz
	.comm	_ERR,4,2                        ## @ERR
	.comm	_isbinary,4,2                   ## @isbinary
	.comm	_lineno,4,2                     ## @lineno
	.comm	_ibufp,8,3                      ## @ibufp
	.comm	_stdin,4,2                      ## @stdin
	.comm	_stderr,4,2                     ## @stderr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"stdin: %s\n"

	.comm	_errno,4,2                      ## @errno
L_.str.1:                               ## @.str.1
	.asciz	"cannot read stdin"

	.comm	_errmsg,8,3                     ## @errmsg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_get_tty_line                   ; -- Begin function get_tty_line
	.p2align	2
_get_tty_line:                          ; @get_tty_line
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, #0
Lloh0:
	adrp	x22, _stdin@GOTPAGE
Lloh1:
	ldr	x22, [x22, _stdin@GOTPAGEOFF]
Lloh2:
	adrp	x23, _ibuf@GOTPAGE
Lloh3:
	ldr	x23, [x23, _ibuf@GOTPAGEOFF]
Lloh4:
	adrp	x24, _ibufsz@GOTPAGE
Lloh5:
	ldr	x24, [x24, _ibufsz@GOTPAGEOFF]
Lloh6:
	adrp	x21, _ERR@GOTPAGE
Lloh7:
	ldr	x21, [x21, _ERR@GOTPAGEOFF]
	mov	w25, #1
Lloh8:
	adrp	x26, _isbinary@GOTPAGE
Lloh9:
	ldr	x26, [x26, _isbinary@GOTPAGEOFF]
LBB0_1:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_2 Depth 2
	mov	x27, #0
LBB0_2:                                 ;   Parent Loop BB0_1 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	bl	_getchar
	cmp	w0, #128
	b.ne	LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=2
	ldr	w0, [x22]
	bl	_ferror
	cbnz	w0, LBB0_9
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=2
	ldr	w0, [x22]
	bl	_clearerr
	cmp	x19, w27, uxtw
	mov	x27, x19
	b.ne	LBB0_2
	b	LBB0_10
LBB0_5:                                 ;   in Loop: Header=BB0_1 Depth=1
	mov	x20, x0
	ldr	x0, [x23]
	ldr	w1, [x24]
	add	w2, w19, #2
	ldr	w3, [x21]
	bl	_REALLOC
	ldr	x8, [x23]
	strb	w20, [x8, x19]
	tst	w20, #0xff
	b.ne	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_1 Depth=1
	str	w25, [x26]
LBB0_7:                                 ;   in Loop: Header=BB0_1 Depth=1
	add	x19, x19, #1
	cmp	w20, #10
	b.ne	LBB0_1
; %bb.8:
Lloh10:
	adrp	x8, _lineno@GOTPAGE
Lloh11:
	ldr	x8, [x8, _lineno@GOTPAGEOFF]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
	b	LBB0_11
LBB0_9:
Lloh12:
	adrp	x8, _stderr@GOTPAGE
Lloh13:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh14:
	ldr	w19, [x8]
Lloh15:
	adrp	x8, _errno@GOTPAGE
Lloh16:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
	bl	_strerror
	mov	x2, x0
Lloh18:
	adrp	x1, l_.str@PAGE
Lloh19:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_fprintf
Lloh20:
	adrp	x8, _errmsg@GOTPAGE
Lloh21:
	ldr	x8, [x8, _errmsg@GOTPAGEOFF]
Lloh22:
	adrp	x9, l_.str.1@PAGE
Lloh23:
	add	x9, x9, l_.str.1@PAGEOFF
Lloh24:
	str	x9, [x8]
	ldr	w0, [x22]
	bl	_clearerr
Lloh25:
	adrp	x8, _ibufp@GOTPAGE
Lloh26:
	ldr	x8, [x8, _ibufp@GOTPAGEOFF]
Lloh27:
	str	xzr, [x8]
	ldr	w19, [x21]
	b	LBB0_13
LBB0_10:
	cbz	w19, LBB0_12
LBB0_11:
	ldr	x8, [x23]
	strb	wzr, [x8, w19, uxtw]
LBB0_12:
	ldr	x8, [x23]
Lloh28:
	adrp	x9, _ibufp@GOTPAGE
Lloh29:
	ldr	x9, [x9, _ibufp@GOTPAGEOFF]
Lloh30:
	str	x8, [x9]
LBB0_13:
	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
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotStr	Lloh25, Lloh26, Lloh27
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotStr	Lloh20, Lloh21, Lloh24
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotStr	Lloh28, Lloh29, Lloh30
	.cfi_endproc
                                        ; -- End function
	.comm	_ibuf,8,3                       ; @ibuf
	.comm	_ibufsz,4,2                     ; @ibufsz
	.comm	_ERR,4,2                        ; @ERR
	.comm	_isbinary,4,2                   ; @isbinary
	.comm	_lineno,4,2                     ; @lineno
	.comm	_ibufp,8,3                      ; @ibufp
	.comm	_stdin,4,2                      ; @stdin
	.comm	_stderr,4,2                     ; @stderr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"stdin: %s\n"

	.comm	_errno,4,2                      ; @errno
l_.str.1:                               ; @.str.1
	.asciz	"cannot read stdin"

	.comm	_errmsg,8,3                     ; @errmsg
.subsections_via_symbols
