	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CMod_LoadLeafs                 ## -- Begin function CMod_LoadLeafs
	.p2align	4, 0x90
_CMod_LoadLeafs:                        ## @CMod_LoadLeafs
	.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	_cmod_base@GOTPCREL(%rip), %rax
	movq	8(%rdi), %r15
	addq	(%rax), %r15
	movslq	(%rdi), %rax
	movabsq	$-6148914691236517205, %r14     ## imm = 0xAAAAAAAAAAAAAAAB
	movq	%rax, %rcx
	imulq	%r14, %rcx
	rorq	$3, %rcx
	movabsq	$768614336404564651, %rdx       ## imm = 0xAAAAAAAAAAAAAAB
	cmpq	%rdx, %rcx
	jb	LBB0_2
## %bb.1:
	movq	%rdi, %rbx
	movq	_ERR_DROP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_Com_Error
	movslq	(%rbx), %rax
LBB0_2:
	mulq	%r14
	movq	%rdx, %r14
	shrq	$4, %r14
	testl	%r14d, %r14d
	jg	LBB0_4
## %bb.3:
	movq	_ERR_DROP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_Com_Error
LBB0_4:
	movq	_BOX_LEAFS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addl	%r14d, %eax
	shll	$4, %eax
	leal	(%rax,%rax,2), %edi
	movq	_h_high@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_Hunk_Alloc
	movq	_cm@GOTPCREL(%rip), %r13
	movq	%rax, 40(%r13)
	movl	%r14d, (%r13)
	testl	%r14d, %r14d
	jle	LBB0_5
## %bb.6:
	movq	%rax, %rbx
	addq	$20, %r15
	xorl	%r12d, %r12d
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_7 Depth=1
	addq	$24, %r12
	decl	%r14d
	je	LBB0_12
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r15,%r12), %edi
	callq	_LittleLong
	movq	%rax, (%rbx,%r12,2)
	movl	-4(%r15,%r12), %edi
	callq	_LittleLong
	movl	%eax, 8(%rbx,%r12,2)
	movl	-8(%r15,%r12), %edi
	callq	_LittleLong
	movq	%rax, 40(%rbx,%r12,2)
	movl	-12(%r15,%r12), %edi
	callq	_LittleLong
	movq	%rax, 32(%rbx,%r12,2)
	movl	-16(%r15,%r12), %edi
	callq	_LittleLong
	movq	%rax, 24(%rbx,%r12,2)
	movl	-20(%r15,%r12), %edi
	callq	_LittleLong
	movq	%rax, 16(%rbx,%r12,2)
	movq	(%rbx,%r12,2), %rax
	cmpq	8(%r13), %rax
	jl	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	incq	%rax
	movq	%rax, 8(%r13)
LBB0_9:                                 ##   in Loop: Header=BB0_7 Depth=1
	movl	8(%rbx,%r12,2), %eax
	movl	16(%r13), %edi
	cmpl	%edi, %eax
	jl	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_7 Depth=1
	incl	%eax
	movl	%eax, 16(%r13)
	movl	%eax, %edi
	jmp	LBB0_11
LBB0_5:
	movl	16(%r13), %edi
LBB0_12:
	movq	_h_high@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	callq	_Hunk_Alloc
	movq	%rax, 32(%r13)
	movl	16(%r13), %edi
	imull	%edi, %edi
	movl	(%rbx), %esi
	callq	_Hunk_Alloc
	movq	%rax, 24(%r13)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_cmod_base,8,3                  ## @cmod_base
	.comm	_ERR_DROP,4,2                   ## @ERR_DROP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"MOD_LoadBmodel: funny lump size"

L_.str.1:                               ## @.str.1
	.asciz	"Map with no leafs"

	.comm	_BOX_LEAFS,4,2                  ## @BOX_LEAFS
	.comm	_h_high,4,2                     ## @h_high
	.comm	_cm,48,3                        ## @cm
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CMod_LoadLeafs                 ; -- Begin function CMod_LoadLeafs
	.p2align	2
