	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_a5xx_preempt_hw_init           ## -- Begin function a5xx_preempt_hw_init
	.p2align	4, 0x90
_a5xx_preempt_hw_init:                  ## @a5xx_preempt_hw_init
	.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
	movq	%rdi, %r15
	callq	_to_adreno_gpu
	movq	%rax, %rdi
	callq	_to_a5xx_gpu
	movq	%rax, %r14
	movq	8(%r15), %rcx
	movq	(%rcx), %rax
	movq	%rax, 8(%r14)
	movl	(%r15), %esi
	cmpq	$1, %rsi
	jne	LBB0_1
## %bb.10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	testl	%esi, %esi
	jle	LBB0_9
## %bb.2:
	movq	(%r14), %rdx
	leaq	-1(%rsi), %rdi
	movl	%esi, %r8d
	andl	$3, %r8d
	cmpq	$3, %rdi
	jae	LBB0_4
## %bb.3:
	xorl	%edi, %edi
	jmp	LBB0_6
LBB0_4:
	andl	$-4, %esi
	xorl	%edi, %edi
	xorps	%xmm0, %xmm0
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rdx,%rdi,8), %rbx
	movups	%xmm0, 8(%rbx)
	movq	(%rcx,%rdi,8), %rax
	movl	(%rax), %eax
	movl	%eax, (%rbx)
	movq	8(%rdx,%rdi,8), %rax
	movups	%xmm0, 8(%rax)
	movq	8(%rcx,%rdi,8), %rbx
	movl	(%rbx), %ebx
	movl	%ebx, (%rax)
	movq	16(%rdx,%rdi,8), %rax
	movups	%xmm0, 8(%rax)
	movq	16(%rcx,%rdi,8), %rbx
	movl	(%rbx), %ebx
	movl	%ebx, (%rax)
	movq	24(%rdx,%rdi,8), %rax
	movups	%xmm0, 8(%rax)
	movq	24(%rcx,%rdi,8), %rbx
	movl	(%rbx), %ebx
	movl	%ebx, (%rax)
	addq	$4, %rdi
	cmpq	%rdi, %rsi
	jne	LBB0_5
LBB0_6:
	testq	%r8, %r8
	je	LBB0_9
## %bb.7:
	leaq	(%rcx,%rdi,8), %rcx
	leaq	(%rdx,%rdi,8), %rdx
	xorl	%esi, %esi
	xorps	%xmm0, %xmm0
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rdx,%rsi,8), %rax
	movups	%xmm0, 8(%rax)
	movq	(%rcx,%rsi,8), %rdi
	movl	(%rdi), %edi
	movl	%edi, (%rax)
	incq	%rsi
	cmpq	%rsi, %r8
	jne	LBB0_8
LBB0_9:
	movq	_REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_LO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	xorl	%ecx, %ecx
	callq	_gpu_write64
	movq	_PREEMPT_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_set_preempt_state              ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_LO,4,2 ## @REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_LO
	.comm	_REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_HI,4,2 ## @REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_HI
	.comm	_PREEMPT_NONE,4,2               ## @PREEMPT_NONE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_a5xx_preempt_hw_init           ; -- Begin function a5xx_preempt_hw_init
	.p2align	2
_a5xx_preempt_hw_init:                  ; @a5xx_preempt_hw_init
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	bl	_to_adreno_gpu
	bl	_to_a5xx_gpu
	ldr	x8, [x19, #8]
	ldr	x9, [x8]
	str	x9, [x0, #8]
	ldr	w9, [x19]
	cmp	w9, #1
	b.ne	LBB0_2
; %bb.1:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_2:
	mov	x20, x0
	cmp	w9, #1
	b.lt	LBB0_5
; %bb.3:
	ldr	x10, [x20]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x10], #8
	stp	xzr, xzr, [x11, #8]
	ldr	x12, [x8], #8
	ldr	w12, [x12]
	str	w12, [x11]
	subs	x9, x9, #1
	b.ne	LBB0_4
LBB0_5:
Lloh0:
	adrp	x8, _REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_LO@GOTPAGE
Lloh1:
	ldr	x8, [x8, _REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_LO@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_HI@GOTPAGE
Lloh4:
	ldr	x8, [x8, _REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_HI@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w3, #0
	bl	_gpu_write64
Lloh6:
	adrp	x8, _PREEMPT_NONE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _PREEMPT_NONE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_set_preempt_state
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_LO,4,2 ; @REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_LO
	.comm	_REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_HI,4,2 ; @REG_A5XX_CP_CONTEXT_SWITCH_SMMU_INFO_HI
	.comm	_PREEMPT_NONE,4,2               ; @PREEMPT_NONE
.subsections_via_symbols
