	.file	"extr_..retroarch.c_path_set_special.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	" + "
.LC1:
	.string	".state"
.LC2:
	.string	"%s \"%s\".\n"
	.text
	.p2align 4
	.globl	path_set_special
	.type	path_set_special, @function
path_set_special:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	r15
	.cfi_offset 15, -24
	mov	r15d, esi
	push	r14
	push	r13
	push	r12
	push	rbx
	.cfi_offset 14, -32
	.cfi_offset 13, -40
	.cfi_offset 12, -48
	.cfi_offset 3, -56
	mov	rbx, rdi
	sub	rsp, 24
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -56[rbp], rax
	xor	eax, eax
	movsx	rax, DWORD PTR PATH_MAX_LENGTH[rip]
	mov	rcx, rsp
	mov	r14, rax
	add	rax, 15
	mov	rdx, rax
	and	rax, -4096
	sub	rcx, rax
	and	rdx, -16
	mov	rax, rcx
	cmp	rsp, rax
	je	.L3
.L29:
	sub	rsp, 4096
	or	QWORD PTR 4088[rsp], 0
	cmp	rsp, rax
	jne	.L29
.L3:
	and	edx, 4095
	sub	rsp, rdx
	test	rdx, rdx
	jne	.L30
.L4:
	mov	rdi, QWORD PTR [rbx]
	mov	r12, rsp
	call	path_set_basename@PLT
	xor	eax, eax
	call	string_list_new@PLT
	mov	QWORD PTR subsystem_fullpaths[rip], rax
	xor	eax, eax
	call	string_list_new@PLT
	mov	rdi, QWORD PTR subsystem_fullpaths[rip]
	mov	r13, rax
	call	retro_assert@PLT
	test	r15d, r15d
	je	.L5
	lea	eax, -1[r15]
	lea	r15, 8[rbx+rax*8]
	.p2align 4,,10
	.p2align 3
.L6:
	mov	rsi, QWORD PTR [rbx]
	mov	rdi, QWORD PTR subsystem_fullpaths[rip]
	xor	edx, edx
	add	rbx, 8
	call	string_list_append@PLT
	mov	rsi, QWORD PTR -8[rbx]
	mov	edx, r14d
	mov	rdi, r12
	call	strlcpy@PLT
	mov	rdi, r12
	call	path_remove_extension@PLT
	mov	rdi, r12
	call	path_basename@PLT
	xor	edx, edx
	mov	rdi, r13
	mov	rsi, rax
	call	string_list_append@PLT
	cmp	rbx, r15
	jne	.L6
.L5:
	mov	BYTE PTR [r12], 0
	mov	rdx, r13
	mov	esi, r14d
	mov	rdi, r12
	lea	rcx, .LC0[rip]
	call	string_list_join_concat@PLT
	mov	edi, DWORD PTR RARCH_DIR_CURRENT_SAVESTATE[rip]
	call	dir_get@PLT
	mov	rdi, rax
	call	path_is_directory@PLT
	test	rax, rax
	jne	.L31
.L7:
	mov	rdi, QWORD PTR g_extern[rip]
	call	path_is_directory@PLT
	test	rax, rax
	jne	.L32
.L8:
	test	r13, r13
	je	.L1
	mov	rdi, r13
	call	string_list_free@PLT
.L1:
	mov	rax, QWORD PTR -56[rbp]
	xor	rax, QWORD PTR fs:40
	jne	.L33
	lea	rsp, -40[rbp]
	pop	rbx
	pop	r12
	pop	r13
	pop	r14
	pop	r15
	pop	rbp
	.cfi_remember_state
	.cfi_def_cfa 7, 8
	ret
	.p2align 4,,10
	.p2align 3
.L32:
	.cfi_restore_state
	mov	rdi, QWORD PTR g_extern[rip]
	mov	rsi, r12
	mov	ecx, 8
	lea	rdx, .LC1[rip]
	call	fill_pathname_dir@PLT
	mov	edi, DWORD PTR MSG_REDIRECTING_SAVESTATE_TO[rip]
	mov	r12, QWORD PTR g_extern[rip]
	call	msg_hash_to_str@PLT
	mov	rdx, r12
	lea	rdi, .LC2[rip]
	mov	esi, eax
	call	RARCH_LOG@PLT
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L31:
	mov	edi, DWORD PTR RARCH_DIR_CURRENT_SAVESTATE[rip]
	call	dir_get@PLT
	mov	rdi, QWORD PTR g_extern[rip]
	mov	edx, 8
	mov	rsi, rax
	call	strlcpy@PLT
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L30:
	or	QWORD PTR -8[rsp+rdx], 0
	jmp	.L4
