	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ilclient_enable_port_buffers   ## -- Begin function ilclient_enable_port_buffers
	.p2align	4, 0x90
_ilclient_enable_port_buffers:          ## @ilclient_enable_port_buffers
	.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	$88, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, %r15
	movq	%rcx, %r13
	movq	%rdx, -120(%rbp)                ## 8-byte Spill
	movl	%esi, %r12d
	movq	%rdi, %r14
	movq	$0, -48(%rbp)
	leaq	-112(%rbp), %rbx
	movq	%rbx, %rdi
	xorl	%esi, %esi
	movl	$48, %edx
	callq	_memset
	movl	$48, -112(%rbp)
	movq	_OMX_VERSION@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -68(%rbp)
	movl	%r12d, -108(%rbp)
	movl	24(%r14), %edi
	movq	_OMX_IndexParamPortDefinition@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdx
	callq	_OMX_GetParameter
	movq	_OMX_ErrorNone@GOTPCREL(%rip), %rcx
	movl	$-1, %ebx
	cmpq	(%rcx), %rax
	jne	LBB0_26
## %bb.1:
	movq	-104(%rbp), %rax
	movq	_OMX_FALSE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_26
## %bb.2:
	cmpl	$0, -96(%rbp)
	je	LBB0_26
## %bb.3:
	cmpq	$0, -88(%rbp)
	je	LBB0_26
## %bb.4:
	movl	24(%r14), %edi
	leaq	-128(%rbp), %rsi
	callq	_OMX_GetState
	movq	_OMX_ErrorNone@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	jne	LBB0_26
## %bb.5:
	movq	-128(%rbp), %rax
	movq	_OMX_StateIdle@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_8
## %bb.6:
	movq	_OMX_StateExecuting@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_8
## %bb.7:
	movq	_OMX_StatePause@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_26
LBB0_8:
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	movl	24(%r14), %edi
	movq	_OMX_CommandPortEnable@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%r13d, %r13d
	movq	%rdx, %rbx
	movl	%r12d, %edx
	xorl	%ecx, %ecx
	callq	_OMX_SendCommand
	xorl	%edi, %edi
	cmpq	(%rbx), %rax
	sete	%dil
	callq	_vc_assert
	cmpl	$0, -96(%rbp)
	je	LBB0_9
## %bb.10:
	leaq	-48(%rbp), %r15
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	-88(%rbp), %rsi
	movl	-72(%rbp), %edx
	movl	28(%r14), %ecx
	movq	-120(%rbp), %rax                ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	*%rax
	jmp	LBB0_14
LBB0_13:                                ##   in Loop: Header=BB0_11 Depth=1
	movq	%rsi, %rdi
	movl	%edx, %esi
	movl	%ecx, %edx
	callq	_vcos_malloc_aligned
LBB0_14:                                ##   in Loop: Header=BB0_11 Depth=1
	movq	%rax, %rbx
	testq	%rax, %rax
	je	LBB0_20
## %bb.15:                              ##   in Loop: Header=BB0_11 Depth=1
	movl	24(%r14), %edi
	movq	-88(%rbp), %r8
	movq	%r15, %rsi
	movl	%r12d, %edx
	xorl	%ecx, %ecx
	movq	%rbx, %r9
	callq	_OMX_UseBuffer
	movq	_OMX_ErrorNone@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_16
## %bb.19:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	(%r15), %r15
	incl	%r13d
	cmpl	-96(%rbp), %r13d
	jne	LBB0_11
	jmp	LBB0_20
LBB0_9:
	leaq	-48(%rbp), %r15
	jmp	LBB0_20
LBB0_16:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_18
## %bb.17:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	*%rax
	jmp	LBB0_20
LBB0_18:
	movq	%rbx, %rdi
	callq	_vcos_free
LBB0_20:
	movq	%r14, %rdi
	callq	_vcos_semaphore_wait
	movq	-80(%rbp), %rax
	movq	_OMX_DirInput@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_22
## %bb.21:
	movq	16(%r14), %rax
	movq	%rax, (%r15)
	movq	-48(%rbp), %rax
	movq	%rax, 16(%r14)
	jmp	LBB0_23
LBB0_22:
	movq	8(%r14), %rax
	movq	%rax, (%r15)
	movq	-48(%rbp), %rax
	movq	%rax, 8(%r14)
LBB0_23:
	movq	%r14, %rdi
	callq	_vcos_semaphore_post
	cmpl	-96(%rbp), %r13d
	jne	LBB0_25
