	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_RefPlusOne                     ## -- Begin function RefPlusOne
	.p2align	4, 0x90
_RefPlusOne:                            ## @RefPlusOne
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_Cursor@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_LastChar@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_21
## %bb.1:
	movl	%edi, %r14d
	movq	_rprompt_h@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	testq	%rcx, %rcx
	je	LBB0_3
## %bb.2:
	movq	_TermH@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	_CursorH@GOTPCREL(%rip), %rsi
	addq	(%rsi), %rcx
	subq	%rcx, %rdx
	cmpq	$2, %rdx
	jle	LBB0_21
LBB0_3:
	subl	%r14d, %eax
	movslq	%eax, %r15
	movq	_CHAR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	andl	(%r15), %ebx
	movq	_InputBuf@GOTPCREL(%rip), %rax
	xorl	%esi, %esi
	cmpq	%r15, (%rax)
	sete	%sil
	movl	%ebx, %edi
	xorl	%edx, %edx
	callq	_NLSClassify
	cmpl	$1, %eax
	je	LBB0_11
## %bb.4:
	cmpl	$128, %eax
	je	LBB0_10
## %bb.5:
	cmpl	$129, %eax
	jne	LBB0_21
## %bb.6:
	movl	$94, %edi
	movl	$1, %esi
	callq	_PutPlusOne
	movl	$127, %edi
	callq	_CTL_ESC
	cmpl	%eax, %ebx
	jne	LBB0_9
## %bb.7:
	movl	$63, %edi
	jmp	LBB0_8
LBB0_21:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_Refresh                        ## TAILCALL
LBB0_11:
	movq	_STRhighlight@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	callq	_adrof
	movq	_MarkIsSet@GOTPCREL(%rip), %r12
	testl	%eax, %eax
	je	LBB0_14
## %bb.12:
	cmpl	$0, (%r12)
	je	LBB0_14
## %bb.13:
	xorl	%eax, %eax
	callq	_StartHighlight
LBB0_14:
	cmpl	$2, %r14d
	jl	LBB0_16
## %bb.15:
	movq	%r15, %rdi
	movl	%r14d, %esi
	xorl	%edx, %edx
	callq	_MakeLiteral
	movl	%eax, %edi
	jmp	LBB0_17
LBB0_10:
	movl	$92, %edi
	movl	$1, %esi
	callq	_PutPlusOne
	movl	%ebx, %edi
	shrl	$6, %edi
	andl	$7, %edi
	orl	$48, %edi
	movl	$1, %esi
	callq	_PutPlusOne
	movl	%ebx, %edi
	shrl	$3, %edi
	andl	$7, %edi
	orl	$48, %edi
	movl	$1, %esi
	callq	_PutPlusOne
	andl	$7, %ebx
	orl	$48, %ebx
	movl	%ebx, %edi
	jmp	LBB0_8
LBB0_9:
	movslq	%ebx, %rax
	movq	__toebcdic@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	__toascii@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movslq	(%rdx,%rax,4), %rax
	orq	$64, %rax
	shlq	$2, %rax
	movl	(%rcx,%rax), %edi
LBB0_8:
	movl	$1, %esi
	callq	_PutPlusOne
	jmp	LBB0_20
LBB0_16:
	movl	(%r15), %edi
LBB0_17:
	movl	$1, %esi
	callq	_PutPlusOne
	movl	(%rbx), %edi
	callq	_adrof
	testl	%eax, %eax
	je	LBB0_20
## %bb.18:
	cmpl	$0, (%r12)
	je	LBB0_20
## %bb.19:
	xorl	%eax, %eax
	callq	_StopHighlight
LBB0_20:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_flush                          ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_Cursor,4,2                     ## @Cursor
	.comm	_LastChar,4,2                   ## @LastChar
	.comm	_rprompt_h,8,3                  ## @rprompt_h
	.comm	_TermH,8,3                      ## @TermH
	.comm	_CursorH,8,3                    ## @CursorH
	.comm	_CHAR,4,2                       ## @CHAR
	.comm	_InputBuf,8,3                   ## @InputBuf
	.comm	__toebcdic,8,3                  ## @_toebcdic
	.comm	__toascii,8,3                   ## @_toascii
	.comm	_STRhighlight,4,2               ## @STRhighlight
	.comm	_MarkIsSet,4,2                  ## @MarkIsSet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_RefPlusOne                     ; -- Begin function RefPlusOne
	.p2align	2
_RefPlusOne:                            ; @RefPlusOne
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
Lloh0:
	adrp	x8, _Cursor@GOTPAGE
