	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mkprime
_mkprime:                               ## @mkprime
	.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	$120, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, -120(%rbp)                 ## 8-byte Spill
	movq	%r8, -104(%rbp)                 ## 8-byte Spill
	movl	%ecx, -72(%rbp)                 ## 4-byte Spill
                                        ## kill: def $edx killed $edx def $rdx
	movq	%rsi, %r12
	movq	%rdi, -112(%rbp)                ## 8-byte Spill
	movl	%edx, (%rsi)
	leal	15(%rdx), %eax
	movl	%eax, -68(%rbp)                 ## 4-byte Spill
	sarl	$4, %eax
	cltq
	movl	%edx, %r15d
	andl	$15, %r15d
	leal	-2(%r15), %ecx
	movl	$3, %esi
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %esi
	movl	%esi, -64(%rbp)                 ## 4-byte Spill
	xorl	%ecx, %ecx
	cmpl	$320, %edx                      ## imm = 0x140
	setl	%cl
	xorl	%edi, %edi
	cmpl	$1386, %edx                     ## imm = 0x56A
	setb	%dil
	orl	$2, %edi
	cmpl	$480, %edx                      ## imm = 0x1E0
	leal	9(%rcx,%rcx,2), %ecx
	movl	$6, %esi
	cmovll	%ecx, %esi
	cmpl	$906, %edx                      ## imm = 0x38A
	movl	$4, %ecx
	cmovbl	%ecx, %edi
	leaq	(%r12,%rax,4), %rcx
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, -152(%rbp)                ## 8-byte Spill
	cmpl	$693, %edx                      ## imm = 0x2B5
	cmovll	%esi, %edi
	movl	%edi, -60(%rbp)                 ## 4-byte Spill
	cmpq	$2, %rax
	movl	$1, %ecx
	cmovaeq	%rax, %rcx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	leaq	(%r12,%rax,4), %rax
	addq	$-4, %rax
	movq	%rax, -128(%rbp)                ## 8-byte Spill
	movq	%r15, -136(%rbp)                ## 8-byte Spill
	movq	%r12, -144(%rbp)                ## 8-byte Spill
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_8 Depth 2
	movq	-112(%rbp), %rdi                ## 8-byte Reload
	movq	%r12, %rsi
	movq	-152(%rbp), %rdx                ## 8-byte Reload
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_mkrand
	testl	%r15d, %r15d
	je	LBB0_2
## %bb.3:                               ##   in Loop: Header=BB0_1 Depth=1
	cmpl	$1, %r15d
	jne	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	orb	$1, (%rax)
	movl	$16384, %eax                    ## imm = 0x4000
	movq	-128(%rbp), %rcx                ## 8-byte Reload
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_2:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	$24576, %eax                    ## imm = 0x6000
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movl	-64(%rbp), %eax                 ## 4-byte Reload
LBB0_6:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	-48(%rbp), %r11                 ## 8-byte Reload
	orl	%eax, (%rcx)
	orb	$3, 4(%r12)
	xorl	%edx, %edx
	movl	$0, %r13d
	movl	$0, %ebx
	movl	$0, %r15d
	cmpl	$16, -68(%rbp)                  ## 4-byte Folded Reload
	jb	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_1 Depth=1
	xorl	%esi, %esi
	xorl	%eax, %eax
	xorl	%r9d, %r9d
	xorl	%ebx, %ebx
	xorl	%r10d, %r10d
	xorl	%edi, %edi
	.p2align	4, 0x90
LBB0_8:                                 ##   Parent Loop BB0_1 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	leaq	1(%rax), %r8
	movl	4(%r12,%rax,4), %r15d
	andb	$1, %al
	movl	%r15d, %edx
	movl	%eax, %ecx
	shll	%cl, %edx
	addl	%edi, %edx
	movzbl	%dl, %edi
	sarl	$8, %edx
	movl	%esi, %ecx
	andb	$3, %cl
	movl	%r15d, %r13d
	shll	%cl, %r13d
	addl	%edi, %edx
	addl	%r10d, %r13d
	movzbl	%r13b, %ecx
	sarl	$8, %r13d
	addl	%ecx, %r13d
	addl	%r15d, %ebx
	movl	%ebx, %edi
	andl	$511, %edi                      ## imm = 0x1FF
	negb	%al
	andb	$5, %al
	movl	%eax, %ecx
	shll	%cl, %r15d
	sarl	$9, %ebx
	addl	%edi, %ebx
	addl	%r9d, %r15d
	movl	%r15d, %eax
	andl	$1023, %eax                     ## imm = 0x3FF
	sarl	$10, %r15d
	addl	%eax, %r15d
	decl	%esi
	movq	%r8, %rax
	movl	%r15d, %r9d
	movl	%r13d, %r10d
	movl	%edx, %edi
	cmpq	%r8, %r11
	jne	LBB0_8