## %bb.24:
	movq	_OMX_CommandPortEnable@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	%r12d, %edx
	callq	_ilclient_wait_for_command_complete
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jns	LBB0_26
LBB0_25:
	movq	%r14, %rdi
	movl	%r12d, %esi
	xorl	%edx, %edx
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	-56(%rbp), %r8                  ## 8-byte Reload
	callq	_ilclient_disable_port_buffers
	movq	_OMX_EventError@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	xorl	%edx, %edx
	movl	$1, %ecx
	movl	$1, %r8d
	xorl	%r9d, %r9d
	callq	_ilclient_remove_event
	movl	$-1, %ebx
LBB0_26:
	movl	%ebx, %eax
	addq	$88, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_OMX_VERSION,4,2                ## @OMX_VERSION
	.comm	_OMX_IndexParamPortDefinition,4,2 ## @OMX_IndexParamPortDefinition
	.comm	_OMX_ErrorNone,8,3              ## @OMX_ErrorNone
	.comm	_OMX_FALSE,8,3                  ## @OMX_FALSE
	.comm	_OMX_StateIdle,8,3              ## @OMX_StateIdle
	.comm	_OMX_StateExecuting,8,3         ## @OMX_StateExecuting
	.comm	_OMX_StatePause,8,3             ## @OMX_StatePause
	.comm	_OMX_CommandPortEnable,4,2      ## @OMX_CommandPortEnable
	.comm	_OMX_DirInput,8,3               ## @OMX_DirInput
	.comm	_OMX_EventError,4,2             ## @OMX_EventError
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ilclient_enable_port_buffers   ; -- Begin function ilclient_enable_port_buffers
	.p2align	2
