	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function max2175_load_from_rom
_max2175_load_from_rom:                 ## @max2175_load_from_rom
	.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	%rdi, %r15
	xorl	%esi, %esi
	callq	_max2175_read_rom
	movl	%eax, %ecx
	andl	$15, %ecx
	movl	%ecx, (%r15)
	sarl	$4, %eax
	movq	%r15, %rdi
	movl	$81, %esi
	movl	$3, %edx
	xorl	%ecx, %ecx
	movl	%eax, %r8d
	callq	_max2175_write_bits
	movq	%r15, %rdi
	movl	$1, %esi
	callq	_max2175_read_rom
	movl	%eax, %ecx
	andl	$15, %ecx
	movl	%ecx, 4(%r15)
	sarl	$4, %eax
	movl	%eax, 8(%r15)
	movl	$2, %r12d
	movq	%r15, %rdi
	movl	$2, %esi
	callq	_max2175_read_rom
	movl	%eax, %ebx
	movl	%eax, %r8d
	andl	$31, %r8d
	movq	%r15, %rdi
	movl	$82, %esi
	movl	$4, %edx
	xorl	%ecx, %ecx
	callq	_max2175_write_bits
	sarl	$5, %ebx
	movq	%r15, %rdi
	movl	$82, %esi
	movl	$7, %edx
	movl	$5, %ecx
	movl	%ebx, %r8d
	callq	_max2175_write_bits
	movq	%r15, %rdi
	movl	$3, %esi
	callq	_max2175_read_rom
	movl	%eax, %r14d
	cmpq	$0, 16(%r15)
	je	LBB0_2
## %bb.1:
	andl	$15, %r14d
	movq	%r15, %rdi
	movl	$7, %esi
	callq	_max2175_read_rom
	movl	%eax, %r8d
	shrl	$2, %r8d
	andl	$16, %r8d
	orl	%r14d, %r8d
	testl	%r8d, %r8d
	cmovel	%r12d, %r8d
	jmp	LBB0_3
LBB0_2:
	shrl	$4, %r14d
	andl	$15, %r14d
	movq	%r15, %rdi
	movl	$7, %esi
	callq	_max2175_read_rom
	shrl	$3, %eax
	andl	$16, %eax
	orl	%r14d, %eax
	testl	%eax, %eax
	movl	$30, %r8d
	cmovnel	%eax, %r8d
LBB0_3:
	addl	$31, %r8d
	movq	%r15, %rdi
	movl	$80, %esi
	movl	$5, %edx
	xorl	%ecx, %ecx
	callq	_max2175_write_bits
	movq	%r15, %rdi
	movl	$6, %esi
	callq	_max2175_read_rom
	sarl	$6, %eax
	movq	%r15, %rdi
	movl	$81, %esi
	movl	$7, %edx
	movl	$6, %ecx
	movl	%eax, %r8d
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_max2175_write_bits             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_max2175_load_from_rom
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function max2175_load_from_rom
_max2175_load_from_rom:                 ; @max2175_load_from_rom
	.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	x19, x0
	mov	w1, #0
	bl	_max2175_read_rom
	and	w8, w0, #0xf
	str	w8, [x19]
	asr	w4, w0, #4
	mov	x0, x19
	mov	w1, #81
	mov	w2, #3
	mov	w3, #0
	bl	_max2175_write_bits
	mov	x0, x19
	mov	w1, #1
	bl	_max2175_read_rom
	and	w8, w0, #0xf
	asr	w9, w0, #4
	stp	w8, w9, [x19, #4]
	mov	w21, #2
	mov	x0, x19
	mov	w1, #2
	bl	_max2175_read_rom
	mov	x20, x0
	and	w4, w0, #0x1f
	mov	x0, x19
	mov	w1, #82
	mov	w2, #4
	mov	w3, #0
	bl	_max2175_write_bits
	asr	w4, w20, #5
	mov	x0, x19
	mov	w1, #82
	mov	w2, #7
	mov	w3, #5
	bl	_max2175_write_bits
	mov	x0, x19
	mov	w1, #3
	bl	_max2175_read_rom
	mov	x20, x0
	ldr	x8, [x19, #16]
	cbz	x8, LBB0_2
; %bb.1:
	mov	x0, x19
	mov	w1, #7
	bl	_max2175_read_rom
	lsr	w8, w0, #2
	and	w8, w8, #0x10
	bfxil	w8, w20, #0, #4
	cmp	w8, #0
	csel	w8, w21, w8, eq
	b	LBB0_3
LBB0_2:
	mov	x0, x19
	mov	w1, #7
	bl	_max2175_read_rom
	lsr	w8, w0, #3
	and	w8, w8, #0x10
	bfxil	w8, w20, #4, #4
	mov	w9, #30
	cmp	w8, #0
	csel	w8, w9, w8, eq
LBB0_3:
	add	w4, w8, #31
	mov	x0, x19
	mov	w1, #80
	mov	w2, #5
	mov	w3, #0
	bl	_max2175_write_bits
	mov	x0, x19
	mov	w1, #6
	bl	_max2175_read_rom
	asr	w4, w0, #6
	mov	x0, x19
	mov	w1, #81
	mov	w2, #7
	mov	w3, #6
	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	_max2175_write_bits
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_max2175_load_from_rom
.subsections_via_symbols
