	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function aw_clk_nm_find_best
_aw_clk_nm_find_best:                   ## @aw_clk_nm_find_best
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movl	%esi, -60(%rbp)                 ## 4-byte Spill
	movq	%rdi, %r14
	movq	%r8, -88(%rbp)                  ## 8-byte Spill
	movl	$0, (%r8)
	movq	%rcx, -80(%rbp)                 ## 8-byte Spill
	movl	$0, (%rcx)
	callq	_aw_clk_factor_get_max
	movl	%eax, %r15d
	leaq	4(%r14), %r12
	movq	%r12, %rdi
	callq	_aw_clk_factor_get_max
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	%r14, -72(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	callq	_aw_clk_factor_get_min
	movl	%eax, %r13d
	movq	%r12, -96(%rbp)                 ## 8-byte Spill
	movq	%r12, %rdi
	callq	_aw_clk_factor_get_min
                                        ## implicit-def: $eax
                                        ## kill: killed $eax
	movl	%r15d, -56(%rbp)                ## 4-byte Spill
	cmpl	%r15d, %r13d
	jle	LBB0_1
LBB0_8:
	movl	-48(%rbp), %eax                 ## 4-byte Reload
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
                                        ## implicit-def: $eax
                                        ## kill: killed $eax
	movl	%r13d, %r14d
	movl	%r13d, -52(%rbp)                ## 4-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_AW_CLK_FACTOR_POWER_OF_TWO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	leal	(%r14,%r14), %ecx
	incl	%r14d
	movq	-72(%rbp), %rdx                 ## 8-byte Reload
	testl	%eax, (%rdx)
	cmovnel	%ecx, %r14d
	cmpl	-56(%rbp), %r14d                ## 4-byte Folded Reload
	movl	-52(%rbp), %r13d                ## 4-byte Reload
	jg	LBB0_8
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
	cmpl	-44(%rbp), %r13d                ## 4-byte Folded Reload
	jg	LBB0_9
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%r13d, %r12d
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_4 Depth=2
	movq	_AW_CLK_FACTOR_POWER_OF_TWO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	leal	(%r12,%r12), %ecx
	incl	%r12d
	movq	-96(%rbp), %rdx                 ## 8-byte Reload
	testl	%eax, (%rdx)
	cmovnel	%ecx, %r12d
	cmpl	-44(%rbp), %r12d                ## 4-byte Folded Reload
	jg	LBB0_7
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	-60(%rbp), %eax                 ## 4-byte Reload
	cltd
	idivl	%r12d
	cltd
	idivl	%r14d
	movl	%eax, %r15d
	movl	(%rbx), %edi
	subl	%eax, %edi
	callq	_abs
	movq	%rax, %r13
	movl	(%rbx), %edi
	subl	-48(%rbp), %edi                 ## 4-byte Folded Reload
	callq	_abs
	cmpq	%rax, %r13
	jge	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=2
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	movl	%r12d, (%rax)
	movq	-88(%rbp), %rax                 ## 8-byte Reload
	movl	%r14d, (%rax)
	movl	%r15d, -48(%rbp)                ## 4-byte Spill
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_AW_CLK_FACTOR_POWER_OF_TWO,4,2 ## @AW_CLK_FACTOR_POWER_OF_TWO
	.no_dead_strip	_aw_clk_nm_find_best
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function aw_clk_nm_find_best
_aw_clk_nm_find_best:                   ; @aw_clk_nm_find_best
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	stp	x3, x4, [sp, #16]               ; 16-byte Folded Spill
	str	wzr, [x4]
	str	wzr, [x3]
	bl	_aw_clk_factor_get_max
	mov	x24, x0
	add	x25, x19, #4
	mov	x0, x25
	bl	_aw_clk_factor_get_max
	mov	x26, x0
	mov	x0, x19
	bl	_aw_clk_factor_get_min
	mov	x28, x0
	mov	x0, x25
	bl	_aw_clk_factor_get_min
                                        ; implicit-def: $w20
	cmp	w28, w24
	b.le	LBB0_2
LBB0_1:
	mov	x0, x20
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_2:
Lloh0:
	adrp	x23, _AW_CLK_FACTOR_POWER_OF_TWO@GOTPAGE
Lloh1:
	ldr	x23, [x23, _AW_CLK_FACTOR_POWER_OF_TWO@GOTPAGEOFF]
                                        ; implicit-def: $w20
	mov	x27, x28
	str	x19, [sp, #8]                   ; 8-byte Folded Spill
	stp	w28, w24, [sp]                  ; 8-byte Folded Spill
	b	LBB0_5
LBB0_3:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	x19, [sp, #8]                   ; 8-byte Folded Reload
	ldp	w28, w24, [sp]                  ; 8-byte Folded Reload
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	w9, [x19]
	lsl	w10, w27, #1
	tst	w8, w9
	csinc	w27, w10, w27, ne
	cmp	w27, w24
	b.gt	LBB0_1
LBB0_5:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_9 Depth 2
	cmp	w28, w26
	b.le	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x23]
	b	LBB0_4
LBB0_7:                                 ;   in Loop: Header=BB0_5 Depth=1
	mov	x19, x28
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=2
	ldr	w9, [x25]
	ldr	w8, [x23]
	lsl	w10, w19, #1
	tst	w8, w9
	csinc	w19, w10, w19, ne
	cmp	w19, w26
	b.gt	LBB0_3
LBB0_9:                                 ;   Parent Loop BB0_5 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	sdiv	w8, w22, w19
	sdiv	w28, w8, w27
	ldr	w8, [x21]
	sub	w0, w8, w28
	bl	_abs
	mov	x24, x0
	ldr	w8, [x21]
	sub	w0, w8, w20
	bl	_abs
	cmp	x24, x0
	b.ge	LBB0_8
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=2
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	str	w19, [x8]
	ldr	x8, [sp, #24]                   ; 8-byte Folded Reload
	str	w27, [x8]
	mov	x20, x28
	b	LBB0_8
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_AW_CLK_FACTOR_POWER_OF_TWO,4,2 ; @AW_CLK_FACTOR_POWER_OF_TWO
	.no_dead_strip	_aw_clk_nm_find_best
.subsections_via_symbols
