	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dbg_reset_state
_dbg_reset_state:                       ## @dbg_reset_state
	.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
	callq	_PCPU_GET
	movl	%eax, %r14d
	movq	_dbg_model@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	leal	-130(%rax), %ecx
	cmpl	$2, %ecx
	jb	LBB0_21
## %bb.1:
	cmpl	$128, %eax
	je	LBB0_7
## %bb.2:
	cmpl	$129, %eax
	jne	LBB0_11
## %bb.3:
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_cp14_dbgprsr_get
	movq	_DBGPRSR_PU@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_5
## %bb.4:
	movq	_ENXIO@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
LBB0_5:
	testl	%r15d, %r15d
	jne	LBB0_9
## %bb.6:
	movq	_dbg_ossr@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	jne	LBB0_14
	jmp	LBB0_9
LBB0_21:
	xorl	%eax, %eax
	callq	_dbg_enable_monitor
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_20
	jmp	LBB0_14
LBB0_7:
	xorl	%eax, %eax
	callq	_cp14_dbgosdlr_get
	movq	_DBGPRSR_DLK@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_11
## %bb.8:
	movq	_ENXIO@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
LBB0_9:
	testl	%r15d, %r15d
	je	LBB0_11
## %bb.10:
	leaq	L_.str(%rip), %rdi
	movl	%r14d, %esi
	callq	_db_printf
	jmp	LBB0_20
LBB0_11:
	testb	$-128, (%rbx)
	jne	LBB0_13
## %bb.12:
	movq	_dbg_ossr@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_14
LBB0_13:
	xorl	%edi, %edi
	callq	_cp14_dbgoslar_set
	xorl	%eax, %eax
	callq	_isb
LBB0_14:
	xorl	%r15d, %r15d
	xorl	%edi, %edi
	callq	_cp14_dbgvcr_set
	xorl	%eax, %eax
	callq	_isb
	movq	_dbg_watchpoint_num@GOTPCREL(%rip), %r14
	cmpq	$0, (%r14)
	je	LBB0_17
## %bb.15:
	xorl	%ebx, %ebx
	movq	_DBG_REG_BASE_WCR@GOTPCREL(%rip), %r12
	movq	_DBG_REG_BASE_WVR@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_16:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_dbg_wb_write_reg
	movl	(%r13), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_dbg_wb_write_reg
	incq	%rbx
	cmpq	(%r14), %rbx
	jb	LBB0_16
LBB0_17:
	movq	_dbg_breakpoint_num@GOTPCREL(%rip), %r14
	cmpq	$0, (%r14)
	je	LBB0_20
## %bb.18:
	xorl	%r15d, %r15d
	movq	_DBG_REG_BASE_BCR@GOTPCREL(%rip), %r12
	movq	_DBG_REG_BASE_BVR@GOTPCREL(%rip), %r13
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_dbg_wb_write_reg
	movl	(%r13), %edi
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_dbg_wb_write_reg
	incq	%rbx
	cmpq	(%r14), %rbx
	jb	LBB0_19
LBB0_20:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_dbg_model,4,2                  ## @dbg_model
	.comm	_DBGPRSR_PU,4,2                 ## @DBGPRSR_PU
	.comm	_ENXIO,4,2                      ## @ENXIO
	.comm	_dbg_ossr,8,3                   ## @dbg_ossr
	.comm	_DBGPRSR_DLK,4,2                ## @DBGPRSR_DLK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Debug facility locked (CPU%d)\n"

	.comm	_dbg_watchpoint_num,8,3         ## @dbg_watchpoint_num
	.comm	_DBG_REG_BASE_WCR,4,2           ## @DBG_REG_BASE_WCR
	.comm	_DBG_REG_BASE_WVR,4,2           ## @DBG_REG_BASE_WVR
	.comm	_dbg_breakpoint_num,8,3         ## @dbg_breakpoint_num
	.comm	_DBG_REG_BASE_BCR,4,2           ## @DBG_REG_BASE_BCR
	.comm	_DBG_REG_BASE_BVR,4,2           ## @DBG_REG_BASE_BVR
	.no_dead_strip	_dbg_reset_state
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dbg_reset_state
_dbg_reset_state:                       ; @dbg_reset_state
	.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
	bl	_PCPU_GET
Lloh0:
	adrp	x21, _dbg_model@GOTPAGE
Lloh1:
	ldr	x21, [x21, _dbg_model@GOTPAGEOFF]
	ldr	w8, [x21]
	sub	w9, w8, #130
	cmp	w9, #2
	b.lo	LBB0_5
; %bb.1:
	mov	x19, x0
	cmp	w8, #128
	b.eq	LBB0_6
; %bb.2:
	cmp	w8, #129
	b.ne	LBB0_9
; %bb.3:
	bl	_cp14_dbgprsr_get
Lloh2:
	adrp	x8, _DBGPRSR_PU@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DBGPRSR_PU@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _ENXIO@GOTPAGE
