	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ## -- Begin function Q2_ParseBrush
LCPI0_0:
	.quad	0x3fe0000000000000              ## double 0.5
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_Q2_ParseBrush
	.p2align	4, 0x90
_Q2_ParseBrush:                         ## @Q2_ParseBrush
	.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	$184, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_nummapbrushes@GOTPCREL(%rip), %r14
	movq	(%r14), %rax
	movq	_MAX_MAPFILE_BRUSHES@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jb	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_Error
	movq	(%r14), %rax
LBB0_2:
	movq	_mapbrushes@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
	leaq	(%rax,%rax,4), %rsi
	leaq	(%rdx,%rsi,8), %rcx
	movq	%rcx, -144(%rbp)                ## 8-byte Spill
	movq	_brushsides@GOTPCREL(%rip), %rdi
	movq	_nummapbrushsides@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	leaq	(%rcx,%rcx,4), %rcx
	shlq	$2, %rcx
	addq	(%rdi), %rcx
	movq	%rcx, 32(%rdx,%rsi,8)
	movq	_num_entities@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	decl	%ecx
	movl	%ecx, (%rdx,%rsi,8)
	movq	%rbx, -216(%rbp)                ## 8-byte Spill
	subq	8(%rbx), %rax
	movq	%rax, 24(%rdx,%rsi,8)
	movq	%rdx, -168(%rbp)                ## 8-byte Spill
	movq	%rsi, -160(%rbp)                ## 8-byte Spill
	movl	$-1, 4(%rdx,%rsi,8)
	leaq	-136(%rbp), %rsi
	movq	%r15, %rdi
	callq	_PS_ReadToken
	testl	%eax, %eax
	je	LBB0_35
## %bb.3:
	movq	-168(%rbp), %rax                ## 8-byte Reload
	movq	-160(%rbp), %rcx                ## 8-byte Reload
	leaq	(%rax,%rcx,8), %rax
	addq	$8, %rax
	movq	%rax, -152(%rbp)                ## 8-byte Spill
	leaq	-136(%rbp), %r12
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_6 Depth=1
	movq	-144(%rbp), %rax                ## 8-byte Reload
	movl	(%rax), %esi
	movq	24(%rax), %rdx
	leaq	L_.str.5(%rip), %rdi
	callq	_Log_Print
LBB0_5:                                 ##   in Loop: Header=BB0_6 Depth=1
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ReadToken
	testl	%eax, %eax
	je	LBB0_35
LBB0_6:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_25 Depth 2
	movl	-132(%rbp), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_strcmp
	testl	%eax, %eax
	je	LBB0_35
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	_nummapbrushsides@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	_MAX_MAPFILE_BRUSHSIDES@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rcx
	jb	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=1
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_Error
	movq	_nummapbrushsides@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
LBB0_9:                                 ##   in Loop: Header=BB0_6 Depth=1
	movq	%rcx, -224(%rbp)                ## 8-byte Spill
	movq	_brushsides@GOTPCREL(%rip), %rax
	movq	(%rax), %r13
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -96(%rbp)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -92(%rbp)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -88(%rbp)
	movq	%r15, %rdi
	leaq	L_.str.4(%rip), %rbx
	movq	%rbx, %rsi
	callq	_PS_ExpectTokenString
	movq	%r15, %rdi
	leaq	L_.str.3(%rip), %r14
	movq	%r14, %rsi
	callq	_PS_ExpectTokenString
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -84(%rbp)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -80(%rbp)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -76(%rbp)
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_PS_ExpectTokenString
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	_PS_ExpectTokenString
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -72(%rbp)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -68(%rbp)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movl	%eax, -64(%rbp)
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_PS_ExpectTokenString
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-200(%rbp), %edi
	movl	-132(%rbp), %esi
	callq	_strcpy
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atol
	movq	-176(%rbp), %rcx
	movq	%rax, (%rcx)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atol
	movq	-176(%rbp), %rcx
	movq	%rax, 8(%rcx)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atol
	movq	%rax, -184(%rbp)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movq	-192(%rbp), %rcx
	movq	%rax, (%rcx)
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_PS_ExpectAnyToken
	movl	-132(%rbp), %edi
	callq	_atof
	movq	-192(%rbp), %rcx
	movq	%rax, 8(%rcx)
	movl	-200(%rbp), %edi
	callq	_FindMiptex
	movq	_textureref@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cltq
	leaq	(%rax,%rax,2), %rax
	movl	(%rcx,%rax,4), %edx
	movl	4(%rcx,%rax,4), %esi
	movl	%esi, -204(%rbp)
	movl	8(%rcx,%rax,4), %eax
	movq	-224(%rbp), %rcx                ## 8-byte Reload
	leaq	(%rcx,%rcx,4), %rcx
	leaq	(%r13,%rcx,4), %rbx
	movl	%eax, (%r13,%rcx,4)
	movl	%edx, -208(%rbp)
	movl	%edx, 4(%r13,%rcx,4)
	movq	_TT_NUMBER@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%r15, %rdi
	xorl	%edx, %edx
	movq	%r12, %rcx
	callq	_PS_CheckTokenType
	testq	%rax, %rax
	je	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_6 Depth=1
	movl	-136(%rbp), %eax
	movl	%eax, (%rbx)
	movl	(%r14), %esi
	movq	%r15, %rdi
	xorl	%edx, %edx
	movq	%r12, %rcx
	callq	_PS_ExpectTokenType
	movl	-136(%rbp), %eax
	movl	%eax, -208(%rbp)
	movl	%eax, 4(%rbx)
	movl	(%r14), %esi
	movq	%r15, %rdi
	xorl	%edx, %edx
	movq	%r12, %rcx
	callq	_PS_ExpectTokenType
	movl	-136(%rbp), %eax
	movl	%eax, -204(%rbp)
LBB0_11:                                ##   in Loop: Header=BB0_6 Depth=1
	movl	4(%rbx), %eax
	movq	_SURF_TRANS66@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	_SURF_TRANS33@GOTPCREL(%rip), %rdx
	orl	(%rdx), %ecx
	testl	%eax, %ecx
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_6 Depth=1
	movl	(%rbx), %ecx
	movq	_CONTENTS_DETAIL@GOTPCREL(%rip), %rdi
	orl	(%rdi), %ecx
	movl	%ecx, (%rbx)
	jmp	LBB0_14
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_6 Depth=1
	movl	(%rbx), %ecx
	movq	_CONTENTS_DETAIL@GOTPCREL(%rip), %rdi
