	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vs_wait
_vs_wait:                               ## @vs_wait
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movq	%rdi, %rbx
	movq	(%rdi), %r12
	callq	_VIP
	movq	%rax, %r13
	movq	32(%r12), %r14
	movq	%rbx, %rdi
	callq	_LASTLINE
	movq	%rbx, %rdi
	movl	%eax, %esi
	xorl	%edx, %edx
	callq	*%r14
	movq	%rbx, %rdi
	callq	_IS_ONELINE
	testq	%rax, %rax
	movq	%r15, -72(%rbp)                 ## 8-byte Spill
	je	LBB0_2
## %bb.1:
	movq	_CMSG_CONT_S@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_2:
	leal	-128(%r15), %eax
	cmpl	$3, %eax
	jae	LBB0_19
## %bb.3:
	cltq
	leaq	l_switch.table.vs_wait(%rip), %rcx
	movq	(%rcx,%rax,8), %rax
LBB0_4:
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movl	(%rax), %esi
	leaq	-80(%rbp), %rdx
	movq	%rbx, %rdi
	callq	_msg_cmsg
	movq	-80(%rbp), %rdx
	movq	%rbx, %rdi
	movq	%rax, %rsi
	callq	*24(%r12)
	incl	8(%r13)
	movq	$0, (%r13)
	movq	%rbx, %rdi
	callq	*16(%r12)
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	*8(%r12)
	testq	%r14, %r14
	je	LBB0_6
## %bb.5:
	movl	$0, (%r14)
LBB0_6:
	leaq	-64(%rbp), %rsi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_v_event_get
	testq	%rax, %rax
	je	LBB0_7
LBB0_18:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_E_CHARACTER@GOTPCREL(%rip), %r15
	movq	_E_INTERRUPT@GOTPCREL(%rip), %r14
	leaq	-64(%rbp), %r13
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	-64(%rbp), %rax
	cmpq	(%r15), %rax
	je	LBB0_11
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	cmpq	(%r14), %rax
	je	LBB0_10
## %bb.20:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	%rbx, %rdi
	callq	*(%r12)
	movq	%rbx, %rdi
	movq	%r13, %rsi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_v_event_get
	testq	%rax, %rax
	je	LBB0_8
	jmp	LBB0_18
LBB0_10:
	movq	_CH_QUIT@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	movb	%al, -56(%rbp)
	movq	_G_INTERRUPTED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_F_SET
LBB0_11:
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	cmpl	$129, %eax
	je	LBB0_15
## %bb.12:
	cmpl	$128, %eax
	jne	LBB0_18
## %bb.13:
	movb	-56(%rbp), %al
	movq	_CH_QUIT@GOTPCREL(%rip), %rcx
	cmpb	(%rcx), %al
	jne	LBB0_18
## %bb.14:
	movq	_G_INTERRUPTED@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r12, %rdi
	callq	_F_SET
	jmp	LBB0_18
LBB0_15:
	cmpq	$0, -48(%rbp)                   ## 8-byte Folded Reload
	je	LBB0_18
## %bb.16:
	cmpb	$58, -56(%rbp)
	jne	LBB0_18
## %bb.17:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
	jmp	LBB0_18
LBB0_19:
	xorl	%eax, %eax
	callq	_abort
	.cfi_endproc
                                        ## -- End function
	.comm	_CMSG_CONT_S,4,2                ## @CMSG_CONT_S
	.comm	_CMSG_CONT_Q,4,2                ## @CMSG_CONT_Q
	.comm	_CMSG_CONT_EX,4,2               ## @CMSG_CONT_EX
	.comm	_CMSG_CONT,4,2                  ## @CMSG_CONT
	.comm	_E_CHARACTER,8,3                ## @E_CHARACTER
	.comm	_E_INTERRUPT,8,3                ## @E_INTERRUPT
	.comm	_CH_QUIT,1,0                    ## @CH_QUIT
	.comm	_G_INTERRUPTED,4,2              ## @G_INTERRUPTED
	.no_dead_strip	_vs_wait
	.section	__DATA,__const
	.p2align	3                               ## @switch.table.vs_wait
