	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function spu_disable
_spu_disable:                           ## @spu_disable
	.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
	xorl	%eax, %eax
	callq	_spu_write_wait
	movq	_ARM_RESET_REGISTER@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	callq	_readl
	movl	%eax, %ebx
	orl	$1, %ebx
	xorl	%eax, %eax
	callq	_spu_write_wait
	callq	_local_irq_save
	movq	(%r14), %rsi
	movl	%ebx, %edi
	callq	_writel
	callq	_local_irq_restore
	movq	_SPU_REGISTER_BASE@GOTPCREL(%rip), %r14
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	xorl	%eax, %eax
	callq	_spu_write_wait
	movq	(%r14), %rdi
	addq	%rbx, %rdi
	callq	_readl
                                        ## kill: def $eax killed $eax def $rax
	andl	$-49153, %eax                   ## imm = 0xFFFF3FFF
	leal	32768(%rax), %r15d
	xorl	%eax, %eax
	callq	_spu_write_wait
	callq	_local_irq_save
	movq	(%r14), %rsi
	addq	%rbx, %rsi
	movl	%r15d, %edi
	callq	_writel
	callq	_local_irq_restore
	subq	$-128, %rbx
	cmpq	$8192, %rbx                     ## imm = 0x2000
	jne	LBB0_1
## %bb.2:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ARM_RESET_REGISTER,8,3         ## @ARM_RESET_REGISTER
	.comm	_SPU_REGISTER_BASE,8,3          ## @SPU_REGISTER_BASE
	.no_dead_strip	_spu_disable
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function spu_disable
_spu_disable:                           ; @spu_disable
	.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
	bl	_spu_write_wait
Lloh0:
	adrp	x20, _ARM_RESET_REGISTER@GOTPAGE
Lloh1:
	ldr	x20, [x20, _ARM_RESET_REGISTER@GOTPAGEOFF]
	ldr	x0, [x20]
	bl	_readl
	orr	w19, w0, #0x1
	bl	_spu_write_wait
	bl	_local_irq_save
	ldr	x1, [x20]
	mov	x0, x19
	bl	_writel
	bl	_local_irq_restore
	mov	x20, #0
Lloh2:
	adrp	x21, _SPU_REGISTER_BASE@GOTPAGE
Lloh3:
	ldr	x21, [x21, _SPU_REGISTER_BASE@GOTPAGEOFF]
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	bl	_spu_write_wait
	ldr	x8, [x21]
	add	x0, x20, x8
	bl	_readl
	and	w8, w0, #0xffff3fff
	orr	w19, w8, #0x8000
	bl	_spu_write_wait
	bl	_local_irq_save
	ldr	x8, [x21]
	add	x1, x20, x8
	mov	x0, x19
	bl	_writel
	bl	_local_irq_restore
	add	x20, x20, #128
	cmp	x20, #2, lsl #12                ; =8192
	b.ne	LBB0_1
; %bb.2:
	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 AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_ARM_RESET_REGISTER,8,3         ; @ARM_RESET_REGISTER
	.comm	_SPU_REGISTER_BASE,8,3          ; @SPU_REGISTER_BASE
	.no_dead_strip	_spu_disable
.subsections_via_symbols
