	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_AAS_Optimize                   ## -- Begin function AAS_Optimize
	.p2align	4, 0x90
_AAS_Optimize:                          ## @AAS_Optimize
	.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
	leaq	-56(%rbp), %rdi
	callq	_AAS_OptimizeAlloc
	movq	_aasworld@GOTPCREL(%rip), %r15
	cmpl	$2, (%r15)
	jl	LBB0_3
## %bb.1:
	movl	$1, %ebx
	leaq	-56(%rbp), %r14
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_AAS_OptimizeArea
	incl	%ebx
	cmpl	(%r15), %ebx
	jl	LBB0_2
LBB0_3:
	cmpl	$0, 4(%r15)
	jle	LBB0_12
## %bb.4:
	movq	8(%r15), %rax
	xorl	%ebx, %ebx
	movq	_TRAVELTYPE_MASK@GOTPCREL(%rip), %rdx
	movq	_TRAVEL_ELEVATOR@GOTPCREL(%rip), %rsi
	xorl	%r12d, %r12d
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_5 Depth=1
	movq	_TRAVELTYPE_MASK@GOTPCREL(%rip), %rdx
	movq	_TRAVEL_ELEVATOR@GOTPCREL(%rip), %rsi
LBB0_11:                                ##   in Loop: Header=BB0_5 Depth=1
	incq	%r12
	movslq	4(%r15), %rcx
	addq	$12, %rbx
	cmpq	%rcx, %r12
	jge	LBB0_12
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rdx), %ecx
	andl	(%rax,%rbx), %ecx
	cmpl	(%rsi), %ecx
	je	LBB0_11
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	_TRAVEL_JUMPPAD@GOTPCREL(%rip), %rdi
	cmpl	(%rdi), %ecx
	je	LBB0_11
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	_TRAVEL_FUNCBOB@GOTPCREL(%rip), %rdi
	cmpl	(%rdi), %ecx
	je	LBB0_11
## %bb.8:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	4(%rax,%rbx), %r14d
	movq	-56(%rbp), %r13
	movl	%r14d, %edi
	callq	_abs
	movl	(%r13,%rax,4), %eax
	movl	%eax, %ecx
	negl	%ecx
	testl	%r14d, %r14d
	cmovnsl	%eax, %ecx
	movq	8(%r15), %rax
	movl	%ecx, 4(%rax,%rbx)
	movl	8(%rax,%rbx), %r14d
	movq	-48(%rbp), %r13
	movl	%r14d, %edi
	callq	_abs
	movl	(%r13,%rax,4), %ecx
	movq	8(%r15), %rax
	movl	%ecx, 8(%rax,%rbx)
	testl	%r14d, %r14d
	jns	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_5 Depth=1
	negl	%ecx
	movl	%ecx, 8(%rax,%rbx)
	jmp	LBB0_10
LBB0_12:
	leaq	-56(%rbp), %rdi
	callq	_AAS_OptimizeStore
	movq	_botimport@GOTPCREL(%rip), %rax
	movq	_PRT_MESSAGE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	leaq	L_.str(%rip), %rsi
	callq	*(%rax)
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_aasworld,16,3                  ## @aasworld
	.comm	_TRAVELTYPE_MASK,4,2            ## @TRAVELTYPE_MASK
	.comm	_TRAVEL_ELEVATOR,4,2            ## @TRAVEL_ELEVATOR
	.comm	_TRAVEL_JUMPPAD,4,2             ## @TRAVEL_JUMPPAD
	.comm	_TRAVEL_FUNCBOB,4,2             ## @TRAVEL_FUNCBOB
	.comm	_botimport,8,3                  ## @botimport
	.comm	_PRT_MESSAGE,4,2                ## @PRT_MESSAGE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"AAS data optimized.\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_AAS_Optimize                   ; -- Begin function AAS_Optimize
	.p2align	2
_AAS_Optimize:                          ; @AAS_Optimize
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x0, sp
	bl	_AAS_OptimizeAlloc
