	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function miller_rabin
_miller_rabin:                          ## @miller_rabin
	.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	$152, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, -176(%rbp)                 ## 8-byte Spill
	movq	%r8, -72(%rbp)                  ## 8-byte Spill
	movq	%rcx, %r15
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	%rsi, %r12
	movq	%rdi, -168(%rbp)                ## 8-byte Spill
	movl	(%rsi), %eax
	movl	%eax, %ecx
	sarl	$5, %ecx
	negl	%ecx
	leal	(%rax,%rcx), %r14d
	addl	$7, %r14d
	movl	%r14d, %eax
	sarl	$3, %eax
	movslq	%eax, %r13
	movq	%r15, %rdi
	movq	%r13, %rsi
	movq	%r12, %rdx
	callq	_br_i31_encode
	cmpl	$8, %r14d
	jb	LBB0_7
## %bb.1:
	cmpq	$2, %r13
	movl	$1, %r8d
	cmovaeq	%r13, %r8
	cmpl	$16, %r14d
	jae	LBB0_3
## %bb.2:
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	jmp	LBB0_5
LBB0_3:
	movq	%r8, %rsi
	andq	$-2, %rsi
	xorl	%edi, %edi
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movzbl	(%r15,%rcx), %ebx
	movzbl	1(%r15,%rcx), %edx
	movl	%ebx, %eax
	shrb	%al
	orb	%dil, %al
	movb	%al, (%r15,%rcx)
	movl	%edx, %eax
	shrb	%al
	shlb	$7, %bl
	orb	%al, %bl
	movb	%bl, 1(%r15,%rcx)
	shlb	$7, %dl
	addq	$2, %rcx
	movl	%edx, %edi
	cmpq	%rcx, %rsi
	jne	LBB0_4
LBB0_5:
	testb	$1, %r8b
	je	LBB0_7
## %bb.6:
	movb	(%r15,%rcx), %al
	shrb	%al
	orb	%dl, %al
	movb	%al, (%r15,%rcx)
LBB0_7:
	movq	%r13, -160(%rbp)                ## 8-byte Spill
	leaq	3(%r13), %rbx
	shrq	$2, %rbx
	leaq	(%r15,%rbx,4), %r13
	movl	(%r12), %ecx
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	leal	31(%rcx), %eax
	movl	%eax, -84(%rbp)                 ## 4-byte Spill
	sarl	$5, %eax
	movslq	%eax, %r14
	movl	%ecx, %edi
	andl	$31, %edi
	callq	_EQ0
	notl	%eax
	addl	-64(%rbp), %eax                 ## 4-byte Folded Reload
	movl	%eax, -80(%rbp)                 ## 4-byte Spill
	movl	4(%r12), %edi
	callq	_br_i31_ninv31
	movl	%eax, -76(%rbp)                 ## 4-byte Spill
	leaq	(,%r14,4), %rax
	addq	%r13, %rax
	notq	%rbx
	addq	-72(%rbp), %rbx                 ## 8-byte Folded Reload
	subq	%r14, %rbx
	movl	%ebx, %ecx
	andl	$1, %ecx
	leaq	(%rax,%rcx,4), %rax
	addq	$4, %rax
	movq	%rax, -144(%rbp)                ## 8-byte Spill
	andq	$-2, %rbx
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	cmpq	$3, %r14
	movl	$2, %eax
	movq	%r14, -152(%rbp)                ## 8-byte Spill
	cmovaeq	%r14, %rax
	leaq	-1(%rax), %rcx
	leaq	-9(%rax), %rdx
	movq	%rdx, -136(%rbp)                ## 8-byte Spill
	shrq	$3, %rdx
	incq	%rdx
	movq	%rcx, -96(%rbp)                 ## 8-byte Spill
	andq	$-8, %rcx
	movq	%rcx, -120(%rbp)                ## 8-byte Spill
	addq	$2, %rcx
	movq	%rcx, -112(%rbp)                ## 8-byte Spill
	movq	%rdx, %rcx
	movq	%rdx, -128(%rbp)                ## 8-byte Spill
	andq	$-2, %rdx
	movq	%rdx, -104(%rbp)                ## 8-byte Spill
	incq	%rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movq	%r15, -72(%rbp)                 ## 8-byte Spill
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_8 Depth=1
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
LBB0_22:                                ##   in Loop: Header=BB0_8 Depth=1
	decl	%ebx
	callq	_EQ0
	movl	%eax, %r15d
	movl	%r14d, %edi
	callq	_EQ0
	orl	%r15d, %eax
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	je	LBB0_23
LBB0_8:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_17 Depth 2
                                        ##     Child Loop BB0_21 Depth 2
	testl	%ebx, %ebx
	jle	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=1
	movl	%ebx, -44(%rbp)                 ## 4-byte Spill
	movl	(%r12), %eax
	movl	%eax, (%r13)
	movq	-152(%rbp), %rax                ## 8-byte Reload
	movl	$0, (%r13,%rax,4)
	movq	-168(%rbp), %rdi                ## 8-byte Reload
	movq	%r13, %rsi
	movl	-80(%rbp), %edx                 ## 4-byte Reload
	callq	_mkrand
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	%rax, (%rsp)
	movq	%r13, %rdi
	movq	%r15, %rsi
	movq	-160(%rbp), %rdx                ## 8-byte Reload
	movq	%r12, %rcx
	movl	-76(%rbp), %r8d                 ## 4-byte Reload
	movq	-144(%rbp), %r9                 ## 8-byte Reload
	callq	*-176(%rbp)                     ## 8-byte Folded Reload
	movl	4(%r13), %edi
	movl	4(%r12), %r14d
	decl	%r14d
	xorl	%edi, %r14d
	xorl	$1, %edi
	cmpl	$64, -84(%rbp)                  ## 4-byte Folded Reload
	jb	LBB0_11
