	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CMod_LoadSubmodels             ## -- Begin function CMod_LoadSubmodels
	.p2align	4, 0x90
_CMod_LoadSubmodels:                    ## @CMod_LoadSubmodels
	.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	$24, %rsp
	.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), %r14
	addq	(%rax), %r14
	movl	(%rdi), %r15d
	testb	$31, %r15b
	je	LBB0_2
## %bb.1:
	movq	%rdi, %rbx
	movq	_ERR_DROP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_Com_Error
	movl	(%rbx), %r15d
LBB0_2:
	movl	%r15d, %ebx
	sarl	$5, %ebx
	cmpl	$31, %r15d
	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:
	movl	%ebx, %eax
	shll	$4, %eax
	leal	(%rax,%rax,2), %edi
	movq	_h_high@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	callq	_Hunk_Alloc
	movq	_cm@GOTPCREL(%rip), %rcx
	movq	%rax, 16(%rcx)
	movl	%ebx, (%rcx)
	movq	_MAX_SUBMODELS@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jle	LBB0_6
## %bb.5:
	movq	_ERR_DROP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	callq	_Com_Error
LBB0_6:
	cmpl	$32, %r15d
	jl	LBB0_16
## %bb.7:
	cmpl	$2, %ebx
	movl	$1, %eax
	cmovgel	%ebx, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_8 Depth=1
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	incq	%rbx
	addq	$32, %r14
	cmpq	-56(%rbp), %rbx                 ## 8-byte Folded Reload
	je	LBB0_16
LBB0_8:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_11 Depth 2
                                        ##     Child Loop BB0_14 Depth 2
	movq	_cm@GOTPCREL(%rip), %rax
	movq	16(%rax), %r15
	leaq	(%rbx,%rbx,2), %r12
	shlq	$4, %r12
	movq	24(%r14), %rax
	movl	(%rax), %edi
	callq	_LittleFloat
	decq	%rax
	movq	40(%r15,%r12), %rcx
	movq	%rax, (%rcx)
	movq	16(%r14), %rax
	movl	(%rax), %edi
	callq	_LittleFloat
	incq	%rax
	movq	32(%r15,%r12), %rcx
	movq	%rax, (%rcx)
	movq	24(%r14), %rax
	movl	4(%rax), %edi
	callq	_LittleFloat
	decq	%rax
	movq	40(%r15,%r12), %rcx
	movq	%rax, 8(%rcx)
	movq	16(%r14), %rax
	movl	4(%rax), %edi
	callq	_LittleFloat
	incq	%rax
	movq	32(%r15,%r12), %rcx
	movq	%rax, 8(%rcx)
	movq	24(%r14), %rax
	movl	8(%rax), %edi
	callq	_LittleFloat
	decq	%rax
	movq	40(%r15,%r12), %rcx
	movq	%rax, 16(%rcx)
	movq	16(%r14), %rax
	movl	8(%rax), %edi
	callq	_LittleFloat
	incq	%rax
	movq	32(%r15,%r12), %rcx
	movq	%rax, 16(%rcx)
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	testq	%rbx, %rbx
	je	LBB0_15
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	movl	12(%r14), %edi
	callq	_LittleLong
                                        ## kill: def $eax killed $eax def $rax
	movl	%eax, (%r15,%r12)
	leal	(,%rax,4), %edi
	movl	(%r13), %esi
	callq	_Hunk_Alloc
	movq	%rax, %rbx
	movq	_cm@GOTPCREL(%rip), %rax
	movslq	4(%rax), %rax
	shlq	$2, %rax
	movq	%rbx, %rcx
	subq	%rax, %rcx
	movq	%rcx, 8(%r15,%r12)
	movq	%r15, -48(%rbp)                 ## 8-byte Spill
	cmpl	$0, (%r15,%r12)
	jle	LBB0_12
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=1
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	leaq	(%rax,%r12), %r15
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_11:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	8(%r14), %edi
	callq	_LittleLong
	addl	%r13d, %eax
	movl	%eax, (%rbx,%r13,4)
	incq	%r13
	movslq	(%r15), %rax
	cmpq	%rax, %r13
	jl	LBB0_11
