	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mips_exit_debug
_mips_exit_debug:                       ## @mips_exit_debug
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	_mips_exit_cleanups@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	callq	_make_cleanup
	movq	%rax, %rbx
	movq	_mips_exiting@GOTPCREL(%rip), %rax
	movl	$1, (%rax)
	movq	_mips_monitor@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_MON_IDT@GOTPCREL(%rip), %rcx
	movq	_mips_receive_wait@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r8d
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	leaq	-12(%rbp), %rcx
	movl	$120, %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	xorl	%r9d, %r9d
	callq	_mips_request
	jmp	LBB0_3
LBB0_2:
	movl	$120, %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	xorl	%r9d, %r9d
	callq	_mips_request
	movq	_mips_need_reply@GOTPCREL(%rip), %rax
	movq	$0, (%rax)
	leaq	L_.str(%rip), %rdi
	callq	_mips_expect
	testl	%eax, %eax
	je	LBB0_6
LBB0_3:
	movq	_mips_monitor_prompt@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_mips_expect
	testl	%eax, %eax
	je	LBB0_6
## %bb.4:
	movq	%rbx, %rdi
	callq	_do_cleanups
	xorl	%eax, %eax
	jmp	LBB0_7
LBB0_6:
	movl	$-1, %eax
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_mips_exit_cleanups,4,2         ## @mips_exit_cleanups
	.comm	_mips_exiting,4,2               ## @mips_exiting
	.comm	_mips_monitor,8,3               ## @mips_monitor
	.comm	_MON_IDT,8,3                    ## @MON_IDT
	.comm	_mips_receive_wait,4,2          ## @mips_receive_wait
	.comm	_mips_need_reply,8,3            ## @mips_need_reply
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	" break!"

	.comm	_mips_monitor_prompt,8,3        ## @mips_monitor_prompt
	.no_dead_strip	_mips_exit_debug
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mips_exit_debug
_mips_exit_debug:                       ; @mips_exit_debug
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
Lloh0:
	adrp	x8, _mips_exit_cleanups@GOTPAGE
Lloh1:
	ldr	x8, [x8, _mips_exit_cleanups@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	mov	x1, #0
	bl	_make_cleanup
	mov	x19, x0
Lloh3:
	adrp	x8, _mips_exiting@GOTPAGE
Lloh4:
	ldr	x8, [x8, _mips_exiting@GOTPAGEOFF]
	mov	w9, #1
Lloh5:
	str	w9, [x8]
Lloh6:
	adrp	x8, _mips_monitor@GOTPAGE
Lloh7:
	ldr	x8, [x8, _mips_monitor@GOTPAGEOFF]
Lloh8:
	adrp	x9, _MON_IDT@GOTPAGE
Lloh9:
	ldr	x9, [x9, _MON_IDT@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
Lloh11:
	ldr	x9, [x9]
Lloh12:
	adrp	x10, _mips_receive_wait@GOTPAGE
Lloh13:
	ldr	x10, [x10, _mips_receive_wait@GOTPAGEOFF]
Lloh14:
	ldr	w4, [x10]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
	add	x3, sp, #12
	mov	w0, #120
	mov	w1, #0
	mov	w2, #0
	mov	x5, #0
	bl	_mips_request
	b	LBB0_3
LBB0_2:
	mov	w0, #120
	mov	w1, #0
	mov	w2, #0
	mov	x3, #0
	mov	x5, #0
	bl	_mips_request
Lloh15:
	adrp	x8, _mips_need_reply@GOTPAGE
Lloh16:
	ldr	x8, [x8, _mips_need_reply@GOTPAGEOFF]
Lloh17:
	str	xzr, [x8]
Lloh18:
	adrp	x0, l_.str@PAGE
Lloh19:
	add	x0, x0, l_.str@PAGEOFF
	bl	_mips_expect
	cbz	w0, LBB0_5
LBB0_3:
Lloh20:
	adrp	x8, _mips_monitor_prompt@GOTPAGE
Lloh21:
	ldr	x8, [x8, _mips_monitor_prompt@GOTPAGEOFF]
Lloh22:
	ldr	x0, [x8]
	bl	_mips_expect
	cbz	w0, LBB0_5
; %bb.4:
	mov	x0, x19
	bl	_do_cleanups
	mov	w0, #0
	b	LBB0_6
LBB0_5:
	mov	w0, #-1
LBB0_6:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh10
	.loh AdrpLdrGotStr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotStr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_mips_exit_cleanups,4,2         ; @mips_exit_cleanups
	.comm	_mips_exiting,4,2               ; @mips_exiting
	.comm	_mips_monitor,8,3               ; @mips_monitor
	.comm	_MON_IDT,8,3                    ; @MON_IDT
	.comm	_mips_receive_wait,4,2          ; @mips_receive_wait
	.comm	_mips_need_reply,8,3            ; @mips_need_reply
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	" break!"

	.comm	_mips_monitor_prompt,8,3        ; @mips_monitor_prompt
	.no_dead_strip	_mips_exit_debug
.subsections_via_symbols
