	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function DI_register
_DI_register:                           ## @DI_register
	.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	$296, %rsp                      ## imm = 0x128
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r12
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	leaq	-328(%rbp), %rdi
	leaq	-320(%rbp), %rsi
	callq	_diva_os_get_time
	testq	%r12, %r12
	je	LBB0_24
## %bb.1:
	cmpq	$0, 8(%r12)
	jne	LBB0_24
## %bb.2:
	movq	_dbg_q_lock@GOTPCREL(%rip), %rdi
	leaq	L_.str(%rip), %rdx
	leaq	-312(%rbp), %rsi
	callq	_diva_os_enter_spin_lock
	movq	_clients@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	callq	_ARRAY_SIZE
	cmpl	$2, %eax
	jl	LBB0_23
## %bb.3:
	movl	$-1, %r14d
	movl	$1, %r13d
	movl	$72, %ebx
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_4 Depth=1
	movl	%r13d, %r14d
LBB0_9:                                 ##   in Loop: Header=BB0_4 Depth=1
	incq	%r13
	callq	_ARRAY_SIZE
	cltq
	addq	$40, %rbx
	cmpq	%rax, %r13
	jge	LBB0_10
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r15), %rdi
	movq	(%rdi,%rbx), %rax
	cmpq	%r12, %rax
	je	LBB0_23
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	testq	%rax, %rax
	jne	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	-24(%rdi,%rbx), %edi
	movq	16(%r12), %rsi
	callq	_strcmp
	testl	%eax, %eax
	je	LBB0_11
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	(%r15), %rdi
	cmpq	$0, (%rdi,%rbx)
	jne	LBB0_8
LBB0_11:
	testl	%eax, %eax
	setne	%al
	movl	%r13d, %r14d
	jmp	LBB0_12
LBB0_10:
	movb	$1, %al
	cmpl	$-1, %r14d
	je	LBB0_23
LBB0_12:
	movb	%al, -305(%rbp)                 ## 1-byte Spill
	movq	(%r15), %rax
	movslq	%r14d, %r13
	leaq	(,%r13,8), %rcx
	leaq	(%rcx,%rcx,4), %rbx
	movq	%r12, 32(%rax,%rbx)
	movq	-328(%rbp), %rax
	movq	(%r15), %rcx
	movq	%rax, 24(%rcx,%rbx)
	movq	-320(%rbp), %rax
	movq	(%r15), %rcx
	movq	%rax, 16(%rcx,%rbx)
	movq	(%r15), %rax
	movl	8(%rax,%rbx), %edi
	movq	16(%r12), %rsi
	callq	_strcpy
	movl	76(%r12), %eax
	movq	(%r15), %rdx
	leaq	(%rdx,%rbx), %rcx
	movl	%eax, 4(%rdx,%rbx)
	cmpb	$0, -305(%rbp)                  ## 1-byte Folded Reload
	je	LBB0_13
## %bb.14:
	movl	$0, (%rcx)
	jmp	LBB0_15
LBB0_13:
	orl	(%rcx), %eax
	movl	%eax, 76(%r12)
LBB0_15:
	movq	_DBG_HANDLE_REG_NEW@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 8(%r12)
	movq	%r13, (%r12)
	movq	_DI_deregister@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 72(%r12)
	movq	_DI_format_locked@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 64(%r12)
	movq	_DiProcessEventLog@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, 56(%r12)
	movq	%rax, 48(%r12)
	cmpq	$0, 24(%r12)
	jle	LBB0_17
## %bb.16:
	movq	_DI_format_old@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 40(%r12)
LBB0_17:
	movq	_DBG_MAGIC@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 32(%r12)
	movq	16(%r12), %rcx
	leaq	L_.str.1(%rip), %rsi
	leaq	-304(%rbp), %rdi
	movl	%r14d, %edx
	callq	_sprintf
	movl	%eax, %r14d
	leal	57(%r14), %r15d
	movq	_dbg_queue@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	movl	%r15d, %esi
	callq	_queueAllocMsg
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_22
## %bb.18:
	leaq	-332(%rbp), %r12
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %edi
	movq	%r12, %rsi
	callq	_queuePeekMsg
	testq	%rax, %rax
	je	LBB0_23