LBB0_14:                                ##   in Loop: Header=BB0_6 Depth=1
	movq	_CONTENTS_MONSTERCLIP@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	movq	_CONTENTS_PLAYERCLIP@GOTPCREL(%rip), %rsi
	orl	(%rsi), %edx
	testl	%ecx, %edx
	je	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_6 Depth=1
	orl	(%rdi), %ecx
	movl	%ecx, (%rbx)
LBB0_16:                                ##   in Loop: Header=BB0_6 Depth=1
	movq	_fulldetail@GOTPCREL(%rip), %rdx
	cmpq	$0, (%rdx)
	je	LBB0_18
## %bb.17:                              ##   in Loop: Header=BB0_6 Depth=1
	movl	(%rdi), %edx
	notl	%edx
	andl	%edx, %ecx
	movl	%ecx, (%rbx)
LBB0_18:                                ##   in Loop: Header=BB0_6 Depth=1
	movq	_LAST_VISIBLE_CONTENTS@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	decl	%edx
	movq	_CONTENTS_PLAYERCLIP@GOTPCREL(%rip), %rsi
	orl	(%rsi), %edx
	movq	_CONTENTS_MONSTERCLIP@GOTPCREL(%rip), %rsi
	orl	(%rsi), %edx
	movq	_CONTENTS_MIST@GOTPCREL(%rip), %rsi
	orl	(%rsi), %edx
	testl	%ecx, %edx
	jne	LBB0_20
## %bb.19:                              ##   in Loop: Header=BB0_6 Depth=1
	movq	_CONTENTS_SOLID@GOTPCREL(%rip), %rdx
	orl	(%rdx), %ecx
	movl	%ecx, (%rbx)
LBB0_20:                                ##   in Loop: Header=BB0_6 Depth=1
	movq	_SURF_SKIP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	_SURF_HINT@GOTPCREL(%rip), %rdx
	orl	(%rdx), %ecx
	testl	%eax, %ecx
	je	LBB0_22
## %bb.21:                              ##   in Loop: Header=BB0_6 Depth=1
	movl	$0, (%rbx)
	movl	(%rdi), %ecx
	notl	%ecx
	andl	%ecx, %eax
	movl	%eax, 4(%rbx)
LBB0_22:                                ##   in Loop: Header=BB0_6 Depth=1
	leaq	-96(%rbp), %rdi
	leaq	-84(%rbp), %rsi
	leaq	-72(%rbp), %rdx
	callq	_PlaneFromPoints
	cmpl	$-1, %eax
	je	LBB0_4
## %bb.23:                              ##   in Loop: Header=BB0_6 Depth=1
	movl	%eax, %r14d
	movq	-152(%rbp), %rax                ## 8-byte Reload
	movl	(%rax), %eax
	testl	%eax, %eax
	jle	LBB0_29
## %bb.24:                              ##   in Loop: Header=BB0_6 Depth=1
	movq	-144(%rbp), %rcx                ## 8-byte Reload
	movq	32(%rcx), %rcx
	movl	%r14d, %edx
	xorl	$1, %edx
	addq	$8, %rcx
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_25:                                ##   Parent Loop BB0_6 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%rcx), %esi
	cmpl	%r14d, %esi
	je	LBB0_30
## %bb.26:                              ##   in Loop: Header=BB0_25 Depth=2
	cmpl	%edx, %esi
	je	LBB0_31
## %bb.27:                              ##   in Loop: Header=BB0_25 Depth=2
	incq	%rbx
	addq	$20, %rcx
	cmpq	%rbx, %rax
	jne	LBB0_25
## %bb.28:                              ##   in Loop: Header=BB0_6 Depth=1
	movl	%eax, %ebx
	jmp	LBB0_33
	.p2align	4, 0x90
LBB0_29:                                ##   in Loop: Header=BB0_6 Depth=1
	xorl	%ebx, %ebx
	jmp	LBB0_33
LBB0_30:                                ##   in Loop: Header=BB0_6 Depth=1
	leaq	L_.str.6(%rip), %rdi
	jmp	LBB0_32
LBB0_31:                                ##   in Loop: Header=BB0_6 Depth=1
	leaq	L_.str.7(%rip), %rdi
LBB0_32:                                ##   in Loop: Header=BB0_6 Depth=1
	movq	-144(%rbp), %rax                ## 8-byte Reload
	movl	(%rax), %esi
	movq	24(%rax), %rdx
	callq	_Log_Print
LBB0_33:                                ##   in Loop: Header=BB0_6 Depth=1
	movq	-152(%rbp), %rax                ## 8-byte Reload
	cmpl	(%rax), %ebx
	jne	LBB0_5
## %bb.34:                              ##   in Loop: Header=BB0_6 Depth=1
	movq	-144(%rbp), %rax                ## 8-byte Reload
	movq	32(%rax), %r13
	movslq	%ebx, %rax
	leaq	(%rax,%rax,4), %rbx
	movl	%r14d, 8(%r13,%rbx,4)
	movslq	%r14d, %rdi
	shlq	$2, %rdi
	movq	_mapplanes@GOTPCREL(%rip), %rax
	addq	(%rax), %rdi
	movq	_vec3_origin@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-208(%rbp), %rsi
	callq	_TexinfoForBrushTexture
	movl	%eax, 12(%r13,%rbx,4)
	movq	_side_brushtextures@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_nummapbrushsides@GOTPCREL(%rip), %rsi
	movq	(%rsi), %rcx
	leaq	(%rcx,%rcx,4), %rcx
	movq	-176(%rbp), %rdx
	movq	%rdx, 32(%rax,%rcx,8)
	movups	-208(%rbp), %xmm0
	movups	-192(%rbp), %xmm1
	movups	%xmm1, 16(%rax,%rcx,8)
	movups	%xmm0, (%rax,%rcx,8)
	incq	(%rsi)
	movq	-152(%rbp), %rax                ## 8-byte Reload
	incl	(%rax)
	jmp	LBB0_5