l_switch.table.vs_wait:
	.quad	_CMSG_CONT_Q
	.quad	_CMSG_CONT_EX
	.quad	_CMSG_CONT

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vs_wait
_vs_wait:                               ; @vs_wait
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x21, x2
	mov	x20, x1
	mov	x22, x0
	ldr	x19, [x0]
	bl	_VIP
	mov	x23, x0
	ldr	x24, [x19, #32]
	mov	x0, x22
	bl	_LASTLINE
	mov	x1, x0
	mov	x0, x22
	mov	w2, #0
	blr	x24
	mov	x0, x22
	bl	_IS_ONELINE
	cbz	x0, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _CMSG_CONT_S@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CMSG_CONT_S@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:
	sub	w8, w21, #128
	cmp	w8, #3
	b.hs	LBB0_20
; %bb.3:
Lloh2:
	adrp	x9, l_switch.table.vs_wait@PAGE
Lloh3:
	add	x9, x9, l_switch.table.vs_wait@PAGEOFF
	ldr	x8, [x9, w8, sxtw #3]
LBB0_4:
	ldr	w1, [x8]
	add	x2, sp, #8
	mov	x0, x22
	bl	_msg_cmsg
	mov	x1, x0
	ldr	x8, [x19, #24]
	ldr	x2, [sp, #8]
	mov	x0, x22
	blr	x8
	ldr	w8, [x23, #8]
	add	w8, w8, #1
	str	w8, [x23, #8]
	str	xzr, [x23]
	ldr	x8, [x19, #16]
	mov	x0, x22
	blr	x8
	ldr	x8, [x19, #8]
	mov	x0, x22
	mov	w1, #0
	blr	x8
	cbz	x20, LBB0_6
; %bb.5:
	str	wzr, [x20]
LBB0_6:
	add	x1, sp, #16
	mov	x0, x22
	mov	w2, #0
	mov	w3, #0
	bl	_v_event_get
	cbz	x0, LBB0_8
LBB0_7:
	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
	add	sp, sp, #96
	ret
LBB0_8:
Lloh4:
	adrp	x23, _E_CHARACTER@GOTPAGE
Lloh5:
	ldr	x23, [x23, _E_CHARACTER@GOTPAGEOFF]
Lloh6:
	adrp	x24, _E_INTERRUPT@GOTPAGE
Lloh7:
	ldr	x24, [x24, _E_INTERRUPT@GOTPAGEOFF]
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [sp, #16]
	ldr	x9, [x23]
	cmp	x8, x9
	b.eq	LBB0_13
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	x9, [x24]
	cmp	x8, x9
	b.eq	LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	x8, [x19]
	mov	x0, x22
	blr	x8
	add	x1, sp, #16
	mov	x0, x22
	mov	w2, #0
	mov	w3, #0
	bl	_v_event_get
	cbz	x0, LBB0_9
	b	LBB0_7
LBB0_12:
Lloh8:
	adrp	x8, _CH_QUIT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _CH_QUIT@GOTPAGEOFF]
	ldrb	w8, [x8]
	strb	w8, [sp, #24]
Lloh10:
	adrp	x8, _G_INTERRUPTED@GOTPAGE
Lloh11:
	ldr	x8, [x8, _G_INTERRUPTED@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_F_SET
LBB0_13:
	cmp	w21, #129
	b.eq	LBB0_17
; %bb.14:
	cmp	w21, #128
	b.ne	LBB0_7
; %bb.15:
	ldrb	w8, [sp, #24]
Lloh13:
	adrp	x9, _CH_QUIT@GOTPAGE
Lloh14:
	ldr	x9, [x9, _CH_QUIT@GOTPAGEOFF]
	ldrb	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_7
; %bb.16:
Lloh15:
	adrp	x8, _G_INTERRUPTED@GOTPAGE
Lloh16:
	ldr	x8, [x8, _G_INTERRUPTED@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_F_SET
	b	LBB0_7
LBB0_17:
	cbz	x20, LBB0_7
; %bb.18:
	ldrb	w8, [sp, #24]
	cmp	w8, #58
	b.ne	LBB0_7
; %bb.19:
	mov	w8, #1
	str	w8, [x20]
	b	LBB0_7
LBB0_20:
	bl	_abort
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_CMSG_CONT_S,4,2                ; @CMSG_CONT_S
	.comm	_CMSG_CONT_Q,4,2                ; @CMSG_CONT_Q
	.comm	_CMSG_CONT_EX,4,2               ; @CMSG_CONT_EX
	.comm	_CMSG_CONT,4,2                  ; @CMSG_CONT
	.comm	_E_CHARACTER,8,3                ; @E_CHARACTER
	.comm	_E_INTERRUPT,8,3                ; @E_INTERRUPT
	.comm	_CH_QUIT,1,0                    ; @CH_QUIT
	.comm	_G_INTERRUPTED,4,2              ; @G_INTERRUPTED
	.no_dead_strip	_vs_wait
	.section	__DATA,__const
	.p2align	3                               ; @switch.table.vs_wait
l_switch.table.vs_wait:
	.quad	_CMSG_CONT_Q
	.quad	_CMSG_CONT_EX
	.quad	_CMSG_CONT

.subsections_via_symbols
