	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ad714x_wheel_cal_sensor_val
_ad714x_wheel_cal_sensor_val:           ## @ad714x_wheel_cal_sensor_val
	.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	%rdi, %r12
	movq	32(%rdi), %rax
	movq	(%rax), %r14
	movslq	%esi, %rbx
	movq	_CDC_RESULT_S0@GOTPCREL(%rip), %rax
	shlq	$4, %rbx
	movq	(%r14,%rbx), %rdi
	movq	(%rax), %rsi
	leaq	(,%rdi,8), %rdx
	addq	(%r12), %rdx
	addq	%rdi, %rsi
	movl	8(%r14,%rbx), %ecx
	subl	%edi, %ecx
	incl	%ecx
	movq	%r12, %rdi
	callq	*24(%r12)
	movq	(%r14,%rbx), %rax
	cmpl	%eax, 8(%r14,%rbx)
	jl	LBB0_3
## %bb.1:
	leaq	(%r14,%rbx), %rcx
	addq	$8, %rcx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	movslq	%eax, %r15
	movq	8(%r12), %rdx
	leaq	(,%r15,8), %rbx
	movq	$-1, %r13
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	leaq	(%r15,%r14), %rax
	movq	_PER_STAGE_REG_NUM@GOTPCREL(%rip), %rcx
	movslq	(%rcx), %rsi
	imulq	%rax, %rsi
	movq	_STAGE0_AMBIENT@GOTPCREL(%rip), %rax
	addq	(%rax), %rsi
	addq	%rbx, %rdx
	movq	%r12, %rdi
	movl	$1, %ecx
	callq	*24(%r12)
	movq	(%r12), %rax
	movq	8(%r12), %rdx
	movq	(%rax,%rbx), %rax
	subq	(%rdx,%rbx), %rax
	movl	$0, %ecx
	cmovleq	%rcx, %rax
	movq	16(%r12), %rcx
	movq	%rax, (%rcx,%rbx)
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movslq	(%rax), %rax
	addq	$8, %rbx
	leaq	(%r15,%r13), %rcx
	incq	%rcx
	incq	%r13
	incq	%r14
	cmpq	%rax, %rcx
	jl	LBB0_2
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CDC_RESULT_S0,8,3              ## @CDC_RESULT_S0
	.comm	_STAGE0_AMBIENT,8,3             ## @STAGE0_AMBIENT
	.comm	_PER_STAGE_REG_NUM,4,2          ## @PER_STAGE_REG_NUM
	.no_dead_strip	_ad714x_wheel_cal_sensor_val
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ad714x_wheel_cal_sensor_val
_ad714x_wheel_cal_sensor_val:           ; @ad714x_wheel_cal_sensor_val
	.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
                                        ; kill: def $w1 killed $w1 def $x1
	mov	x19, x0
	ldp	x9, x8, [x0, #24]
	ldr	x21, [x8]
Lloh0:
	adrp	x8, _CDC_RESULT_S0@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CDC_RESULT_S0@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	sbfiz	x22, x1, #4, #32
	add	x20, x21, x22
	ldr	x10, [x21, x22]
	add	x1, x10, x8
	ldr	x8, [x0]
	add	x2, x8, x10, lsl #3
	ldr	w8, [x20, #8]!
	sub	w8, w8, w10
	add	w3, w8, #1
	blr	x9
	ldr	x8, [x21, x22]
	ldr	w9, [x20]
	cmp	w9, w8
	b.lt	LBB0_3
; %bb.1:
	sxtw	x9, w8
	ldr	x8, [x19, #8]
	lsl	x21, x9, #3
	sub	x22, x9, #1
Lloh3:
	adrp	x23, _STAGE0_AMBIENT@GOTPAGE
Lloh4:
	ldr	x23, [x23, _STAGE0_AMBIENT@GOTPAGEOFF]
Lloh5:
	adrp	x24, _PER_STAGE_REG_NUM@GOTPAGE
Lloh6:
	ldr	x24, [x24, _PER_STAGE_REG_NUM@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	add	x22, x22, #1
	ldr	x9, [x19, #24]
	ldr	x10, [x23]
	ldrsw	x11, [x24]
	madd	x1, x22, x11, x10
	add	x2, x8, x21
	mov	x0, x19
	mov	w3, #1
	blr	x9
	ldp	x9, x8, [x19]
	ldr	x9, [x9, x21]
	ldr	x10, [x8, x21]
	subs	x9, x9, x10
	csel	x9, x9, xzr, gt
	ldr	x10, [x19, #16]
	str	x9, [x10, x21]
	ldrsw	x9, [x20]
	add	x21, x21, #8
	cmp	x22, x9
	b.lt	LBB0_2
LBB0_3:
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_CDC_RESULT_S0,8,3              ; @CDC_RESULT_S0
	.comm	_STAGE0_AMBIENT,8,3             ; @STAGE0_AMBIENT
	.comm	_PER_STAGE_REG_NUM,4,2          ; @PER_STAGE_REG_NUM
	.no_dead_strip	_ad714x_wheel_cal_sensor_val
.subsections_via_symbols
