	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_view_sort_layers               ## -- Begin function view_sort_layers
	.p2align	4, 0x90
_view_sort_layers:                      ## @view_sort_layers
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$64, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -24(%rbp)
	leaq	L_.str(%rip), %rsi
	callq	_view_find_layer
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	_VIDEO_LAYOUT_BLEND_MOD@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	movq	%rcx, -80(%rbp)
	movl	$1, %r14d
	jmp	LBB0_3
LBB0_1:
	xorl	%r14d, %r14d
LBB0_3:
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_view_find_layer
	testq	%rax, %rax
	je	LBB0_5
## %bb.4:
	movq	_VIDEO_LAYOUT_BLEND_MOD@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	movl	%r14d, %eax
	movq	%rcx, -80(%rbp,%rax,8)
	incl	%r14d
LBB0_5:
	leaq	L_.str.2(%rip), %rsi
	movq	%rbx, %rdi
	callq	_view_find_layer
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	movq	_VIDEO_LAYOUT_BLEND_ADD@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	movl	%r14d, %eax
	movq	%rcx, -80(%rbp,%rax,8)
	incl	%r14d
LBB0_7:
	leaq	L_.str.3(%rip), %rsi
	movq	%rbx, %rdi
	callq	_view_find_layer
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	_VIDEO_LAYOUT_BLEND_ALPHA@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	movl	%r14d, %eax
	movq	%rcx, -80(%rbp,%rax,8)
	incl	%r14d
LBB0_9:
	leaq	L_.str.4(%rip), %rsi
	movq	%rbx, %rdi
	callq	_view_find_layer
	testq	%rax, %rax
	je	LBB0_11
## %bb.10:
	movq	_VIDEO_LAYOUT_BLEND_ALPHA@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	movl	%r14d, %eax
	movq	%rcx, -80(%rbp,%rax,8)
	incl	%r14d
LBB0_11:
	leaq	L_.str.5(%rip), %rsi
	movq	%rbx, %rdi
	callq	_view_find_layer
	testq	%rax, %rax
	je	LBB0_13
## %bb.12:
	movq	_VIDEO_LAYOUT_BLEND_ALPHA@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%rax)
	movl	%r14d, %eax
	movq	%rcx, -80(%rbp,%rax,8)
LBB0_13:
	movl	(%rbx), %edx
	testl	%edx, %edx
	jle	LBB0_20
## %bb.14:
	leaq	-1(%rdx), %rcx
	movl	%edx, %eax
	andl	$3, %eax
	cmpq	$3, %rcx
	jae	LBB0_16
## %bb.15:
	xorl	%ecx, %ecx
	jmp	LBB0_18
LBB0_16:
	andl	$-4, %edx
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_17:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%rbx), %rsi
	movq	-80(%rbp,%rcx,8), %rdi
	movq	%rdi, (%rsi,%rcx,8)
	movq	8(%rbx), %rsi
	movq	-72(%rbp,%rcx,8), %rdi
	movq	%rdi, 8(%rsi,%rcx,8)
	movq	8(%rbx), %rsi
	movq	-64(%rbp,%rcx,8), %rdi
	movq	%rdi, 16(%rsi,%rcx,8)
	movq	8(%rbx), %rsi
	movq	-56(%rbp,%rcx,8), %rdi
	movq	%rdi, 24(%rsi,%rcx,8)
	addq	$4, %rcx
	cmpq	%rcx, %rdx
	jne	LBB0_17
LBB0_18:
	testq	%rax, %rax
	je	LBB0_20
	.p2align	4, 0x90
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%rbx), %rdx
	movq	-80(%rbp,%rcx,8), %rsi
	movq	%rsi, (%rdx,%rcx,8)
	incq	%rcx
	decq	%rax
	jne	LBB0_19
LBB0_20:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-24(%rbp), %rax
	jne	LBB0_22
## %bb.21:
	addq	$64, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_22:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"screen"

	.comm	_VIDEO_LAYOUT_BLEND_MOD,8,3     ## @VIDEO_LAYOUT_BLEND_MOD
L_.str.1:                               ## @.str.1
	.asciz	"overlay"

L_.str.2:                               ## @.str.2
	.asciz	"backdrop"

	.comm	_VIDEO_LAYOUT_BLEND_ADD,8,3     ## @VIDEO_LAYOUT_BLEND_ADD
L_.str.3:                               ## @.str.3
	.asciz	"bezel"

	.comm	_VIDEO_LAYOUT_BLEND_ALPHA,8,3   ## @VIDEO_LAYOUT_BLEND_ALPHA
