	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mclk_get_divisor
_mclk_get_divisor:                      ## @mclk_get_divisor
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	(%rdi), %r15d
	movl	16(%rdi), %edi
	callq	_clk_get_rate
	movq	%rax, %rcx
	leal	(%r15,%r15), %esi
	addq	%rsi, %rax
	decq	%rax
	movq	%rax, %rdx
	shrq	$32, %rdx
	je	LBB0_1
## %bb.2:
	xorl	%edx, %edx
	divq	%rsi
	movq	%rax, %rbx
	jmp	LBB0_3
LBB0_1:
                                        ## kill: def $eax killed $eax killed $rax
	xorl	%edx, %edx
	divl	%esi
	movl	%eax, %ebx
LBB0_3:
	decq	%rbx
	movq	8(%r14), %rax
	movl	(%rax), %edi
	shrq	$3, %rcx
	movabsq	$2361183241434822607, %rdx      ## imm = 0x20C49BA5E353F7CF
	movq	%rcx, %rax
	mulq	%rdx
	shrq	$4, %rdx
	movl	%r15d, %eax
	imulq	$274877907, %rax, %rcx          ## imm = 0x10624DD3
	shrq	$38, %rcx
	leaq	L_.str(%rip), %rsi
                                        ## kill: def $ecx killed $ecx killed $rcx
	movq	%rbx, %r8
	callq	_dev_dbg
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"System clock %lukHz, target freq %dkHz, divisor %lu\n"

	.no_dead_strip	_mclk_get_divisor
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mclk_get_divisor
_mclk_get_divisor:                      ; @mclk_get_divisor
	.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
	mov	x19, x0
	ldr	w21, [x0]
	ldr	w0, [x0, #16]
	bl	_clk_get_rate
	lsl	w8, w21, #1
	add	x9, x8, x0
	sub	x9, x9, #1
	udiv	x8, x9, x8
	sub	x20, x8, #1
	ldr	x8, [x19, #8]
	ldr	w8, [x8]
	lsr	x9, x0, #3
	mov	x10, #63439
	movk	x10, #58195, lsl #16
	movk	x10, #39845, lsl #32
	movk	x10, #8388, lsl #48
	umulh	x9, x9, x10
	lsr	x2, x9, #4
	mov	w9, #19923
	movk	w9, #4194, lsl #16
	mul	x9, x21, x9
	lsr	x3, x9, #38
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x8
                                        ; kill: def $w3 killed $w3 killed $x3
	mov	x4, x20
	bl	_dev_dbg
	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 AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"System clock %lukHz, target freq %dkHz, divisor %lu\n"

	.no_dead_strip	_mclk_get_divisor
.subsections_via_symbols