Lloh1:
	ldr	x8, [x8, _Cursor@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _LastChar@GOTPAGE
Lloh4:
	ldr	x9, [x9, _LastChar@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_8
; %bb.1:
	mov	x19, x0
Lloh6:
	adrp	x9, _rprompt_h@GOTPAGE
Lloh7:
	ldr	x9, [x9, _rprompt_h@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cbz	x9, LBB0_3
; %bb.2:
Lloh9:
	adrp	x10, _TermH@GOTPAGE
Lloh10:
	ldr	x10, [x10, _TermH@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
Lloh12:
	adrp	x11, _CursorH@GOTPAGE
Lloh13:
	ldr	x11, [x11, _CursorH@GOTPAGEOFF]
Lloh14:
	ldr	x11, [x11]
	add	x9, x9, x11
	sub	x9, x10, x9
	cmp	x9, #2
	b.le	LBB0_8
LBB0_3:
	sub	w8, w8, w19
	sxtw	x21, w8
	ldr	w8, [x21]
Lloh15:
	adrp	x9, _CHAR@GOTPAGE
Lloh16:
	ldr	x9, [x9, _CHAR@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	and	w20, w9, w8
Lloh18:
	adrp	x8, _InputBuf@GOTPAGE
Lloh19:
	ldr	x8, [x8, _InputBuf@GOTPAGEOFF]
Lloh20:
	ldr	x8, [x8]
	cmp	x8, x21
	cset	w1, eq
	mov	x0, x20
	mov	w2, #0
	bl	_NLSClassify
	cmp	w0, #1
	b.eq	LBB0_9
; %bb.4:
	cmp	w0, #128
	b.eq	LBB0_13
; %bb.5:
	cmp	w0, #129
	b.ne	LBB0_8
; %bb.6:
	mov	w0, #94
	mov	w1, #1
	bl	_PutPlusOne
	mov	w0, #127
	bl	_CTL_ESC
	cmp	w20, w0
	b.ne	LBB0_14
; %bb.7:
	mov	w0, #63
	b	LBB0_15
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_Refresh
LBB0_9:
Lloh21:
	adrp	x20, _STRhighlight@GOTPAGE
Lloh22:
	ldr	x20, [x20, _STRhighlight@GOTPAGEOFF]
	ldr	w0, [x20]
	bl	_adrof
Lloh23:
	adrp	x22, _MarkIsSet@GOTPAGE
Lloh24:
	ldr	x22, [x22, _MarkIsSet@GOTPAGEOFF]
	ldr	w8, [x22]
	cmp	w0, #0
	ccmp	w8, #0, #4, ne
	b.eq	LBB0_11
; %bb.10:
	bl	_StartHighlight
LBB0_11:
	cmp	w19, #2
	b.lt	LBB0_16
; %bb.12:
	mov	x0, x21
	mov	x1, x19
	mov	w2, #0
	bl	_MakeLiteral
	b	LBB0_17
LBB0_13:
	mov	w0, #92
	mov	w1, #1
	bl	_PutPlusOne
	mov	w19, #48
	mov	w0, #48
	bfxil	w0, w20, #6, #3
	mov	w1, #1
	bl	_PutPlusOne
	mov	w0, #48
	bfxil	w0, w20, #3, #3
	mov	w1, #1
	bl	_PutPlusOne
	bfxil	w19, w20, #0, #3
	mov	x0, x19
	b	LBB0_15
LBB0_14:
Lloh25:
	adrp	x8, __toebcdic@GOTPAGE
Lloh26:
	ldr	x8, [x8, __toebcdic@GOTPAGEOFF]
Lloh27:
	ldr	x8, [x8]
Lloh28:
	adrp	x9, __toascii@GOTPAGE
Lloh29:
	ldr	x9, [x9, __toascii@GOTPAGEOFF]
Lloh30:
	ldr	x9, [x9]
	ldrsw	x9, [x9, w20, sxtw #2]
	lsl	x9, x9, #2
	orr	x9, x9, #0x100
	ldr	w0, [x8, x9]
LBB0_15:
	mov	w1, #1
	bl	_PutPlusOne
	b	LBB0_19
LBB0_16:
	ldr	w0, [x21]
LBB0_17:
	mov	w1, #1
	bl	_PutPlusOne
	ldr	w0, [x20]
	bl	_adrof
	ldr	w8, [x22]
	cmp	w0, #0
	ccmp	w8, #0, #4, ne
	b.eq	LBB0_19
; %bb.18:
	bl	_StopHighlight
LBB0_19:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_flush
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_Cursor,4,2                     ; @Cursor
	.comm	_LastChar,4,2                   ; @LastChar
	.comm	_rprompt_h,8,3                  ; @rprompt_h
	.comm	_TermH,8,3                      ; @TermH
	.comm	_CursorH,8,3                    ; @CursorH
	.comm	_CHAR,4,2                       ; @CHAR
	.comm	_InputBuf,8,3                   ; @InputBuf
	.comm	__toebcdic,8,3                  ; @_toebcdic
	.comm	__toascii,8,3                   ; @_toascii
	.comm	_STRhighlight,4,2               ; @STRhighlight
	.comm	_MarkIsSet,4,2                  ; @MarkIsSet
.subsections_via_symbols