## %bb.20:                              ##   in Loop: Header=BB0_19 Depth=1
	movl	(%r13), %edi
	callq	_queueFreeMsg
	movl	(%r13), %edi
	movl	%r15d, %esi
	callq	_queueAllocMsg
	testq	%rax, %rax
	je	LBB0_19
## %bb.21:
	movq	%rax, %rbx
LBB0_22:
	incl	%r14d
	movq	_dbg_sequence@GOTPCREL(%rip), %rax
	movslq	(%rax), %rcx
	leal	1(%rcx), %edx
	movl	%edx, (%rax)
	movq	%rcx, 48(%rbx)
	movq	-328(%rbp), %rax
	movq	%rax, 40(%rbx)
	movq	-320(%rbp), %rax
	movq	%rax, 32(%rbx)
	movq	_MSG_TYPE_STRING@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 28(%rbx)
	movq	_DLI_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 8(%rbx)
	movl	%r14d, (%rbx)
	leaq	56(%rbx), %rdi
	leaq	-304(%rbp), %rsi
	movl	%r14d, %edx
	callq	_memcpy
	movq	%rbx, %rdi
	callq	_queueCompleteMsg
	xorl	%eax, %eax
	callq	_diva_maint_wakeup_read
LBB0_23:
	movq	_dbg_q_lock@GOTPCREL(%rip), %rdi
	leaq	L_.str(%rip), %rdx
	leaq	-312(%rbp), %rsi
	callq	_diva_os_leave_spin_lock
LBB0_24:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_26
## %bb.25:
	addq	$296, %rsp                      ## imm = 0x128
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_26:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_dbg_q_lock,4,2                 ## @dbg_q_lock
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"register"

	.comm	_clients,8,3                    ## @clients
	.comm	_DBG_HANDLE_REG_NEW,8,3         ## @DBG_HANDLE_REG_NEW
	.comm	_DI_deregister,4,2              ## @DI_deregister
	.comm	_DI_format_locked,8,3           ## @DI_format_locked
	.comm	_DiProcessEventLog,4,2          ## @DiProcessEventLog
	.comm	_DI_format_old,4,2              ## @DI_format_old
	.comm	_DBG_MAGIC,8,3                  ## @DBG_MAGIC