LBB0_12:                                ##   in Loop: Header=BB0_8 Depth=1
	movl	4(%r14), %edi
	callq	_LittleLong
                                        ## kill: def $eax killed $eax def $rax
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movl	%eax, 16(%rbx,%r12)
	leal	(,%rax,4), %edi
	movq	_h_high@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	callq	_Hunk_Alloc
	movq	%rax, %r15
	movq	_cm@GOTPCREL(%rip), %rax
	movslq	8(%rax), %rax
	shlq	$2, %rax
	movq	%r15, %rcx
	subq	%rax, %rcx
	movq	%rcx, 24(%rbx,%r12)
	cmpl	$0, 16(%rbx,%r12)
	jle	LBB0_15
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=1
	addq	%rbx, %r12
	addq	$16, %r12
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_14:                                ##   Parent Loop BB0_8 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r14), %edi
	callq	_LittleLong
	addl	%ebx, %eax
	movl	%eax, (%r15,%rbx,4)
	incq	%rbx
	movslq	(%r12), %rax
	cmpq	%rax, %rbx
	jl	LBB0_14
	jmp	LBB0_15
LBB0_16:
	addq	$24, %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	"CMod_LoadSubmodels: funny lump size"

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

	.comm	_h_high,4,2                     ## @h_high
	.comm	_cm,24,3                        ## @cm
	.comm	_MAX_SUBMODELS,4,2              ## @MAX_SUBMODELS
L_.str.2:                               ## @.str.2
	.asciz	"MAX_SUBMODELS exceeded"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CMod_LoadSubmodels             ; -- Begin function CMod_LoadSubmodels
	.p2align	2
_CMod_LoadSubmodels:                    ; @CMod_LoadSubmodels
	.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
Lloh0:
	adrp	x8, _cmod_base@GOTPAGE
Lloh1:
	ldr	x8, [x8, _cmod_base@GOTPAGEOFF]