_ilclient_enable_port_buffers:          ; @ilclient_enable_port_buffers
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x28, x27, [sp, #64]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #80]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #96]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x4
	mov	x21, x3
	mov	x23, x2
	mov	x22, x1
	mov	x19, x0
	str	xzr, [sp, #8]
	mov	w24, #48
	add	x0, sp, #16
	mov	w1, #0
	mov	w2, #48
	bl	_memset
Lloh0:
	adrp	x8, _OMX_VERSION@GOTPAGE
Lloh1:
	ldr	x8, [x8, _OMX_VERSION@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [sp, #60]
	stp	w24, w22, [sp, #16]
	ldr	w0, [x19, #24]
Lloh3:
	adrp	x8, _OMX_IndexParamPortDefinition@GOTPAGE
Lloh4:
	ldr	x8, [x8, _OMX_IndexParamPortDefinition@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x2, sp, #16
	bl	_OMX_GetParameter
Lloh6:
	adrp	x27, _OMX_ErrorNone@GOTPAGE
Lloh7:
	ldr	x27, [x27, _OMX_ErrorNone@GOTPAGEOFF]
	ldr	x8, [x27]
	cmp	x0, x8
	b.ne	LBB0_24
; %bb.1:
	ldr	x8, [sp, #24]
Lloh8:
	adrp	x9, _OMX_FALSE@GOTPAGE
Lloh9:
	ldr	x9, [x9, _OMX_FALSE@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	ldr	w10, [sp, #32]
	ldr	x11, [sp, #40]
	cmp	x8, x9
	ccmp	w10, #0, #4, eq
	ccmp	x11, #0, #4, ne
	b.eq	LBB0_24
; %bb.2:
	ldr	w0, [x19, #24]
	mov	x1, sp
	bl	_OMX_GetState
	ldr	x8, [x27]
	cmp	x0, x8
	b.ne	LBB0_24
; %bb.3:
	ldr	x8, [sp]
Lloh11:
	adrp	x9, _OMX_StateIdle@GOTPAGE
Lloh12:
	ldr	x9, [x9, _OMX_StateIdle@GOTPAGEOFF]
Lloh13:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_6
; %bb.4:
Lloh14:
	adrp	x9, _OMX_StateExecuting@GOTPAGE
Lloh15:
	ldr	x9, [x9, _OMX_StateExecuting@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_6
; %bb.5:
Lloh17:
	adrp	x9, _OMX_StatePause@GOTPAGE
Lloh18:
	ldr	x9, [x9, _OMX_StatePause@GOTPAGEOFF]
Lloh19:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_24
LBB0_6:
	ldr	w0, [x19, #24]
Lloh20:
	adrp	x26, _OMX_CommandPortEnable@GOTPAGE
Lloh21:
	ldr	x26, [x26, _OMX_CommandPortEnable@GOTPAGEOFF]
	ldr	w1, [x26]
	mov	x2, x22
	mov	x3, #0
	bl	_OMX_SendCommand
	ldr	x8, [x27]
	cmp	x0, x8
	cset	w0, eq
	bl	_vc_assert
	ldr	w8, [sp, #32]
	cbz	w8, LBB0_13
; %bb.7:
	mov	w28, #0
	add	x24, sp, #8
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x1, [sp, #40]
	ldr	w2, [sp, #56]
	ldr	w3, [x19, #28]
	cbz	x23, LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x20
	blr	x23
	mov	x25, x0
	cbnz	x0, LBB0_11
	b	LBB0_17
LBB0_10:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x1
	mov	x1, x2
	mov	x2, x3
	bl	_vcos_malloc_aligned
	mov	x25, x0
	cbz	x0, LBB0_17
LBB0_11:                                ;   in Loop: Header=BB0_8 Depth=1
	ldr	w0, [x19, #24]
	ldr	x4, [sp, #40]
	mov	x1, x24
	mov	x2, x22
	mov	x3, #0
	mov	x5, x25
	bl	_OMX_UseBuffer
	ldr	x8, [x27]
	cmp	x0, x8
	b.ne	LBB0_14
; %bb.12:                               ;   in Loop: Header=BB0_8 Depth=1
	ldr	x24, [x24]
	add	w28, w28, #1
	ldr	w8, [sp, #32]
	cmp	w28, w8
	b.ne	LBB0_8
	b	LBB0_17
LBB0_13:
	mov	w28, #0
	add	x24, sp, #8
	b	LBB0_17
LBB0_14:
	cbz	x21, LBB0_16
; %bb.15:
	mov	x0, x20
	mov	x1, x25
	blr	x21
	b	LBB0_17
LBB0_16:
	mov	x0, x25
	bl	_vcos_free
LBB0_17:
	mov	x0, x19
	bl	_vcos_semaphore_wait
	ldr	x8, [sp, #48]
Lloh22:
	adrp	x9, _OMX_DirInput@GOTPAGE
Lloh23:
	ldr	x9, [x9, _OMX_DirInput@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_19
; %bb.18:
	ldr	x8, [x19, #16]
	str	x8, [x24]
	ldr	x8, [sp, #8]
	str	x8, [x19, #16]
	b	LBB0_20
LBB0_19:
	ldr	x8, [x19, #8]
	str	x8, [x24]
	ldr	x8, [sp, #8]
	str	x8, [x19, #8]
LBB0_20:
	mov	x0, x19
	bl	_vcos_semaphore_post
	ldr	w8, [sp, #32]
	cmp	w28, w8
	b.ne	LBB0_23
; %bb.21:
	ldr	w1, [x26]
	mov	x0, x19
	mov	x2, x22
	bl	_ilclient_wait_for_command_complete
	tbnz	x0, #63, LBB0_23
; %bb.22:
	mov	w0, #0
	b	LBB0_25
LBB0_23:
	mov	x0, x19
	mov	x1, x22
	mov	x2, #0
	mov	x3, x21
	mov	x4, x20
	bl	_ilclient_disable_port_buffers
Lloh25:
	adrp	x8, _OMX_EventError@GOTPAGE
Lloh26:
	ldr	x8, [x8, _OMX_EventError@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	mov	w3, #1
	mov	w4, #1
	mov	w5, #0
	bl	_ilclient_remove_event
LBB0_24:
	mov	w0, #-1
LBB0_25:
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_OMX_VERSION,4,2                ; @OMX_VERSION
	.comm	_OMX_IndexParamPortDefinition,4,2 ; @OMX_IndexParamPortDefinition
	.comm	_OMX_ErrorNone,8,3              ; @OMX_ErrorNone
	.comm	_OMX_FALSE,8,3                  ; @OMX_FALSE
	.comm	_OMX_StateIdle,8,3              ; @OMX_StateIdle
	.comm	_OMX_StateExecuting,8,3         ; @OMX_StateExecuting
	.comm	_OMX_StatePause,8,3             ; @OMX_StatePause
	.comm	_OMX_CommandPortEnable,4,2      ; @OMX_CommandPortEnable
	.comm	_OMX_DirInput,8,3               ; @OMX_DirInput
	.comm	_OMX_EventError,4,2             ; @OMX_EventError
.subsections_via_symbols
