	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_FixFaceEdges                   ## -- Begin function FixFaceEdges
	.p2align	4, 0x90
_FixFaceEdges:                          ## @FixFaceEdges
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_MAX_SUPERVERTS@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	shlq	$2, %rbx
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, -56(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %rcx
	cmpq	$0, 32(%r15)
	jne	LBB0_19
## %bb.1:
	movq	%r15, %rsi
	movq	24(%r15), %rax
	cmpq	$0, (%rax)
	jne	LBB0_19
## %bb.2:
	cmpq	$0, 8(%rax)
	jne	LBB0_19
## %bb.3:
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movq	_numsuperverts@GOTPCREL(%rip), %rax
	movl	$0, (%rax)
	movl	(%rsi), %ecx
	testl	%ecx, %ecx
	jle	LBB0_18
## %bb.4:
	movq	%r14, -72(%rbp)                 ## 8-byte Spill
	xorl	%r14d, %r14d
	movq	%rsi, -80(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%rsi), %rsi
	movslq	(%rsi,%r14,4), %rdi
	movq	%rdi, -88(%rbp)                 ## 8-byte Spill
	leaq	1(%r14), %rax
	movq	%rax, -96(%rbp)                 ## 8-byte Spill
                                        ## kill: def $eax killed $eax killed $rax
	cltd
	idivl	%ecx
                                        ## kill: def $edx killed $edx def $rdx
	movslq	(%rsi,%rdx,4), %rbx
	movq	_dvertexes@GOTPCREL(%rip), %r13
	movq	(%r13), %rax
	movl	(%rax,%rdi,4), %edi
	movq	_edge_start@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	callq	_VectorCopy
	movq	(%r13), %rax
	movl	(%rax,%rbx,4), %edi
	callq	_VectorCopy
	movl	(%r12), %edi
	callq	_FindEdgeVerts
	movl	(%r12), %esi
	movq	_edge_dir@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	callq	_VectorSubtract
	movl	(%r12), %edi
	callq	_VectorNormalize
	movq	_numsuperverts@GOTPCREL(%rip), %r13
	movl	(%r13), %r15d
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movl	%r15d, (%rcx,%r14,4)
	xorl	%edi, %edi
	movl	%eax, %esi
	movq	-88(%rbp), %rdx                 ## 8-byte Reload
                                        ## kill: def $edx killed $edx killed $rdx
	movl	%ebx, %ecx
	xorl	%r8d, %r8d
	callq	_TestEdge
	movl	(%r13), %eax
	movl	%eax, %ecx
	subl	%r15d, %ecx
	movq	-80(%rbp), %r12                 ## 8-byte Reload
	movq	-56(%rbp), %r13                 ## 8-byte Reload
	movl	%ecx, (%r13,%r14,4)
	movq	%r12, %rsi
	movslq	(%r12), %rcx
	movq	-96(%rbp), %rdx                 ## 8-byte Reload
	movq	%rdx, %r14
	cmpq	%rcx, %rdx
	jl	LBB0_5
## %bb.6:
	cmpl	$3, %eax
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	jge	LBB0_7
LBB0_18:
	movl	$0, (%rsi)
	movq	_c_facecollapse@GOTPCREL(%rip), %rax
	incl	(%rax)
LBB0_19:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_21
## %bb.20:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movl	%ecx, %ecx
	testl	%ecx, %ecx
	jle	LBB0_8
## %bb.11:
	leal	-1(%rcx), %r8d
	xorl	%ebx, %ebx
	jmp	LBB0_12
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_12 Depth=1
	incq	%rbx
	cmpq	%rbx, %rcx
	je	LBB0_15
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	cmpl	$1, (%rax,%rbx,4)
	jne	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	leal	(%r8,%rbx), %eax
	cltd
	idivl	%ecx
	movslq	%edx, %rax
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	cmpl	$1, (%rdx,%rax,4)
	jne	LBB0_14
	jmp	LBB0_9
LBB0_8:
	xorl	%ebx, %ebx
LBB0_9:
	cmpl	%ecx, %ebx
	jne	LBB0_10
LBB0_15:
	movl	$1, 16(%rsi)
	movq	_c_badstartverts@GOTPCREL(%rip), %rax
	incl	(%rax)
	xorl	%edx, %edx
	jmp	LBB0_16
LBB0_10:
	movl	%ebx, %eax
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movl	(%rcx,%rax,4), %edx
LBB0_16:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_21
## %bb.17:
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_FaceFromSuperverts             ## TAILCALL
LBB0_21:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MAX_SUPERVERTS,4,2             ## @MAX_SUPERVERTS
	.comm	_numsuperverts,4,2              ## @numsuperverts
	.comm	_dvertexes,8,3                  ## @dvertexes
	.comm	_edge_start,4,2                 ## @edge_start
	.comm	_edge_dir,4,2                   ## @edge_dir
	.comm	_c_facecollapse,4,2             ## @c_facecollapse
	.comm	_c_badstartverts,4,2            ## @c_badstartverts
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_FixFaceEdges                   ; -- Begin function FixFaceEdges
	.p2align	2
_FixFaceEdges:                          ; @FixFaceEdges
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	sub	sp, sp, #16
	mov	x19, x1
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _MAX_SUPERVERTS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MAX_SUPERVERTS@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	lsl	x8, x8, #2
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x10, x8, #15
	and	x12, x10, #0x7fffffff0
	sub	x24, x9, x12
	mov	sp, x24
	mov	x9, x8
Lloh8:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh9:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	sub	x23, x8, x12
	mov	sp, x23
	ldr	x8, [x1, #32]
	cbnz	x8, LBB0_8
; %bb.1:
	ldr	x8, [x19, #24]
	ldr	x9, [x8]
	cbnz	x9, LBB0_8
; %bb.2:
	ldr	x8, [x8, #8]
	cbnz	x8, LBB0_8
; %bb.3:
Lloh10:
	adrp	x20, _numsuperverts@GOTPAGE
Lloh11:
	ldr	x20, [x20, _numsuperverts@GOTPAGEOFF]
	str	wzr, [x20]
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_7
; %bb.4:
	stur	x0, [x29, #-96]                 ; 8-byte Folded Spill
	mov	x26, #0
Lloh12:
	adrp	x28, _edge_start@GOTPAGE
Lloh13:
	ldr	x28, [x28, _edge_start@GOTPAGEOFF]
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19, #8]
	lsl	x25, x26, #2
	ldrsw	x21, [x9, x25]
	add	x26, x26, #1
	sdiv	w10, w26, w8
	msub	w8, w10, w8, w26
	ldrsw	x22, [x9, w8, uxtw #2]
Lloh14:
	adrp	x27, _dvertexes@GOTPAGE
Lloh15:
	ldr	x27, [x27, _dvertexes@GOTPAGEOFF]
	ldr	x8, [x27]
	ldr	w0, [x8, x21, lsl #2]
	ldr	w1, [x28]
	bl	_VectorCopy
	ldr	x8, [x27]
	ldr	w0, [x8, x22, lsl #2]
	bl	_VectorCopy
	ldr	w0, [x28]
	bl	_FindEdgeVerts
	ldr	w1, [x28]
Lloh16:
	adrp	x27, _edge_dir@GOTPAGE
Lloh17:
	ldr	x27, [x27, _edge_dir@GOTPAGEOFF]
	ldr	w2, [x27]
	bl	_VectorSubtract
	ldr	w0, [x27]
	bl	_VectorNormalize
	mov	x1, x0
	ldr	w27, [x20]
	str	w27, [x23, x25]
	mov	w0, #0
	mov	x2, x21
	mov	x3, x22
	mov	w4, #0
	bl	_TestEdge
	ldr	w9, [x20]
	sub	w8, w9, w27
	str	w8, [x24, x25]
	ldrsw	x8, [x19]
	cmp	x26, x8
	b.lt	LBB0_5
; %bb.6:
	cmp	w9, #3
	ldur	x0, [x29, #-96]                 ; 8-byte Folded Reload
	b.ge	LBB0_10
LBB0_7:
	str	wzr, [x19]
Lloh18:
	adrp	x8, _c_facecollapse@GOTPAGE
Lloh19:
	ldr	x8, [x8, _c_facecollapse@GOTPAGEOFF]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
LBB0_8:
	ldur	x8, [x29, #-88]
Lloh20:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh21:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_21
; %bb.9:
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_10:
	and	x8, x8, #0xffffffff
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.11:
	mov	x9, #0
	sub	w10, w8, #1
	b	LBB0_13
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	add	x9, x9, #1
	cmp	x8, x9
	b.eq	LBB0_17
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	w11, [x24, x9, lsl #2]
	cmp	w11, #1
	b.ne	LBB0_12
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	add	w11, w10, w9
	sdiv	w12, w11, w8
	msub	w11, w12, w8, w11
	ldr	w11, [x24, w11, sxtw #2]
	cmp	w11, #1
	b.ne	LBB0_12
	b	LBB0_16
LBB0_15:
	mov	w9, #0
LBB0_16:
	cmp	w9, w8
	b.ne	LBB0_18
LBB0_17:
	mov	w2, #0
	mov	w8, #1
	str	w8, [x19, #16]
Lloh23:
	adrp	x8, _c_badstartverts@GOTPAGE
Lloh24:
	ldr	x8, [x8, _c_badstartverts@GOTPAGEOFF]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
	b	LBB0_19
LBB0_18:
	ldr	w2, [x23, w9, uxtw #2]
LBB0_19:
	ldur	x8, [x29, #-88]
Lloh25:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh26:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh27:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_21
; %bb.20:
	mov	x1, x19
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_FaceFromSuperverts
LBB0_21:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_MAX_SUPERVERTS,4,2             ; @MAX_SUPERVERTS
	.comm	_numsuperverts,4,2              ; @numsuperverts
	.comm	_dvertexes,8,3                  ; @dvertexes
	.comm	_edge_start,4,2                 ; @edge_start
	.comm	_edge_dir,4,2                   ; @edge_dir
	.comm	_c_facecollapse,4,2             ; @c_facecollapse
	.comm	_c_badstartverts,4,2            ; @c_badstartverts
.subsections_via_symbols
