	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lpc18xx_dac_read_raw
_lpc18xx_dac_read_raw:                  ## @lpc18xx_dac_read_raw
	.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
	movq	%r8, %rbx
	movq	%rcx, %r14
	movq	%rdx, %r15
	callq	_iio_priv
	cmpq	$128, %rbx
	je	LBB0_3
## %bb.1:
	cmpq	$129, %rbx
	jne	LBB0_4
## %bb.2:
	movq	_LPC18XX_DAC_CR@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdi
	addq	8(%rax), %rdi
	callq	_readl
	movq	_LPC18XX_DAC_CR_VALUE_SHIFT@GOTPCREL(%rip), %rcx
	movb	(%rcx), %cl
	sarl	%cl, %eax
	movl	%eax, (%r15)
	movq	_LPC18XX_DAC_CR_VALUE_MASK@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	movl	%eax, (%r15)
	movq	_IIO_VAL_INT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_5
LBB0_3:
	movl	(%rax), %edi
	callq	_regulator_get_voltage
	cltq
	imulq	$274877907, %rax, %rax          ## imm = 0x10624DD3
	movq	%rax, %rcx
	shrq	$63, %rcx
	sarq	$38, %rax
	addl	%ecx, %eax
	movl	%eax, (%r15)
	movl	$10, (%r14)
	movq	_IIO_VAL_FRACTIONAL_LOG2@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_5
LBB0_4:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_5:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LPC18XX_DAC_CR,8,3             ## @LPC18XX_DAC_CR
	.comm	_LPC18XX_DAC_CR_VALUE_SHIFT,4,2 ## @LPC18XX_DAC_CR_VALUE_SHIFT
	.comm	_LPC18XX_DAC_CR_VALUE_MASK,4,2  ## @LPC18XX_DAC_CR_VALUE_MASK
	.comm	_IIO_VAL_INT,4,2                ## @IIO_VAL_INT
	.comm	_IIO_VAL_FRACTIONAL_LOG2,4,2    ## @IIO_VAL_FRACTIONAL_LOG2
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_lpc18xx_dac_read_raw
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lpc18xx_dac_read_raw
_lpc18xx_dac_read_raw:                  ; @lpc18xx_dac_read_raw
	.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
	mov	x21, x4
	mov	x20, x3
	mov	x19, x2
	bl	_iio_priv
	cmp	x21, #128
	b.eq	LBB0_3
; %bb.1:
	cmp	x21, #129
	b.ne	LBB0_4
; %bb.2:
	ldr	x8, [x0, #8]
Lloh0:
	adrp	x9, _LPC18XX_DAC_CR@GOTPAGE
Lloh1:
	ldr	x9, [x9, _LPC18XX_DAC_CR@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	add	x0, x9, x8
	bl	_readl
Lloh3:
	adrp	x8, _LPC18XX_DAC_CR_VALUE_SHIFT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _LPC18XX_DAC_CR_VALUE_SHIFT@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	asr	w8, w0, w8
	str	w8, [x19]
Lloh6:
	adrp	x9, _LPC18XX_DAC_CR_VALUE_MASK@GOTPAGE
Lloh7:
	ldr	x9, [x9, _LPC18XX_DAC_CR_VALUE_MASK@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	and	w8, w9, w8
	str	w8, [x19]
Lloh9:
	adrp	x8, _IIO_VAL_INT@GOTPAGE
Lloh10:
	ldr	x8, [x8, _IIO_VAL_INT@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
	b	LBB0_5
LBB0_3:
	ldr	w0, [x0]
	bl	_regulator_get_voltage
	mov	w8, #19923
	movk	w8, #4194, lsl #16
	smull	x8, w0, w8
	lsr	x9, x8, #63
	asr	x8, x8, #38
	add	w8, w8, w9
	str	w8, [x19]
	mov	w8, #10
	str	w8, [x20]
Lloh12:
	adrp	x8, _IIO_VAL_FRACTIONAL_LOG2@GOTPAGE
Lloh13:
	ldr	x8, [x8, _IIO_VAL_FRACTIONAL_LOG2@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	b	LBB0_5
LBB0_4:
Lloh15:
	adrp	x8, _EINVAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_5:
	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
	ret
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_LPC18XX_DAC_CR,8,3             ; @LPC18XX_DAC_CR
	.comm	_LPC18XX_DAC_CR_VALUE_SHIFT,4,2 ; @LPC18XX_DAC_CR_VALUE_SHIFT
	.comm	_LPC18XX_DAC_CR_VALUE_MASK,4,2  ; @LPC18XX_DAC_CR_VALUE_MASK
	.comm	_IIO_VAL_INT,4,2                ; @IIO_VAL_INT
	.comm	_IIO_VAL_FRACTIONAL_LOG2,4,2    ; @IIO_VAL_FRACTIONAL_LOG2
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_lpc18xx_dac_read_raw
.subsections_via_symbols
