	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_device_enable_mgpu_fan_boost
_amdgpu_device_enable_mgpu_fan_boost:   ## @amdgpu_device_enable_mgpu_fan_boost
	.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
	movq	_mgpu_info@GOTPCREL(%rip), %r15
	leaq	4(%r15), %rbx
	movq	%rbx, %rdi
	callq	_mutex_lock
	movl	(%r15), %eax
	xorl	%r12d, %r12d
	cmpl	$2, %eax
	jl	LBB0_12
## %bb.1:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	movq	_AMD_IS_APU@GOTPCREL(%rip), %rdx
	xorl	%r14d, %r14d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	incq	%r14
	movslq	%eax, %rcx
	addq	$16, %rbx
	cmpq	%rcx, %r14
	jge	LBB0_10
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r15), %r13
	movq	8(%r13,%rbx), %rdi
	movl	(%rdx), %ecx
	testl	%ecx, (%rdi)
	jne	LBB0_9
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$0, (%r13,%rbx)
	jne	LBB0_9
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%rdi), %rcx
	testq	%rcx, %rcx
	je	LBB0_9
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpq	$0, (%rcx)
	je	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	callq	_amdgpu_dpm_enable_mgpu_fan_boost
	testl	%eax, %eax
	jne	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	$1, (%r13,%rbx)
	movl	(%r15), %eax
	movq	_AMD_IS_APU@GOTPCREL(%rip), %rdx
	jmp	LBB0_9
LBB0_10:
	xorl	%r12d, %r12d
LBB0_11:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
LBB0_12:
	movq	%rbx, %rdi
	callq	_mutex_unlock
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movl	%eax, %r12d
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_mgpu_info,16,3                 ## @mgpu_info
	.comm	_AMD_IS_APU,4,2                 ## @AMD_IS_APU
	.no_dead_strip	_amdgpu_device_enable_mgpu_fan_boost
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_device_enable_mgpu_fan_boost
_amdgpu_device_enable_mgpu_fan_boost:   ; @amdgpu_device_enable_mgpu_fan_boost
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
Lloh0:
	adrp	x21, _mgpu_info@GOTPAGE
Lloh1:
	ldr	x21, [x21, _mgpu_info@GOTPAGEOFF]
	add	x19, x21, #4
	mov	x0, x19
	bl	_mutex_lock
	ldr	w8, [x21]
	cmp	w8, #2
	b.lt	LBB0_9
; %bb.1:
	mov	x22, #0
	mov	x23, #0
Lloh2:
	adrp	x24, _AMD_IS_APU@GOTPAGE
Lloh3:
	ldr	x24, [x24, _AMD_IS_APU@GOTPAGEOFF]
	mov	w25, #1
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x23, x23, #1
	add	x22, x22, #16
	cmp	x23, w8, sxtw
	b.ge	LBB0_9
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x26, [x21, #8]
	add	x9, x26, x22
	ldr	x0, [x9, #8]
	ldr	w9, [x0]
	ldr	w10, [x24]
	tst	w10, w9
	b.ne	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w9, [x26, x22]
	cbnz	w9, LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x9, [x0, #8]
	cbz	x9, LBB0_2
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x9, [x9]
	cbz	x9, LBB0_2
; %bb.7:                                ;   in Loop: Header=BB0_3 Depth=1
	bl	_amdgpu_dpm_enable_mgpu_fan_boost
	cbnz	w0, LBB0_11
; %bb.8:                                ;   in Loop: Header=BB0_3 Depth=1
	str	w25, [x26, x22]
	ldr	w8, [x21]
	b	LBB0_2
LBB0_9:
	mov	w20, #0
LBB0_10:
	mov	x0, x19
	bl	_mutex_unlock
	mov	x0, x20
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_11:
	mov	x20, x0
	b	LBB0_10
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.comm	_mgpu_info,16,3                 ; @mgpu_info
	.comm	_AMD_IS_APU,4,2                 ; @AMD_IS_APU
	.no_dead_strip	_amdgpu_device_enable_mgpu_fan_boost
.subsections_via_symbols