Lloh6:
	ldr	x9, [x9, _ENXIO@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	tst	w8, w0
	csel	w20, w9, wzr, eq
Lloh8:
	adrp	x8, _dbg_ossr@GOTPAGE
Lloh9:
	ldr	x8, [x8, _dbg_ossr@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	cmp	w20, #0
	ccmp	x8, #0, #4, eq
	b.ne	LBB0_12
; %bb.4:
	cbnz	w20, LBB0_8
	b	LBB0_9
LBB0_5:
	bl	_dbg_enable_monitor
	mov	x20, x0
	cbnz	w0, LBB0_19
	b	LBB0_12
LBB0_6:
	bl	_cp14_dbgosdlr_get
Lloh11:
	adrp	x8, _DBGPRSR_DLK@GOTPAGE
Lloh12:
	ldr	x8, [x8, _DBGPRSR_DLK@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_9
; %bb.7:
Lloh14:
	adrp	x8, _ENXIO@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
Lloh16:
	ldr	w20, [x8]
	cbz	w20, LBB0_9
LBB0_8:
Lloh17:
	adrp	x0, l_.str@PAGE
Lloh18:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x19
	bl	_db_printf
	b	LBB0_19
LBB0_9:
	ldrb	w8, [x21]
	tbnz	w8, #7, LBB0_11
; %bb.10:
Lloh19:
	adrp	x8, _dbg_ossr@GOTPAGE
Lloh20:
	ldr	x8, [x8, _dbg_ossr@GOTPAGEOFF]
Lloh21:
	ldr	x8, [x8]
	cbz	x8, LBB0_12
LBB0_11:
	mov	w0, #0
	bl	_cp14_dbgoslar_set
	bl	_isb
LBB0_12:
	mov	w0, #0
	bl	_cp14_dbgvcr_set
	bl	_isb
Lloh22:
	adrp	x20, _dbg_watchpoint_num@GOTPAGE
Lloh23:
	ldr	x20, [x20, _dbg_watchpoint_num@GOTPAGEOFF]
	ldr	x8, [x20]
	cbz	x8, LBB0_15
; %bb.13:
	mov	x19, #0
Lloh24:
	adrp	x21, _DBG_REG_BASE_WCR@GOTPAGE
Lloh25:
	ldr	x21, [x21, _DBG_REG_BASE_WCR@GOTPAGEOFF]
Lloh26:
	adrp	x22, _DBG_REG_BASE_WVR@GOTPAGE
Lloh27:
	ldr	x22, [x22, _DBG_REG_BASE_WVR@GOTPAGEOFF]
LBB0_14:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x21]
	mov	x1, x19
	mov	w2, #0
	bl	_dbg_wb_write_reg
	ldr	w0, [x22]
	mov	x1, x19
	mov	w2, #0
	bl	_dbg_wb_write_reg
	add	x19, x19, #1
	ldr	x8, [x20]
	cmp	x19, x8
	b.lo	LBB0_14
LBB0_15:
Lloh28:
	adrp	x20, _dbg_breakpoint_num@GOTPAGE
Lloh29:
	ldr	x20, [x20, _dbg_breakpoint_num@GOTPAGEOFF]
	ldr	x8, [x20]
	cbz	x8, LBB0_18
; %bb.16:
	mov	x19, #0
Lloh30:
	adrp	x21, _DBG_REG_BASE_BCR@GOTPAGE
Lloh31:
	ldr	x21, [x21, _DBG_REG_BASE_BCR@GOTPAGEOFF]
Lloh32:
	adrp	x22, _DBG_REG_BASE_BVR@GOTPAGE
Lloh33:
	ldr	x22, [x22, _DBG_REG_BASE_BVR@GOTPAGEOFF]
LBB0_17:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x21]
	mov	x1, x19
	mov	w2, #0
	bl	_dbg_wb_write_reg
	ldr	w0, [x22]
	mov	x1, x19
	mov	w2, #0
	bl	_dbg_wb_write_reg
	add	x19, x19, #1
	ldr	x8, [x20]
	cmp	x19, x8
	b.lo	LBB0_17
LBB0_18:
	mov	w20, #0
LBB0_19:
	mov	x0, x20
	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
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_dbg_model,4,2                  ; @dbg_model
	.comm	_DBGPRSR_PU,4,2                 ; @DBGPRSR_PU
	.comm	_ENXIO,4,2                      ; @ENXIO
	.comm	_dbg_ossr,8,3                   ; @dbg_ossr
	.comm	_DBGPRSR_DLK,4,2                ; @DBGPRSR_DLK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Debug facility locked (CPU%d)\n"

	.comm	_dbg_watchpoint_num,8,3         ; @dbg_watchpoint_num
	.comm	_DBG_REG_BASE_WCR,4,2           ; @DBG_REG_BASE_WCR
	.comm	_DBG_REG_BASE_WVR,4,2           ; @DBG_REG_BASE_WVR
	.comm	_dbg_breakpoint_num,8,3         ; @dbg_breakpoint_num
	.comm	_DBG_REG_BASE_BCR,4,2           ; @DBG_REG_BASE_BCR
	.comm	_DBG_REG_BASE_BVR,4,2           ; @DBG_REG_BASE_BVR
	.no_dead_strip	_dbg_reset_state
.subsections_via_symbols