L_.str.4:                               ## @.str.4
	.asciz	"cpanel"

L_.str.5:                               ## @.str.5
	.asciz	"marquee"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_view_sort_layers               ; -- Begin function view_sort_layers
	.p2align	2
_view_sort_layers:                      ; @view_sort_layers
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-40]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_view_find_layer
Lloh5:
	adrp	x21, _VIDEO_LAYOUT_BLEND_MOD@GOTPAGE
Lloh6:
	ldr	x21, [x21, _VIDEO_LAYOUT_BLEND_MOD@GOTPAGEOFF]
	cbz	x0, LBB0_2
; %bb.1:
	ldr	x8, [x21]
	str	x8, [x0]
	str	x8, [sp, #8]
	mov	w20, #1
	b	LBB0_3
LBB0_2:
	mov	w20, #0
LBB0_3:
Lloh7:
	adrp	x1, l_.str.1@PAGE
Lloh8:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_view_find_layer
	cbz	x0, LBB0_5
; %bb.4:
	ldr	x8, [x21]
	str	x8, [x0]
	add	x9, sp, #8
	str	x8, [x9, w20, uxtw #3]
	add	w20, w20, #1
LBB0_5:
Lloh9:
	adrp	x1, l_.str.2@PAGE
Lloh10:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_view_find_layer
	cbz	x0, LBB0_7
; %bb.6:
Lloh11:
	adrp	x8, _VIDEO_LAYOUT_BLEND_ADD@GOTPAGE
Lloh12:
	ldr	x8, [x8, _VIDEO_LAYOUT_BLEND_ADD@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
	str	x8, [x0]
	add	x9, sp, #8
	str	x8, [x9, w20, uxtw #3]
	add	w20, w20, #1
LBB0_7:
Lloh14:
	adrp	x1, l_.str.3@PAGE
Lloh15:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_view_find_layer
Lloh16:
	adrp	x21, _VIDEO_LAYOUT_BLEND_ALPHA@GOTPAGE
Lloh17:
	ldr	x21, [x21, _VIDEO_LAYOUT_BLEND_ALPHA@GOTPAGEOFF]
	cbz	x0, LBB0_9
; %bb.8:
	ldr	x8, [x21]
	str	x8, [x0]
	add	x9, sp, #8
	str	x8, [x9, w20, uxtw #3]
	add	w20, w20, #1
LBB0_9:
Lloh18:
	adrp	x1, l_.str.4@PAGE
Lloh19:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x19
	bl	_view_find_layer
	cbz	x0, LBB0_11
; %bb.10:
	ldr	x8, [x21]
	str	x8, [x0]
	add	x9, sp, #8
	str	x8, [x9, w20, uxtw #3]
	add	w20, w20, #1
LBB0_11:
Lloh20:
	adrp	x1, l_.str.5@PAGE
Lloh21:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x19
	bl	_view_find_layer
	cbz	x0, LBB0_13
; %bb.12:
	ldr	x8, [x21]
	str	x8, [x0]
	add	x9, sp, #8
	str	x8, [x9, w20, uxtw #3]
LBB0_13:
	ldr	w9, [x19]
	cmp	w9, #1
	b.lt	LBB0_16
; %bb.14:
	mov	x8, #0
	lsl	x9, x9, #3
	add	x10, sp, #8
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x19, #8]
	ldr	x12, [x10, x8]
	str	x12, [x11, x8]
	add	x8, x8, #8
	cmp	x9, x8
	b.ne	LBB0_15
LBB0_16:
	ldur	x8, [x29, #-40]
Lloh22:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh23:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_18
; %bb.17:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_18:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"screen"

	.comm	_VIDEO_LAYOUT_BLEND_MOD,8,3     ; @VIDEO_LAYOUT_BLEND_MOD
l_.str.1:                               ; @.str.1
	.asciz	"overlay"

l_.str.2:                               ; @.str.2
	.asciz	"backdrop"

	.comm	_VIDEO_LAYOUT_BLEND_ADD,8,3     ; @VIDEO_LAYOUT_BLEND_ADD
l_.str.3:                               ; @.str.3
	.asciz	"bezel"

	.comm	_VIDEO_LAYOUT_BLEND_ALPHA,8,3   ; @VIDEO_LAYOUT_BLEND_ALPHA
l_.str.4:                               ; @.str.4
	.asciz	"cpanel"

l_.str.5:                               ; @.str.5
	.asciz	"marquee"

.subsections_via_symbols
