	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function playlist_association_right
_playlist_association_right:            ## @playlist_association_right
	.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
	movl	%edx, %ebx
	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
	xorl	%eax, %eax
	callq	_playlist_get_cached
	movq	$0, -56(%rbp)
	movb	$0, (%r15)
	movl	$-1, %r14d
	testq	%rax, %rax
	je	LBB0_15
## %bb.1:
	movq	%rax, %r12
	leaq	-56(%rbp), %rdi
	callq	_core_info_get_list
	cmpq	$0, -56(%rbp)
	je	LBB0_2
## %bb.3:
	movq	%r12, %rdi
	callq	_playlist_get_default_core_path
	movl	%eax, %edi
	callq	_string_is_empty
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movl	$1163150660, (%r15)             ## imm = 0x45544544
	movw	$21571, 4(%r15)                 ## imm = 0x5443
	movb	$0, 6(%r15)
	jmp	LBB0_6
LBB0_2:
	xorl	%eax, %eax
	callq	_menu_cbs_exit
	movl	%eax, %r14d
	jmp	LBB0_15
LBB0_5:
	movq	%r12, %rdi
	callq	_playlist_get_default_core_path
	movq	%r15, %rdi
	movl	%eax, %esi
	movl	%r13d, %edx
	callq	_strlcpy
LBB0_6:
	movq	-56(%rbp), %rdi
	movq	_CORE_INFO_LIST_SORT_DISPLAY_NAME@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_core_info_qsort
	movq	-56(%rbp), %rdi
	cmpq	$0, (%rdi)
	je	LBB0_7
## %bb.8:
	movl	%ebx, -60(%rbp)                 ## 4-byte Spill
	xorl	%r13d, %r13d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rsi
	callq	_core_info_get
	testq	%rax, %rax
	je	LBB0_15
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movl	4(%rax), %edi
	movq	%r15, %rsi
	callq	_string_is_equal
	testq	%rax, %rax
	cmovneq	%rbx, %r13
	incq	%rbx
	movq	-56(%rbp), %rdi
	movq	(%rdi), %rax
	cmpq	%rax, %rbx
	jb	LBB0_9
## %bb.11:
	incq	%r13
	cmpq	%rax, %r13
	movl	-60(%rbp), %ebx                 ## 4-byte Reload
	jae	LBB0_12
	jmp	LBB0_13
LBB0_7:
	xorl	%eax, %eax
LBB0_12:
	xorl	%ecx, %ecx
	subq	$1, %rax
	cmovbq	%rcx, %rax
	testl	%ebx, %ebx
	cmovneq	%rcx, %rax
	movq	%rax, %r13
LBB0_13:
	movq	%r13, %rsi
	callq	_core_info_get
	testq	%rax, %rax
	je	LBB0_15
## %bb.14:
	movq	%rax, %rbx
	movl	4(%rax), %esi
	movq	%r12, %rdi
	callq	_playlist_set_default_core_path
	movl	(%rbx), %esi
	movq	%r12, %rdi
	callq	_playlist_set_default_core_name
	movq	%r12, %rdi
	callq	_playlist_write_file
	xorl	%r14d, %r14d
LBB0_15:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_17
## %bb.16:
	movl	%r14d, %eax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_17:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_PATH_MAX_LENGTH,4,2            ## @PATH_MAX_LENGTH
	.comm	_CORE_INFO_LIST_SORT_DISPLAY_NAME,4,2 ## @CORE_INFO_LIST_SORT_DISPLAY_NAME
	.no_dead_strip	_playlist_association_right
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function playlist_association_right
_playlist_association_right:            ; @playlist_association_right
	.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	x20, x2
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	w22, [x8]
	mov	x9, x22
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x8, sp
	add	x9, x22, #15
	and	x9, x9, #0x1fffffff0
	sub	x21, x8, x9
	mov	sp, x21
	bl	_playlist_get_cached
	stur	xzr, [x29, #-64]
	strb	wzr, [x21]
	cbz	x0, LBB0_14
; %bb.1:
	mov	x19, x0
	sub	x0, x29, #64
	bl	_core_info_get_list
	ldur	x8, [x29, #-64]
	cbz	x8, LBB0_4
; %bb.2:
	mov	x0, x19
	bl	_playlist_get_default_core_path
	bl	_string_is_empty
	cbz	x0, LBB0_5
; %bb.3:
	mov	w8, #17732
	movk	w8, #17748, lsl #16
	str	w8, [x21]
	mov	w8, #21571
	strh	w8, [x21, #4]
	strb	wzr, [x21, #6]
	b	LBB0_6
LBB0_4:
	bl	_menu_cbs_exit
	b	LBB0_15
LBB0_5:
	mov	x0, x19
	bl	_playlist_get_default_core_path
	mov	x1, x0
	mov	x0, x21
	mov	x2, x22
	bl	_strlcpy
LBB0_6:
	ldur	x0, [x29, #-64]
Lloh8:
	adrp	x8, _CORE_INFO_LIST_SORT_DISPLAY_NAME@GOTPAGE
Lloh9:
	ldr	x8, [x8, _CORE_INFO_LIST_SORT_DISPLAY_NAME@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	bl	_core_info_qsort
	ldur	x0, [x29, #-64]
	ldr	x8, [x0]
	cbz	x8, LBB0_11
; %bb.7:
	mov	x23, #0
	mov	x22, #0
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	mov	x1, x22
	bl	_core_info_get
	cbz	x0, LBB0_14
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	ldr	w0, [x0, #4]
	mov	x1, x21
	bl	_string_is_equal
	cmp	x0, #0
	csel	x23, x23, x22, eq
	add	x22, x22, #1
	ldur	x0, [x29, #-64]
	ldr	x8, [x0]
	cmp	x22, x8
	b.lo	LBB0_8
; %bb.10:
	add	x1, x23, #1
	cmp	x1, x8
	b.lo	LBB0_12
LBB0_11:
	sub	x9, x8, #1
	cmp	x8, #0
	ccmp	w20, #0, #0, ne
	csel	x1, xzr, x9, ne
LBB0_12:
	bl	_core_info_get
	cbz	x0, LBB0_14
; %bb.13:
	mov	x20, x0
	ldr	w1, [x0, #4]
	mov	x0, x19
	bl	_playlist_set_default_core_path
	ldr	w1, [x20]
	mov	x0, x19
	bl	_playlist_set_default_core_name
	mov	x0, x19
	bl	_playlist_write_file
	mov	w0, #0
	b	LBB0_15
LBB0_14:
	mov	w0, #-1
LBB0_15:
	ldur	x8, [x29, #-56]
Lloh11:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh12:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_17
; %bb.16:
	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_17:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_PATH_MAX_LENGTH,4,2            ; @PATH_MAX_LENGTH
	.comm	_CORE_INFO_LIST_SORT_DISPLAY_NAME,4,2 ; @CORE_INFO_LIST_SORT_DISPLAY_NAME
	.no_dead_strip	_playlist_association_right
.subsections_via_symbols