.L33:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	path_set_special, .-path_set_special
	.comm	subsystem_fullpaths,8,8
	.comm	g_extern,8,8
	.comm	RARCH_DIR_CURRENT_SAVESTATE,4,4
	.comm	PATH_MAX_LENGTH,4,4
	.comm	MSG_REDIRECTING_SAVESTATE_TO,4,4
	.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_..retroarch.c_path_set_special.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	" + \000"
	.align	2
.LC1:
	.ascii	".state\000"
	.align	2
.LC2:
	.ascii	"%s \"%s\".\012\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	path_set_special
	.syntax unified
	.arm
	.fpu softvfp
	.type	path_set_special, %function
path_set_special:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, fp, lr}
	add	fp, sp, #28
	sub	sp, sp, #8
	ldr	r3, .L25
	mov	r4, r0
	ldr	r8, [r3]
	ldr	r0, [r0]
	add	r3, r8, #7
	bic	r3, r3, #7
	sub	sp, sp, r3
	ldr	r3, .L25+4
	mov	r6, r1
	ldr	r3, [r3]
	str	r3, [fp, #-32]
	mov	r3,#0
	bl	path_set_basename
	bl	string_list_new
	ldr	r9, .L25+8
	mov	r5, sp
	str	r0, [r9]
	bl	string_list_new
	mov	r7, r0
	ldr	r0, [r9]
	bl	retro_assert
	cmp	r6, #0
	beq	.L2
	add	r6, r4, r6, lsl #2
	sub	r6, r6, #4
	sub	r4, r4, #4
.L3:
	ldr	r1, [r4, #4]!
	mov	r2, #0
	ldr	r0, [r9]
	bl	string_list_append
	mov	r2, r8
	ldr	r1, [r4]
	mov	r0, r5
	bl	strlcpy
	mov	r0, r5
	bl	path_remove_extension
	mov	r0, r5
	bl	path_basename
	mov	r2, #0
	mov	r1, r0
	mov	r0, r7
	bl	string_list_append
	cmp	r4, r6
	bne	.L3
.L2:
	mov	r0, #0
	ldr	r6, .L25+12
	mov	r1, r8
	mov	r2, r7
	ldr	r3, .L25+16
	strb	r0, [r5]
	mov	r0, r5
	bl	string_list_join_concat
	ldr	r0, [r6]
	bl	dir_get
	bl	path_is_directory
	cmp	r0, #0
	ldr	r4, .L25+20
	bne	.L20
	ldr	r0, [r4]
	bl	path_is_directory
	cmp	r0, #0
	bne	.L23
.L5:
	cmp	r7, #0
	beq	.L1
	mov	r0, r7
	bl	string_list_free
.L1:
	ldr	r3, .L25+4
	ldr	r2, [r3]
	ldr	r3, [fp, #-32]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L24
	sub	sp, fp, #28
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, fp, pc}
.L20:
	ldr	r0, [r6]
	ldr	r6, [r4]
	bl	dir_get
	mov	r2, #4
	mov	r1, r0
	mov	r0, r6
	bl	strlcpy
	ldr	r0, [r4]
	bl	path_is_directory
	cmp	r0, #0
	beq	.L5
.L23:
	mov	r1, r5
	ldr	r2, .L25+24
	mov	r3, #4
	ldr	r0, [r4]
	bl	fill_pathname_dir
	ldr	r3, .L25+28
	ldr	r0, [r3]
	bl	msg_hash_to_str
	ldr	r2, [r4]
	mov	r1, r0
	ldr	r0, .L25+32
	bl	RARCH_LOG
	b	.L5
.L24:
	bl	__stack_chk_fail
.L26:
	.align	2
.L25:
	.word	PATH_MAX_LENGTH
	.word	.LC3
	.word	subsystem_fullpaths
	.word	RARCH_DIR_CURRENT_SAVESTATE
	.word	.LC0
	.word	g_extern
	.word	.LC1
	.word	MSG_REDIRECTING_SAVESTATE_TO
	.word	.LC2
	.size	path_set_special, .-path_set_special
	.comm	subsystem_fullpaths,4,4
	.comm	g_extern,4,4
	.comm	RARCH_DIR_CURRENT_SAVESTATE,4,4
	.comm	PATH_MAX_LENGTH,4,4
	.comm	MSG_REDIRECTING_SAVESTATE_TO,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
