	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function command_event_save_config
_command_event_save_config:             ## @command_event_save_config
	.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	%rdx, %r12
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_PATH_MAX_LENGTH@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	%r13, %rax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, %r15
	movq	%rbx, %rdi
	callq	_string_is_empty
	testl	%eax, %eax
	je	LBB0_2
## %bb.1:
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movq	_RARCH_PATH_CONFIG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_path_get
	movq	%rax, %rbx
LBB0_4:
	movq	%rbx, %rdi
	callq	_string_is_empty
	xorl	%r12d, %r12d
	testl	%eax, %eax
	jne	LBB0_6
## %bb.5:
	movq	_MSG_FAILED_SAVING_CONFIG_TO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_msg_hash_to_str
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movq	%rax, %rcx
	movq	%rbx, %r8
	callq	_snprintf
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	movl	%r13d, %edx
	callq	_strlcpy
	movq	%r15, %rdi
	movq	%r14, %rsi
	movl	%r13d, %edx
	callq	_strlcat
	leaq	L_.str.2(%rip), %rdi
	movq	%r15, %rsi
	callq	_RARCH_ERR
	jmp	LBB0_6
LBB0_2:
	movq	%rbx, %rdi
	callq	_config_save_file
	testq	%rax, %rax
	je	LBB0_3
## %bb.8:
	movq	_MSG_SAVED_NEW_CONFIG_TO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_msg_hash_to_str
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	movq	%r12, %rsi
	movq	%rax, %rcx
	movq	%rbx, %r8
	callq	_snprintf
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	movl	%r13d, %edx
	callq	_strlcpy
	movq	%r15, %rdi
	movq	%r14, %rsi
	movl	%r13d, %edx
	callq	_strlcat
	leaq	L_.str.2(%rip), %rdi
	movq	%r15, %rsi
	callq	_RARCH_LOG
	movl	$1, %r12d
LBB0_6:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_9
## %bb.7:
	movl	%r12d, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_4
LBB0_9:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_PATH_MAX_LENGTH,4,2            ## @PATH_MAX_LENGTH
	.comm	_RARCH_PATH_CONFIG,4,2          ## @RARCH_PATH_CONFIG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s \"%s\"."

	.comm	_MSG_SAVED_NEW_CONFIG_TO,4,2    ## @MSG_SAVED_NEW_CONFIG_TO
L_.str.1:                               ## @.str.1
	.asciz	"[config] "

L_.str.2:                               ## @.str.2
	.asciz	"%s\n"

	.comm	_MSG_FAILED_SAVING_CONFIG_TO,4,2 ## @MSG_FAILED_SAVING_CONFIG_TO
	.no_dead_strip	_command_event_save_config
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function command_event_save_config
_command_event_save_config:             ; @command_event_save_config
	.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
	sub	sp, sp, #16
	mov	x22, x2
	mov	x20, x1
	mov	x23, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
Lloh3:
	adrp	x8, _PATH_MAX_LENGTH@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PATH_MAX_LENGTH@GOTPAGEOFF]
Lloh5:
	ldr	w21, [x8]
	mov	x9, x21
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x21, #15
	and	x9, x9, #0x1fffffff0
	sub	x19, x8, x9
	mov	sp, x19
	bl	_string_is_empty
	cbz	w0, LBB0_5
; %bb.1:
Lloh8:
	adrp	x8, _RARCH_PATH_CONFIG@GOTPAGE
Lloh9:
	ldr	x8, [x8, _RARCH_PATH_CONFIG@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	bl	_path_get
	mov	x23, x0
LBB0_2:
	mov	x0, x23
	bl	_string_is_empty
	cbnz	w0, LBB0_4
; %bb.3:
Lloh11:
	adrp	x8, _MSG_FAILED_SAVING_CONFIG_TO@GOTPAGE
Lloh12:
	ldr	x8, [x8, _MSG_FAILED_SAVING_CONFIG_TO@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	bl	_msg_hash_to_str
	mov	x3, x0
Lloh14:
	adrp	x2, l_.str@PAGE
Lloh15:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x20
	mov	x1, x22
	mov	x4, x23
	bl	_snprintf
Lloh16:
	adrp	x1, l_.str.1@PAGE
Lloh17:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x2, x21
	bl	_strlcpy
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	bl	_strlcat
Lloh18:
	adrp	x0, l_.str.2@PAGE
Lloh19:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x19
	bl	_RARCH_ERR
LBB0_4:
	mov	w0, #0
	b	LBB0_7
LBB0_5:
	mov	x0, x23
	bl	_config_save_file
	cbz	x0, LBB0_2
; %bb.6:
Lloh20:
	adrp	x8, _MSG_SAVED_NEW_CONFIG_TO@GOTPAGE
Lloh21:
	ldr	x8, [x8, _MSG_SAVED_NEW_CONFIG_TO@GOTPAGEOFF]
Lloh22:
	ldr	w0, [x8]
	bl	_msg_hash_to_str
	mov	x3, x0
Lloh23:
	adrp	x2, l_.str@PAGE
Lloh24:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x20
	mov	x1, x22
	mov	x4, x23
	bl	_snprintf
Lloh25:
	adrp	x1, l_.str.1@PAGE
Lloh26:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x2, x21
	bl	_strlcpy
	mov	x0, x19
	mov	x1, x20
	mov	x2, x21
	bl	_strlcat
Lloh27:
	adrp	x0, l_.str.2@PAGE
Lloh28:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x19
	bl	_RARCH_LOG
	mov	w0, #1
LBB0_7:
	ldur	x8, [x29, #-56]
Lloh29:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh30:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh31:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_9
; %bb.8:
	sub	sp, x29, #48
	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
LBB0_9:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_PATH_MAX_LENGTH,4,2            ; @PATH_MAX_LENGTH
	.comm	_RARCH_PATH_CONFIG,4,2          ; @RARCH_PATH_CONFIG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s \"%s\"."

	.comm	_MSG_SAVED_NEW_CONFIG_TO,4,2    ; @MSG_SAVED_NEW_CONFIG_TO
l_.str.1:                               ; @.str.1
	.asciz	"[config] "

l_.str.2:                               ; @.str.2
	.asciz	"%s\n"

	.comm	_MSG_FAILED_SAVING_CONFIG_TO,4,2 ; @MSG_FAILED_SAVING_CONFIG_TO
	.no_dead_strip	_command_event_save_config
.subsections_via_symbols