## %bb.12:                              ##   in Loop: Header=BB0_8 Depth=1
	movl	$2, %eax
	cmpq	$8, -96(%rbp)                   ## 8-byte Folded Reload
	jae	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=1
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	jmp	LBB0_21
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_8 Depth=1
	movd	%r14d, %xmm1
	movd	%edi, %xmm0
	cmpq	$8, -136(%rbp)                  ## 8-byte Folded Reload
	jae	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_8 Depth=1
	pxor	%xmm3, %xmm3
	xorl	%eax, %eax
	pxor	%xmm2, %xmm2
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	jmp	LBB0_18
LBB0_16:                                ##   in Loop: Header=BB0_8 Depth=1
	pxor	%xmm8, %xmm8
	movq	-104(%rbp), %rcx                ## 8-byte Reload
	xorl	%eax, %eax
	movdqa	%xmm1, %xmm10
	pxor	%xmm2, %xmm2
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_17:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movdqu	8(%r13,%rax,4), %xmm6
	movdqu	24(%r13,%rax,4), %xmm7
	movdqu	40(%r13,%rax,4), %xmm11
	movdqu	56(%r13,%rax,4), %xmm9
	por	%xmm6, %xmm0
	por	%xmm7, %xmm2
	movdqu	8(%r12,%rax,4), %xmm5
	movdqu	24(%r12,%rax,4), %xmm4
	movdqu	40(%r12,%rax,4), %xmm1
	movdqu	56(%r12,%rax,4), %xmm3
	pxor	%xmm6, %xmm5
	por	%xmm10, %xmm5
	pxor	%xmm7, %xmm4
	por	%xmm8, %xmm4
	por	%xmm11, %xmm0
	por	%xmm9, %xmm2
	pxor	%xmm11, %xmm1
	por	%xmm5, %xmm1
	pxor	%xmm9, %xmm3
	por	%xmm4, %xmm3
	addq	$16, %rax
	movdqa	%xmm1, %xmm10
	movdqa	%xmm3, %xmm8
	addq	$-2, %rcx
	jne	LBB0_17
LBB0_18:                                ##   in Loop: Header=BB0_8 Depth=1
	testb	$1, -128(%rbp)                  ## 1-byte Folded Reload
	je	LBB0_20
## %bb.19:                              ##   in Loop: Header=BB0_8 Depth=1
	shlq	$2, %rax
	orq	$8, %rax
	movdqu	(%r13,%rax), %xmm4
	movdqu	16(%r13,%rax), %xmm5
	por	%xmm4, %xmm0
	por	%xmm5, %xmm2
	movdqu	(%r12,%rax), %xmm6
	movdqu	16(%r12,%rax), %xmm7
	pxor	%xmm4, %xmm6
	por	%xmm6, %xmm1
	pxor	%xmm5, %xmm7
	por	%xmm7, %xmm3