Lloh0:
	adrp	x20, _aasworld@GOTPAGE
Lloh1:
	ldr	x20, [x20, _aasworld@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, #1
	b.le	LBB0_3
; %bb.1:
	mov	w19, #1
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, sp
	mov	x1, x19
	bl	_AAS_OptimizeArea
	add	w19, w19, #1
	ldr	w8, [x20]
	cmp	w19, w8
	b.lt	LBB0_2
LBB0_3:
	ldr	w8, [x20, #4]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.4:
	mov	x21, #0
	mov	x22, #0
	ldr	x8, [x20, #8]
Lloh2:
	adrp	x23, _TRAVELTYPE_MASK@GOTPAGE
Lloh3:
	ldr	x23, [x23, _TRAVELTYPE_MASK@GOTPAGEOFF]
Lloh4:
	adrp	x24, _TRAVEL_ELEVATOR@GOTPAGE
Lloh5:
	ldr	x24, [x24, _TRAVEL_ELEVATOR@GOTPAGEOFF]
Lloh6:
	adrp	x25, _TRAVEL_JUMPPAD@GOTPAGE
Lloh7:
	ldr	x25, [x25, _TRAVEL_JUMPPAD@GOTPAGEOFF]
Lloh8:
	adrp	x26, _TRAVEL_FUNCBOB@GOTPAGE
Lloh9:
	ldr	x26, [x26, _TRAVEL_FUNCBOB@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x22, x22, #1
	ldrsw	x9, [x20, #4]
	add	x21, x21, #12
	cmp	x22, x9
	b.ge	LBB0_9
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w9, [x8, x21]
	ldr	w10, [x23]
	and	w9, w10, w9
	ldr	w10, [x24]
	ldr	w11, [x25]
	ldr	w12, [x26]
	cmp	w9, w10
	ccmp	w9, w11, #4, ne
	ccmp	w9, w12, #4, ne
	b.eq	LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	add	x8, x8, x21
	ldr	w19, [x8, #4]
	ldr	x27, [sp]
	mov	x0, x19
	bl	_abs
	ldr	w8, [x27, x0, lsl #2]
	ldr	x9, [x20, #8]
	add	x9, x9, x21
	cmp	w19, #0
	cneg	w8, w8, lt
	str	w8, [x9, #4]
	ldr	w19, [x9, #8]
	ldr	x27, [sp, #8]
	mov	x0, x19
	bl	_abs
	ldr	w9, [x27, x0, lsl #2]
	ldr	x8, [x20, #8]
	add	x10, x8, x21
	str	w9, [x10, #8]
	tbz	w19, #31, LBB0_5
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	neg	w9, w9
	str	w9, [x10, #8]
	b	LBB0_5
LBB0_9:
	mov	x0, sp
	bl	_AAS_OptimizeStore
Lloh10:
	adrp	x8, _botimport@GOTPAGE
Lloh11:
	ldr	x8, [x8, _botimport@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
Lloh13:
	adrp	x9, _PRT_MESSAGE@GOTPAGE
Lloh14:
	ldr	x9, [x9, _PRT_MESSAGE@GOTPAGEOFF]
Lloh15:
	ldr	w0, [x9]
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
	blr	x8
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_aasworld,16,3                  ; @aasworld
	.comm	_TRAVELTYPE_MASK,4,2            ; @TRAVELTYPE_MASK
	.comm	_TRAVEL_ELEVATOR,4,2            ; @TRAVEL_ELEVATOR
	.comm	_TRAVEL_JUMPPAD,4,2             ; @TRAVEL_JUMPPAD
	.comm	_TRAVEL_FUNCBOB,4,2             ; @TRAVEL_FUNCBOB
	.comm	_botimport,8,3                  ; @botimport
	.comm	_PRT_MESSAGE,4,2                ; @PRT_MESSAGE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"AAS data optimized.\n"

.subsections_via_symbols