LBB0_35:
	movq	-144(%rbp), %rdi                ## 8-byte Reload
	callq	_Q2_BrushContents
	movq	-168(%rbp), %r15                ## 8-byte Reload
	movq	-160(%rbp), %r12                ## 8-byte Reload
	movl	%eax, 12(%r15,%r12,8)
	movq	_nodetail@GOTPCREL(%rip), %rcx
	cmpq	$0, (%rcx)
	je	LBB0_38
## %bb.36:
	movq	_CONTENTS_DETAIL@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_55
LBB0_38:
	movq	_nowater@GOTPCREL(%rip), %rcx
	cmpq	$0, (%rcx)
	je	LBB0_41
## %bb.39:
	movq	_CONTENTS_LAVA@GOTPCREL(%rip), %rcx
	movq	_CONTENTS_SLIME@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	movq	_CONTENTS_WATER@GOTPCREL(%rip), %rcx
	orl	(%rcx), %edx
	testl	%eax, %edx
	jne	LBB0_55
LBB0_41:
	leaq	(%r15,%r12,8), %r14
	addq	$12, %r14
	movq	-144(%rbp), %rdi                ## 8-byte Reload
	callq	_MakeBrushWindings
	movq	_CONTENTS_PLAYERCLIP@GOTPCREL(%rip), %rax
	movq	_CONTENTS_MONSTERCLIP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	testl	%ecx, (%r14)
	je	LBB0_50
## %bb.42:
	movq	_c_clipbrushes@GOTPCREL(%rip), %rax
	incl	(%rax)
	movl	8(%r15,%r12,8), %edx
	testl	%edx, %edx
	jle	LBB0_50
## %bb.43:
	movq	-144(%rbp), %rax                ## 8-byte Reload
	movq	32(%rax), %r8
	leaq	-1(%rdx), %rax
	movl	%edx, %ecx
	andl	$3, %ecx
	cmpq	$3, %rax
	jae	LBB0_45
## %bb.44:
	xorl	%esi, %esi
	jmp	LBB0_47
LBB0_45:
	andl	$-4, %edx
	leaq	72(%r8), %rdi
	xorl	%esi, %esi
	movq	_TEXINFO_NODE@GOTPCREL(%rip), %rax
	.p2align	4, 0x90
LBB0_46:                                ## =>This Inner Loop Header: Depth=1
	movl	(%rax), %ebx
	movl	%ebx, -60(%rdi)
	movl	(%rax), %ebx
	movl	%ebx, -40(%rdi)
	movl	(%rax), %ebx
	movl	%ebx, -20(%rdi)
	movl	(%rax), %ebx
	movl	%ebx, (%rdi)
	addq	$4, %rsi
	addq	$80, %rdi
	cmpq	%rsi, %rdx
	jne	LBB0_46
LBB0_47:
	testq	%rcx, %rcx
	je	LBB0_50
## %bb.48:
	leaq	(%rsi,%rsi,4), %rax
	leaq	(%r8,%rax,4), %rax
	addq	$12, %rax
	shlq	$2, %rcx
	leaq	(%rcx,%rcx,4), %rcx
	xorl	%edx, %edx
	movq	_TEXINFO_NODE@GOTPCREL(%rip), %rsi
	.p2align	4, 0x90
LBB0_49:                                ## =>This Inner Loop Header: Depth=1
	movl	(%rsi), %edi
	movl	%edi, (%rax,%rdx)
	addq	$20, %rdx
	cmpq	%rdx, %rcx
	jne	LBB0_49
LBB0_50:
	movq	_CONTENTS_ORIGIN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r14)
	je	LBB0_53
## %bb.51:
	movq	_num_entities@GOTPCREL(%rip), %rax
	cmpl	$1, (%rax)
	jne	LBB0_54
## %bb.52:
	movq	-144(%rbp), %rax                ## 8-byte Reload
	movl	(%rax), %esi
	movq	24(%rax), %rdx
	leaq	L_.str.8(%rip), %rdi
	xorl	%eax, %eax
	callq	_Error
	jmp	LBB0_56
LBB0_53:
	movq	-144(%rbp), %rdi                ## 8-byte Reload
	callq	_AddBrushBevels
	movq	_nummapbrushes@GOTPCREL(%rip), %rax
	incq	(%rax)
	movq	-216(%rbp), %rax                ## 8-byte Reload
	incl	(%rax)
	jmp	LBB0_56
LBB0_54:
	movl	16(%r15,%r12,8), %esi
	movl	20(%r15,%r12,8), %edi
	callq	_VectorAdd
	movsd	LCPI0_0(%rip), %xmm0            ## xmm0 = mem[0],zero
	callq	_VectorScale
	leaq	L_.str.9(%rip), %rsi
	leaq	-128(%rbp), %r14
	movq	%r14, %rdi
	callq	_sprintf
	movq	_entities@GOTPCREL(%rip), %r13
	movq	-144(%rbp), %rbx                ## 8-byte Reload
	movslq	(%rbx), %rdi
	shlq	$2, %rdi
	addq	(%r13), %rdi
	leaq	L_.str.10(%rip), %rsi
	movq	%r14, %rdx
	callq	_SetKeyValue
	movq	(%r13), %rax
	movslq	(%rbx), %rcx
	movl	(%rax,%rcx,4), %esi
	callq	_VectorCopy
LBB0_55:
	movl	$0, 8(%r15,%r12,8)
LBB0_56:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_58
## %bb.57:
	addq	$184, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_58:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_nummapbrushes,8,3              ## @nummapbrushes
	.comm	_MAX_MAPFILE_BRUSHES,8,3        ## @MAX_MAPFILE_BRUSHES
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"nummapbrushes == MAX_MAPFILE_BRUSHES"

	.comm	_mapbrushes,8,3                 ## @mapbrushes
	.comm	_brushsides,8,3                 ## @brushsides
	.comm	_nummapbrushsides,8,3           ## @nummapbrushsides
	.comm	_num_entities,4,2               ## @num_entities
L_.str.1:                               ## @.str.1
	.asciz	"}"

	.comm	_MAX_MAPFILE_BRUSHSIDES,8,3     ## @MAX_MAPFILE_BRUSHSIDES
L_.str.2:                               ## @.str.2
	.asciz	"MAX_MAPFILE_BRUSHSIDES"

L_.str.3:                               ## @.str.3
	.asciz	"("

