	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function smu10_get_clock_by_type_with_latency
_smu10_get_clock_by_type_with_latency:  ## @smu10_get_clock_by_type_with_latency
	.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
                                        ## kill: def $esi killed $esi def $rsi
	movq	(%rdi), %rax
	testq	%rax, %rax
	je	LBB0_17
## %bb.1:
	addl	$-128, %esi
	cmpl	$5, %esi
	ja	LBB0_17
## %bb.2:
	movq	%rdx, %r12
	movq	%rdi, %r14
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rsi,4), %rdx
	addq	%rcx, %rdx
	jmpq	*%rdx
LBB0_3:
	addq	$8, %rax
	jmp	LBB0_10
LBB0_5:
	addq	$40, %rax
	jmp	LBB0_7
LBB0_6:
	addq	$32, %rax
LBB0_7:
	xorl	%r15d, %r15d
	jmp	LBB0_11
LBB0_8:
	addq	$16, %rax
	jmp	LBB0_10
LBB0_9:
	addq	$24, %rax
LBB0_10:
	movb	$1, %r15b
LBB0_11:
	movq	(%rax), %r13
	testq	%r13, %r13
	je	LBB0_17
## %bb.12:
	movq	(%r13), %rcx
	testq	%rcx, %rcx
	je	LBB0_17
## %bb.13:
	movq	$0, (%r12)
	movq	8(%r12), %rdi
	xorl	%edx, %edx
	xorl	%ebx, %ebx
	jmp	LBB0_15
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_15 Depth=1
	movl	%eax, 4(%rdi,%rbx,8)
	incq	%rdx
	movq	%rdx, (%r12)
	incq	%rbx
	cmpq	%rcx, %rbx
	jae	LBB0_18
LBB0_15:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r13), %rax
	movl	(%rax,%rbx,4), %esi
	leal	(%rsi,%rsi), %eax
	leal	(%rax,%rax,4), %eax
	movl	%eax, (%rdi,%rbx,8)
	movl	$0, %eax
	testb	%r15b, %r15b
	jne	LBB0_14
## %bb.16:                              ##   in Loop: Header=BB0_15 Depth=1
	movq	%r14, %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_smu10_get_mem_latency
	movq	(%r12), %rdx
	movq	8(%r12), %rdi
	movq	(%r13), %rcx
	jmp	LBB0_14
LBB0_17:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_19
LBB0_18:
	xorl	%eax, %eax
LBB0_19:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_10, LBB0_10-LJTI0_0
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
LJTI0_0:
	.long	L0_0_set_3
	.long	L0_0_set_5
	.long	L0_0_set_6
	.long	L0_0_set_10
	.long	L0_0_set_8
	.long	L0_0_set_9
	.end_data_region
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_smu10_get_clock_by_type_with_latency
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function smu10_get_clock_by_type_with_latency
_smu10_get_clock_by_type_with_latency:  ; @smu10_get_clock_by_type_with_latency
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	x8, [x0]
	cbz	x8, LBB0_15
; %bb.1:
	sub	w9, w1, #128
	cmp	w9, #5
	b.hi	LBB0_15
; %bb.2:
	mov	x19, x2
	mov	x20, x0
Lloh0:
	adrp	x10, lJTI0_0@PAGE
Lloh1:
	add	x10, x10, lJTI0_0@PAGEOFF
	adr	x11, LBB0_3
	ldrb	w12, [x10, x9]
	add	x11, x11, x12, lsl #2
	br	x11
LBB0_3:
	add	x8, x8, #8
	b	LBB0_8
LBB0_4:
	mov	w21, #0
	add	x8, x8, #40
	ldr	x22, [x8]
	cbnz	x22, LBB0_9
	b	LBB0_15
LBB0_5:
	mov	w21, #0
	add	x8, x8, #32
	ldr	x22, [x8]
	cbnz	x22, LBB0_9
	b	LBB0_15
LBB0_6:
	add	x8, x8, #16
	b	LBB0_8
LBB0_7:
	add	x8, x8, #24
LBB0_8:
	mov	w21, #1
	ldr	x22, [x8]
	cbz	x22, LBB0_15
LBB0_9:
	ldr	x8, [x22]
	cbz	x8, LBB0_15
; %bb.10:
	mov	x23, #0
	mov	x9, #0
	mov	x24, #0
	str	xzr, [x19]
	ldr	x10, [x19, #8]
	b	LBB0_13
LBB0_11:                                ;   in Loop: Header=BB0_13 Depth=1
	mov	x0, x20
	bl	_smu10_get_mem_latency
	ldp	x9, x10, [x19]
	ldr	x8, [x22]
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	add	x11, x10, x23
	str	w0, [x11, #4]
	add	x9, x9, #1
	str	x9, [x19]
	add	x24, x24, #1
	add	x23, x23, #8
	cmp	x24, x8
	b.hs	LBB0_16
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x22, #8]
	ldr	w1, [x11, x24, lsl #2]
	add	w11, w1, w1, lsl #2
	lsl	w11, w11, #1
	str	w11, [x10, x23]
	tbz	w21, #0, LBB0_11
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	mov	w0, #0
	b	LBB0_12
LBB0_15:
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_17
LBB0_16:
	mov	w0, #0
LBB0_17:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_3-LBB0_3)>>2
	.byte	(LBB0_4-LBB0_3)>>2
	.byte	(LBB0_5-LBB0_3)>>2
	.byte	(LBB0_8-LBB0_3)>>2
	.byte	(LBB0_6-LBB0_3)>>2
	.byte	(LBB0_7-LBB0_3)>>2
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_smu10_get_clock_by_type_with_latency
.subsections_via_symbols
