	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mpt_register                   ## -- Begin function mpt_register
	.p2align	4, 0x90
_mpt_register:                          ## @mpt_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	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	_MPT_MAX_PROTOCOL_DRIVERS@GOTPCREL(%rip), %rax
	movslq	(%rax), %r8
	movl	%r8d, %eax
	movq	_last_drv_idx@GOTPCREL(%rip), %r14
	movl	%r8d, (%r14)
	movq	_MptCallbacks@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	leaq	(%rcx,%r8,8), %r9
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	leal	(%rax,%rbx), %ecx
	cmpl	$1, %ecx
	je	LBB0_4
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	leaq	-1(%rbx), %rcx
	cmpq	$0, -8(%r9,%rbx,8)
	movq	%rcx, %rbx
	jne	LBB0_1
## %bb.3:
	addl	%ecx, %eax
	movq	%rdi, (%r9,%rcx,8)
	movq	_MptDriverClass@GOTPCREL(%rip), %rdi
	leaq	(,%r8,4), %rbx
	movq	(%rdi), %rdi
	addq	%rbx, %rdi
	movl	%esi, (%rdi,%rcx,4)
	movq	_MptEvHandlers@GOTPCREL(%rip), %rsi
	shlq	$3, %r8
	addq	(%rsi), %r8
	movq	$0, (%r8,%rcx,8)
	movl	%eax, (%r14)
	movq	_MptCallbacksName@GOTPCREL(%rip), %rax
	addq	(%rax), %rbx
	movl	(%rbx,%rcx,4), %edi
	movq	_MPT_MAX_CALLBACKNAME_LEN@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	incq	%rax
	movq	%rdx, %rsi
	movq	%rax, %rdx
	callq	_strlcpy
	movl	(%r14), %eax
LBB0_4:
                                        ## kill: def $eax killed $eax killed $rax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MPT_MAX_PROTOCOL_DRIVERS,4,2   ## @MPT_MAX_PROTOCOL_DRIVERS
	.comm	_last_drv_idx,4,2               ## @last_drv_idx
	.comm	_MptCallbacks,8,3               ## @MptCallbacks
	.comm	_MptDriverClass,8,3             ## @MptDriverClass
	.comm	_MptEvHandlers,8,3              ## @MptEvHandlers
	.comm	_MptCallbacksName,8,3           ## @MptCallbacksName
	.comm	_MPT_MAX_CALLBACKNAME_LEN,8,3   ## @MPT_MAX_CALLBACKNAME_LEN
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mpt_register                   ; -- Begin function mpt_register
	.p2align	2
_mpt_register:                          ; @mpt_register
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x8, x0
	mov	x9, #0
Lloh0:
	adrp	x10, _MPT_MAX_PROTOCOL_DRIVERS@GOTPAGE
Lloh1:
	ldr	x10, [x10, _MPT_MAX_PROTOCOL_DRIVERS@GOTPAGEOFF]
Lloh2:
	ldrsw	x10, [x10]
Lloh3:
	adrp	x19, _last_drv_idx@GOTPAGE
Lloh4:
	ldr	x19, [x19, _last_drv_idx@GOTPAGEOFF]
	and	x0, x10, #0xffffffff
	str	w10, [x19]
Lloh5:
	adrp	x11, _MptCallbacks@GOTPAGE
Lloh6:
	ldr	x11, [x11, _MptCallbacks@GOTPAGEOFF]
Lloh7:
	ldr	x11, [x11]
	sub	x11, x11, #8
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	add	w12, w0, w9
	cmp	w12, #1
	b.eq	LBB0_4
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	ldr	x12, [x11, x10, lsl #3]
	sub	x9, x9, #1
	sub	x11, x11, #8
	cbnz	x12, LBB0_1
; %bb.3:
	lsl	x12, x10, #3
	add	x11, x11, x12
	str	x8, [x11, #8]
Lloh8:
	adrp	x8, _MptDriverClass@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MptDriverClass@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	lsl	x10, x10, #2
	add	x8, x8, x10
	lsl	x11, x9, #2
	str	w1, [x8, x11]
Lloh11:
	adrp	x8, _MptEvHandlers@GOTPAGE
Lloh12:
	ldr	x8, [x8, _MptEvHandlers@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
	add	x8, x8, x12
	str	xzr, [x8, x9, lsl #3]
	add	w8, w0, w9
	str	w8, [x19]
Lloh14:
	adrp	x8, _MptCallbacksName@GOTPAGE
Lloh15:
	ldr	x8, [x8, _MptCallbacksName@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	add	x8, x8, x10
	ldr	w0, [x8, x11]
Lloh17:
	adrp	x8, _MPT_MAX_CALLBACKNAME_LEN@GOTPAGE
Lloh18:
	ldr	x8, [x8, _MPT_MAX_CALLBACKNAME_LEN@GOTPAGEOFF]
Lloh19:
	ldr	x8, [x8]
	add	x8, x8, #1
	mov	x1, x2
	mov	x2, x8
	bl	_strlcpy
	ldr	w0, [x19]
LBB0_4:
                                        ; kill: def $w0 killed $w0 killed $x0
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_MPT_MAX_PROTOCOL_DRIVERS,4,2   ; @MPT_MAX_PROTOCOL_DRIVERS
	.comm	_last_drv_idx,4,2               ; @last_drv_idx
	.comm	_MptCallbacks,8,3               ; @MptCallbacks
	.comm	_MptDriverClass,8,3             ; @MptDriverClass
	.comm	_MptEvHandlers,8,3              ; @MptEvHandlers
	.comm	_MptCallbacksName,8,3           ; @MptCallbacksName
	.comm	_MPT_MAX_CALLBACKNAME_LEN,8,3   ; @MPT_MAX_CALLBACKNAME_LEN
.subsections_via_symbols
