	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function get_rpm_fan
_get_rpm_fan:                           ## @get_rpm_fan
	.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
	movl	%esi, %r14d
	movq	_fcu_fans@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	%edi, %rcx
	shlq	$4, %rcx
	movq	(%rax,%rcx), %rdx
	movq	_FCU_FAN_RPM@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rdx
	jne	LBB0_1
## %bb.3:
	movl	8(%rax,%rcx), %ebx
	movq	_FCU_FAN_ABSENT_ID@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_4
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_13:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	leaq	-26(%rbp), %rsi
	movl	$1, %r15d
	movl	$11, %edi
	movl	$1, %edx
	callq	_fan_read_reg
	cmpl	$1, %eax
	jne	LBB0_5
## %bb.6:
	movzbl	-26(%rbp), %eax
	movl	%ebx, %ecx
	shll	%cl, %r15d
	btl	%ebx, %eax
	jae	LBB0_8
## %bb.7:
	movq	_EFAULT@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_8:
	leaq	-25(%rbp), %rsi
	movl	$13, %edi
	movl	$1, %edx
	callq	_fan_read_reg
	cmpl	$1, %eax
	jne	LBB0_5
## %bb.9:
	movzbl	-25(%rbp), %eax
	testl	%eax, %r15d
	je	LBB0_10
## %bb.11:
	xorl	%eax, %eax
	testl	%r14d, %r14d
	sete	%al
	leal	(%rax,%rbx,2), %edi
	addl	$16, %edi
	leaq	-28(%rbp), %rsi
	movl	$2, %edx
	callq	_fan_read_reg
	cmpl	$2, %eax
	jne	LBB0_5
## %bb.12:
	movzbl	-28(%rbp), %esi
	movq	_fcu_rpm_shift@GOTPCREL(%rip), %rax
	movb	(%rax), %dl
	movb	$8, %cl
	subb	%dl, %cl
	shll	%cl, %esi
	movzbl	-27(%rbp), %eax
	movl	%edx, %ecx
	shrl	%cl, %eax
	orl	%esi, %eax
	jmp	LBB0_13
LBB0_5:
	movq	_EIO@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
LBB0_10:
	movq	_ENXIO@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
	.cfi_endproc
                                        ## -- End function
	.comm	_fcu_fans,8,3                   ## @fcu_fans
	.comm	_FCU_FAN_RPM,8,3                ## @FCU_FAN_RPM
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_FCU_FAN_ABSENT_ID,4,2          ## @FCU_FAN_ABSENT_ID
	.comm	_EIO,4,2                        ## @EIO
	.comm	_EFAULT,4,2                     ## @EFAULT
	.comm	_ENXIO,4,2                      ## @ENXIO
	.comm	_fcu_rpm_shift,4,2              ## @fcu_rpm_shift
	.no_dead_strip	_get_rpm_fan
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function get_rpm_fan
_get_rpm_fan:                           ; @get_rpm_fan
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
                                        ; kill: def $w0 killed $w0 def $x0
Lloh0:
	adrp	x8, _fcu_fans@GOTPAGE
Lloh1:
	ldr	x8, [x8, _fcu_fans@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	sbfiz	x9, x0, #4, #32
	ldr	x9, [x8, x9]
Lloh3:
	adrp	x10, _FCU_FAN_RPM@GOTPAGE
Lloh4:
	ldr	x10, [x10, _FCU_FAN_RPM@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_2
; %bb.1:
	sxtw	x9, w0
	add	x8, x8, x9, lsl #4
	ldr	w20, [x8, #8]
Lloh6:
	adrp	x8, _FCU_FAN_ABSENT_ID@GOTPAGE
Lloh7:
	ldr	x8, [x8, _FCU_FAN_ABSENT_ID@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmp	w20, w8
	b.ne	LBB0_5
LBB0_2:
Lloh9:
	adrp	x8, _EINVAL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_3:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	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
	add	sp, sp, #64
	ret
LBB0_5:
	mov	x19, x1
	mov	w21, #1
	add	x1, sp, #15
	mov	w0, #11
	mov	w2, #1
	bl	_fan_read_reg
	cmp	w0, #1
	b.ne	LBB0_12
; %bb.6:
	ldrb	w8, [sp, #15]
	lsl	w21, w21, w20
	tst	w21, w8
	b.eq	LBB0_8
; %bb.7:
Lloh11:
	adrp	x8, _EFAULT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
	b	LBB0_3
LBB0_8:
	add	x1, sp, #14
	mov	w0, #13
	mov	w2, #1
	bl	_fan_read_reg
	cmp	w0, #1
	b.ne	LBB0_12
; %bb.9:
	ldrb	w8, [sp, #14]
	tst	w21, w8
	b.eq	LBB0_13
; %bb.10:
	cmp	w19, #0
	mov	w8, #16
	cinc	w8, w8, eq
	add	w0, w8, w20, lsl #1
	add	x1, sp, #12
	mov	w2, #2
	bl	_fan_read_reg
	cmp	w0, #2
	b.ne	LBB0_12
; %bb.11:
	ldrb	w8, [sp, #12]
Lloh13:
	adrp	x9, _fcu_rpm_shift@GOTPAGE
Lloh14:
	ldr	x9, [x9, _fcu_rpm_shift@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	mov	w10, #8
	sub	w10, w10, w9
	lsl	w8, w8, w10
	ldrb	w10, [sp, #13]
	lsr	w9, w10, w9
	orr	w0, w9, w8
	b	LBB0_4
LBB0_12:
Lloh16:
	adrp	x8, _EIO@GOTPAGE
Lloh17:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
	b	LBB0_3
LBB0_13:
Lloh18:
	adrp	x8, _ENXIO@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_fcu_fans,8,3                   ; @fcu_fans
	.comm	_FCU_FAN_RPM,8,3                ; @FCU_FAN_RPM
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_FCU_FAN_ABSENT_ID,4,2          ; @FCU_FAN_ABSENT_ID
	.comm	_EIO,4,2                        ; @EIO
	.comm	_EFAULT,4,2                     ; @EFAULT
	.comm	_ENXIO,4,2                      ; @ENXIO
	.comm	_fcu_rpm_shift,4,2              ; @fcu_rpm_shift
	.no_dead_strip	_get_rpm_fan
.subsections_via_symbols
