	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function HL_SplitBrush
LCPI0_0:
	.quad	0x3fb999999999999a              ## double 0.10000000000000001
LCPI0_1:
	.quad	0xbfb999999999999a              ## double -0.10000000000000001
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_HL_SplitBrush
	.p2align	4, 0x90
_HL_SplitBrush:                         ## @HL_SplitBrush
	.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
	movl	%edx, -104(%rbp)                ## 4-byte Spill
	movq	%rdi, %r12
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	%r8, -88(%rbp)                  ## 8-byte Spill
	movq	$0, (%r8)
	movq	%rcx, -80(%rbp)                 ## 8-byte Spill
	movq	$0, (%rcx)
	movq	_mapplanes@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	movl	%esi, -100(%rbp)                ## 4-byte Spill
	movslq	%esi, %r13
	movl	(%rdi), %eax
	testl	%eax, %eax
	movq	%rdi, -96(%rbp)                 ## 8-byte Spill
	jle	LBB0_1
## %bb.2:
	xorl	%r14d, %r14d
	xorps	%xmm2, %xmm2
	xorps	%xmm4, %xmm4
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_3 Depth=1
	incq	%r14
	movslq	%eax, %rcx
	cmpq	%rcx, %r14
	jge	LBB0_9
LBB0_3:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_6 Depth 2
	movq	24(%r12), %rcx
	movq	%r14, %rdx
	shlq	$5, %rdx
	movq	8(%rcx,%rdx), %rbx
	movq	%rbx, -72(%rbp)
	testq	%rbx, %rbx
	je	LBB0_8
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	cmpl	$0, (%rbx)
	jle	LBB0_8
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_6:                                 ##   Parent Loop BB0_3 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movaps	%xmm4, -144(%rbp)               ## 16-byte Spill
	movaps	%xmm2, -128(%rbp)               ## 16-byte Spill
	movq	8(%rbx), %rax
	movl	(%rax,%r12,4), %edi
	movl	4(%r15,%r13,8), %esi
	callq	_DotProduct
	xorps	%xmm3, %xmm3
	subss	(%r15,%r13,8), %xmm0
	movaps	%xmm0, %xmm1
	movaps	-144(%rbp), %xmm4               ## 16-byte Reload
	maxss	%xmm4, %xmm1
	xorps	%xmm2, %xmm2
	cmpltss	%xmm0, %xmm2
	andps	%xmm2, %xmm1
	andnps	%xmm4, %xmm2
	orps	%xmm1, %xmm2
	movaps	%xmm2, %xmm4
	movaps	%xmm0, %xmm1
	movaps	-128(%rbp), %xmm2               ## 16-byte Reload
	minss	%xmm2, %xmm1
	cmpltss	%xmm3, %xmm0
	andps	%xmm0, %xmm1
	andnps	%xmm2, %xmm0
	orps	%xmm1, %xmm0
	movaps	%xmm0, %xmm2
	incq	%r12
	movslq	(%rbx), %rax
	cmpq	%rax, %r12
	jl	LBB0_6
## %bb.7:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	-96(%rbp), %r12                 ## 8-byte Reload
	movl	(%r12), %eax
	jmp	LBB0_8
LBB0_1:
	xorps	%xmm4, %xmm4
	xorps	%xmm2, %xmm2
LBB0_9:
	xorps	%xmm0, %xmm0
	cvtss2sd	%xmm4, %xmm0
	movsd	LCPI0_0(%rip), %xmm1            ## xmm1 = mem[0],zero
	ucomisd	%xmm0, %xmm1
	jbe	LBB0_13
