	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ilcs_process_message
_ilcs_process_message:                  ## @ilcs_process_message
	.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	%rdi, %r15
	testl	%esi, %esi
	je	LBB0_1
LBB0_2:
	leaq	24(%r15), %rdi
	callq	_vchiu_queue_pop
	movq	%rax, %r13
	movq	8(%rax), %r12
	movq	%r12, %rdi
	callq	_UINT32
	movq	%rax, %rbx
	leaq	4(%r12), %rdi
	callq	_UINT32
	movq	%rax, %rsi
	addq	$8, %r12
	movq	(%r13), %r14
	addq	$-8, %r14
	movq	_IL_RESPONSE@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rbx
	jne	LBB0_4
## %bb.3:
	movq	%r15, %rdi
	movq	%r12, %rdx
	movq	%r14, %rcx
	callq	_ilcs_response
	movl	16(%r15), %edi
	movq	%r13, %rsi
	callq	_vchiq_release_message
	jmp	LBB0_9
LBB0_4:
	movq	%rbx, %rdx
	movq	_IL_SERVICE_QUIT@GOTPCREL(%rip), %rax
	movl	$1, %ebx
	cmpq	(%rax), %rdx
	je	LBB0_10
## %bb.5:
	movl	(%r15), %eax
	movq	_ILCS_MSG_INUSE_MASK@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_6
## %bb.11:
	xorl	%edi, %edi
	callq	_vcos_assert
	jmp	LBB0_10
LBB0_1:
	leaq	24(%r15), %rdi
	callq	_vchiu_queue_is_empty
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jne	LBB0_10
	jmp	LBB0_2
LBB0_6:
	movq	%rsi, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdx
	xorl	%r15d, %r15d
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movl	$1, %ebx
	movl	%r15d, %ecx
	shll	%cl, %ebx
	movl	%r15d, %ecx
	incq	%r15
	btl	%ecx, %eax
	jb	LBB0_7
## %bb.8:
	orl	%ebx, %eax
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	movl	%eax, (%rdx)
	movq	8(%rdx), %rax
	movl	-4(%rax,%r15,4), %edi
	movq	%r12, %rsi
	movq	%r14, %rdx
	callq	_memcpy
	movq	-48(%rbp), %r12                 ## 8-byte Reload
	movl	16(%r12), %edi
	movq	%r13, %rsi
	callq	_vchiq_release_message
	movq	8(%r12), %rax
	movl	-4(%rax,%r15,4), %ecx
	movq	%r12, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	movq	%r14, %r8
	callq	_ilcs_command
	notl	%ebx
	andl	%ebx, (%r12)
LBB0_9:
	movl	$1, %ebx
LBB0_10:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IL_RESPONSE,8,3                ## @IL_RESPONSE
	.comm	_IL_SERVICE_QUIT,8,3            ## @IL_SERVICE_QUIT
	.comm	_ILCS_MSG_INUSE_MASK,4,2        ## @ILCS_MSG_INUSE_MASK
	.no_dead_strip	_ilcs_process_message
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ilcs_process_message
_ilcs_process_message:                  ; @ilcs_process_message
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x0
	cbz	w1, LBB0_3
LBB0_1:
	add	x0, x19, #24
	bl	_vchiu_queue_pop
	mov	x20, x0
	ldr	x23, [x0, #8]
	mov	x0, x23
	bl	_UINT32
	mov	x21, x0
	add	x0, x23, #4
	bl	_UINT32
	mov	x22, x0
	add	x2, x23, #8
	ldr	x8, [x20]
	sub	x23, x8, #8
Lloh0:
	adrp	x8, _IL_RESPONSE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IL_RESPONSE@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x21, x8
	b.ne	LBB0_5
; %bb.2:
	mov	x0, x19
	mov	x1, x22
	mov	x3, x23
	bl	_ilcs_response
	ldr	w0, [x19, #16]
	mov	x1, x20
	bl	_vchiq_release_message
	b	LBB0_11
LBB0_3:
	add	x0, x19, #24
	bl	_vchiu_queue_is_empty
	cbz	x0, LBB0_1
; %bb.4:
	mov	w0, #0
	b	LBB0_12
LBB0_5:
Lloh3:
	adrp	x8, _IL_SERVICE_QUIT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IL_SERVICE_QUIT@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x21, x8
	b.eq	LBB0_11
; %bb.6:
	ldr	w8, [x19]
Lloh6:
	adrp	x9, _ILCS_MSG_INUSE_MASK@GOTPAGE
Lloh7:
	ldr	x9, [x9, _ILCS_MSG_INUSE_MASK@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_8
; %bb.7:
	mov	w0, #0
	bl	_vcos_assert
	b	LBB0_11
LBB0_8:
	mov	x9, #-1
	mov	w10, #1
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	add	x9, x9, #1
	lsl	w24, w10, w9
	tst	w24, w8
	b.ne	LBB0_9
; %bb.10:
	orr	w8, w24, w8
	str	w8, [x19]
	ldr	x8, [x19, #8]
	lsl	x25, x9, #2
	ldr	w0, [x8, x25]
	mov	x1, x2
	mov	x2, x23
	bl	_memcpy
	ldr	w0, [x19, #16]
	mov	x1, x20
	bl	_vchiq_release_message
	ldr	x8, [x19, #8]
	ldr	w3, [x8, x25]
	mov	x0, x19
	mov	x1, x21
	mov	x2, x22
	mov	x4, x23
	bl	_ilcs_command
	ldr	w8, [x19]
	bic	w8, w8, w24
	str	w8, [x19]
LBB0_11:
	mov	w0, #1
LBB0_12:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_IL_RESPONSE,8,3                ; @IL_RESPONSE
	.comm	_IL_SERVICE_QUIT,8,3            ; @IL_SERVICE_QUIT
	.comm	_ILCS_MSG_INUSE_MASK,4,2        ; @ILCS_MSG_INUSE_MASK
	.no_dead_strip	_ilcs_process_message
.subsections_via_symbols
