	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mp_div_2d
_mp_div_2d:                             ## @mp_div_2d
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r15
	movq	%rdx, %r14
	movq	%rdi, %r13
	testl	%esi, %esi
	jle	LBB0_1
## %bb.3:
	movl	%esi, %r12d
	leaq	-56(%rbp), %rdi
	callq	_mp_init
	movl	%eax, %ebx
	movq	_MP_OKAY@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_23
## %bb.4:
	testq	%r15, %r15
	je	LBB0_7
## %bb.5:
	leaq	-56(%rbp), %rdx
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_mp_mod_2d
	movl	%eax, %ebx
	movq	_MP_OKAY@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_6
LBB0_7:
	movq	%r13, %rdi
	movq	%r14, %rsi
	callq	_mp_copy
	movl	%eax, %ebx
	movq	_MP_OKAY@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_6
## %bb.8:
	movq	_DIGIT_BIT@GOTPCREL(%rip), %rbx
	movl	(%rbx), %r13d
	cmpl	%r12d, %r13d
	jg	LBB0_10
## %bb.9:
	movl	%r12d, %eax
	cltd
	idivl	%r13d
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_mp_rshd
	movl	(%rbx), %r13d
LBB0_10:
	movl	%r12d, %eax
	cltd
	idivl	%r13d
	testl	%edx, %edx
	je	LBB0_20
## %bb.11:
	movl	%edx, %r10d
	movl	$-1, %r11d
	movl	%r10d, %ecx
	shll	%cl, %r11d
	movl	8(%r14), %edx
	testl	%edx, %edx
	jle	LBB0_20
## %bb.12:
	notl	%r11d
	subl	%r10d, %r13d
	movq	(%r14), %r12
	decl	%edx
	leaq	(%r12,%rdx,4), %rdi
	xorl	%eax, %eax
	cmpl	$7, %edx
	jae	LBB0_14
## %bb.13:
	movl	%edx, %r8d
	jmp	LBB0_18
LBB0_1:
	movq	%r13, %rdi
	movq	%r14, %rsi
	callq	_mp_copy
	movl	%eax, %ebx
	testq	%r15, %r15
	je	LBB0_23
## %bb.2:
	movq	%r15, %rdi
	callq	_mp_zero
	jmp	LBB0_23
LBB0_6:
	leaq	-56(%rbp), %rdi
	callq	_mp_clear
	jmp	LBB0_23
LBB0_14:
	leaq	1(%rdx), %rsi
	movq	%rsi, %r9
	andq	$-8, %r9
	movq	%r9, %rcx
	negq	%rcx
	leaq	(,%r9,4), %rax
	subq	%rax, %rdi
	movl	%edx, %r8d
	subl	%r9d, %r8d
	movd	%r11d, %xmm0
	pshufd	$0, %xmm0, %xmm8                ## xmm8 = xmm0[0,0,0,0]
	movd	%r10d, %xmm1
	movd	%r13d, %xmm3
	leaq	(%r12,%rdx,4), %rdx
	addq	$-12, %rdx
	pxor	%xmm6, %xmm6
	xorl	%eax, %eax
	pmovzxdq	%xmm1, %xmm1                    ## xmm1 = xmm1[0],zero,xmm1[1],zero
	pmovzxdq	%xmm3, %xmm3                    ## xmm3 = xmm3[0],zero,xmm3[1],zero
	.p2align	4, 0x90
