	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CheatAddCode                   ## -- Begin function CheatAddCode
	.p2align	4, 0x90
_CheatAddCode:                          ## @CheatAddCode
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_cheatlist@GOTPCREL(%rip), %r12
	movq	(%r12), %rax
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	_numcheats@GOTPCREL(%rip), %r14
	movq	(%r14), %rbx
	movq	%rbx, %rcx
	shlq	$5, %rcx
	movl	%edi, (%rax,%rcx)
	movq	%rsi, 24(%rax,%rcx)
	movq	(%r12), %rax
	movq	%rdx, 16(%rax,%rcx)
	movq	(%r12), %rax
	movq	$0, 8(%rax,%rcx)
	movq	(%r12), %rax
	movl	$1, 4(%rax,%rcx)
	incq	%rbx
	movq	%rbx, (%r14)
	movq	_cheatsize@GOTPCREL(%rip), %r15
	movq	(%r15), %rsi
	cmpq	%rsi, %rbx
	jb	LBB0_4
## %bb.3:
	shll	$3, %esi
	movq	%rax, %rdi
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_realloc
	shlq	(%r15)
	movq	%rax, (%r12)
	movq	(%r14), %rbx
LBB0_4:
	movq	_CHEATTYPE_NONE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	shlq	$5, %rbx
	movl	%ecx, (%rax,%rbx)
	xorl	%eax, %eax
	jmp	LBB0_5
LBB0_1:
	movl	$-1, %eax
LBB0_5:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_cheatlist,8,3                  ## @cheatlist
	.comm	_numcheats,8,3                  ## @numcheats
	.comm	_cheatsize,8,3                  ## @cheatsize
	.comm	_CHEATTYPE_NONE,4,2             ## @CHEATTYPE_NONE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_CheatAddCode                   ; -- Begin function CheatAddCode
	.p2align	2
_CheatAddCode:                          ; @CheatAddCode
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
Lloh0:
	adrp	x19, _cheatlist@GOTPAGE
Lloh1:
	ldr	x19, [x19, _cheatlist@GOTPAGEOFF]
	ldr	x8, [x19]
	cbz	x8, LBB0_4
; %bb.1:
Lloh2:
	adrp	x20, _numcheats@GOTPAGE
Lloh3:
	ldr	x20, [x20, _numcheats@GOTPAGEOFF]
	ldr	x9, [x20]
	lsl	x10, x9, #5
	add	x8, x8, x10
	str	w0, [x8]
	str	x1, [x8, #24]
	ldr	x8, [x19]
	add	x8, x8, x10
	str	x2, [x8, #16]
	ldr	x8, [x19]
	add	x8, x8, x10
	str	xzr, [x8, #8]
	ldr	x0, [x19]
	add	x8, x0, x10
	mov	w10, #1
	str	w10, [x8, #4]
	add	x9, x9, #1
	str	x9, [x20]
Lloh4:
	adrp	x21, _cheatsize@GOTPAGE
Lloh5:
	ldr	x21, [x21, _cheatsize@GOTPAGEOFF]
	ldr	x8, [x21]
	cmp	x9, x8
	b.lo	LBB0_3
; %bb.2:
	lsl	w1, w8, #3
	bl	_realloc
	str	x0, [x19]
	ldr	x8, [x21]
	lsl	x8, x8, #1
	str	x8, [x21]
	ldr	x9, [x20]
LBB0_3:
	mov	w8, #0
Lloh6:
	adrp	x10, _CHEATTYPE_NONE@GOTPAGE
Lloh7:
	ldr	x10, [x10, _CHEATTYPE_NONE@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	lsl	x9, x9, #5
	str	w10, [x0, x9]
	b	LBB0_5
LBB0_4:
	mov	w8, #-1
LBB0_5:
	mov	x0, x8
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_cheatlist,8,3                  ; @cheatlist
	.comm	_numcheats,8,3                  ; @numcheats
	.comm	_cheatsize,8,3                  ; @cheatsize
	.comm	_CHEATTYPE_NONE,4,2             ; @CHEATTYPE_NONE
.subsections_via_symbols
