	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lp3944_dim_set_dutycycle
_lp3944_dim_set_dutycycle:              ## @lp3944_dim_set_dutycycle
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	_LP3944_DIM0@GOTPCREL(%rip), %rax
	cmpq	%rsi, (%rax)
	jne	LBB0_2
## %bb.1:
	movq	_LP3944_REG_PWM0@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_2:
	movq	_LP3944_DIM1@GOTPCREL(%rip), %rax
	cmpq	%rsi, (%rax)
	jne	LBB0_9
## %bb.3:
	movq	_LP3944_REG_PWM1@GOTPCREL(%rip), %rax
LBB0_4:
	movq	_LP3944_DUTY_CYCLE_MAX@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	%rdx, %rcx
	jge	LBB0_5
LBB0_9:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbp
	retq
LBB0_5:
	movq	(%rax), %rsi
	movq	%rdx, %rax
	shlq	$8, %rax
	subq	%rdx, %rax
	movq	%rax, %rdx
	orq	%rcx, %rdx
	shrq	$32, %rdx
	je	LBB0_6
## %bb.7:
	cqto
	idivq	%rcx
	movq	%rax, %rdx
	popq	%rbp
	jmp	_lp3944_reg_write               ## TAILCALL
LBB0_6:
                                        ## kill: def $eax killed $eax killed $rax
	xorl	%edx, %edx
	divl	%ecx
	movl	%eax, %edx
	popq	%rbp
	jmp	_lp3944_reg_write               ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_LP3944_DIM0,8,3                ## @LP3944_DIM0
	.comm	_LP3944_REG_PWM0,8,3            ## @LP3944_REG_PWM0
	.comm	_LP3944_DIM1,8,3                ## @LP3944_DIM1
	.comm	_LP3944_REG_PWM1,8,3            ## @LP3944_REG_PWM1
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_LP3944_DUTY_CYCLE_MAX,8,3      ## @LP3944_DUTY_CYCLE_MAX
	.no_dead_strip	_lp3944_dim_set_dutycycle
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lp3944_dim_set_dutycycle
_lp3944_dim_set_dutycycle:              ; @lp3944_dim_set_dutycycle
	.cfi_startproc
; %bb.0:
Lloh0:
	adrp	x8, _LP3944_DIM0@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LP3944_DIM0@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x8, x1
	b.ne	LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _LP3944_REG_PWM0@GOTPAGE
Lloh4:
	ldr	x8, [x8, _LP3944_REG_PWM0@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:
Lloh5:
	adrp	x8, _LP3944_DIM1@GOTPAGE
Lloh6:
	ldr	x8, [x8, _LP3944_DIM1@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	cmp	x8, x1
	b.ne	LBB0_5
; %bb.3:
Lloh8:
	adrp	x8, _LP3944_REG_PWM1@GOTPAGE
Lloh9:
	ldr	x8, [x8, _LP3944_REG_PWM1@GOTPAGEOFF]
LBB0_4:
Lloh10:
	adrp	x9, _LP3944_DUTY_CYCLE_MAX@GOTPAGE
Lloh11:
	ldr	x9, [x9, _LP3944_DUTY_CYCLE_MAX@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	cmp	x9, x2
	b.ge	LBB0_6
LBB0_5:
Lloh13:
	adrp	x8, _EINVAL@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w0, w8
	ret
LBB0_6:
	ldr	x1, [x8]
	lsl	x8, x2, #8
	sub	x8, x8, x2
	sdiv	x2, x8, x9
	b	_lp3944_reg_write
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_LP3944_DIM0,8,3                ; @LP3944_DIM0
	.comm	_LP3944_REG_PWM0,8,3            ; @LP3944_REG_PWM0
	.comm	_LP3944_DIM1,8,3                ; @LP3944_DIM1
	.comm	_LP3944_REG_PWM1,8,3            ; @LP3944_REG_PWM1
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_LP3944_DUTY_CYCLE_MAX,8,3      ; @LP3944_DUTY_CYCLE_MAX
	.no_dead_strip	_lp3944_dim_set_dutycycle
.subsections_via_symbols
