	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function _dpu_core_perf_calc_crtc
__dpu_core_perf_calc_crtc:              ## @_dpu_core_perf_calc_crtc
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rdi, %rdi
	je	LBB0_13
## %bb.1:
	movq	%rcx, %r15
	testq	%rcx, %rcx
	je	LBB0_13
## %bb.2:
	testq	%rdx, %rdx
	je	LBB0_13
## %bb.3:
	movq	%rsi, %r14
	testq	%rsi, %rsi
	je	LBB0_13
## %bb.4:
	movq	%rdi, %rbx
	cmpq	$0, 40(%rdi)
	je	LBB0_13
## %bb.5:
	movq	%rdx, %rdi
	callq	_to_dpu_crtc_state
	movq	%rax, %r12
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$24, %edx
	callq	_memset
	cmpl	$0, (%r12)
	je	LBB0_6
## %bb.7:
	movq	24(%rbx), %rax
	movq	_DPU_PERF_MODE_MINIMUM@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_9
## %bb.8:
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%r15)
	movq	$0, 16(%r15)
	xorl	%r8d, %r8d
	xorl	%ecx, %ecx
	xorl	%edx, %edx
	jmp	LBB0_12
LBB0_13:
	leaq	L_.str(%rip), %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DPU_ERROR                      ## TAILCALL
LBB0_6:
	movq	40(%rbx), %rax
	imulq	$1000, (%rax), %r8              ## imm = 0x3E8
	movq	%r8, (%r15)
	movq	%r8, 8(%r15)
	movq	32(%rbx), %rdx
	movq	%rdx, 16(%r15)
	movq	%r8, %rcx
	jmp	LBB0_12
LBB0_9:
	movq	_DPU_PERF_MODE_FIXED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_10
## %bb.11:
	movq	(%rbx), %r8
	movq	%r8, (%r15)
	movq	8(%rbx), %rcx
	movq	%rcx, 8(%r15)
	movq	16(%rbx), %rdx
	movq	%rdx, 16(%r15)
	jmp	LBB0_12
LBB0_10:
	movq	16(%r15), %rdx
	movq	(%r15), %r8
	movq	8(%r15), %rcx
LBB0_12:
	movl	(%r14), %esi
	leaq	L_.str.1(%rip), %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DPU_DEBUG                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid parameters\n"

	.comm	_DPU_PERF_MODE_MINIMUM,8,3      ## @DPU_PERF_MODE_MINIMUM
	.comm	_DPU_PERF_MODE_FIXED,8,3        ## @DPU_PERF_MODE_FIXED
L_.str.1:                               ## @.str.1
	.asciz	"crtc=%d clk_rate=%llu core_ib=%llu core_ab=%llu\n"

	.no_dead_strip	__dpu_core_perf_calc_crtc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function _dpu_core_perf_calc_crtc
__dpu_core_perf_calc_crtc:              ; @_dpu_core_perf_calc_crtc
	.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
	cbz	x0, LBB0_8
; %bb.1:
	mov	x20, x3
	cbz	x3, LBB0_8
; %bb.2:
	cbz	x2, LBB0_8
; %bb.3:
	mov	x19, x1
	cbz	x1, LBB0_8
; %bb.4:
	mov	x21, x0
	ldr	x8, [x0, #40]
	cbz	x8, LBB0_8
; %bb.5:
	mov	x0, x2
	bl	_to_dpu_crtc_state
	mov	x22, x0
	mov	x0, x20
	mov	w1, #0
	mov	w2, #24
	bl	_memset
	ldr	w8, [x22]
	cbz	w8, LBB0_9
; %bb.6:
	ldr	x8, [x21, #24]
Lloh0:
	adrp	x9, _DPU_PERF_MODE_MINIMUM@GOTPAGE
Lloh1:
	ldr	x9, [x9, _DPU_PERF_MODE_MINIMUM@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_10
; %bb.7:
	mov	x4, #0
	mov	x3, #0
	mov	x2, #0
	stp	xzr, xzr, [x20]
	str	xzr, [x20, #16]
	b	LBB0_13
LBB0_8:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	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
	b	_DPU_ERROR
LBB0_9:
	ldp	x2, x8, [x21, #32]
	ldr	x8, [x8]
	mov	w9, #1000
	mul	x4, x8, x9
	stp	x4, x4, [x20]
	str	x2, [x20, #16]
	mov	x3, x4
	b	LBB0_13
LBB0_10:
Lloh5:
	adrp	x9, _DPU_PERF_MODE_FIXED@GOTPAGE
Lloh6:
	ldr	x9, [x9, _DPU_PERF_MODE_FIXED@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_12
; %bb.11:
	ldp	x4, x3, [x21]
	stp	x4, x3, [x20]
	ldr	x2, [x21, #16]
	str	x2, [x20, #16]
	b	LBB0_13
LBB0_12:
	ldp	x3, x2, [x20, #8]
	ldr	x4, [x20]
LBB0_13:
Lloh8:
	adrp	x0, l_.str.1@PAGE
Lloh9:
	add	x0, x0, l_.str.1@PAGEOFF
	ldr	w1, [x19]
	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
	b	_DPU_DEBUG
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid parameters\n"

	.comm	_DPU_PERF_MODE_MINIMUM,8,3      ; @DPU_PERF_MODE_MINIMUM
	.comm	_DPU_PERF_MODE_FIXED,8,3        ; @DPU_PERF_MODE_FIXED
l_.str.1:                               ; @.str.1
	.asciz	"crtc=%d clk_rate=%llu core_ib=%llu core_ab=%llu\n"

	.no_dead_strip	__dpu_core_perf_calc_crtc
.subsections_via_symbols