L_.str.4:                               ## @.str.4
	.asciz	")"

	.comm	_textureref,8,3                 ## @textureref
	.comm	_TT_NUMBER,4,2                  ## @TT_NUMBER
	.comm	_SURF_TRANS33,4,2               ## @SURF_TRANS33
	.comm	_SURF_TRANS66,4,2               ## @SURF_TRANS66
	.comm	_CONTENTS_DETAIL,4,2            ## @CONTENTS_DETAIL
	.comm	_CONTENTS_PLAYERCLIP,4,2        ## @CONTENTS_PLAYERCLIP
	.comm	_CONTENTS_MONSTERCLIP,4,2       ## @CONTENTS_MONSTERCLIP
	.comm	_fulldetail,8,3                 ## @fulldetail
	.comm	_LAST_VISIBLE_CONTENTS,4,2      ## @LAST_VISIBLE_CONTENTS
	.comm	_CONTENTS_MIST,4,2              ## @CONTENTS_MIST
	.comm	_CONTENTS_SOLID,4,2             ## @CONTENTS_SOLID
	.comm	_SURF_HINT,4,2                  ## @SURF_HINT
	.comm	_SURF_SKIP,4,2                  ## @SURF_SKIP
L_.str.5:                               ## @.str.5
	.asciz	"Entity %i, Brush %i: plane with no normal\n"

L_.str.6:                               ## @.str.6
	.asciz	"Entity %i, Brush %i: duplicate plane\n"

L_.str.7:                               ## @.str.7
	.asciz	"Entity %i, Brush %i: mirrored plane\n"

	.comm	_mapplanes,8,3                  ## @mapplanes
	.comm	_vec3_origin,4,2                ## @vec3_origin
	.comm	_side_brushtextures,8,3         ## @side_brushtextures
	.comm	_nodetail,8,3                   ## @nodetail
	.comm	_nowater,8,3                    ## @nowater
	.comm	_CONTENTS_LAVA,4,2              ## @CONTENTS_LAVA
	.comm	_CONTENTS_SLIME,4,2             ## @CONTENTS_SLIME
	.comm	_CONTENTS_WATER,4,2             ## @CONTENTS_WATER
	.comm	_c_clipbrushes,4,2              ## @c_clipbrushes
	.comm	_TEXINFO_NODE,4,2               ## @TEXINFO_NODE
	.comm	_CONTENTS_ORIGIN,4,2            ## @CONTENTS_ORIGIN
L_.str.8:                               ## @.str.8
	.asciz	"Entity %i, Brush %i: origin brushes not allowed in world"

L_.str.9:                               ## @.str.9
	.asciz	"%i %i %i"

	.comm	_entities,8,3                   ## @entities
L_.str.10:                              ## @.str.10
	.asciz	"origin"

	.comm	_SFL_TEXTURED,4,2               ## @SFL_TEXTURED
	.comm	_c_squattbrushes,4,2            ## @c_squattbrushes
	.comm	_create_aas,8,3                 ## @create_aas
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Q2_ParseBrush                  ; -- Begin function Q2_ParseBrush
	.p2align	2
