	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_wm8785_params
_set_wm8785_params:                     ## @set_wm8785_params
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	(%rdi), %r12
	movq	_WM8785_MCR_SLAVE@GOTPCREL(%rip), %rax
	movq	_WM8785_FORMAT_LJUST@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
	orl	(%rax), %ebx
	movq	%rsi, %rdi
	callq	_params_rate
	cmpl	$48001, %eax                    ## imm = 0xBB81
	jge	LBB0_2
## %bb.1:
	movq	_WM8785_OSR_SINGLE@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_2:
	movq	%r15, %rdi
	callq	_params_rate
	cmpl	$96001, %eax                    ## imm = 0x17701
	jge	LBB0_3
## %bb.4:
	movq	_WM8785_OSR_DOUBLE@GOTPCREL(%rip), %rax
	jmp	LBB0_5
LBB0_3:
	movq	_WM8785_OSR_QUAD@GOTPCREL(%rip), %rax
LBB0_5:
	orl	(%rax), %ebx
	movq	(%r12), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_7
## %bb.6:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_WM8785_R7@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_wm8785_write
	movq	_WM8785_R0@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_wm8785_write
	movq	_WM8785_R2@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	(%r12), %rax
	movl	8(%rax), %edx
	movq	%r14, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_wm8785_write                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_WM8785_MCR_SLAVE,4,2           ## @WM8785_MCR_SLAVE
	.comm	_WM8785_FORMAT_LJUST,4,2        ## @WM8785_FORMAT_LJUST
	.comm	_WM8785_OSR_SINGLE,4,2          ## @WM8785_OSR_SINGLE
	.comm	_WM8785_OSR_DOUBLE,4,2          ## @WM8785_OSR_DOUBLE
	.comm	_WM8785_OSR_QUAD,4,2            ## @WM8785_OSR_QUAD
	.comm	_WM8785_R7,4,2                  ## @WM8785_R7
	.comm	_WM8785_R0,4,2                  ## @WM8785_R0
	.comm	_WM8785_R2,4,2                  ## @WM8785_R2
	.no_dead_strip	_set_wm8785_params
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_wm8785_params
_set_wm8785_params:                     ; @set_wm8785_params
	.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	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _WM8785_MCR_SLAVE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _WM8785_MCR_SLAVE@GOTPAGEOFF]
	ldr	x21, [x0]
Lloh2:
	ldr	w8, [x8]
Lloh3:
	adrp	x9, _WM8785_FORMAT_LJUST@GOTPAGE
Lloh4:
	ldr	x9, [x9, _WM8785_FORMAT_LJUST@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	orr	w22, w9, w8
	mov	x0, x1
	bl	_params_rate
	mov	w8, #48001
	cmp	w0, w8
	b.ge	LBB0_2
; %bb.1:
Lloh6:
	adrp	x8, _WM8785_OSR_SINGLE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _WM8785_OSR_SINGLE@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:
	mov	x0, x20
	bl	_params_rate
Lloh8:
	adrp	x8, _WM8785_OSR_QUAD@GOTPAGE
Lloh9:
	ldr	x8, [x8, _WM8785_OSR_QUAD@GOTPAGEOFF]
Lloh10:
	adrp	x9, _WM8785_OSR_DOUBLE@GOTPAGE
Lloh11:
	ldr	x9, [x9, _WM8785_OSR_DOUBLE@GOTPAGEOFF]
	mov	w10, #30465
	movk	w10, #1, lsl #16
	cmp	w0, w10
	csel	x8, x9, x8, lt
LBB0_3:
	ldr	w8, [x8]
	orr	w20, w22, w8
	ldr	x8, [x21]
	ldr	w8, [x8]
	cmp	w20, w8
	b.ne	LBB0_5
; %bb.4:
	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
LBB0_5:
Lloh12:
	adrp	x8, _WM8785_R7@GOTPAGE
Lloh13:
	ldr	x8, [x8, _WM8785_R7@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_wm8785_write
Lloh15:
	adrp	x8, _WM8785_R0@GOTPAGE
Lloh16:
	ldr	x8, [x8, _WM8785_R0@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x20
	bl	_wm8785_write
Lloh18:
	adrp	x8, _WM8785_R2@GOTPAGE
Lloh19:
	ldr	x8, [x8, _WM8785_R2@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	ldr	x8, [x21]
	ldr	w2, [x8, #8]
	mov	x0, x19
	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
	b	_wm8785_write
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_WM8785_MCR_SLAVE,4,2           ; @WM8785_MCR_SLAVE
	.comm	_WM8785_FORMAT_LJUST,4,2        ; @WM8785_FORMAT_LJUST
	.comm	_WM8785_OSR_SINGLE,4,2          ; @WM8785_OSR_SINGLE
	.comm	_WM8785_OSR_DOUBLE,4,2          ; @WM8785_OSR_DOUBLE
	.comm	_WM8785_OSR_QUAD,4,2            ; @WM8785_OSR_QUAD
	.comm	_WM8785_R7,4,2                  ; @WM8785_R7
	.comm	_WM8785_R0,4,2                  ; @WM8785_R0
	.comm	_WM8785_R2,4,2                  ; @WM8785_R2
	.no_dead_strip	_set_wm8785_params
.subsections_via_symbols