## %bb.10:
	movq	%r12, %rdi
	callq	_CopyBrush
	movq	-88(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_73
## %bb.11:
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_12
LBB0_13:
	xorps	%xmm0, %xmm0
	cvtss2sd	%xmm2, %xmm0
	ucomisd	LCPI0_1(%rip), %xmm0
	jbe	LBB0_16
## %bb.14:
	movq	%r12, %rdi
	callq	_CopyBrush
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_73
## %bb.15:
	leaq	L_.str.1(%rip), %rdi
LBB0_12:
	addq	$120, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_Log_Print                      ## TAILCALL
LBB0_16:
	movl	4(%r15,%r13,8), %edi
	movss	(%r15,%r13,8), %xmm0            ## xmm0 = mem[0],zero,zero,zero
	callq	_BaseWindingForPlane
	movq	%rax, -72(%rbp)
	testq	%rax, %rax
	setne	%cl
	cmpl	$0, (%r12)
	jle	LBB0_21
## %bb.17:
	testq	%rax, %rax
	je	LBB0_21
## %bb.18:
	movl	$1, %r12d
	xorl	%ebx, %ebx
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movq	_mapplanes@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	24(%r14), %rcx
	movslq	(%rcx,%rbx), %rcx
	xorq	$1, %rcx
	movl	4(%rax,%rcx,8), %esi
	movss	(%rax,%rcx,8), %xmm0            ## xmm0 = mem[0],zero,zero,zero
	leaq	-72(%rbp), %rdi
	xorl	%edx, %edx
	callq	_ChopWindingInPlace
	movq	-72(%rbp), %rax
	movslq	(%r14), %rdx
	testq	%rax, %rax
	setne	%cl
	cmpq	%rdx, %r12
	jge	LBB0_21
## %bb.20:                              ##   in Loop: Header=BB0_19 Depth=1
	addq	$32, %rbx
	incq	%r12
	testq	%rax, %rax
	jne	LBB0_19
LBB0_21:
	testb	%cl, %cl
	je	LBB0_23
## %bb.22:
	movq	%rax, %rdi
	callq	_WindingIsTiny
	testq	%rax, %rax
	je	LBB0_28
LBB0_23:
	leaq	(%r15,%r13,8), %r14
	leaq	L_.str.2(%rip), %rdi
	callq	_Log_Print
	movq	-96(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_BrushMostlyOnSide
	movl	%eax, %r14d
	movq	_PSIDE_FRONT@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	jne	LBB0_25
## %bb.24:
	movq	%rbx, %rdi
	callq	_CopyBrush
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
LBB0_25:
	movq	_PSIDE_BACK@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	jne	LBB0_71
## %bb.26:
	movq	%rbx, %rdi
LBB0_27:
	callq	_CopyBrush
	movq	-88(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
LBB0_71:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_73
## %bb.72:
	addq	$120, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_28:
	movq	-72(%rbp), %rdi
	callq	_WindingIsHuge
	testq	%rax, %rax
	movq	-96(%rbp), %r12                 ## 8-byte Reload
	je	LBB0_30
## %bb.29:
	leaq	L_.str.3(%rip), %rdi
	callq	_Log_Print
LBB0_30:
	movq	-72(%rbp), %rax
	movq	%rax, -152(%rbp)                ## 8-byte Spill
	movl	(%r12), %edi
	incl	%edi
	callq	_AllocBrush
	movl	32(%r12), %ecx
	movq	%rax, -144(%rbp)                ## 8-byte Spill
	movl	%ecx, 32(%rax)
	movl	(%r12), %edi
	incl	%edi
	callq	_AllocBrush
	movl	32(%r12), %ecx
	movq	%rax, -128(%rbp)                ## 8-byte Spill
	movl	%ecx, 32(%rax)
	movl	(%r12), %edx
	testl	%edx, %edx
	jle	LBB0_39
## %bb.31:
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	jmp	LBB0_32
	.p2align	4, 0x90
LBB0_37:                                ##   in Loop: Header=BB0_32 Depth=1
	movl	(%r12), %edx
LBB0_38:                                ##   in Loop: Header=BB0_32 Depth=1
	incq	%rbx
	movslq	%edx, %rcx
	addq	$32, %r14
	cmpq	%rcx, %rbx
	jge	LBB0_39
LBB0_32:                                ## =>This Inner Loop Header: Depth=1
	movq	24(%r12), %rax
	movq	8(%rax,%r14), %rdi
	movq	%rdi, -72(%rbp)
	testq	%rdi, %rdi
	je	LBB0_38
## %bb.33:                              ##   in Loop: Header=BB0_32 Depth=1
	movl	4(%r15,%r13,8), %esi
	movss	(%r15,%r13,8), %xmm0            ## xmm0 = mem[0],zero,zero,zero
	xorl	%edx, %edx
	leaq	-64(%rbp), %rcx
	movq	%rax, %r12
	leaq	-56(%rbp), %r8
	callq	_ClipWindingEpsilon
	movq	%r12, %rsi
	addq	%r14, %rsi
	movq	-64(%rbp), %rax
	testq	%rax, %rax
	je	LBB0_35
## %bb.34:                              ##   in Loop: Header=BB0_32 Depth=1
	movq	-144(%rbp), %rdi                ## 8-byte Reload
	movq	24(%rdi), %rcx
	movslq	(%rdi), %rdx
	leal	1(%rdx), %r8d
	shlq	$5, %rdx
	movl	%r8d, (%rdi)
	movups	(%rsi), %xmm0
	movupd	16(%rsi), %xmm1
	movups	%xmm0, (%rcx,%rdx)
	movupd	%xmm1, 16(%rcx,%rdx)
	movq	%rax, 8(%rcx,%rdx)
	movq	_SFL_TESTED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 16(%rcx,%rdx)
LBB0_35:                                ##   in Loop: Header=BB0_32 Depth=1
	movq	-56(%rbp), %rax
	testq	%rax, %rax
	movq	-96(%rbp), %r12                 ## 8-byte Reload
	je	LBB0_37
## %bb.36:                              ##   in Loop: Header=BB0_32 Depth=1
	movq	-128(%rbp), %rdi                ## 8-byte Reload
	movq	24(%rdi), %rcx
	movslq	(%rdi), %rdx
	leal	1(%rdx), %r8d
	shlq	$5, %rdx
	movl	%r8d, (%rdi)
	movups	(%rsi), %xmm0
	movupd	16(%rsi), %xmm1
	movups	%xmm0, (%rcx,%rdx)
	movupd	%xmm1, 16(%rcx,%rdx)
	movq	%rax, 8(%rcx,%rdx)
	movq	_SFL_TESTED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 16(%rcx,%rdx)
	jmp	LBB0_37
LBB0_39:
	movq	-144(%rbp), %r15                ## 8-byte Reload
	movq	%r15, %rdi
	callq	_BoundBrush
	movq	8(%r15), %rax
	cmpl	$-4096, (%rax)                  ## imm = 0xF000
	jl	LBB0_46
## %bb.40:
	movq	16(%r15), %rcx
	cmpl	$4097, (%rcx)                   ## imm = 0x1001
	jge	LBB0_46
## %bb.41:
	cmpl	$-4096, 4(%rax)                 ## imm = 0xF000
	jl	LBB0_46
## %bb.42:
	cmpl	$4096, 4(%rcx)                  ## imm = 0x1000
	jg	LBB0_46
## %bb.43:
	cmpl	$-4096, 8(%rax)                 ## imm = 0xF000
	jl	LBB0_46
## %bb.44:
	cmpl	$4096, 8(%rcx)                  ## imm = 0x1000
	jle	LBB0_45
LBB0_46:
	leaq	L_.str.4(%rip), %rdi
	callq	_Log_Print
LBB0_47:
	movq	%r15, %rdi
	callq	_FreeBrush
	leaq	L_.str.5(%rip), %rdi
	callq	_Log_Print
	xorl	%r15d, %r15d
LBB0_48:
	movq	-128(%rbp), %rbx                ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_BoundBrush
	movq	8(%rbx), %rax
	cmpl	$-4096, (%rax)                  ## imm = 0xF000
	jl	LBB0_57
## %bb.49:
	movq	16(%rbx), %rcx
	cmpl	$4096, (%rcx)                   ## imm = 0x1000
	jg	LBB0_57
## %bb.50:
	cmpl	$-4096, 4(%rax)                 ## imm = 0xF000
	jl	LBB0_57
## %bb.51:
	cmpl	$4096, 4(%rcx)                  ## imm = 0x1000
	jg	LBB0_57
## %bb.52:
	cmpl	$-4096, 8(%rax)                 ## imm = 0xF000
	jl	LBB0_57
## %bb.53:
	cmpl	$4096, 8(%rcx)                  ## imm = 0x1000
	jle	LBB0_54
LBB0_57:
	leaq	L_.str.4(%rip), %rdi
	callq	_Log_Print
LBB0_58:
	movq	%rbx, %rdi
	callq	_FreeBrush
	leaq	L_.str.5(%rip), %rdi
	callq	_Log_Print
	testq	%r15, %r15
	setne	%cl
	xorl	%eax, %eax
	xorl	%ebx, %ebx
	testb	%cl, %cl
	jne	LBB0_62
LBB0_60:
	testb	%al, %al
	jne	LBB0_62
## %bb.61:
	leaq	L_.str.6(%rip), %rdi
	callq	_Log_Print
	jmp	LBB0_71
LBB0_45:
	cmpl	$3, (%r15)
	jl	LBB0_47
	jmp	LBB0_48
LBB0_54:
	cmpl	$3, (%rbx)
	jl	LBB0_58
## %bb.55:
	testq	%r15, %r15
	setne	%cl
	je	LBB0_56
## %bb.66:
	movq	24(%r15), %r14
	movq	%r15, %r12
	movslq	(%r15), %rbx
	leal	1(%rbx), %eax
	movl	%eax, (%r15)
	movl	-100(%rbp), %eax                ## 4-byte Reload
	xorl	$1, %eax
	shlq	$5, %rbx
	movl	%eax, (%r14,%rbx)
	movq	$0, 24(%r14,%rbx)
	movl	-104(%rbp), %r13d               ## 4-byte Reload
	movl	%r13d, 4(%r14,%rbx)
	movq	_SFL_VISIBLE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	16(%r14,%rbx), %eax
	movl	%eax, 16(%r14,%rbx)
	movq	_SFL_TESTED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	notl	%ecx
	andl	%eax, %ecx
	movl	%ecx, 16(%r14,%rbx)
	movq	-152(%rbp), %r15                ## 8-byte Reload
	movq	%r15, %rdi
	callq	_CopyWinding
	movq	%rax, 8(%r14,%rbx)
	movq	-128(%rbp), %rbx                ## 8-byte Reload
	movq	24(%rbx), %rax
	movslq	(%rbx), %rcx
	leal	1(%rcx), %edx
	movl	%edx, (%rbx)
	shlq	$5, %rcx
	movl	-100(%rbp), %edx                ## 4-byte Reload
	movl	%edx, (%rax,%rcx)
	movq	$0, 24(%rax,%rcx)
	movl	%r13d, 4(%rax,%rcx)
	movq	_SFL_VISIBLE@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	notl	%edx
	andl	16(%rax,%rcx), %edx
	movl	%edx, 16(%rax,%rcx)
	movq	_SFL_TESTED@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
	notl	%esi
	andl	%edx, %esi
	movl	%esi, 16(%rax,%rcx)
	movq	%r15, 8(%rax,%rcx)
	movq	%r12, %rdi
	callq	_BrushVolume
	testl	%eax, %eax
	jg	LBB0_68
## %bb.67:
	movq	%r12, %rdi
	callq	_FreeBrush
	leaq	L_.str.8(%rip), %rdi
	callq	_Log_Print
	xorl	%r12d, %r12d
LBB0_68:
	movq	%rbx, %rdi
	callq	_BrushVolume
	testl	%eax, %eax
	jg	LBB0_70
## %bb.69:
	movq	%rbx, %rdi
	callq	_FreeBrush
	leaq	L_.str.8(%rip), %rdi
	callq	_Log_Print
	xorl	%ebx, %ebx
LBB0_70:
	movq	-88(%rbp), %rax                 ## 8-byte Reload
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	%r12, (%rcx)
	movq	%rbx, (%rax)
	jmp	LBB0_71
LBB0_56:
	movb	$1, %al
	testb	%cl, %cl
	je	LBB0_60
LBB0_62:
	leaq	L_.str.7(%rip), %rdi
	callq	_Log_Print
	testq	%r15, %r15
	je	LBB0_64
## %bb.63:
	movq	%r15, %rdi
	callq	_FreeBrush
	movq	%r12, %rdi
	callq	_CopyBrush
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
LBB0_64:
	testq	%rbx, %rbx
	je	LBB0_71
## %bb.65:
	movq	%rbx, %rdi
	callq	_FreeBrush
	movq	%r12, %rdi
	jmp	LBB0_27
LBB0_73:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_mapplanes,8,3                  ## @mapplanes
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"HL_SplitBrush: only on back\n"

L_.str.1:                               ## @.str.1
	.asciz	"HL_SplitBrush: only on front\n"

L_.str.2:                               ## @.str.2
	.asciz	"HL_SplitBrush: no split winding\n"

	.comm	_PSIDE_FRONT,4,2                ## @PSIDE_FRONT
	.comm	_PSIDE_BACK,4,2                 ## @PSIDE_BACK
L_.str.3:                               ## @.str.3
	.asciz	"HL_SplitBrush: WARNING huge split winding\n"

	.comm	_SFL_TESTED,4,2                 ## @SFL_TESTED
L_.str.4:                               ## @.str.4
	.asciz	"HL_SplitBrush: bogus brush after clip\n"

L_.str.5:                               ## @.str.5
	.asciz	"HL_SplitBrush: numsides < 3\n"

L_.str.6:                               ## @.str.6
	.asciz	"HL_SplitBrush: split removed brush\n"

L_.str.7:                               ## @.str.7
	.asciz	"HL_SplitBrush: split not on both sides\n"

	.comm	_SFL_VISIBLE,4,2                ## @SFL_VISIBLE
L_.str.8:                               ## @.str.8
	.asciz	"HL_SplitBrush: tiny volume after clip\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_HL_SplitBrush                  ; -- Begin function HL_SplitBrush
	.p2align	2
_HL_SplitBrush:                         ; @HL_SplitBrush
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #192
	.cfi_def_cfa_offset 192
	stp	d11, d10, [sp, #64]             ; 16-byte Folded Spill
	stp	d9, d8, [sp, #80]               ; 16-byte Folded Spill
	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
	.cfi_offset b8, -104
	.cfi_offset b9, -112
	.cfi_offset b10, -120
	.cfi_offset b11, -128
	str	w2, [sp, #12]                   ; 4-byte Folded Spill
	mov	x23, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #56]
	str	x4, [sp, #24]                   ; 8-byte Folded Spill
	str	xzr, [x4]
Lloh3:
	adrp	x24, _mapplanes@GOTPAGE
Lloh4:
	ldr	x24, [x24, _mapplanes@GOTPAGEOFF]
	str	x3, [sp, #16]                   ; 8-byte Folded Spill
	str	xzr, [x3]
	ldr	x25, [x24]
	sxtw	x27, w23
	add	x26, x25, w1, sxtw #3
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.1:
	mov	x20, #0
	add	x9, x25, x27, lsl #3
	add	x22, x9, #4
	movi	d10, #0000000000000000
	movi	d8, #0000000000000000
	movi	d9, #0000000000000000
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x20, x20, #1
	cmp	x20, w8, sxtw
	b.ge	LBB0_9
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_6 Depth 2
	ldr	x9, [x21, #24]
	add	x9, x9, x20, lsl #5
	ldr	x19, [x9, #8]
	str	x19, [sp, #32]
	cbz	x19, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w9, [x19]
	cmp	w9, #1
	b.lt	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x28, #0
LBB0_6:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x8, [x19, #8]
	ldr	w0, [x8, x28, lsl #2]
	ldr	w1, [x22]
	bl	_DotProduct
	ldr	s1, [x26]
	fsub	s0, s0, s1
	fcmp	s0, s9
	fccmp	s0, s10, #4, gt
	fcsel	s9, s0, s9, gt
	fcmp	s0, s8
	fccmp	s0, s10, #0, mi
	fcsel	s8, s0, s8, mi
	add	x28, x28, #1
	ldrsw	x8, [x19]
	cmp	x28, x8
	b.lt	LBB0_6
; %bb.7:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x21]
	b	LBB0_2
LBB0_8:
	movi	d9, #0000000000000000
	movi	d8, #0000000000000000
LBB0_9:
	fcvt	d0, s9
	mov	x8, #-7378697629483820647
	movk	x8, #39322
	movk	x8, #16313, lsl #48
	fmov	d1, x8
	fcmp	d0, d1
	b.pl	LBB0_12
; %bb.10:
	mov	x0, x21
	bl	_CopyBrush
	ldr	x8, [sp, #24]                   ; 8-byte Folded Reload
	str	x0, [x8]
	ldr	x8, [sp, #56]
Lloh5:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh6:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_70
; %bb.11:
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_15
LBB0_12:
	fcvt	d0, s8
	mov	x8, #-7378697629483820647
	movk	x8, #39322
	movk	x8, #49081, lsl #48
	fmov	d1, x8
	fcmp	d0, d1
	b.le	LBB0_16
; %bb.13:
	mov	x0, x21
	bl	_CopyBrush
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	str	x0, [x8]
	ldr	x8, [sp, #56]
Lloh10:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh11:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_70
; %bb.14:
Lloh13:
	adrp	x0, l_.str.1@PAGE
Lloh14:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_15:
	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
	ldp	d9, d8, [sp, #80]               ; 16-byte Folded Reload
	ldp	d11, d10, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #192
	b	_Log_Print
LBB0_16:
	add	x27, x25, x27, lsl #3
	ldr	w0, [x27, #4]!
	ldr	s0, [x26]
	bl	_BaseWindingForPlane
	str	x0, [sp, #32]
	ldr	w9, [x21]
	cmp	x0, #0
	cset	w8, ne
	cmp	w9, #1
	b.lt	LBB0_20
; %bb.17:
	cbz	x0, LBB0_20
; %bb.18:
	mov	x19, #0
	mov	w20, #1
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x24]
	ldr	x9, [x21, #24]
	ldrsw	x9, [x9, x19]
	eor	x9, x9, #0x1
	add	x8, x8, x9, lsl #3
	ldr	w1, [x8, #4]
	ldr	s0, [x8]
	add	x0, sp, #32
	mov	w2, #0
	bl	_ChopWindingInPlace
	ldr	x0, [sp, #32]
	ldrsw	x9, [x21]
	cmp	x0, #0
	cset	w8, ne
	add	x19, x19, #32
	cmp	x20, x9
	add	x20, x20, #1
	ccmp	x0, #0, #4, lt
	b.ne	LBB0_19
LBB0_20:
	cbz	w8, LBB0_22
; %bb.21:
	bl	_WindingIsTiny
	cbz	x0, LBB0_28
LBB0_22:
Lloh15:
	adrp	x0, l_.str.2@PAGE
Lloh16:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_Log_Print
	mov	x0, x21
	mov	x1, x26
	bl	_BrushMostlyOnSide
	mov	x22, x0
Lloh17:
	adrp	x8, _PSIDE_FRONT@GOTPAGE
Lloh18:
	ldr	x8, [x8, _PSIDE_FRONT@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_24
; %bb.23:
	mov	x0, x21
	bl	_CopyBrush
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	str	x0, [x8]
LBB0_24:
Lloh20:
	adrp	x8, _PSIDE_BACK@GOTPAGE
Lloh21:
	ldr	x8, [x8, _PSIDE_BACK@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
	cmp	w22, w8
	b.ne	LBB0_26
LBB0_25:
	mov	x0, x21
	bl	_CopyBrush
	ldr	x8, [sp, #24]                   ; 8-byte Folded Reload
	str	x0, [x8]
LBB0_26:
	ldr	x8, [sp, #56]
Lloh23:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh24:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh25:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_70
; %bb.27:
	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
	ldp	d9, d8, [sp, #80]               ; 16-byte Folded Reload
	ldp	d11, d10, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #192
	ret
LBB0_28:
	ldr	x0, [sp, #32]
	bl	_WindingIsHuge
	cbz	x0, LBB0_30
; %bb.29:
Lloh26:
	adrp	x0, l_.str.3@PAGE
Lloh27:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_Log_Print
LBB0_30:
	ldr	x8, [sp, #32]
	str	x8, [sp]                        ; 8-byte Folded Spill
	ldr	w8, [x21]
	add	w0, w8, #1
	bl	_AllocBrush
	mov	x25, x0
	ldr	w8, [x21, #32]
	str	w8, [x0, #32]
	ldr	w8, [x21]
	add	w0, w8, #1
	bl	_AllocBrush
	mov	x24, x0
	ldr	w8, [x21, #32]
	str	w8, [x0, #32]
	ldr	w8, [x21]
	cmp	w8, #1
	b.lt	LBB0_39
; %bb.31:
	mov	x22, #0
	mov	x20, #0
	add	x9, sp, #40
	add	x28, x9, #8
	b	LBB0_34
LBB0_32:                                ;   in Loop: Header=BB0_34 Depth=1
	ldr	w8, [x21]
LBB0_33:                                ;   in Loop: Header=BB0_34 Depth=1
	add	x20, x20, #1
	add	x22, x22, #32
	cmp	x20, w8, sxtw
	b.ge	LBB0_39
LBB0_34:                                ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x21, #24]
	add	x19, x9, x22
	ldr	x0, [x19, #8]
	str	x0, [sp, #32]
	cbz	x0, LBB0_33
; %bb.35:                               ;   in Loop: Header=BB0_34 Depth=1
	ldr	w1, [x27]
	ldr	s0, [x26]
	add	x3, sp, #40
	mov	w2, #0
	mov	x4, x28
	bl	_ClipWindingEpsilon
	ldr	x8, [sp, #40]
	cbz	x8, LBB0_37
; %bb.36:                               ;   in Loop: Header=BB0_34 Depth=1
	ldr	x9, [x25, #24]
	ldrsw	x10, [x25]
	add	x9, x9, x10, lsl #5
	add	w10, w10, #1
	str	w10, [x25]
	ldp	q1, q0, [x19]
	stp	q1, q0, [x9]
	str	x8, [x9, #8]
Lloh28:
	adrp	x8, _SFL_TESTED@GOTPAGE
Lloh29:
	ldr	x8, [x8, _SFL_TESTED@GOTPAGEOFF]
Lloh30:
	ldr	w8, [x8]
	ldr	w10, [x9, #16]
	bic	w8, w10, w8
	str	w8, [x9, #16]
LBB0_37:                                ;   in Loop: Header=BB0_34 Depth=1
	ldr	x8, [sp, #48]
	cbz	x8, LBB0_32
; %bb.38:                               ;   in Loop: Header=BB0_34 Depth=1
	ldr	x9, [x24, #24]
	ldrsw	x10, [x24]
	add	x9, x9, x10, lsl #5
	add	w10, w10, #1
	str	w10, [x24]
	ldp	q1, q0, [x19]
	stp	q1, q0, [x9]
	str	x8, [x9, #8]
Lloh31:
	adrp	x8, _SFL_TESTED@GOTPAGE
Lloh32:
	ldr	x8, [x8, _SFL_TESTED@GOTPAGEOFF]
Lloh33:
	ldr	w8, [x8]
	ldr	w10, [x9, #16]
	bic	w8, w10, w8
	str	w8, [x9, #16]
	b	LBB0_32
LBB0_39:
	mov	x0, x25
	bl	_BoundBrush
	ldr	x8, [x25, #8]
	ldr	w9, [x8]
	cmn	w9, #1, lsl #12                 ; =4096
	b.lt	LBB0_45
; %bb.40:
	ldr	x9, [x25, #16]
	ldr	w10, [x9]
	cmp	w10, #1, lsl #12                ; =4096
	b.gt	LBB0_45
; %bb.41:
	ldr	w10, [x8, #4]
	cmn	w10, #1, lsl #12                ; =4096
	b.lt	LBB0_45
; %bb.42:
	ldr	w10, [x9, #4]
	cmp	w10, #1, lsl #12                ; =4096
	b.gt	LBB0_45
; %bb.43:
	ldr	w8, [x8, #8]
	cmn	w8, #1, lsl #12                 ; =4096
	b.lt	LBB0_45
; %bb.44:
	ldr	w8, [x9, #8]
	cmp	w8, #1, lsl #12                 ; =4096
	b.le	LBB0_57
LBB0_45:
Lloh34:
	adrp	x0, l_.str.4@PAGE
Lloh35:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_Log_Print
LBB0_46:
	mov	x0, x25
	bl	_FreeBrush
Lloh36:
	adrp	x0, l_.str.5@PAGE
Lloh37:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_Log_Print
	mov	x25, #0
LBB0_47:
	mov	x0, x24
	bl	_BoundBrush
	ldr	x8, [x24, #8]
	ldr	w9, [x8]
	cmn	w9, #1, lsl #12                 ; =4096
	b.lt	LBB0_53
; %bb.48:
	ldr	x9, [x24, #16]
	ldr	w10, [x9]
	cmp	w10, #1, lsl #12                ; =4096
	b.gt	LBB0_53
; %bb.49:
	ldr	w10, [x8, #4]
	cmn	w10, #1, lsl #12                ; =4096
	b.lt	LBB0_53
; %bb.50:
	ldr	w10, [x9, #4]
	cmp	w10, #1, lsl #12                ; =4096
	b.gt	LBB0_53
; %bb.51:
	ldr	w8, [x8, #8]
	cmn	w8, #1, lsl #12                 ; =4096
	b.lt	LBB0_53
; %bb.52:
	ldr	w8, [x9, #8]
	cmp	w8, #1, lsl #12                 ; =4096
	b.le	LBB0_58
LBB0_53:
Lloh38:
	adrp	x0, l_.str.4@PAGE
Lloh39:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_Log_Print
LBB0_54:
	mov	x0, x24
	bl	_FreeBrush
Lloh40:
	adrp	x0, l_.str.5@PAGE
Lloh41:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_Log_Print
	mov	w8, #0
	mov	x24, #0
	cmp	x25, #0
	cset	w9, ne
	tbnz	w9, #0, LBB0_66
LBB0_55:
	tbnz	w8, #0, LBB0_66
; %bb.56:
Lloh42:
	adrp	x0, l_.str.6@PAGE
Lloh43:
	add	x0, x0, l_.str.6@PAGEOFF
	bl	_Log_Print
	b	LBB0_26
LBB0_57:
	ldr	w8, [x25]
	cmp	w8, #3
	b.lt	LBB0_46
	b	LBB0_47
LBB0_58:
	ldr	w8, [x24]
	cmp	w8, #3
	b.lt	LBB0_54
; %bb.59:
	cmp	x25, #0
	cset	w9, ne
	cbz	x25, LBB0_65
; %bb.60:
	ldr	x8, [x25, #24]
	ldrsw	x9, [x25]
	add	w10, w9, #1
	str	w10, [x25]
	eor	w10, w23, #0x1
	add	x19, x8, x9, lsl #5
	str	xzr, [x19, #24]
	ldr	w22, [sp, #12]                  ; 4-byte Folded Reload
	stp	w10, w22, [x19]
Lloh44:
	adrp	x20, _SFL_VISIBLE@GOTPAGE
Lloh45:
	ldr	x20, [x20, _SFL_VISIBLE@GOTPAGEOFF]
	ldr	w8, [x20]
	ldr	w9, [x19, #16]
	bic	w8, w9, w8
	str	w8, [x19, #16]
Lloh46:
	adrp	x21, _SFL_TESTED@GOTPAGE
Lloh47:
	ldr	x21, [x21, _SFL_TESTED@GOTPAGEOFF]
	ldr	w9, [x21]
	bic	w8, w8, w9
	str	w8, [x19, #16]
	ldr	x26, [sp]                       ; 8-byte Folded Reload
	mov	x0, x26
	bl	_CopyWinding
	str	x0, [x19, #8]
	ldr	x8, [x24, #24]
	ldrsw	x9, [x24]
	add	w10, w9, #1
	str	w10, [x24]
	add	x8, x8, x9, lsl #5
	str	xzr, [x8, #24]
	stp	w23, w22, [x8]
	ldr	w9, [x20]
	ldr	w10, [x8, #16]
	bic	w9, w10, w9
	str	w9, [x8, #16]
	ldr	w10, [x21]
	bic	w9, w9, w10
	str	w9, [x8, #16]
	str	x26, [x8, #8]
	mov	x0, x25
	bl	_BrushVolume
	cmp	w0, #0
	b.gt	LBB0_62
; %bb.61:
	mov	x0, x25
	bl	_FreeBrush
Lloh48:
	adrp	x0, l_.str.8@PAGE
Lloh49:
	add	x0, x0, l_.str.8@PAGEOFF
	bl	_Log_Print
	mov	x25, #0
LBB0_62:
	mov	x0, x24
	bl	_BrushVolume
	cmp	w0, #0
	b.gt	LBB0_64
; %bb.63:
	mov	x0, x24
	bl	_FreeBrush
Lloh50:
	adrp	x0, l_.str.8@PAGE
Lloh51:
	add	x0, x0, l_.str.8@PAGEOFF
	bl	_Log_Print
	mov	x24, #0
LBB0_64:
	ldp	x9, x8, [sp, #16]               ; 16-byte Folded Reload
	str	x25, [x9]
	str	x24, [x8]
	b	LBB0_26
LBB0_65:
	mov	w8, #1
	tbz	w9, #0, LBB0_55
LBB0_66:
Lloh52:
	adrp	x0, l_.str.7@PAGE
Lloh53:
	add	x0, x0, l_.str.7@PAGEOFF
	bl	_Log_Print
	cbz	x25, LBB0_68
; %bb.67:
	mov	x0, x25
	bl	_FreeBrush
	mov	x0, x21
	bl	_CopyBrush
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	str	x0, [x8]
LBB0_68:
	cbz	x24, LBB0_26
; %bb.69:
	mov	x0, x24
	bl	_FreeBrush
	b	LBB0_25
LBB0_70:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpAdd	Lloh34, Lloh35
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpAdd	Lloh38, Lloh39
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpLdrGot	Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh44, Lloh45
	.loh AdrpAdd	Lloh48, Lloh49
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpAdd	Lloh52, Lloh53
	.cfi_endproc
                                        ; -- End function
	.comm	_mapplanes,8,3                  ; @mapplanes
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"HL_SplitBrush: only on back\n"

l_.str.1:                               ; @.str.1
	.asciz	"HL_SplitBrush: only on front\n"

l_.str.2:                               ; @.str.2
	.asciz	"HL_SplitBrush: no split winding\n"

	.comm	_PSIDE_FRONT,4,2                ; @PSIDE_FRONT
	.comm	_PSIDE_BACK,4,2                 ; @PSIDE_BACK
l_.str.3:                               ; @.str.3
	.asciz	"HL_SplitBrush: WARNING huge split winding\n"

	.comm	_SFL_TESTED,4,2                 ; @SFL_TESTED
l_.str.4:                               ; @.str.4
	.asciz	"HL_SplitBrush: bogus brush after clip\n"

l_.str.5:                               ; @.str.5
	.asciz	"HL_SplitBrush: numsides < 3\n"

l_.str.6:                               ; @.str.6
	.asciz	"HL_SplitBrush: split removed brush\n"

l_.str.7:                               ; @.str.7
	.asciz	"HL_SplitBrush: split not on both sides\n"

	.comm	_SFL_VISIBLE,4,2                ; @SFL_VISIBLE
l_.str.8:                               ; @.str.8
	.asciz	"HL_SplitBrush: tiny volume after clip\n"

.subsections_via_symbols
