	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function komeda_wb_layer_validate
_komeda_wb_layer_validate:              ## @komeda_wb_layer_validate
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r15
	movq	%rsi, %rbx
	movq	%rdi, %r12
	movq	16(%rsi), %rax
	movl	(%rax), %edi
	callq	_to_kfb
	movq	%rax, %r13
	movq	%r12, %rdi
	movq	%rax, %rsi
	movq	%r15, %rdx
	callq	_komeda_layer_check_cfg
	movl	%eax, %r14d
	testl	%eax, %eax
	je	LBB0_1
LBB0_6:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movl	8(%rbx), %esi
	movl	(%rbx), %ecx
	movl	4(%rbx), %edx
	movq	%r12, %rdi
	callq	_komeda_component_get_state_and_set_user
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_2
## %bb.7:
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_PTR_ERR                        ## TAILCALL
LBB0_2:
	movq	%r12, -48(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_to_layer_st
	movq	%rax, %r12
	movl	16(%r15), %eax
	movl	%eax, 20(%r12)
	movl	12(%r15), %eax
	movl	%eax, 16(%r12)
	movq	(%r13), %rax
	cmpl	$0, (%rax)
	jle	LBB0_5
## %bb.3:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	4(%r15), %edx
	movl	8(%r15), %esi
	movq	%r13, %rdi
	movl	%ebx, %ecx
	callq	_komeda_fb_get_pixel_addr
	movq	8(%r12), %rcx
	movl	%eax, (%rcx,%rbx,4)
	incq	%rbx
	movq	(%r13), %rax
	movslq	(%rax), %rax
	cmpq	%rax, %rbx
	jl	LBB0_4
LBB0_5:
	xorl	%r14d, %r14d
	movq	%r12, %rdi
	movq	%r15, %rsi
	xorl	%edx, %edx
	callq	_komeda_component_add_input
	movq	%r15, %rdi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	xorl	%edx, %edx
	callq	_komeda_component_set_output
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_komeda_wb_layer_validate
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function komeda_wb_layer_validate
_komeda_wb_layer_validate:              ; @komeda_wb_layer_validate
	.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
	mov	x19, x2
	mov	x22, x1
	mov	x20, x0
	ldr	x8, [x1, #16]
	ldr	w0, [x8]
	bl	_to_kfb
	mov	x21, x0
	mov	x0, x20
	mov	x1, x21
	mov	x2, x19
	bl	_komeda_layer_check_cfg
	cbz	w0, LBB0_2
LBB0_1:
	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_2:
	ldp	w2, w1, [x22, #4]
	ldr	w3, [x22]
	mov	x0, x20
	bl	_komeda_component_get_state_and_set_user
	mov	x22, x0
	bl	_IS_ERR
	cbz	x0, LBB0_4
; %bb.3:
	mov	x0, x22
	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
	b	_PTR_ERR
LBB0_4:
	mov	x0, x22
	bl	_to_layer_st
	mov	x22, x0
	ldur	d0, [x19, #12]
	str	d0, [x0, #16]
	ldr	x8, [x21]
	ldr	w8, [x8]
	cmp	w8, #1
	b.lt	LBB0_7
; %bb.5:
	mov	x23, #0
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldp	w2, w1, [x19, #4]
	mov	x0, x21
	mov	x3, x23
	bl	_komeda_fb_get_pixel_addr
	ldr	x8, [x22, #8]
	str	w0, [x8, x23, lsl #2]
	add	x23, x23, #1
	ldr	x8, [x21]
	ldrsw	x8, [x8]
	cmp	x23, x8
	b.lt	LBB0_6
LBB0_7:
	mov	x0, x22
	mov	x1, x19
	mov	w2, #0
	bl	_komeda_component_add_input
	mov	x0, x19
	mov	x1, x20
	mov	w2, #0
	bl	_komeda_component_set_output
	mov	w0, #0
	b	LBB0_1
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_komeda_wb_layer_validate
.subsections_via_symbols