LBB0_20:                                ##   in Loop: Header=BB0_8 Depth=1
	por	%xmm3, %xmm1
	por	%xmm2, %xmm0
	pshufd	$238, %xmm0, %xmm2              ## xmm2 = xmm0[2,3,2,3]
	por	%xmm0, %xmm2
	pshufd	$85, %xmm2, %xmm0               ## xmm0 = xmm2[1,1,1,1]
	por	%xmm2, %xmm0
	movd	%xmm0, %edi
	pshufd	$238, %xmm1, %xmm0              ## xmm0 = xmm1[2,3,2,3]
	por	%xmm1, %xmm0
	pshufd	$85, %xmm0, %xmm1               ## xmm1 = xmm0[1,1,1,1]
	por	%xmm0, %xmm1
	movd	%xmm1, %r14d
	movq	-112(%rbp), %rax                ## 8-byte Reload
	movq	-120(%rbp), %rcx                ## 8-byte Reload
	cmpq	%rcx, -96(%rbp)                 ## 8-byte Folded Reload
	je	LBB0_22
	.p2align	4, 0x90
LBB0_21:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r13,%rax,4), %ecx
	orl	%ecx, %edi
	xorl	(%r12,%rax,4), %ecx
	orl	%ecx, %r14d
	incq	%rax
	cmpq	%rax, %rsi
	jne	LBB0_21
	jmp	LBB0_22
LBB0_9:
	movl	$1, %eax
	jmp	LBB0_24
LBB0_23:
	xorl	%eax, %eax