Lloh2:
	ldr	x23, [x8]
	ldr	x24, [x0, #8]
	ldr	w22, [x0]
Lloh3:
	adrp	x25, _ERR_DROP@GOTPAGE
Lloh4:
	ldr	x25, [x25, _ERR_DROP@GOTPAGEOFF]
	tst	w22, #0x1f
	b.eq	LBB0_2
; %bb.1:
	mov	x19, x0
	ldr	w0, [x25]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	bl	_Com_Error
	ldr	w22, [x19]
LBB0_2:
	asr	w19, w22, #5
	cmp	w22, #31
	b.gt	LBB0_4
; %bb.3:
	ldr	w0, [x25]
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_Com_Error
LBB0_4:
	add	w8, w19, w19, lsl #1
	lsl	w0, w8, #4
Lloh9:
	adrp	x20, _h_high@GOTPAGE
Lloh10:
	ldr	x20, [x20, _h_high@GOTPAGEOFF]
	ldr	w1, [x20]
	bl	_Hunk_Alloc
Lloh11:
	adrp	x21, _cm@GOTPAGE
Lloh12:
	ldr	x21, [x21, _cm@GOTPAGEOFF]
	str	x0, [x21, #16]
	str	w19, [x21]
Lloh13:
	adrp	x8, _MAX_SUBMODELS@GOTPAGE
Lloh14:
	ldr	x8, [x8, _MAX_SUBMODELS@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	cmp	w19, w8
	b.le	LBB0_6
; %bb.5:
	ldr	w0, [x25]
Lloh16:
	adrp	x1, l_.str.2@PAGE
Lloh17:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_Com_Error
LBB0_6:
	cmp	w22, #32
	b.lt	LBB0_16
; %bb.7:
	mov	x22, #0
	add	x23, x24, x23
	cmp	w19, #1
	csinc	w24, w19, wzr, gt
	mov	w25, #48
	b	LBB0_9
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	add	x22, x22, #1
	add	x23, x23, #32
	cmp	x22, x24
	b.eq	LBB0_16
LBB0_9:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_12 Depth 2
                                        ;     Child Loop BB0_15 Depth 2
	ldr	x26, [x21, #16]
	madd	x19, x22, x25, x26
	ldr	x8, [x23, #24]
	ldr	w0, [x8]
	bl	_LittleFloat
	sub	x8, x0, #1
	ldr	x9, [x19, #40]
	str	x8, [x9]
	ldr	x8, [x23, #16]
	ldr	w0, [x8]
	bl	_LittleFloat
	add	x8, x0, #1
	ldr	x9, [x19, #32]
	str	x8, [x9]
	ldr	x8, [x23, #24]
	ldr	w0, [x8, #4]
	bl	_LittleFloat
	sub	x8, x0, #1
	ldr	x9, [x19, #40]
	str	x8, [x9, #8]
	ldr	x8, [x23, #16]
	ldr	w0, [x8, #4]
	bl	_LittleFloat
	add	x8, x0, #1
	ldr	x9, [x19, #32]
	str	x8, [x9, #8]
	ldr	x8, [x23, #24]
	ldr	w0, [x8, #8]
	bl	_LittleFloat
	sub	x8, x0, #1
	ldr	x9, [x19, #40]
	str	x8, [x9, #16]
	ldr	x8, [x23, #16]
	ldr	w0, [x8, #8]
	bl	_LittleFloat
	add	x8, x0, #1
	ldr	x9, [x19, #32]
	str	x8, [x9, #16]
	cbz	x22, LBB0_8
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	w0, [x23, #12]
	bl	_LittleLong
	madd	x27, x22, x25, x26
	str	w0, [x27]
	lsl	w0, w0, #2
	ldr	w1, [x20]
	bl	_Hunk_Alloc
	ldrsw	x8, [x21, #4]
	sub	x8, x0, x8, lsl #2
	str	x8, [x27, #8]
	ldr	w8, [x27]
	cmp	w8, #1
	b.lt	LBB0_13
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x19, x0
	mov	x28, #0
LBB0_12:                                ;   Parent Loop BB0_9 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w0, [x23, #8]
	bl	_LittleLong
	add	w8, w28, w0
	str	w8, [x19, x28, lsl #2]
	add	x28, x28, #1
	ldrsw	x8, [x27]
	cmp	x28, x8
	b.lt	LBB0_12
LBB0_13:                                ;   in Loop: Header=BB0_9 Depth=1
	ldr	w0, [x23, #4]
	bl	_LittleLong
	mul	x8, x22, x25
	add	x26, x26, x8
	str	w0, [x26, #16]!
	lsl	w0, w0, #2
	ldr	w1, [x20]
	bl	_Hunk_Alloc
	ldrsw	x8, [x21, #8]
	sub	x8, x0, x8, lsl #2
	str	x8, [x26, #8]
	ldr	w8, [x26]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.14:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	x19, x0
	mov	x27, #0
LBB0_15:                                ;   Parent Loop BB0_9 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w0, [x23]
	bl	_LittleLong
	add	w8, w27, w0
	str	w8, [x19, x27, lsl #2]
	add	x27, x27, #1
	ldrsw	x8, [x26]
	cmp	x27, x8
	b.lt	LBB0_15
	b	LBB0_8
LBB0_16:
	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
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh16, Lloh17
	.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	"CMod_LoadSubmodels: funny lump size"

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

	.comm	_h_high,4,2                     ; @h_high
	.comm	_cm,24,3                        ; @cm
	.comm	_MAX_SUBMODELS,4,2              ; @MAX_SUBMODELS
l_.str.2:                               ; @.str.2
	.asciz	"MAX_SUBMODELS exceeded"

.subsections_via_symbols