L_.str.1:                               ## @.str.1
	.asciz	"DIMAINT - drv # %d = '%s' registered"

	.comm	_dbg_queue,4,2                  ## @dbg_queue
	.comm	_dbg_sequence,4,2               ## @dbg_sequence
	.comm	_MSG_TYPE_STRING,4,2            ## @MSG_TYPE_STRING
	.comm	_DLI_REG,4,2                    ## @DLI_REG
	.no_dead_strip	_DI_register
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function DI_register
_DI_register:                           ; @DI_register
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #368
	.cfi_def_cfa_offset 368
	stp	x24, x23, [sp, #304]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #320]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #336]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #352]            ; 16-byte Folded Spill
	add	x29, sp, #352
	.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	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	add	x0, sp, #24
	add	x1, sp, #16
	bl	_diva_os_get_time
	cbz	x19, LBB0_24
; %bb.1:
	ldr	x8, [x19, #8]
	cbnz	x8, LBB0_24
; %bb.2:
Lloh3:
	adrp	x0, _dbg_q_lock@GOTPAGE
Lloh4:
	ldr	x0, [x0, _dbg_q_lock@GOTPAGEOFF]
Lloh5:
	adrp	x2, l_.str@PAGE
Lloh6:
	add	x2, x2, l_.str@PAGEOFF
	add	x1, sp, #36
	bl	_diva_os_enter_spin_lock
Lloh7:
	adrp	x21, _clients@GOTPAGE
Lloh8:
	ldr	x21, [x21, _clients@GOTPAGEOFF]
	ldr	x0, [x21]
	bl	_ARRAY_SIZE
	cmp	w0, #2
	b.lt	LBB0_23
; %bb.3:
	mov	x22, #0
	mov	w23, #-1
	mov	w20, #1
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	mov	x23, x20
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x20, x20, #1
	bl	_ARRAY_SIZE
	add	x22, x22, #40
	cmp	x20, w0, sxtw
	b.ge	LBB0_11
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x21]
	add	x8, x0, x22
	ldr	x8, [x8, #72]
	cmp	x8, x19
	b.eq	LBB0_23
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	cbnz	x8, LBB0_5
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x8, x0, x22
	ldr	w0, [x8, #48]
	ldr	x1, [x19, #16]
	bl	_strcmp
	mov	x8, x0
	cbz	w0, LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x0, [x21]
	add	x9, x0, x22
	ldr	x9, [x9, #72]
	cbnz	x9, LBB0_4
LBB0_10:
	cmp	w8, #0
	cset	w22, ne
	mov	x23, x20
	b	LBB0_13
LBB0_11:
	cmn	w23, #1
	b.eq	LBB0_23
; %bb.12:
	mov	w22, #1
LBB0_13:
	ldr	x8, [x21]
	sxtw	x20, w23
	add	x9, x20, w23, sxtw #2
	lsl	x23, x9, #3
	add	x8, x8, x23
	str	x19, [x8, #32]
	ldr	x8, [sp, #24]
	ldr	x9, [x21]
	add	x9, x9, x23
	str	x8, [x9, #24]
	ldr	x8, [sp, #16]
	ldr	x9, [x21]
	add	x9, x9, x23
	str	x8, [x9, #16]
	ldr	x8, [x21]
	add	x8, x8, x23
	ldr	w0, [x8, #8]
	ldr	x1, [x19, #16]
	bl	_strcpy
	ldr	w8, [x19, #76]
	ldr	x9, [x21]
	add	x9, x9, x23
	str	w8, [x9, #4]
	tbz	w22, #0, LBB0_15
; %bb.14:
	str	wzr, [x9]
	b	LBB0_16
LBB0_15:
	ldr	w9, [x9]
	orr	w8, w9, w8
	str	w8, [x19, #76]
LBB0_16:
Lloh9:
	adrp	x8, _DBG_HANDLE_REG_NEW@GOTPAGE
Lloh10:
	ldr	x8, [x8, _DBG_HANDLE_REG_NEW@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	stp	x20, x8, [x19]
Lloh12:
	adrp	x8, _DI_deregister@GOTPAGE
Lloh13:
	ldr	x8, [x8, _DI_deregister@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	str	w8, [x19, #72]
Lloh15:
	adrp	x8, _DI_format_locked@GOTPAGE
Lloh16:
	ldr	x8, [x8, _DI_format_locked@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
Lloh18:
	adrp	x9, _DiProcessEventLog@GOTPAGE
Lloh19:
	ldr	x9, [x9, _DiProcessEventLog@GOTPAGEOFF]
	str	x8, [x19, #64]
Lloh20:
	ldr	w9, [x9]
	str	w9, [x19, #56]
	str	x8, [x19, #48]
	ldr	x8, [x19, #24]
	cmp	x8, #1
	b.lt	LBB0_18
; %bb.17:
Lloh21:
	adrp	x8, _DI_format_old@GOTPAGE
Lloh22:
	ldr	x8, [x8, _DI_format_old@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	str	w8, [x19, #40]
LBB0_18:
Lloh24:
	adrp	x8, _DBG_MAGIC@GOTPAGE
Lloh25:
	ldr	x8, [x8, _DBG_MAGIC@GOTPAGEOFF]
Lloh26:
	ldr	x8, [x8]
	str	x8, [x19, #32]
	ldr	x3, [x19, #16]
Lloh27:
	adrp	x1, l_.str.1@PAGE
Lloh28:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x0, sp, #40
	mov	x2, x20
	bl	_sprintf
	mov	x19, x0
	add	w21, w0, #57
Lloh29:
	adrp	x22, _dbg_queue@GOTPAGE
Lloh30:
	ldr	x22, [x22, _dbg_queue@GOTPAGEOFF]
	ldr	w0, [x22]
	mov	x1, x21
	bl	_queueAllocMsg
	mov	x20, x0
	cbnz	x0, LBB0_22
	b	LBB0_20
LBB0_19:                                ;   in Loop: Header=BB0_20 Depth=1
	ldr	w0, [x22]
	bl	_queueFreeMsg
	ldr	w0, [x22]
	mov	x1, x21
	bl	_queueAllocMsg
	cbnz	x0, LBB0_21
LBB0_20:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x22]
	add	x1, sp, #12
	bl	_queuePeekMsg
	cbnz	x0, LBB0_19
	b	LBB0_23
LBB0_21:
	mov	x20, x0
LBB0_22:
	add	w2, w19, #1
Lloh31:
	adrp	x8, _dbg_sequence@GOTPAGE
Lloh32:
	ldr	x8, [x8, _dbg_sequence@GOTPAGEOFF]
	ldrsw	x11, [x8]
	add	w10, w11, #1
	str	w10, [x8]
	ldp	x9, x8, [sp, #16]
	stp	x8, x11, [x20, #40]
	str	x9, [x20, #32]
Lloh33:
	adrp	x8, _MSG_TYPE_STRING@GOTPAGE
Lloh34:
	ldr	x8, [x8, _MSG_TYPE_STRING@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
Lloh36:
	adrp	x9, _DLI_REG@GOTPAGE
Lloh37:
	ldr	x9, [x9, _DLI_REG@GOTPAGEOFF]
Lloh38:
	ldr	w9, [x9]
	stp	w9, w8, [x20, #24]
	stp	xzr, xzr, [x20, #8]
	str	w2, [x20]
	add	x0, x20, #56
	add	x1, sp, #40
	bl	_memcpy
	mov	x0, x20
	bl	_queueCompleteMsg
	bl	_diva_maint_wakeup_read
LBB0_23:
Lloh39:
	adrp	x0, _dbg_q_lock@GOTPAGE
Lloh40:
	ldr	x0, [x0, _dbg_q_lock@GOTPAGEOFF]
Lloh41:
	adrp	x2, l_.str@PAGE
Lloh42:
	add	x2, x2, l_.str@PAGEOFF
	add	x1, sp, #36
	bl	_diva_os_leave_spin_lock
LBB0_24:
	ldur	x8, [x29, #-56]
Lloh43:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh44:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh45:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_26
; %bb.25:
	ldp	x29, x30, [sp, #352]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #336]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #320]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #304]            ; 16-byte Folded Reload
	add	sp, sp, #368
	ret
LBB0_26:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpAdd	Lloh41, Lloh42
	.loh AdrpLdrGot	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.cfi_endproc
                                        ; -- End function
	.comm	_dbg_q_lock,4,2                 ; @dbg_q_lock
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"register"

	.comm	_clients,8,3                    ; @clients
	.comm	_DBG_HANDLE_REG_NEW,8,3         ; @DBG_HANDLE_REG_NEW
	.comm	_DI_deregister,4,2              ; @DI_deregister
	.comm	_DI_format_locked,8,3           ; @DI_format_locked
	.comm	_DiProcessEventLog,4,2          ; @DiProcessEventLog
	.comm	_DI_format_old,4,2              ; @DI_format_old
	.comm	_DBG_MAGIC,8,3                  ; @DBG_MAGIC
l_.str.1:                               ; @.str.1
	.asciz	"DIMAINT - drv # %d = '%s' registered"

	.comm	_dbg_queue,4,2                  ; @dbg_queue
	.comm	_dbg_sequence,4,2               ; @dbg_sequence
	.comm	_MSG_TYPE_STRING,4,2            ; @MSG_TYPE_STRING
	.comm	_DLI_REG,4,2                    ; @DLI_REG
	.no_dead_strip	_DI_register
.subsections_via_symbols