LBB0_24:
	addq	$152, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_miller_rabin
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function miller_rabin
_miller_rabin:                          ; @miller_rabin
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #192
	.cfi_def_cfa_offset 192
	stp	x28, x27, [sp, #96]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #112]            ; 16-byte Folded Spill
	stp	x24, x23, [sp, #128]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #144]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #160]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #176]            ; 16-byte Folded Spill
	add	x29, sp, #176
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	stp	x0, x5, [sp, #64]               ; 16-byte Folded Spill
	mov	x19, x4
	mov	x21, x2
	mov	x22, x1
	ldr	w8, [x1]
	sub	w8, w8, w8, asr #5
	add	w20, w8, #7
	sbfx	x1, x20, #3, #29
	stp	x1, x3, [sp, #80]               ; 16-byte Folded Spill
	mov	x0, x3
	mov	x2, x22
	bl	_br_i31_encode
	cmp	w20, #8
	b.lo	LBB0_3
; %bb.1:
	mov	w9, #0
	ldp	x8, x10, [sp, #80]              ; 16-byte Folded Reload
	cmp	x8, #1
	csinc	x8, x8, xzr, hi
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldrb	w11, [x10]
	orr	w9, w9, w11, lsr #1
	strb	w9, [x10], #1
	lsl	w9, w11, #7
	subs	x8, x8, #1
	b.ne	LBB0_2
LBB0_3:
	ldr	x8, [sp, #80]                   ; 8-byte Folded Reload
	add	x8, x8, #3
	lsr	x20, x8, #2
	ldr	x8, [sp, #88]                   ; 8-byte Folded Reload
	add	x25, x8, x20, lsl #2
	ldr	w23, [x22]
	add	w24, w23, #31
	asr	w28, w24, #5
	sbfx	x26, x24, #5, #27
	and	w0, w23, #0x1f
	bl	_EQ0
	mvn	w8, w0
	add	w8, w23, w8
	str	w8, [sp, #60]                   ; 4-byte Folded Spill
	ldr	w0, [x22, #4]
	bl	_br_i31_ninv31
	mov	x27, x0
	add	x8, x25, w28, sxtw #2
	mvn	x9, x20
	add	x9, x9, x19
	sub	x9, x9, x26
	and	x10, x9, #0x1
	add	x8, x8, x10, lsl #2
	add	x28, x8, #4
	and	x19, x9, #0xfffffffffffffffe
	mov	w8, #2
	cmp	x26, #2
	csel	x8, x26, x8, hi
	sub	x9, x8, #1
	str	x9, [sp, #48]                   ; 8-byte Folded Spill
	and	x9, x9, #0xfffffffffffffff0
	str	x9, [sp, #40]                   ; 8-byte Folded Spill
	orr	x10, x9, #0x2
	add	x9, x22, #40
	stp	x9, x10, [sp, #16]              ; 16-byte Folded Spill
	add	x9, x25, #40
	str	x9, [sp, #8]                    ; 8-byte Folded Spill
	add	x8, x8, #1
	str	x8, [sp, #32]                   ; 8-byte Folded Spill
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	bl	_EQ0
	mov	x20, x0
	mov	x0, x23
	bl	_EQ0
	orr	w8, w0, w20
	cbz	w8, LBB0_14
LBB0_5:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
                                        ;     Child Loop BB0_13 Depth 2
	subs	w21, w21, #1
	b.lt	LBB0_15
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x22]
	str	w8, [x25]
	str	wzr, [x25, x26, lsl #2]
	ldr	x0, [sp, #64]                   ; 8-byte Folded Reload
	mov	x1, x25
	ldr	w2, [sp, #60]                   ; 4-byte Folded Reload
	bl	_mkrand
	mov	x0, x25
	ldp	x2, x1, [sp, #80]               ; 16-byte Folded Reload
	mov	x3, x22
	mov	x4, x27
	mov	x5, x28
	mov	x6, x19
	ldr	x8, [sp, #72]                   ; 8-byte Folded Reload
	blr	x8
	ldr	w8, [x25, #4]
	eor	w0, w8, #0x1
	ldr	w9, [x22, #4]
	sub	w9, w9, #1
	eor	w23, w9, w8
	cmp	w24, #64
	b.lo	LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [sp, #48]                   ; 8-byte Folded Reload
	cmp	x8, #16
	b.hs	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	w9, #2
	b	LBB0_12
LBB0_9:                                 ;   in Loop: Header=BB0_5 Depth=1
	movi.2d	v0, #0000000000000000
	mov.s	v0[0], w23
	movi.2d	v1, #0000000000000000
	movi.2d	v4, #0000000000000000
	mov.s	v4[0], w0
	ldp	x8, x9, [sp, #8]                ; 16-byte Folded Reload
	ldr	x10, [sp, #40]                  ; 8-byte Folded Reload
	movi.2d	v2, #0000000000000000
	movi.2d	v3, #0000000000000000
	movi.2d	v5, #0000000000000000
	movi.2d	v6, #0000000000000000
	movi.2d	v7, #0000000000000000
LBB0_10:                                ;   Parent Loop BB0_5 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldp	q16, q17, [x8, #-32]
	ldp	q18, q19, [x8], #64
	orr.16b	v4, v16, v4
	orr.16b	v5, v17, v5
	orr.16b	v6, v18, v6
	orr.16b	v7, v19, v7
	ldp	q20, q21, [x9, #-32]
	ldp	q22, q23, [x9], #64
	eor.16b	v16, v20, v16
	eor.16b	v17, v21, v17
	eor.16b	v18, v22, v18
	eor.16b	v19, v23, v19
	orr.16b	v0, v16, v0
	orr.16b	v1, v17, v1
	orr.16b	v2, v18, v2
	orr.16b	v3, v19, v3
	subs	x10, x10, #16
	b.ne	LBB0_10
; %bb.11:                               ;   in Loop: Header=BB0_5 Depth=1
	orr.16b	v4, v5, v4
	orr.16b	v4, v6, v4
	orr.16b	v4, v7, v4
	ext.16b	v5, v4, v4, #8
	orr.8b	v4, v4, v5
	fmov	w8, s4
	mov.s	w9, v4[1]
	orr	w0, w8, w9
	orr.16b	v0, v1, v0
	orr.16b	v0, v2, v0
	orr.16b	v0, v3, v0
	ext.16b	v1, v0, v0, #8
	orr.8b	v0, v0, v1
	mov.s	w8, v0[1]
	fmov	w9, s0
	orr	w23, w9, w8
	ldr	x9, [sp, #24]                   ; 8-byte Folded Reload
	ldp	x10, x8, [sp, #40]              ; 16-byte Folded Reload
	cmp	x8, x10
	b.eq	LBB0_4
LBB0_12:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x8, [sp, #32]                   ; 8-byte Folded Reload
	sub	x8, x8, x9
	lsl	x10, x9, #2
	add	x9, x22, x10
	add	x10, x25, x10
LBB0_13:                                ;   Parent Loop BB0_5 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w11, [x10], #4
	orr	w0, w11, w0
	ldr	w12, [x9], #4
	eor	w11, w12, w11
	orr	w23, w11, w23
	subs	x8, x8, #1
	b.ne	LBB0_13
	b	LBB0_4
LBB0_14:
	mov	w0, #0
	b	LBB0_16
LBB0_15:
	mov	w0, #1
LBB0_16:
	ldp	x29, x30, [sp, #176]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #160]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #144]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #128]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #112]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #96]             ; 16-byte Folded Reload
	add	sp, sp, #192
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_miller_rabin
.subsections_via_symbols
