	.file	"extr_..managerscheat_manager.c_cheat_manager_apply_cheats.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"%s\n"
	.text
	.p2align 4
	.globl	cheat_manager_apply_cheats
	.type	cheat_manager_apply_cheats, @function
cheat_manager_apply_cheats:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 40
	.cfi_def_cfa_offset 80
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 24[rsp], rax
	xor	eax, eax
	cmp	QWORD PTR cheat_manager_state[rip+8], 0
	je	.L1
	call	core_reset_cheat@PLT
	mov	ecx, DWORD PTR cheat_manager_state[rip]
	test	ecx, ecx
	je	.L1
	xor	ecx, ecx
	lea	r12, cheat_manager_state[rip]
	lea	rbp, 12[rsp]
	xor	ebx, ebx
	.p2align 4,,10
	.p2align 3
.L7:
	mov	eax, ebx
	lea	rdx, [rax+rax*2]
	mov	rax, QWORD PTR cheat_manager_state[rip+8]
	lea	rax, [rax+rdx*8]
	cmp	QWORD PTR 16[rax], 0
	je	.L5
	mov	rsi, QWORD PTR CHEAT_HANDLER_TYPE_EMU[rip]
	cmp	QWORD PTR [rax], rsi
	je	.L15
.L5:
	mov	eax, DWORD PTR [r12]
	add	ebx, 1
	cmp	eax, ebx
	ja	.L7
	test	eax, eax
	jne	.L16
.L1:
	mov	rax, QWORD PTR 24[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L17
	add	rsp, 40
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	mov	edi, DWORD PTR 8[rax]
	mov	DWORD PTR 20[rsp], ecx
	lea	r13d, 1[rcx]
	mov	DWORD PTR 12[rsp], 1
	mov	DWORD PTR 16[rsp], edi
	call	string_is_empty@PLT
	test	eax, eax
	je	.L18
	mov	ecx, r13d
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L16:
	mov	edi, DWORD PTR MSG_APPLYING_CHEAT[rip]
	mov	ebp, DWORD PTR MESSAGE_QUEUE_CATEGORY_INFO[rip]
	mov	ebx, DWORD PTR MESSAGE_QUEUE_ICON_DEFAULT[rip]
	call	msg_hash_to_str@PLT
	sub	rsp, 8
	.cfi_def_cfa_offset 88
	mov	edx, 180
	xor	r8d, r8d
	push	rbp
	.cfi_def_cfa_offset 96
	mov	r9d, ebx
	mov	ecx, 1
	mov	esi, 1
	mov	edi, eax
	call	runloop_msg_queue_push@PLT
	mov	edi, DWORD PTR MSG_APPLYING_CHEAT[rip]
	call	msg_hash_to_str@PLT
	lea	rdi, .LC0[rip]
	mov	esi, eax
	call	RARCH_LOG@PLT
	pop	rax
	.cfi_def_cfa_offset 88
	pop	rdx
	.cfi_def_cfa_offset 80
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L18:
	mov	rdi, rbp
	call	core_set_cheat@PLT
	mov	ecx, r13d
	jmp	.L5
.L17:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	cheat_manager_apply_cheats, .-cheat_manager_apply_cheats
	.comm	cheat_manager_state,16,16
	.comm	MSG_APPLYING_CHEAT,4,4
	.comm	MESSAGE_QUEUE_ICON_DEFAULT,4,4
	.comm	MESSAGE_QUEUE_CATEGORY_INFO,4,4
	.comm	CHEAT_HANDLER_TYPE_EMU,8,8
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_..managerscheat_manager.c_cheat_manager_apply_cheats.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"%s\012\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	cheat_manager_apply_cheats
	.syntax unified
	.arm
	.fpu softvfp
	.type	cheat_manager_apply_cheats, %function
cheat_manager_apply_cheats:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, lr}
	ldr	r3, .L25
	ldr	r6, .L25+4
	sub	sp, sp, #36
	ldr	r3, [r3]
	str	r3, [sp, #28]
	mov	r3,#0
	ldr	r3, [r6, #4]
	cmp	r3, #0
	beq	.L1
	bl	core_reset_cheat
	ldr	r3, [r6]
	cmp	r3, #0
	beq	.L1
	mov	r4, #0
	mov	r7, #1
	mov	ip, r4
	mov	r5, r4
	ldr	r8, .L25+8
.L7:
	ldr	r3, [r6, #4]
	add	r2, r3, r4
	ldr	r1, [r2, #8]
	cmp	r1, #0
	beq	.L5
	ldr	r1, [r3, r4]
	ldr	r3, [r8]
	cmp	r1, r3
	beq	.L21
.L5:
	ldr	r3, [r6]
	add	r5, r5, #1
	cmp	r3, r5
	add	r4, r4, #12
	bhi	.L7
	cmp	r3, #0
	bne	.L22
.L1:
	ldr	r3, .L25
	ldr	r2, [r3]
	ldr	r3, [sp, #28]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L23
	add	sp, sp, #36
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, pc}
.L21:
	ldr	r0, [r2, #4]
	add	r9, ip, #1
	str	ip, [sp, #24]
	str	r0, [sp, #20]
	str	r7, [sp, #16]
	bl	string_is_empty
	cmp	r0, #0
	beq	.L24
	mov	ip, r9
	b	.L5
.L22:
	ldr	r4, .L25+12
	ldr	r0, [r4]
	bl	msg_hash_to_str
	mov	r3, #1
	mov	r2, #0
	ldr	ip, .L25+16
	ldr	r1, .L25+20
	ldr	ip, [ip]
	ldr	r1, [r1]
	str	r2, [sp]
	stmib	sp, {r1, ip}
	mov	r2, #180
	mov	r1, r3
	bl	runloop_msg_queue_push
	ldr	r0, [r4]
	bl	msg_hash_to_str
	mov	r1, r0
	ldr	r0, .L25+24
	bl	RARCH_LOG
	b	.L1
.L24:
	add	r0, sp, #16
	bl	core_set_cheat
	mov	ip, r9
	b	.L5
.L23:
	bl	__stack_chk_fail
.L26:
	.align	2
.L25:
	.word	.LC1
	.word	cheat_manager_state
	.word	CHEAT_HANDLER_TYPE_EMU
	.word	MSG_APPLYING_CHEAT
	.word	MESSAGE_QUEUE_CATEGORY_INFO
	.word	MESSAGE_QUEUE_ICON_DEFAULT
	.word	.LC0
	.size	cheat_manager_apply_cheats, .-cheat_manager_apply_cheats
	.comm	cheat_manager_state,8,4
	.comm	MSG_APPLYING_CHEAT,4,4
	.comm	MESSAGE_QUEUE_ICON_DEFAULT,4,4
	.comm	MESSAGE_QUEUE_CATEGORY_INFO,4,4
	.comm	CHEAT_HANDLER_TYPE_EMU,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
