	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function parisc_agp_remove_memory
_parisc_agp_remove_memory:              ## @parisc_agp_remove_memory
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	testl	%edx, %edx
	jne	LBB0_2
## %bb.1:
	cmpq	$0, (%rdi)
	je	LBB0_3
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_18:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_3:
	movq	_parisc_agp_info@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	8(%rdi), %eax
	imull	%edx, %eax
	testl	%eax, %eax
	jle	LBB0_4
## %bb.5:
	imull	%esi, %edx
	addl	%edx, %eax
	movq	_agp_bridge@GOTPCREL(%rip), %rsi
	movq	(%rsi), %r11
	movq	8(%rcx), %r14
	movslq	%edx, %rdx
	movslq	%eax, %rsi
	leaq	1(%rdx), %rax
	cmpq	%rsi, %rax
	movq	%rsi, %r8
	cmovgq	%rax, %r8
	subq	%rdx, %r8
	cmpq	$8, %r8
	jb	LBB0_16
## %bb.6:
	leaq	(%r14,%rdx,4), %rcx
	cmpq	%rsi, %rax
	cmovleq	%rsi, %rax
	leaq	12(%r11), %rbx
	cmpq	%rbx, %rcx
	jae	LBB0_8
## %bb.7:
	leaq	(%r14,%rax,4), %rax
	leaq	8(%r11), %rcx
	cmpq	%rax, %rcx
	jb	LBB0_16
LBB0_8:
	movq	%r8, %r9
	andq	$-8, %r9
	leaq	-8(%r9), %rax
	movq	%rax, %r10
	shrq	$3, %r10
	incq	%r10
	testq	%rax, %rax
	je	LBB0_9
## %bb.10:
	movq	%r10, %rbx
	andq	$-2, %rbx
	movd	8(%r11), %xmm0                  ## xmm0 = mem[0],zero,zero,zero
	pshufd	$0, %xmm0, %xmm0                ## xmm0 = xmm0[0,0,0,0]
	leaq	(%r14,%rdx,4), %rcx
	addq	$48, %rcx
	xorl	%eax, %eax
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movdqu	%xmm0, -48(%rcx,%rax,4)
	movdqu	%xmm0, -32(%rcx,%rax,4)
	movdqu	%xmm0, -16(%rcx,%rax,4)
	movdqu	%xmm0, (%rcx,%rax,4)
	addq	$16, %rax
	addq	$-2, %rbx
	jne	LBB0_11
	jmp	LBB0_12
LBB0_4:
	movq	_agp_bridge@GOTPCREL(%rip), %rax
	movq	(%rax), %r11
	jmp	LBB0_17
LBB0_9:
	xorl	%eax, %eax
LBB0_12:
	testb	$1, %r10b
	je	LBB0_14
## %bb.13:
	addq	%rdx, %rax
	movd	8(%r11), %xmm0                  ## xmm0 = mem[0],zero,zero,zero
	pshufd	$0, %xmm0, %xmm0                ## xmm0 = xmm0[0,0,0,0]
	movdqu	%xmm0, (%r14,%rax,4)
	movdqu	%xmm0, 16(%r14,%rax,4)
LBB0_14:
	cmpq	%r9, %r8
	je	LBB0_17
## %bb.15:
	addq	%r9, %rdx
	.p2align	4, 0x90
LBB0_16:                                ## =>This Inner Loop Header: Depth=1
	movl	8(%r11), %eax
	movl	%eax, (%r14,%rdx,4)
	incq	%rdx
	cmpq	%rsi, %rdx
	jl	LBB0_16
LBB0_17:
	movq	(%r11), %rax
	callq	*(%rax)
	xorl	%eax, %eax
	jmp	LBB0_18
	.cfi_endproc
                                        ## -- End function
	.comm	_parisc_agp_info,16,3           ## @parisc_agp_info
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_agp_bridge,8,3                 ## @agp_bridge
	.no_dead_strip	_parisc_agp_remove_memory
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function parisc_agp_remove_memory
_parisc_agp_remove_memory:              ; @parisc_agp_remove_memory
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	cbnz	w2, LBB0_2
; %bb.1:
	ldr	x8, [x0]
	cbz	x8, LBB0_3
LBB0_2:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_3:
Lloh3:
	adrp	x9, _parisc_agp_info@GOTPAGE
Lloh4:
	ldr	x9, [x9, _parisc_agp_info@GOTPAGEOFF]
	ldr	w8, [x9]
	ldr	w10, [x0, #8]
	mul	w10, w10, w8
	cmp	w10, #0
	b.le	LBB0_10
; %bb.4:
	mul	w11, w8, w1
	add	w12, w10, w11
Lloh5:
	adrp	x8, _agp_bridge@GOTPAGE
Lloh6:
	ldr	x8, [x8, _agp_bridge@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	ldr	x9, [x9, #8]
	sxtw	x10, w11
	sxtw	x11, w12
	add	x13, x10, #1
	cmp	x13, x11
	csinc	x12, x11, x10, le
	sub	x12, x12, x10
	cmp	x12, #16
	b.lo	LBB0_9
; %bb.5:
	add	x14, x9, x10, lsl #2
	cmp	x13, x11
	csinc	x13, x11, x10, le
	add	x13, x9, x13, lsl #2
	add	x15, x8, #8
	add	x16, x8, #12
	cmp	x14, x16
	ccmp	x15, x13, #2, lo
	b.lo	LBB0_9
; %bb.6:
	and	x13, x12, #0xfffffffffffffff0
	add	x10, x13, x10
	ld1r.4s	{ v0 }, [x15]
	add	x14, x14, #32
	mov	x15, x13
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	stp	q0, q0, [x14, #-32]
	stp	q0, q0, [x14], #64
	subs	x15, x15, #16
	b.ne	LBB0_7
; %bb.8:
	cmp	x12, x13
	b.eq	LBB0_11
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w12, [x8, #8]
	str	w12, [x9, x10, lsl #2]
	add	x10, x10, #1
	cmp	x10, x11
	b.lt	LBB0_9
	b	LBB0_11
LBB0_10:
Lloh8:
	adrp	x8, _agp_bridge@GOTPAGE
Lloh9:
	ldr	x8, [x8, _agp_bridge@GOTPAGEOFF]
Lloh10:
	ldr	x8, [x8]
LBB0_11:
	ldr	x8, [x8]
	ldr	x8, [x8]
	blr	x8
	mov	w0, #0
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_parisc_agp_info,16,3           ; @parisc_agp_info
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_agp_bridge,8,3                 ; @agp_bridge
	.no_dead_strip	_parisc_agp_remove_memory
.subsections_via_symbols
