	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_venus_helper_set_color_format  ## -- Begin function venus_helper_set_color_format
	.p2align	4, 0x90
_venus_helper_set_color_format:         ## @venus_helper_set_color_format
	.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
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	(%rdi), %rax
	movq	_VIDC_SESSION_TYPE_DEC@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	movq	_HFI_BUFFER_OUTPUT@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_2:
	movq	_VIDC_SESSION_TYPE_ENC@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_5
## %bb.3:
	movq	_HFI_BUFFER_INPUT@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %r14d
	movl	%esi, %edi
	callq	_to_hfi_raw_fmt
	testl	%eax, %eax
	je	LBB0_5
## %bb.6:
	movq	%rbx, %rdi
	movl	%eax, %esi
	movl	%r14d, %edx
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_venus_helper_set_raw_format    ## TAILCALL
LBB0_5:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_VIDC_SESSION_TYPE_DEC,8,3      ## @VIDC_SESSION_TYPE_DEC
	.comm	_HFI_BUFFER_OUTPUT,4,2          ## @HFI_BUFFER_OUTPUT
	.comm	_VIDC_SESSION_TYPE_ENC,8,3      ## @VIDC_SESSION_TYPE_ENC
	.comm	_HFI_BUFFER_INPUT,4,2           ## @HFI_BUFFER_INPUT
	.comm	_EINVAL,4,2                     ## @EINVAL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_venus_helper_set_color_format  ; -- Begin function venus_helper_set_color_format
	.p2align	2
_venus_helper_set_color_format:         ; @venus_helper_set_color_format
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _VIDC_SESSION_TYPE_DEC@GOTPAGE
Lloh1:
	ldr	x9, [x9, _VIDC_SESSION_TYPE_DEC@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _HFI_BUFFER_OUTPUT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _HFI_BUFFER_OUTPUT@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:
Lloh5:
	adrp	x9, _VIDC_SESSION_TYPE_ENC@GOTPAGE
Lloh6:
	ldr	x9, [x9, _VIDC_SESSION_TYPE_ENC@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_6
; %bb.3:
Lloh8:
	adrp	x8, _HFI_BUFFER_INPUT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _HFI_BUFFER_INPUT@GOTPAGEOFF]
LBB0_4:
	ldr	w20, [x8]
	mov	x0, x1
	bl	_to_hfi_raw_fmt
	cbz	w0, LBB0_6
; %bb.5:
	mov	x1, x0
	mov	x0, x19
	mov	x2, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_venus_helper_set_raw_format
LBB0_6:
Lloh10:
	adrp	x8, _EINVAL@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_VIDC_SESSION_TYPE_DEC,8,3      ; @VIDC_SESSION_TYPE_DEC
	.comm	_HFI_BUFFER_OUTPUT,4,2          ; @HFI_BUFFER_OUTPUT
	.comm	_VIDC_SESSION_TYPE_ENC,8,3      ; @VIDC_SESSION_TYPE_ENC
	.comm	_HFI_BUFFER_INPUT,4,2           ; @HFI_BUFFER_INPUT
	.comm	_EINVAL,4,2                     ; @EINVAL
.subsections_via_symbols