LBB0_15:                                ## =>This Inner Loop Header: Depth=1
	movdqa	%xmm6, %xmm4
	movdqu	-16(%rdx,%rax,4), %xmm2
	movdqu	(%rdx,%rax,4), %xmm5
	pshufd	$27, %xmm5, %xmm5               ## xmm5 = xmm5[3,2,1,0]
	pshufd	$27, %xmm2, %xmm0               ## xmm0 = xmm2[3,2,1,0]
	movdqa	%xmm5, %xmm7
	pand	%xmm8, %xmm7
	movdqa	%xmm0, %xmm6
	pand	%xmm8, %xmm6
	movdqa	%xmm6, %xmm2
	palignr	$12, %xmm7, %xmm2               ## xmm2 = xmm7[12,13,14,15],xmm2[0,1,2,3,4,5,6,7,8,9,10,11]
	palignr	$12, %xmm4, %xmm7               ## xmm7 = xmm4[12,13,14,15],xmm7[0,1,2,3,4,5,6,7,8,9,10,11]
	psrad	%xmm1, %xmm5
	psrad	%xmm1, %xmm0
	pslld	%xmm3, %xmm7
	pslld	%xmm3, %xmm2
	por	%xmm5, %xmm7
	por	%xmm0, %xmm2
	pshufd	$27, %xmm7, %xmm0               ## xmm0 = xmm7[3,2,1,0]
	movdqu	%xmm0, (%rdx,%rax,4)
	pshufd	$27, %xmm2, %xmm0               ## xmm0 = xmm2[3,2,1,0]
	movdqu	%xmm0, -16(%rdx,%rax,4)
	addq	$-8, %rax
	cmpq	%rax, %rcx
	jne	LBB0_15
## %bb.16:
	cmpq	%r9, %rsi
	je	LBB0_20
## %bb.17:
	pextrd	$3, %xmm6, %eax
LBB0_18:
	notl	%r8d
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movl	(%rdi,%rdx,4), %esi
	movl	%esi, %ebx
	movl	%r10d, %ecx
	sarl	%cl, %esi
	andl	%r11d, %ebx
	movl	%r13d, %ecx
	shll	%cl, %eax
	orl	%esi, %eax
	movl	%eax, (%rdi,%rdx,4)
	decq	%rdx
	movl	%ebx, %eax
	cmpl	%edx, %r8d
	jne	LBB0_19
LBB0_20:
	movq	%r14, %rdi
	callq	_mp_clamp
	testq	%r15, %r15
	je	LBB0_22
## %bb.21:
	leaq	-56(%rbp), %rdi
	movq	%r15, %rsi
	callq	_mp_exch
LBB0_22:
	leaq	-56(%rbp), %rdi
	callq	_mp_clear
	movq	_MP_OKAY@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_23:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MP_OKAY,4,2                    ## @MP_OKAY
	.comm	_DIGIT_BIT,4,2                  ## @DIGIT_BIT
	.no_dead_strip	_mp_div_2d
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mp_div_2d
_mp_div_2d:                             ; @mp_div_2d
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x3
	mov	x20, x2
	mov	x23, x0
	cmp	w1, #0
	b.le	LBB0_11
; %bb.1:
	mov	x21, x1
	mov	x0, sp
	bl	_mp_init
	mov	x22, x0
Lloh0:
	adrp	x24, _MP_OKAY@GOTPAGE
Lloh1:
	ldr	x24, [x24, _MP_OKAY@GOTPAGEOFF]
	ldr	w8, [x24]
	cmp	w0, w8
	b.ne	LBB0_23
; %bb.2:
	cbz	x19, LBB0_4
; %bb.3:
	mov	x2, sp
	mov	x0, x23
	mov	x1, x21
	bl	_mp_mod_2d
	ldr	w8, [x24]
	cmp	w0, w8
	b.ne	LBB0_13
LBB0_4:
	mov	x0, x23
	mov	x1, x20
	bl	_mp_copy
	ldr	w8, [x24]
	cmp	w0, w8
	b.ne	LBB0_13
; %bb.5:
Lloh2:
	adrp	x22, _DIGIT_BIT@GOTPAGE
Lloh3:
	ldr	x22, [x22, _DIGIT_BIT@GOTPAGEOFF]
	ldr	w10, [x22]
	cmp	w10, w21
	b.gt	LBB0_7
; %bb.6:
	sdiv	w1, w21, w10
	mov	x0, x20
	bl	_mp_rshd
	ldr	w10, [x22]
LBB0_7:
	sdiv	w8, w21, w10
	msub	w8, w8, w10, w21
	cbz	w8, LBB0_20