_Q2_ParseBrush:                         ; @Q2_ParseBrush
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #304
	.cfi_def_cfa_offset 304
	stp	x28, x27, [sp, #208]            ; 16-byte Folded Spill
	stp	x26, x25, [sp, #224]            ; 16-byte Folded Spill
	stp	x24, x23, [sp, #240]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #256]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #272]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #288]            ; 16-byte Folded Spill
	add	x29, sp, #288
	.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
	mov	x19, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
Lloh3:
	adrp	x20, _nummapbrushes@GOTPAGE
Lloh4:
	ldr	x20, [x20, _nummapbrushes@GOTPAGEOFF]
	stur	x8, [x29, #-96]
	ldr	x11, [x20]
Lloh5:
	adrp	x8, _MAX_MAPFILE_BRUSHES@GOTPAGE
Lloh6:
	ldr	x8, [x8, _MAX_MAPFILE_BRUSHES@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	cmp	x11, x8
	b.lo	LBB0_2
; %bb.1:
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	bl	_Error
	ldr	x11, [x20]
LBB0_2:
Lloh10:
	adrp	x8, _mapbrushes@GOTPAGE
Lloh11:
	ldr	x8, [x8, _mapbrushes@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x8]
	mov	w8, #40
	str	x9, [sp, #24]                   ; 8-byte Folded Spill
	madd	x10, x11, x8, x9
Lloh13:
	adrp	x8, _brushsides@GOTPAGE
Lloh14:
	ldr	x8, [x8, _brushsides@GOTPAGEOFF]
Lloh15:
	ldr	x8, [x8]
Lloh16:
	adrp	x27, _nummapbrushsides@GOTPAGE
Lloh17:
	ldr	x27, [x27, _nummapbrushsides@GOTPAGEOFF]
	ldr	x9, [x27]
	mov	w12, #20
	madd	x8, x9, x12, x8
	mov	x9, x10
	str	x8, [x9, #32]!
	str	x9, [sp, #48]                   ; 8-byte Folded Spill
Lloh18:
	adrp	x8, _num_entities@GOTPAGE
Lloh19:
	ldr	x8, [x8, _num_entities@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	sub	w8, w8, #1
	str	w8, [x10]
	str	x19, [sp, #16]                  ; 8-byte Folded Spill
	ldr	x8, [x19, #8]
	sub	x8, x11, x8
	mov	x9, x10
	str	x8, [x9, #24]!
	stp	x11, x9, [sp, #32]              ; 16-byte Folded Spill
	mov	w8, #-1
	str	x10, [sp, #56]                  ; 8-byte Folded Spill
	str	w8, [x10, #4]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ReadToken
Lloh21:
	adrp	x28, _CONTENTS_DETAIL@GOTPAGE
Lloh22:
	ldr	x28, [x28, _CONTENTS_DETAIL@GOTPAGEOFF]
	cbz	w0, LBB0_35
; %bb.3:
	sub	x8, x29, #132
	add	x9, x8, #12
	str	x9, [sp, #64]                   ; 8-byte Folded Spill
	add	x23, x8, #24
	mov	w10, #40
	ldp	x9, x8, [sp, #24]               ; 16-byte Folded Reload
	madd	x8, x8, x10, x9
Lloh23:
	adrp	x25, l_.str.4@PAGE
Lloh24:
	add	x25, x25, l_.str.4@PAGEOFF
Lloh25:
	adrp	x24, _TT_NUMBER@GOTPAGE
Lloh26:
	ldr	x24, [x24, _TT_NUMBER@GOTPAGEOFF]
Lloh27:
	adrp	x26, l_.str.3@PAGE
Lloh28:
	add	x26, x26, l_.str.3@PAGEOFF
	add	x19, x8, #8
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [sp, #56]                   ; 8-byte Folded Reload
	ldr	w1, [x8]
	ldr	x8, [sp, #40]                   ; 8-byte Folded Reload
	ldr	x2, [x8]
Lloh29:
	adrp	x0, l_.str.5@PAGE
Lloh30:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_Log_Print
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ReadToken
	cbz	w0, LBB0_35
LBB0_6:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_25 Depth 2
	ldr	w0, [sp, #76]
Lloh31:
	adrp	x1, l_.str.1@PAGE
Lloh32:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_strcmp
	cbz	w0, LBB0_35
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x20, [x27]
Lloh33:
	adrp	x8, _MAX_MAPFILE_BRUSHSIDES@GOTPAGE
Lloh34:
	ldr	x8, [x8, _MAX_MAPFILE_BRUSHSIDES@GOTPAGEOFF]
Lloh35:
	ldr	x8, [x8]
	cmp	x20, x8
	b.lo	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh36:
	adrp	x0, l_.str.2@PAGE
Lloh37:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_Error
	ldr	x20, [x27]
LBB0_9:                                 ;   in Loop: Header=BB0_6 Depth=1
Lloh38:
	adrp	x8, _brushsides@GOTPAGE
Lloh39:
	ldr	x8, [x8, _brushsides@GOTPAGEOFF]
Lloh40:
	ldr	x22, [x8]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-132]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-128]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-124]
	mov	x0, x21
	mov	x1, x25
	bl	_PS_ExpectTokenString
	mov	x0, x21
	mov	x1, x26
	bl	_PS_ExpectTokenString
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-120]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-116]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-112]
	mov	x0, x21
	mov	x1, x25
	bl	_PS_ExpectTokenString
	mov	x0, x21
	mov	x1, x26
	bl	_PS_ExpectTokenString
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-108]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-104]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	stur	w0, [x29, #-100]
	mov	x0, x21
	mov	x1, x25
	bl	_PS_ExpectTokenString
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #88]
	ldr	w1, [sp, #76]
	bl	_strcpy
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atol
	ldr	x8, [sp, #112]
	str	x0, [x8]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atol
	ldr	x8, [sp, #112]
	str	x0, [x8, #8]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atol
	str	x0, [sp, #104]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	ldr	x8, [sp, #96]
	str	x0, [x8]
	add	x1, sp, #72
	mov	x0, x21
	bl	_PS_ExpectAnyToken
	ldr	w0, [sp, #76]
	bl	_atof
	ldr	x8, [sp, #96]
	str	x0, [x8, #8]
	ldr	w0, [sp, #88]
	bl	_FindMiptex
Lloh41:
	adrp	x8, _textureref@GOTPAGE
Lloh42:
	ldr	x8, [x8, _textureref@GOTPAGEOFF]
Lloh43:
	ldr	x8, [x8]
	mov	w9, #12
	smaddl	x8, w0, w9, x8
	ldr	w9, [x8, #8]
	mov	w10, #20
	madd	x20, x20, x10, x22
	str	w9, [x20]
	ldr	d0, [x8]
	str	d0, [sp, #80]
	fmov	w8, s0
	mov	x22, x20
	str	w8, [x22, #4]!
	ldr	w1, [x24]
	add	x3, sp, #72
	mov	x0, x21
	mov	w2, #0
	bl	_PS_CheckTokenType
	cbz	x0, LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [sp, #72]
	str	w8, [x20]
	ldr	w1, [x24]
	add	x3, sp, #72
	mov	x0, x21
	mov	w2, #0
	bl	_PS_ExpectTokenType
	ldr	w8, [sp, #72]
	str	w8, [sp, #80]
	str	w8, [x22]
	ldr	w1, [x24]
	add	x3, sp, #72
	mov	x0, x21
	mov	w2, #0
	bl	_PS_ExpectTokenType
	ldr	w8, [sp, #72]
	str	w8, [sp, #84]
LBB0_11:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [x22]
Lloh44:
	adrp	x9, _SURF_TRANS33@GOTPAGE
Lloh45:
	ldr	x9, [x9, _SURF_TRANS33@GOTPAGEOFF]
Lloh46:
	ldr	w9, [x9]
Lloh47:
	adrp	x10, _SURF_TRANS66@GOTPAGE
Lloh48:
	ldr	x10, [x10, _SURF_TRANS66@GOTPAGEOFF]
Lloh49:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.eq	LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	w9, [x28]
	ldr	w10, [x20]
	orr	w9, w10, w9
	str	w9, [x20]
	b	LBB0_14
LBB0_13:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w9, [x20]
LBB0_14:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh50:
	adrp	x10, _CONTENTS_PLAYERCLIP@GOTPAGE
Lloh51:
	ldr	x10, [x10, _CONTENTS_PLAYERCLIP@GOTPAGEOFF]
Lloh52:
	ldr	w10, [x10]
Lloh53:
	adrp	x11, _CONTENTS_MONSTERCLIP@GOTPAGE
Lloh54:
	ldr	x11, [x11, _CONTENTS_MONSTERCLIP@GOTPAGEOFF]
Lloh55:
	ldr	w11, [x11]
	orr	w10, w11, w10
	tst	w10, w9
	b.eq	LBB0_16
; %bb.15:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	w10, [x28]
	orr	w9, w10, w9
	str	w9, [x20]
LBB0_16:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh56:
	adrp	x10, _fulldetail@GOTPAGE
Lloh57:
	ldr	x10, [x10, _fulldetail@GOTPAGEOFF]
Lloh58:
	ldr	x10, [x10]
	cbz	x10, LBB0_18
; %bb.17:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	w10, [x28]
	bic	w9, w9, w10
	str	w9, [x20]
LBB0_18:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh59:
	adrp	x10, _LAST_VISIBLE_CONTENTS@GOTPAGE
Lloh60:
	ldr	x10, [x10, _LAST_VISIBLE_CONTENTS@GOTPAGEOFF]
Lloh61:
	ldr	w10, [x10]
	sub	w10, w10, #1
Lloh62:
	adrp	x11, _CONTENTS_PLAYERCLIP@GOTPAGE
Lloh63:
	ldr	x11, [x11, _CONTENTS_PLAYERCLIP@GOTPAGEOFF]
Lloh64:
	ldr	w11, [x11]
	orr	w10, w10, w11
Lloh65:
	adrp	x11, _CONTENTS_MONSTERCLIP@GOTPAGE
Lloh66:
	ldr	x11, [x11, _CONTENTS_MONSTERCLIP@GOTPAGEOFF]
Lloh67:
	ldr	w11, [x11]
	orr	w10, w10, w11
Lloh68:
	adrp	x11, _CONTENTS_MIST@GOTPAGE
Lloh69:
	ldr	x11, [x11, _CONTENTS_MIST@GOTPAGEOFF]
Lloh70:
	ldr	w11, [x11]
	orr	w10, w10, w11
	tst	w10, w9
	b.ne	LBB0_20
; %bb.19:                               ;   in Loop: Header=BB0_6 Depth=1
Lloh71:
	adrp	x10, _CONTENTS_SOLID@GOTPAGE
Lloh72:
	ldr	x10, [x10, _CONTENTS_SOLID@GOTPAGEOFF]
Lloh73:
	ldr	w10, [x10]
	orr	w9, w10, w9
	str	w9, [x20]
LBB0_20:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh74:
	adrp	x9, _SURF_HINT@GOTPAGE
Lloh75:
	ldr	x9, [x9, _SURF_HINT@GOTPAGEOFF]
Lloh76:
	ldr	w9, [x9]
Lloh77:
	adrp	x10, _SURF_SKIP@GOTPAGE
Lloh78:
	ldr	x10, [x10, _SURF_SKIP@GOTPAGEOFF]
Lloh79:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.eq	LBB0_22
; %bb.21:                               ;   in Loop: Header=BB0_6 Depth=1
	str	wzr, [x20]
	ldr	w9, [x28]
	bic	w8, w8, w9
	str	w8, [x22]
LBB0_22:                                ;   in Loop: Header=BB0_6 Depth=1
	sub	x0, x29, #132
	ldr	x1, [sp, #64]                   ; 8-byte Folded Reload
	mov	x2, x23
	bl	_PlaneFromPoints
	cmn	w0, #1
	b.eq	LBB0_4
; %bb.23:                               ;   in Loop: Header=BB0_6 Depth=1
	mov	x20, x0
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_29
; %bb.24:                               ;   in Loop: Header=BB0_6 Depth=1
	mov	x22, #0
	ldr	x9, [sp, #48]                   ; 8-byte Folded Reload
	ldr	x10, [x9]
	eor	w9, w20, #0x1
	add	x10, x10, #8
LBB0_25:                                ;   Parent Loop BB0_6 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w11, [x10]
	cmp	w11, w20
	b.eq	LBB0_30
; %bb.26:                               ;   in Loop: Header=BB0_25 Depth=2
	cmp	w11, w9
	b.eq	LBB0_31
; %bb.27:                               ;   in Loop: Header=BB0_25 Depth=2
	add	x22, x22, #1
	add	x10, x10, #20
	cmp	x8, x22
	b.ne	LBB0_25
; %bb.28:                               ;   in Loop: Header=BB0_6 Depth=1
	mov	x22, x8
	b	LBB0_33
LBB0_29:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	w22, #0
	b	LBB0_33
LBB0_30:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh80:
	adrp	x0, l_.str.6@PAGE
Lloh81:
	add	x0, x0, l_.str.6@PAGEOFF
	b	LBB0_32
LBB0_31:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh82:
	adrp	x0, l_.str.7@PAGE
Lloh83:
	add	x0, x0, l_.str.7@PAGEOFF
LBB0_32:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [sp, #56]                   ; 8-byte Folded Reload
	ldr	w1, [x8]
	ldr	x8, [sp, #40]                   ; 8-byte Folded Reload
	ldr	x2, [x8]
	bl	_Log_Print
LBB0_33:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [x19]
	cmp	w22, w8
	b.ne	LBB0_5
; %bb.34:                               ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [sp, #48]                   ; 8-byte Folded Reload
	ldr	x8, [x8]
	mov	w9, #20
	smaddl	x22, w22, w9, x8
	str	w20, [x22, #8]
Lloh84:
	adrp	x8, _mapplanes@GOTPAGE
Lloh85:
	ldr	x8, [x8, _mapplanes@GOTPAGEOFF]
Lloh86:
	ldr	x8, [x8]
	add	x0, x8, w20, sxtw #2
Lloh87:
	adrp	x8, _vec3_origin@GOTPAGE
Lloh88:
	ldr	x8, [x8, _vec3_origin@GOTPAGEOFF]
Lloh89:
	ldr	w2, [x8]
	add	x1, sp, #80
	bl	_TexinfoForBrushTexture
	str	w0, [x22, #12]
Lloh90:
	adrp	x8, _side_brushtextures@GOTPAGE
Lloh91:
	ldr	x8, [x8, _side_brushtextures@GOTPAGEOFF]
Lloh92:
	ldr	x8, [x8]
	ldr	x9, [x27]
	mov	w10, #40
	madd	x8, x9, x10, x8
	ldp	q1, q0, [sp, #80]
	ldr	x9, [sp, #112]
	str	x9, [x8, #32]
	stp	q1, q0, [x8]
	ldr	x8, [x27]
	add	x8, x8, #1
	str	x8, [x27]
	ldr	w8, [x19]
	add	w8, w8, #1
	str	w8, [x19]
	b	LBB0_5
LBB0_35:
	ldr	x0, [sp, #56]                   ; 8-byte Folded Reload
	bl	_Q2_BrushContents
	mov	w8, #40
	ldp	x21, x20, [sp, #24]             ; 16-byte Folded Reload
	mul	x8, x20, x8
	add	x19, x21, x8
	str	w0, [x19, #12]!
Lloh93:
	adrp	x8, _nodetail@GOTPAGE
Lloh94:
	ldr	x8, [x8, _nodetail@GOTPAGEOFF]
Lloh95:
	ldr	x8, [x8]
	cbz	x8, LBB0_37
; %bb.36:
	ldr	w8, [x28]
	tst	w8, w0
	b.ne	LBB0_39
LBB0_37:
Lloh96:
	adrp	x8, _nowater@GOTPAGE
Lloh97:
	ldr	x8, [x8, _nowater@GOTPAGEOFF]
Lloh98:
	ldr	x8, [x8]
	cbz	x8, LBB0_42
; %bb.38:
Lloh99:
	adrp	x8, _CONTENTS_LAVA@GOTPAGE
Lloh100:
	ldr	x8, [x8, _CONTENTS_LAVA@GOTPAGEOFF]
Lloh101:
	ldr	w8, [x8]
Lloh102:
	adrp	x9, _CONTENTS_SLIME@GOTPAGE
Lloh103:
	ldr	x9, [x9, _CONTENTS_SLIME@GOTPAGEOFF]
Lloh104:
	ldr	w9, [x9]
	orr	w8, w9, w8
Lloh105:
	adrp	x9, _CONTENTS_WATER@GOTPAGE
Lloh106:
	ldr	x9, [x9, _CONTENTS_WATER@GOTPAGEOFF]
Lloh107:
	ldr	w9, [x9]
	orr	w8, w8, w9
	tst	w8, w0
	b.eq	LBB0_42
LBB0_39:
	mov	w8, #40
	mul	x8, x20, x8
	add	x8, x21, x8
	str	wzr, [x8, #8]
LBB0_40:
	ldur	x8, [x29, #-96]
Lloh108:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh109:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh110:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_51
; %bb.41:
	ldp	x29, x30, [sp, #288]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #272]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #256]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #240]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #224]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #208]            ; 16-byte Folded Reload
	add	sp, sp, #304
	ret
LBB0_42:
	ldr	x0, [sp, #56]                   ; 8-byte Folded Reload
	bl	_MakeBrushWindings
	ldr	w8, [x19]
Lloh111:
	adrp	x9, _CONTENTS_PLAYERCLIP@GOTPAGE
Lloh112:
	ldr	x9, [x9, _CONTENTS_PLAYERCLIP@GOTPAGEOFF]
Lloh113:
	ldr	w9, [x9]
Lloh114:
	adrp	x10, _CONTENTS_MONSTERCLIP@GOTPAGE
Lloh115:
	ldr	x10, [x10, _CONTENTS_MONSTERCLIP@GOTPAGEOFF]
Lloh116:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.eq	LBB0_46
; %bb.43:
Lloh117:
	adrp	x8, _c_clipbrushes@GOTPAGE
Lloh118:
	ldr	x8, [x8, _c_clipbrushes@GOTPAGEOFF]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
	mov	w8, #40
	mul	x8, x20, x8
	add	x8, x21, x8
	ldr	w8, [x8, #8]
	cmp	w8, #1
	b.lt	LBB0_46
; %bb.44:
	ldr	x9, [sp, #48]                   ; 8-byte Folded Reload
	ldr	x9, [x9]
	add	x9, x9, #12
Lloh119:
	adrp	x10, _TEXINFO_NODE@GOTPAGE
Lloh120:
	ldr	x10, [x10, _TEXINFO_NODE@GOTPAGEOFF]
LBB0_45:                                ; =>This Inner Loop Header: Depth=1
	ldr	w11, [x10]
	str	w11, [x9], #20
	subs	x8, x8, #1
	b.ne	LBB0_45
LBB0_46:
	ldr	w8, [x19]
Lloh121:
	adrp	x9, _CONTENTS_ORIGIN@GOTPAGE
Lloh122:
	ldr	x9, [x9, _CONTENTS_ORIGIN@GOTPAGEOFF]
Lloh123:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_49
; %bb.47:
Lloh124:
	adrp	x8, _num_entities@GOTPAGE
Lloh125:
	ldr	x8, [x8, _num_entities@GOTPAGEOFF]
Lloh126:
	ldr	w8, [x8]
	cmp	w8, #1
	b.ne	LBB0_50
; %bb.48:
	ldr	x8, [sp, #40]                   ; 8-byte Folded Reload
	ldr	x8, [x8]
	ldr	x9, [sp, #56]                   ; 8-byte Folded Reload
	ldr	w9, [x9]
	stp	x9, x8, [sp]
Lloh127:
	adrp	x0, l_.str.8@PAGE
Lloh128:
	add	x0, x0, l_.str.8@PAGEOFF
	bl	_Error
	b	LBB0_40
LBB0_49:
	ldr	x0, [sp, #56]                   ; 8-byte Folded Reload
	bl	_AddBrushBevels
Lloh129:
	adrp	x9, _nummapbrushes@GOTPAGE
Lloh130:
	ldr	x9, [x9, _nummapbrushes@GOTPAGEOFF]
	ldr	x8, [x9]
	add	x8, x8, #1
	str	x8, [x9]
	ldr	x9, [sp, #16]                   ; 8-byte Folded Reload
	ldr	w8, [x9]
	add	w8, w8, #1
	str	w8, [x9]
	b	LBB0_40
LBB0_50:
	mov	w8, #40
	mul	x8, x20, x8
	add	x19, x21, x8
	ldp	w1, w0, [x19, #16]
	bl	_VectorAdd
	fmov	d0, #0.50000000
	bl	_VectorScale
Lloh131:
	adrp	x1, l_.str.9@PAGE
Lloh132:
	add	x1, x1, l_.str.9@PAGEOFF
	add	x0, sp, #124
	bl	_sprintf
Lloh133:
	adrp	x20, _entities@GOTPAGE
Lloh134:
	ldr	x20, [x20, _entities@GOTPAGEOFF]
	ldr	x8, [x20]
	ldr	x21, [sp, #56]                  ; 8-byte Folded Reload
	ldrsw	x9, [x21]
	add	x0, x8, x9, lsl #2
Lloh135:
	adrp	x1, l_.str.10@PAGE
Lloh136:
	add	x1, x1, l_.str.10@PAGEOFF
	add	x2, sp, #124
	bl	_SetKeyValue
	ldr	x8, [x20]
	ldrsw	x9, [x21]
	ldr	w1, [x8, x9, lsl #2]
	bl	_VectorCopy
	str	wzr, [x19, #8]
	b	LBB0_40
LBB0_51:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh68, Lloh69, Lloh70
	.loh AdrpLdrGotLdr	Lloh65, Lloh66, Lloh67
	.loh AdrpLdrGotLdr	Lloh62, Lloh63, Lloh64
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.loh AdrpLdrGotLdr	Lloh71, Lloh72, Lloh73
	.loh AdrpLdrGotLdr	Lloh77, Lloh78, Lloh79
	.loh AdrpLdrGotLdr	Lloh74, Lloh75, Lloh76
	.loh AdrpAdd	Lloh80, Lloh81
	.loh AdrpAdd	Lloh82, Lloh83
	.loh AdrpLdrGotLdr	Lloh90, Lloh91, Lloh92
	.loh AdrpLdrGotLdr	Lloh87, Lloh88, Lloh89
	.loh AdrpLdrGotLdr	Lloh84, Lloh85, Lloh86
	.loh AdrpLdrGotLdr	Lloh93, Lloh94, Lloh95
	.loh AdrpLdrGotLdr	Lloh96, Lloh97, Lloh98
	.loh AdrpLdrGotLdr	Lloh105, Lloh106, Lloh107
	.loh AdrpLdrGotLdr	Lloh102, Lloh103, Lloh104
	.loh AdrpLdrGotLdr	Lloh99, Lloh100, Lloh101
	.loh AdrpLdrGotLdr	Lloh108, Lloh109, Lloh110
	.loh AdrpLdrGotLdr	Lloh114, Lloh115, Lloh116
	.loh AdrpLdrGotLdr	Lloh111, Lloh112, Lloh113
	.loh AdrpLdrGot	Lloh117, Lloh118
	.loh AdrpLdrGot	Lloh119, Lloh120
	.loh AdrpLdrGotLdr	Lloh121, Lloh122, Lloh123
	.loh AdrpLdrGotLdr	Lloh124, Lloh125, Lloh126
	.loh AdrpAdd	Lloh127, Lloh128
	.loh AdrpLdrGot	Lloh129, Lloh130
	.loh AdrpAdd	Lloh135, Lloh136
	.loh AdrpLdrGot	Lloh133, Lloh134
	.loh AdrpAdd	Lloh131, Lloh132
	.cfi_endproc
                                        ; -- End function
	.comm	_nummapbrushes,8,3              ; @nummapbrushes
	.comm	_MAX_MAPFILE_BRUSHES,8,3        ; @MAX_MAPFILE_BRUSHES
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"nummapbrushes == MAX_MAPFILE_BRUSHES"

	.comm	_mapbrushes,8,3                 ; @mapbrushes
	.comm	_brushsides,8,3                 ; @brushsides
	.comm	_nummapbrushsides,8,3           ; @nummapbrushsides
	.comm	_num_entities,4,2               ; @num_entities
l_.str.1:                               ; @.str.1
	.asciz	"}"

	.comm	_MAX_MAPFILE_BRUSHSIDES,8,3     ; @MAX_MAPFILE_BRUSHSIDES
l_.str.2:                               ; @.str.2
	.asciz	"MAX_MAPFILE_BRUSHSIDES"

l_.str.3:                               ; @.str.3
	.asciz	"("

l_.str.4:                               ; @.str.4
	.asciz	")"

	.comm	_textureref,8,3                 ; @textureref
	.comm	_TT_NUMBER,4,2                  ; @TT_NUMBER
	.comm	_SURF_TRANS33,4,2               ; @SURF_TRANS33
	.comm	_SURF_TRANS66,4,2               ; @SURF_TRANS66
	.comm	_CONTENTS_DETAIL,4,2            ; @CONTENTS_DETAIL
	.comm	_CONTENTS_PLAYERCLIP,4,2        ; @CONTENTS_PLAYERCLIP
	.comm	_CONTENTS_MONSTERCLIP,4,2       ; @CONTENTS_MONSTERCLIP
	.comm	_fulldetail,8,3                 ; @fulldetail
	.comm	_LAST_VISIBLE_CONTENTS,4,2      ; @LAST_VISIBLE_CONTENTS
	.comm	_CONTENTS_MIST,4,2              ; @CONTENTS_MIST
	.comm	_CONTENTS_SOLID,4,2             ; @CONTENTS_SOLID
	.comm	_SURF_HINT,4,2                  ; @SURF_HINT
	.comm	_SURF_SKIP,4,2                  ; @SURF_SKIP
l_.str.5:                               ; @.str.5
	.asciz	"Entity %i, Brush %i: plane with no normal\n"

l_.str.6:                               ; @.str.6
	.asciz	"Entity %i, Brush %i: duplicate plane\n"

l_.str.7:                               ; @.str.7
	.asciz	"Entity %i, Brush %i: mirrored plane\n"

	.comm	_mapplanes,8,3                  ; @mapplanes
	.comm	_vec3_origin,4,2                ; @vec3_origin
	.comm	_side_brushtextures,8,3         ; @side_brushtextures
	.comm	_nodetail,8,3                   ; @nodetail
	.comm	_nowater,8,3                    ; @nowater
	.comm	_CONTENTS_LAVA,4,2              ; @CONTENTS_LAVA
	.comm	_CONTENTS_SLIME,4,2             ; @CONTENTS_SLIME
	.comm	_CONTENTS_WATER,4,2             ; @CONTENTS_WATER
	.comm	_c_clipbrushes,4,2              ; @c_clipbrushes
	.comm	_TEXINFO_NODE,4,2               ; @TEXINFO_NODE
	.comm	_CONTENTS_ORIGIN,4,2            ; @CONTENTS_ORIGIN
l_.str.8:                               ; @.str.8
	.asciz	"Entity %i, Brush %i: origin brushes not allowed in world"

l_.str.9:                               ; @.str.9
	.asciz	"%i %i %i"

	.comm	_entities,8,3                   ; @entities
l_.str.10:                              ; @.str.10
	.asciz	"origin"

	.comm	_SFL_TEXTURED,4,2               ; @SFL_TEXTURED
	.comm	_c_squattbrushes,4,2            ; @c_squattbrushes
	.comm	_create_aas,8,3                 ; @create_aas
.subsections_via_symbols