_CMod_LoadLeafs:                        ; @CMod_LoadLeafs
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
Lloh0:
	adrp	x8, _cmod_base@GOTPAGE
Lloh1:
	ldr	x8, [x8, _cmod_base@GOTPAGEOFF]
Lloh2:
	ldr	x23, [x8]
	ldr	x24, [x0, #8]
	ldrsw	x8, [x0]
	mov	x20, #-6148914691236517206
	movk	x20, #43691
	mul	x9, x8, x20
	ror	x9, x9, #3
	mov	x10, #-6148914691236517206
	movk	x10, #43691
	movk	x10, #2730, lsl #48
Lloh3:
	adrp	x21, _ERR_DROP@GOTPAGE
Lloh4:
	ldr	x21, [x21, _ERR_DROP@GOTPAGEOFF]
	cmp	x9, x10
	b.lo	LBB0_2
; %bb.1:
	mov	x19, x0
	ldr	w0, [x21]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	bl	_Com_Error
	ldrsw	x8, [x19]
LBB0_2:
	umulh	x8, x8, x20
	lsr	x20, x8, #4
	cmp	w20, #0
	b.gt	LBB0_4
; %bb.3:
	ldr	w0, [x21]
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_Com_Error
LBB0_4:
Lloh9:
	adrp	x8, _BOX_LEAFS@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BOX_LEAFS@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	add	w8, w8, w20
	add	w8, w8, w8, lsl #1
	lsl	w0, w8, #4
Lloh12:
	adrp	x21, _h_high@GOTPAGE
Lloh13:
	ldr	x21, [x21, _h_high@GOTPAGEOFF]
	ldr	w1, [x21]
	bl	_Hunk_Alloc
Lloh14:
	adrp	x22, _cm@GOTPAGE
Lloh15:
	ldr	x22, [x22, _cm@GOTPAGEOFF]
	str	x0, [x22, #40]
	str	w20, [x22]
	cmp	w20, #0
	b.le	LBB0_11
; %bb.5:
	mov	x19, x0
	add	x8, x24, x23
	add	x23, x8, #12
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	x23, x23, #24
	add	x19, x19, #48
	subs	w20, w20, #1
	b.eq	LBB0_12
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x23, #8]
	bl	_LittleLong
	str	x0, [x19]
	ldr	w0, [x23, #4]
	bl	_LittleLong
	str	w0, [x19, #8]
	ldr	w0, [x23]
	bl	_LittleLong
	str	x0, [x19, #40]
	ldur	w0, [x23, #-4]
	bl	_LittleLong
	str	x0, [x19, #32]
	ldur	w0, [x23, #-8]
	bl	_LittleLong
	str	x0, [x19, #24]
	ldur	w0, [x23, #-12]
	bl	_LittleLong
	str	x0, [x19, #16]
	ldr	x8, [x19]
	ldr	x9, [x22, #8]
	cmp	x8, x9
	b.lt	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	add	x8, x8, #1
	str	x8, [x22, #8]
LBB0_9:                                 ;   in Loop: Header=BB0_7 Depth=1
	ldr	w8, [x19, #8]
	ldr	w0, [x22, #16]
	cmp	w8, w0
	b.lt	LBB0_6
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	add	w0, w8, #1
	str	w0, [x22, #16]
	b	LBB0_6
LBB0_11:
	ldr	w0, [x22, #16]
LBB0_12:
	ldr	w1, [x21]
	bl	_Hunk_Alloc
	str	x0, [x22, #32]
	ldr	w8, [x22, #16]
	mul	w0, w8, w8
	ldr	w1, [x21]
	bl	_Hunk_Alloc
	str	x0, [x22, #24]
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_cmod_base,8,3                  ; @cmod_base
	.comm	_ERR_DROP,4,2                   ; @ERR_DROP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"MOD_LoadBmodel: funny lump size"

l_.str.1:                               ; @.str.1
	.asciz	"Map with no leafs"

	.comm	_BOX_LEAFS,4,2                  ; @BOX_LEAFS
	.comm	_h_high,4,2                     ; @h_high
	.comm	_cm,48,3                        ; @cm
.subsections_via_symbols