LBB0_9:                                 ##   in Loop: Header=BB0_1 Depth=1
	movl	-72(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, %ecx
	xorl	$11, %ecx
	movl	%ecx, -96(%rbp)                 ## 4-byte Spill
	movl	%eax, %ecx
	xorl	$7, %ecx
	movl	%ecx, -92(%rbp)                 ## 4-byte Spill
	movl	%eax, %ecx
	xorl	$5, %ecx
	movl	%ecx, -88(%rbp)                 ## 4-byte Spill
	xorl	$3, %eax
	movl	%eax, -84(%rbp)                 ## 4-byte Spill
	movl	%edx, %eax
	andl	$15, %eax
	sarl	$4, %edx
	addl	%eax, %edx
	movl	%edx, %eax
	andl	$15, %eax
	shrl	$4, %edx
	addl	%eax, %edx
	imull	$43, %edx, %eax
	shrl	$5, %eax
	andl	$3, %eax
	movl	%eax, -80(%rbp)                 ## 4-byte Spill
	movzbl	%r13b, %eax
	sarl	$8, %r13d
	addl	%eax, %r13d
	movl	%r13d, %eax
	andl	$15, %eax
	sarl	$4, %r13d
	addl	%eax, %r13d
	movl	%r13d, %eax
	andl	$15, %eax
	sarl	$4, %r13d
	addl	%eax, %r13d
	movl	%r13d, %edi
	movl	$9, %esi
	callq	_GT
	negl	%eax
	andl	$10, %eax
	subl	%eax, %r13d
	movl	%r13d, %edi
	movl	$4, %esi
	callq	_GT
	negl	%eax
	andl	$5, %eax
	movl	%r13d, %r12d
	movl	%eax, -76(%rbp)                 ## 4-byte Spill
	subl	%eax, %r12d
	movl	%ebx, %eax
	andl	$63, %eax
	sarl	$6, %ebx
	addl	%eax, %ebx
	movl	%ebx, %eax
	andl	$7, %eax
	shrl	$3, %ebx
	addl	%eax, %ebx
	imull	$147, %ebx, %ebx
	movl	%r15d, %r14d
	andl	$31, %r14d
	sarl	$5, %r15d
	subl	%r15d, %r14d
	addl	$66, %r14d
	movl	%r14d, %edi
	movl	$87, %esi
	callq	_GT
	negl	%eax
	andl	$88, %eax
	subl	%eax, %r14d
	movl	%r14d, %edi
	movl	$43, %esi
	callq	_GT
	negl	%eax
	andl	$44, %eax
	subl	%eax, %r14d
	movl	%r14d, %edi
	movl	$21, %esi
	callq	_GT
	negl	%eax
	andl	$22, %eax
	subl	%eax, %r14d
	movl	%r14d, %edi
	movl	$10, %esi
	callq	_GT
	movl	-80(%rbp), %edi                 ## 4-byte Reload
	movl	%edi, %ecx
	xorl	$1, %ecx
	orl	-84(%rbp), %ecx                 ## 4-byte Folded Reload
	sete	%cl
	movl	%r12d, %edx
	xorl	$5, %edx
	orl	-88(%rbp), %edx                 ## 4-byte Folded Reload
	sete	%dl
	movl	%r12d, %esi
	xorl	$7, %esi
	orl	-92(%rbp), %esi                 ## 4-byte Folded Reload
	sete	%sil
	xorl	$11, %r12d
	orl	-96(%rbp), %r12d                ## 4-byte Folded Reload
	movq	-144(%rbp), %r12                ## 8-byte Reload
	sete	%r8b
	testl	%edi, %edi
	movq	-136(%rbp), %r15                ## 8-byte Reload
	je	LBB0_1
## %bb.10:                              ##   in Loop: Header=BB0_1 Depth=1
	negl	%eax
	andl	$896, %ebx                      ## imm = 0x380
	cmpl	-76(%rbp), %r13d                ## 4-byte Folded Reload
	je	LBB0_1
## %bb.11:                              ##   in Loop: Header=BB0_1 Depth=1
	andl	$11, %eax
	testl	%ebx, %ebx
	je	LBB0_1
## %bb.12:                              ##   in Loop: Header=BB0_1 Depth=1
	cmpl	%eax, %r14d
	je	LBB0_1
## %bb.13:                              ##   in Loop: Header=BB0_1 Depth=1
	testb	%cl, %cl
	jne	LBB0_1
## %bb.14:                              ##   in Loop: Header=BB0_1 Depth=1
	testb	%dl, %dl
	jne	LBB0_1
## %bb.15:                              ##   in Loop: Header=BB0_1 Depth=1
	testb	%sil, %sil
	jne	LBB0_1
## %bb.16:                              ##   in Loop: Header=BB0_1 Depth=1
	testb	%r8b, %r8b
	jne	LBB0_1
## %bb.17:                              ##   in Loop: Header=BB0_1 Depth=1
	movq	%r12, %rdi
	movq	-104(%rbp), %rsi                ## 8-byte Reload
	callq	_trial_divisions
	testl	%eax, %eax
	je	LBB0_1
## %bb.18:                              ##   in Loop: Header=BB0_1 Depth=1
	movq	-112(%rbp), %rdi                ## 8-byte Reload
	movq	%r12, %rsi
	movl	-60(%rbp), %edx                 ## 4-byte Reload
	movq	-104(%rbp), %rcx                ## 8-byte Reload
	movq	-120(%rbp), %r8                 ## 8-byte Reload
	callq	_miller_rabin
	testq	%rax, %rax
	je	LBB0_1
## %bb.19:
	addq	$120, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_mkprime
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mkprime
_mkprime:                               ; @mkprime
	.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
	str	x5, [sp, #16]                   ; 8-byte Folded Spill
	mov	x21, x3
	mov	x20, x1
	str	x0, [sp, #88]                   ; 8-byte Folded Spill
	mov	x28, x1
	str	w2, [x28], #4
	add	w9, w2, #15
	asr	w8, w9, #4
	str	x9, [sp, #64]                   ; 8-byte Folded Spill
	sbfx	x9, x9, #4, #28
	and	w23, w2, #0xf
	add	x8, x1, w8, sxtw #2
	stp	x4, x8, [sp, #40]               ; 16-byte Folded Spill
	sub	x8, x8, #4
	str	x8, [sp, #32]                   ; 8-byte Folded Spill
	sub	w8, w23, #2
	mov	w10, #3
	lsl	w8, w10, w8
	str	w8, [sp, #28]                   ; 4-byte Folded Spill
	cmp	w2, #1386
	mov	w8, #2
	cinc	w8, w8, lo
	mov	w10, #9
	mov	w11, #12
	cmp	w2, #320
	csel	w10, w11, w10, lt
	mov	w11, #6
	cmp	w2, #480
	csel	w10, w10, w11, lt
	mov	w11, #4
	cmp	w2, #906
	csel	w8, w11, w8, lo
	str	w2, [sp, #84]                   ; 4-byte Folded Spill
	cmp	w2, #693
	csel	w8, w10, w8, lt
	str	w8, [sp, #12]                   ; 4-byte Folded Spill
	cmp	x9, #1
	csinc	x19, x9, xzr, hi
	mov	w22, #5
	str	x1, [sp, #72]                   ; 8-byte Folded Spill
	str	w23, [sp, #60]                  ; 4-byte Folded Spill
LBB0_1:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_9 Depth 2
	ldr	x0, [sp, #88]                   ; 8-byte Folded Reload
	mov	x1, x20
	ldr	w2, [sp, #84]                   ; 4-byte Folded Reload
	bl	_mkrand
	cbz	w23, LBB0_4
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	cmp	w23, #1
	b.ne	LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_1 Depth=1
	ldr	x9, [sp, #48]                   ; 8-byte Folded Reload
	ldr	w8, [x9]
	orr	w8, w8, #0x1
	str	w8, [x9]
	mov	w8, #16384
	ldr	x9, [sp, #32]                   ; 8-byte Folded Reload
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_1 Depth=1
	mov	w8, #24576
	ldr	x9, [sp, #48]                   ; 8-byte Folded Reload
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	x9, [sp, #48]                   ; 8-byte Folded Reload
	ldr	w8, [sp, #28]                   ; 4-byte Folded Reload
LBB0_6:                                 ;   in Loop: Header=BB0_1 Depth=1
	ldr	w10, [x9]
	orr	w8, w10, w8
	str	w8, [x9]
	ldr	w8, [x20, #4]
	orr	w8, w8, #0x3
	str	w8, [x20, #4]
	ldr	x8, [sp, #64]                   ; 8-byte Folded Reload
	cmp	w8, #16
	b.hs	LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	w20, #0
	mov	w8, #0
	mov	w24, #0
	mov	w27, #0
	b	LBB0_10
LBB0_8:                                 ;   in Loop: Header=BB0_1 Depth=1
	mov	w9, #0
	mov	x10, #0
	mov	w27, #0
	mov	w24, #0
	mov	w8, #0
	mov	w20, #0
LBB0_9:                                 ;   Parent Loop BB0_1 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w11, [x28, x10, lsl #2]
	and	w12, w10, #0x1
	lsl	w13, w11, w12
	add	x14, x10, #1
	add	w10, w13, w20
	asr	w13, w10, #8
	add	w20, w13, w10, uxtb
	and	w10, w9, #0x3
	lsl	w10, w11, w10
	add	w8, w10, w8
	asr	w10, w8, #8
	add	w8, w10, w8, uxtb
	add	w10, w11, w24
	and	w13, w10, #0x1ff
	add	w24, w13, w10, asr #9
	neg	w10, w12
	and	w10, w10, w22
	lsl	w10, w11, w10
	add	w10, w10, w27
	and	w11, w10, #0x3ff
	add	w27, w11, w10, asr #10
	sub	w9, w9, #1
	mov	x10, x14
	cmp	x19, x14
	b.ne	LBB0_9
LBB0_10:                                ;   in Loop: Header=BB0_1 Depth=1
	asr	w9, w8, #8
	add	w8, w9, w8, uxtb
	and	w9, w8, #0xf
	add	w8, w9, w8, asr #4
	and	w9, w8, #0xf
	add	w26, w9, w8, asr #4
	mov	x0, x26
	mov	w1, #9
	bl	_GT
	neg	w8, w0
	mov	w9, #10
	and	w8, w8, w9
	sub	w26, w26, w8
	mov	x0, x26
	mov	w1, #4
	bl	_GT
	neg	w8, w0
	and	w25, w8, w22
	sub	w23, w26, w25
	and	w8, w27, #0x1f
	sub	w8, w8, w27, asr #5
	add	w27, w8, #66
	mov	x0, x27
	mov	w1, #87
	bl	_GT
	neg	w8, w0
	mov	w9, #88
	and	w8, w8, w9
	sub	w27, w27, w8
	mov	x0, x27
	mov	w1, #43
	bl	_GT
	neg	w8, w0
	mov	w9, #44
	and	w8, w8, w9
	sub	w27, w27, w8
	mov	x0, x27
	mov	w1, #21
	bl	_GT
	neg	w8, w0
	mov	w9, #22
	and	w8, w8, w9
	sub	w27, w27, w8
	mov	x0, x27
	mov	w1, #10
	bl	_GT
	cmp	w21, #3
	and	w8, w20, #0xf
	add	w8, w8, w20, asr #4
	and	w9, w8, #0xf
	add	w8, w9, w8, lsr #4
	mov	w9, #43
	mul	w8, w8, w9
	ubfx	w12, w8, #5, #2
	ccmp	w12, #1, #0, eq
	cset	w8, eq
	cmp	w21, #5
	ccmp	w23, #5, #0, eq
	cset	w9, eq
	cmp	w21, #7
	ccmp	w23, #7, #0, eq
	cset	w10, eq
	cmp	w21, #11
	ccmp	w23, #11, #0, eq
	cset	w11, eq
	ldr	x20, [sp, #72]                  ; 8-byte Folded Reload
	ldr	w23, [sp, #60]                  ; 4-byte Folded Reload
	cbz	w12, LBB0_1
; %bb.11:                               ;   in Loop: Header=BB0_1 Depth=1
	cmp	w26, w25
	b.eq	LBB0_1
; %bb.12:                               ;   in Loop: Header=BB0_1 Depth=1
	neg	w12, w0
	and	w13, w24, #0x3f
	add	w13, w13, w24, asr #6
	and	w14, w13, #0x7
	add	w13, w14, w13, lsr #3
	mov	w14, #147
	mul	w13, w13, w14
	and	w13, w13, #0x380
	cbz	w13, LBB0_1
; %bb.13:                               ;   in Loop: Header=BB0_1 Depth=1
	mov	w13, #11
	and	w12, w12, w13
	cmp	w27, w12
	b.eq	LBB0_1
; %bb.14:                               ;   in Loop: Header=BB0_1 Depth=1
	tbnz	w8, #0, LBB0_1
; %bb.15:                               ;   in Loop: Header=BB0_1 Depth=1
	tbnz	w9, #0, LBB0_1
; %bb.16:                               ;   in Loop: Header=BB0_1 Depth=1
	tbnz	w10, #0, LBB0_1
; %bb.17:                               ;   in Loop: Header=BB0_1 Depth=1
	tbnz	w11, #0, LBB0_1
; %bb.18:                               ;   in Loop: Header=BB0_1 Depth=1
	mov	x0, x20
	ldr	x1, [sp, #40]                   ; 8-byte Folded Reload
	bl	_trial_divisions
	cbz	w0, LBB0_1
; %bb.19:                               ;   in Loop: Header=BB0_1 Depth=1
	ldr	x0, [sp, #88]                   ; 8-byte Folded Reload
	mov	x1, x20
	ldr	w2, [sp, #12]                   ; 4-byte Folded Reload
	ldr	x3, [sp, #40]                   ; 8-byte Folded Reload
	ldr	x4, [sp, #16]                   ; 8-byte Folded Reload
	bl	_miller_rabin
	cbz	x0, LBB0_1
; %bb.20:
	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	_mkprime
.subsections_via_symbols
