	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_FaceBSP                        ## -- Begin function FaceBSP
	.p2align	4, 0x90
_FaceBSP:                               ## @FaceBSP
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	leaq	L_.str(%rip), %rdi
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_qprintf
	xorl	%eax, %eax
	callq	_AllocTree
	movq	%rax, %r12
	testq	%r14, %r14
	je	LBB0_6
## %bb.1:
	xorl	%r15d, %r15d
	movq	%r14, %r13
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	incl	%r15d
	movq	8(%r13), %r13
	testq	%r13, %r13
	je	LBB0_6
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
	movq	(%r13), %rax
	cmpl	$0, (%rax)
	jle	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	8(%rax), %rax
	movl	(%rax,%rbx,4), %edi
	movl	8(%r12), %edx
	movl	12(%r12), %esi
	callq	_AddPointToBounds
	incq	%rbx
	movq	(%r13), %rax
	movslq	(%rax), %rcx
	cmpq	%rcx, %rbx
	jl	LBB0_4
	jmp	LBB0_5
LBB0_6:
	leaq	L_.str.1(%rip), %rdi
	movl	%r15d, %esi
	xorl	%eax, %eax
	callq	_qprintf
	xorl	%eax, %eax
	callq	_AllocNode
	movq	%rax, (%r12)
	movl	12(%r12), %edi
	movl	4(%rax), %esi
	callq	_VectorCopy
	movl	8(%r12), %edi
	movq	(%r12), %rax
	movl	(%rax), %esi
	callq	_VectorCopy
	movq	_c_faceLeafs@GOTPCREL(%rip), %rbx
	movl	$0, (%rbx)
	movq	(%r12), %rdi
	movq	%r14, %rsi
	callq	_BuildFaceTree_r
	movl	(%rbx), %esi
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_qprintf
	movq	%r12, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"--- FaceBSP ---\n"

L_.str.1:                               ## @.str.1
	.asciz	"%5i faces\n"

	.comm	_c_faceLeafs,4,2                ## @c_faceLeafs
L_.str.2:                               ## @.str.2
	.asciz	"%5i leafs\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_FaceBSP                        ; -- Begin function FaceBSP
	.p2align	2
_FaceBSP:                               ; @FaceBSP
	.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	x20, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_qprintf
	bl	_AllocTree
	mov	x19, x0
	mov	w21, #0
	cbz	x20, LBB0_6
; %bb.1:
	mov	x22, x20
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	w21, w21, #1
	ldr	x22, [x22, #8]
	cbz	x22, LBB0_6
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
	ldr	x8, [x22]
	ldr	w9, [x8]
	cmp	w9, #1
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x23, #0
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [x8, #8]
	ldr	w0, [x8, x23, lsl #2]
	ldp	w2, w1, [x19, #8]
	bl	_AddPointToBounds
	add	x23, x23, #1
	ldr	x8, [x22]
	ldrsw	x9, [x8]
	cmp	x23, x9
	b.lt	LBB0_5
	b	LBB0_2
LBB0_6:
	str	x21, [sp]
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_qprintf
	bl	_AllocNode
	str	x0, [x19]
	ldr	w8, [x19, #12]
	ldr	w1, [x0, #4]
	mov	x0, x8
	bl	_VectorCopy
	ldr	w0, [x19, #8]
	ldr	x8, [x19]
	ldr	w1, [x8]
	bl	_VectorCopy
Lloh4:
	adrp	x21, _c_faceLeafs@GOTPAGE
Lloh5:
	ldr	x21, [x21, _c_faceLeafs@GOTPAGEOFF]
	str	wzr, [x21]
	ldr	x0, [x19]
	mov	x1, x20
	bl	_BuildFaceTree_r
	ldr	w8, [x21]
	str	x8, [sp]
Lloh6:
	adrp	x0, l_.str.2@PAGE
Lloh7:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_qprintf
	mov	x0, x19
	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 AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"--- FaceBSP ---\n"

l_.str.1:                               ; @.str.1
	.asciz	"%5i faces\n"

	.comm	_c_faceLeafs,4,2                ; @c_faceLeafs
l_.str.2:                               ; @.str.2
	.asciz	"%5i leafs\n"

.subsections_via_symbols
