	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function PicoWriteS68k8_pr
_PicoWriteS68k8_pr:                     ## @PicoWriteS68k8_pr
	.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
	movl	%esi, %r14d
	movl	%edi, %r15d
	movl	%edi, %eax
	andl	$65024, %eax                    ## imm = 0xFE00
	cmpl	$32768, %eax                    ## imm = 0x8000
	jne	LBB0_3
## %bb.1:
	movl	%r15d, %ebx
	andl	$511, %ebx                      ## imm = 0x1FF
	movq	_EL_CDREGS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_SekPcS68k@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	movl	%r14d, %ecx
	callq	_elprintf
	leal	-89(%rbx), %eax
	cmpl	$14, %eax
	ja	LBB0_2
## %bb.10:
	andl	$510, %r15d                     ## imm = 0x1FE
	movl	%r14d, %esi
	shll	$8, %esi
	orl	%r14d, %esi
	movl	%r15d, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_s68k_reg_write16               ## TAILCALL
LBB0_3:
	testl	$32768, %r15d                   ## imm = 0x8000
	jne	LBB0_9
## %bb.4:
	movl	%r15d, %edi
	andl	$32767, %edi                    ## imm = 0x7FFF
	cmpl	$8192, %edi                     ## imm = 0x2000
	jb	LBB0_7
## %bb.5:
	movq	_Pico_mcd@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rcx
	movq	8(%rax), %rax
	movq	(%rcx,%rax,8), %rax
	shrl	%r15d
	andl	$4095, %r15d                    ## imm = 0xFFF
	movl	%r14d, (%rax,%r15,4)
	jmp	LBB0_6
LBB0_2:
	movl	%ebx, %edi
	movl	%r14d, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_s68k_reg_write8                ## TAILCALL
LBB0_9:
	movl	%r15d, %edi
	movl	%r14d, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_s68k_unmapped_write8           ## TAILCALL
LBB0_7:
	cmpl	$17, %edi
	ja	LBB0_6
## %bb.8:
	shrl	%edi
	movl	%r14d, %esi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pcd_pcm_write                  ## TAILCALL
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EL_CDREGS,4,2                  ## @EL_CDREGS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"s68k_regs w8: [%02x] %02x @%06x"

	.comm	_SekPcS68k,4,2                  ## @SekPcS68k
	.comm	_Pico_mcd,8,3                   ## @Pico_mcd
	.no_dead_strip	_PicoWriteS68k8_pr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function PicoWriteS68k8_pr
_PicoWriteS68k8_pr:                     ; @PicoWriteS68k8_pr
	.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, x1
	mov	x20, x0
	and	w8, w0, #0xfe00
	cmp	w8, #8, lsl #12                 ; =32768
	b.ne	LBB0_3
; %bb.1:
	and	w21, w20, #0x1ff
Lloh0:
	adrp	x8, _EL_CDREGS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EL_CDREGS@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x8, _SekPcS68k@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SekPcS68k@GOTPAGEOFF]
Lloh5:
	ldr	w4, [x8]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x21
	mov	x3, x19
	bl	_elprintf
	sub	w8, w21, #89
	cmp	w8, #14
	b.hi	LBB0_6
; %bb.2:
	and	w0, w20, #0x1fe
	orr	w1, w19, w19, lsl #8
	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	_s68k_reg_write16
LBB0_3:
	tbnz	w20, #15, LBB0_7
; %bb.4:
	and	w8, w20, #0x7fff
	cmp	w8, #2, lsl #12                 ; =8192
	b.lo	LBB0_8
; %bb.5:
Lloh8:
	adrp	x8, _Pico_mcd@GOTPAGE
Lloh9:
	ldr	x8, [x8, _Pico_mcd@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
	ldp	x9, x8, [x8]
	ldr	x8, [x9, x8, lsl #3]
	ubfx	w9, w20, #1, #12
	str	w19, [x8, w9, uxtw #2]
	b	LBB0_10
LBB0_6:
	mov	x0, x21
	mov	x1, 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	_s68k_reg_write8
LBB0_7:
	mov	x0, x20
	mov	x1, 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	_s68k_unmapped_write8
LBB0_8:
	cmp	w8, #17
	b.hi	LBB0_10
; %bb.9:
	lsr	w0, w8, #1
	mov	x1, 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	_pcd_pcm_write
LBB0_10:
	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 AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_EL_CDREGS,4,2                  ; @EL_CDREGS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"s68k_regs w8: [%02x] %02x @%06x"

	.comm	_SekPcS68k,4,2                  ; @SekPcS68k
	.comm	_Pico_mcd,8,3                   ; @Pico_mcd
	.no_dead_strip	_PicoWriteS68k8_pr
.subsections_via_symbols