; %bb.8:
	ldr	w9, [x20, #8]
	subs	w15, w9, #1
	b.lt	LBB0_20
; %bb.9:
	mov	w9, #-1
	lsl	w9, w9, w8
	mvn	w9, w9
	sub	w10, w10, w8
	ldr	x16, [x20]
	add	x11, x16, w15, uxtw #2
	cmp	w15, #15
	b.hs	LBB0_14
; %bb.10:
	mov	w13, #0
	mov	x12, x15
	b	LBB0_18
LBB0_11:
	mov	x0, x23
	mov	x1, x20
	bl	_mp_copy
	mov	x22, x0
	cbz	x19, LBB0_23
; %bb.12:
	mov	x0, x19
	bl	_mp_zero
	b	LBB0_23
LBB0_13:
	mov	x22, x0
	mov	x0, sp
	bl	_mp_clear
	b	LBB0_23
LBB0_14:
	add	x13, x15, #1
	and	x14, x13, #0x1fffffff0
	sub	x11, x11, x14, lsl #2
	dup.4s	v0, w9
	dup.4s	v2, w8
	dup.4s	v1, w10
	sub	w12, w15, w14
	add	x15, x16, x15, lsl #2
	sub	x15, x15, #28
	movi.2d	v3, #0000000000000000
	neg.4s	v2, v2
	mov	x16, x14
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	ldp	q5, q4, [x15]
	rev64.4s	v4, v4
	ext.16b	v4, v4, v4, #8
	rev64.4s	v5, v5
	ext.16b	v5, v5, v5, #8
	ldp	q7, q6, [x15, #-32]
	rev64.4s	v6, v6
	ext.16b	v6, v6, v6, #8
	rev64.4s	v7, v7
	ext.16b	v7, v7, v7, #8
	and.16b	v16, v4, v0
	and.16b	v17, v5, v0
	and.16b	v18, v6, v0
	ext.16b	v19, v3, v16, #12
	and.16b	v3, v7, v0
	ext.16b	v16, v16, v17, #12
	ext.16b	v17, v17, v18, #12
	ext.16b	v18, v18, v3, #12
	sshl.4s	v4, v4, v2
	sshl.4s	v5, v5, v2
	sshl.4s	v6, v6, v2
	sshl.4s	v7, v7, v2
	ushl.4s	v19, v19, v1
	ushl.4s	v16, v16, v1
	ushl.4s	v17, v17, v1
	ushl.4s	v18, v18, v1
	orr.16b	v4, v4, v19
	orr.16b	v5, v5, v16
	orr.16b	v6, v6, v17
	orr.16b	v7, v7, v18
	rev64.4s	v4, v4
	ext.16b	v4, v4, v4, #8
	rev64.4s	v5, v5
	ext.16b	v5, v5, v5, #8
	stp	q5, q4, [x15]
	rev64.4s	v4, v6
	ext.16b	v4, v4, v4, #8
	rev64.4s	v5, v7
	ext.16b	v5, v5, v5, #8
	stp	q5, q4, [x15, #-32]
	sub	x15, x15, #64
	sub	x16, x16, #16
	cbnz	x16, LBB0_15
; %bb.16:
	cmp	x13, x14
	b.eq	LBB0_20
; %bb.17:
	mov.s	w13, v3[3]
LBB0_18:
	add	w12, w12, #1
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	ldr	w14, [x11]
	lsl	w13, w13, w10
	and	w15, w14, w9
	asr	w14, w14, w8
	orr	w13, w14, w13
	str	w13, [x11], #-4
	mov	x13, x15
	subs	w12, w12, #1
	b.ne	LBB0_19
LBB0_20:
	mov	x0, x20
	bl	_mp_clamp
	cbz	x19, LBB0_22
; %bb.21:
	mov	x0, sp
	mov	x1, x19
	bl	_mp_exch
LBB0_22:
	mov	x0, sp
	bl	_mp_clear
	ldr	w22, [x24]
LBB0_23:
	mov	x0, x22
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.comm	_MP_OKAY,4,2                    ; @MP_OKAY
	.comm	_DIGIT_BIT,4,2                  ; @DIGIT_BIT
	.no_dead_strip	_mp_div_2d
.subsections_via_symbols
