	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function r_debug_bochs_wait
_r_debug_bochs_wait:                    ## @r_debug_bochs_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
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_isBochs
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movq	_bStep@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_4
## %bb.3:
	movl	$0, (%rax)
	jmp	LBB0_12
LBB0_1:
	xorl	%eax, %eax
	jmp	LBB0_17
LBB0_4:
	movq	_bochs_debug_break@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_r_cons_break_push
	movq	_desc@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rdi
	movl	$500, %r15d                     ## imm = 0x1F4
	movq	_bBreak@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	callq	_bochs_wait
	cmpl	$0, (%r14)
	movq	(%rbx), %rdi
	movq	(%rdi), %rsi
	movzbl	(%rsi), %eax
	jne	LBB0_6
## %bb.10:                              ##   in Loop: Header=BB0_5 Depth=1
	testb	%al, %al
	je	LBB0_5
	jmp	LBB0_11
LBB0_6:                                 ##   in Loop: Header=BB0_5 Depth=1
	testb	%al, %al
	jne	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=1
	decl	%r15d
	jne	LBB0_5
## %bb.9:
	movl	$0, (%r14)
	leaq	L_.str.1(%rip), %rdi
	xorl	%eax, %eax
	callq	_eprintf
	jmp	LBB0_11
LBB0_7:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_eprintf
	movl	$0, (%r14)
LBB0_11:
	xorl	%eax, %eax
	callq	_r_cons_break_pop
LBB0_12:
	movq	_ripStop@GOTPCREL(%rip), %r12
	movq	$0, (%r12)
	movq	_desc@GOTPCREL(%rip), %r13
	movq	(%r13), %rax
	movq	(%rax), %r14
	leaq	L_.str.2(%rip), %rsi
	movq	%r14, %rdi
	callq	_strstr
	testq	%rax, %rax
	je	LBB0_16
## %bb.13:
	leaq	L_.str.3(%rip), %rsi
	movq	%rax, %rdi
	callq	_strstr
	testq	%rax, %rax
	je	LBB0_16
## %bb.14:
	movq	%rax, %rbx
	movq	%rax, %rdi
	movl	$93, %esi
	callq	_strchr
	testq	%rax, %rax
	je	LBB0_16
## %bb.15:
	movq	%rax, %r15
	movq	%rbx, %rax
	notq	%rax
	addq	%rax, %r15
	incq	%rbx
	leaq	-80(%rbp), %r14
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movl	%r15d, %edx
	callq	_strncpy
	movslq	%r15d, %rax
	movb	$0, -80(%rbp,%rax)
	xorl	%edi, %edi
	movq	%r14, %rsi
	callq	_r_num_get
	movq	%rax, (%r12)
	movq	(%r13), %rax
	movq	(%rax), %r14
LBB0_16:
	movb	$0, (%r14)
	movl	$1, %eax
LBB0_17:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_19
## %bb.18:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_bStep,4,2                      ## @bStep
	.comm	_bochs_debug_break,4,2          ## @bochs_debug_break
	.comm	_desc,8,3                       ## @desc
	.comm	_bBreak,4,2                     ## @bBreak
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ctrl+c %s\n"

L_.str.1:                               ## @.str.1
	.asciz	"empty ctrl+c.\n"

	.comm	_ripStop,8,3                    ## @ripStop
L_.str.2:                               ## @.str.2
	.asciz	"Next at"

L_.str.3:                               ## @.str.3
	.asciz	"[0x"

	.no_dead_strip	_r_debug_bochs_wait
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function r_debug_bochs_wait
_r_debug_bochs_wait:                    ; @r_debug_bochs_wait
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
	bl	_isBochs
	cbz	w0, LBB0_16
; %bb.1:
Lloh3:
	adrp	x8, _bStep@GOTPAGE
Lloh4:
	ldr	x8, [x8, _bStep@GOTPAGEOFF]
	ldr	w9, [x8]
Lloh5:
	adrp	x21, _desc@GOTPAGE
Lloh6:
	ldr	x21, [x21, _desc@GOTPAGEOFF]
	cbz	w9, LBB0_3
; %bb.2:
	str	wzr, [x8]
	b	LBB0_11
LBB0_3:
Lloh7:
	adrp	x8, _bochs_debug_break@GOTPAGE
Lloh8:
	ldr	x8, [x8, _bochs_debug_break@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_r_cons_break_push
	ldr	x0, [x21]
	mov	w20, #500
Lloh10:
	adrp	x19, _bBreak@GOTPAGE
Lloh11:
	ldr	x19, [x19, _bBreak@GOTPAGEOFF]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	bl	_bochs_wait
	ldr	w10, [x19]
	ldr	x0, [x21]
	ldr	x8, [x0]
	ldrb	w9, [x8]
	cbnz	w10, LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	cbz	w9, LBB0_4
	b	LBB0_10
LBB0_6:                                 ;   in Loop: Header=BB0_4 Depth=1
	cbnz	w9, LBB0_9
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	subs	w20, w20, #1
	b.ne	LBB0_4
; %bb.8:
	str	wzr, [x19]
Lloh12:
	adrp	x0, l_.str.1@PAGE
Lloh13:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_eprintf
	b	LBB0_10
LBB0_9:
	str	x8, [sp]
Lloh14:
	adrp	x0, l_.str@PAGE
Lloh15:
	add	x0, x0, l_.str@PAGEOFF
	bl	_eprintf
	str	wzr, [x19]
LBB0_10:
	bl	_r_cons_break_pop
LBB0_11:
Lloh16:
	adrp	x22, _ripStop@GOTPAGE
Lloh17:
	ldr	x22, [x22, _ripStop@GOTPAGEOFF]
	str	xzr, [x22]
	ldr	x8, [x21]
	ldr	x19, [x8]
Lloh18:
	adrp	x1, l_.str.2@PAGE
Lloh19:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_strstr
	cbz	x0, LBB0_15
; %bb.12:
Lloh20:
	adrp	x1, l_.str.3@PAGE
Lloh21:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_strstr
	cbz	x0, LBB0_15
; %bb.13:
	mov	x20, x0
	mov	w1, #93
	bl	_strchr
	cbz	x0, LBB0_15
; %bb.14:
	mvn	x8, x20
	add	x19, x0, x8
	add	x1, x20, #1
	add	x20, sp, #21
	add	x0, sp, #21
	mov	x2, x19
	bl	_strncpy
	strb	wzr, [x20, w19, sxtw]
	add	x1, sp, #21
	mov	x0, #0
	bl	_r_num_get
	str	x0, [x22]
	ldr	x8, [x21]
	ldr	x19, [x8]
LBB0_15:
	strb	wzr, [x19]
	mov	w0, #1
LBB0_16:
	ldr	x8, [sp, #40]
Lloh22:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh23:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_18
; %bb.17:
	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
	add	sp, sp, #96
	ret
LBB0_18:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_bStep,4,2                      ; @bStep
	.comm	_bochs_debug_break,4,2          ; @bochs_debug_break
	.comm	_desc,8,3                       ; @desc
	.comm	_bBreak,4,2                     ; @bBreak
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ctrl+c %s\n"

l_.str.1:                               ; @.str.1
	.asciz	"empty ctrl+c.\n"

	.comm	_ripStop,8,3                    ; @ripStop
l_.str.2:                               ; @.str.2
	.asciz	"Next at"

l_.str.3:                               ; @.str.3
	.asciz	"[0x"

	.no_dead_strip	_r_debug_bochs_wait
.subsections_via_symbols
