	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function av1_metadata_update_sequence_header
_av1_metadata_update_sequence_header:   ## @av1_metadata_update_sequence_header
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	(%rdi), %rbx
	movq	(%rbx), %rax
	testq	%rax, %rax
	js	LBB0_1
## %bb.4:
	movl	$1, 32(%r15)
	movq	%rax, 40(%r15)
	movq	8(%rbx), %rax
	testq	%rax, %rax
	js	LBB0_7
LBB0_6:
	movq	%rax, 48(%r15)
LBB0_7:
	movq	16(%rbx), %rax
	testq	%rax, %rax
	js	LBB0_9
## %bb.8:
	movq	%rax, 56(%r15)
LBB0_9:
	movq	24(%rbx), %rax
	testq	%rax, %rax
	js	LBB0_15
## %bb.10:
	movq	40(%r15), %rcx
	movq	_AVCOL_PRI_BT709@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_14
## %bb.11:
	movq	48(%r15), %rcx
	movq	_AVCOL_TRC_IEC61966_2_1@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_14
## %bb.12:
	movq	56(%r15), %rcx
	movq	_AVCOL_SPC_RGB@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_14
## %bb.13:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	callq	_av_log
	jmp	LBB0_15
LBB0_14:
	movq	%rax, 64(%r15)
LBB0_15:
	movq	32(%rbx), %rax
	testq	%rax, %rax
	js	LBB0_21
## %bb.16:
	cmpq	$0, 88(%r15)
	je	LBB0_17
LBB0_19:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	%r14, %rdi
	callq	_av_log
LBB0_21:
	movq	56(%rbx), %rdx
	testq	%rdx, %rdx
	je	LBB0_25
## %bb.22:
	movq	48(%rbx), %rcx
	testq	%rcx, %rcx
	je	LBB0_25
## %bb.23:
	movq	_UINT32_MAX@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_INT_MAX@GOTPCREL(%rip), %rsi
	movq	(%rsi), %r8
	cmpq	%r8, %rax
	cmovgq	%rax, %r8
	leaq	-32(%rbp), %rdi
	leaq	-28(%rbp), %rsi
	callq	_av_reduce
	movl	-32(%rbp), %eax
	movl	%eax, 8(%r15)
	movl	-28(%rbp), %eax
	movl	%eax, 12(%r15)
	movl	$1, (%r15)
	movq	40(%rbx), %rax
	testq	%rax, %rax
	jle	LBB0_25
## %bb.24:
	movl	$1, 16(%r15)
	decq	%rax
	movq	%rax, 24(%r15)
LBB0_25:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	8(%rbx), %rax
	testq	%rax, %rax
	jns	LBB0_3
## %bb.2:
	cmpq	$0, 16(%rbx)
	js	LBB0_9
LBB0_3:
	movl	$1, 32(%r15)
	testq	%rax, %rax
	jns	LBB0_6
	jmp	LBB0_7
LBB0_17:
	cmpl	$0, 84(%r15)
	je	LBB0_19
## %bb.18:
	cmpl	$0, 80(%r15)
	je	LBB0_19
## %bb.20:
	movq	%rax, 72(%r15)
	jmp	LBB0_21
	.cfi_endproc
                                        ## -- End function
	.comm	_AVCOL_PRI_BT709,8,3            ## @AVCOL_PRI_BT709
	.comm	_AVCOL_TRC_IEC61966_2_1,8,3     ## @AVCOL_TRC_IEC61966_2_1
	.comm	_AVCOL_SPC_RGB,8,3              ## @AVCOL_SPC_RGB
	.comm	_AV_LOG_WARNING,4,2             ## @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Warning: color_range cannot be set on RGB streams encoded in BT.709 sRGB.\n"

L_.str.1:                               ## @.str.1
	.asciz	"Warning: chroma_sample_position can only be set for 4:2:0 streams.\n"

	.comm	_UINT32_MAX,8,3                 ## @UINT32_MAX
	.comm	_INT_MAX,8,3                    ## @INT_MAX
	.no_dead_strip	_av1_metadata_update_sequence_header
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function av1_metadata_update_sequence_header
_av1_metadata_update_sequence_header:   ; @av1_metadata_update_sequence_header
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x1
	mov	x20, x0
	ldr	x21, [x0]
	ldr	x8, [x21]
	tbnz	x8, #63, LBB0_19
; %bb.1:
	mov	w9, #1
	str	w9, [x19, #32]
	str	x8, [x19, #40]
	ldr	x8, [x21, #8]
	tbnz	x8, #63, LBB0_3
LBB0_2:
	str	x8, [x19, #48]
LBB0_3:
	ldr	x8, [x21, #16]
	tbnz	x8, #63, LBB0_5
; %bb.4:
	str	x8, [x19, #56]
LBB0_5:
	ldr	x8, [x21, #24]
	tbnz	x8, #63, LBB0_11
; %bb.6:
	ldr	x9, [x19, #40]
Lloh0:
	adrp	x10, _AVCOL_PRI_BT709@GOTPAGE
Lloh1:
	ldr	x10, [x10, _AVCOL_PRI_BT709@GOTPAGEOFF]
Lloh2:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_10
; %bb.7:
	ldr	x9, [x19, #48]
Lloh3:
	adrp	x10, _AVCOL_TRC_IEC61966_2_1@GOTPAGE
Lloh4:
	ldr	x10, [x10, _AVCOL_TRC_IEC61966_2_1@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_10
; %bb.8:
	ldr	x9, [x19, #56]
Lloh6:
	adrp	x10, _AVCOL_SPC_RGB@GOTPAGE
Lloh7:
	ldr	x10, [x10, _AVCOL_SPC_RGB@GOTPAGEOFF]
Lloh8:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_10
; %bb.9:
Lloh9:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh10:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x2, l_.str@PAGE
Lloh13:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x20
	bl	_av_log
	b	LBB0_11
LBB0_10:
	str	x8, [x19, #64]
LBB0_11:
	ldr	x8, [x21, #32]
	tbnz	x8, #63, LBB0_14
; %bb.12:
	ldr	x9, [x19, #88]
	cbz	x9, LBB0_22
LBB0_13:
Lloh14:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh15:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
Lloh17:
	adrp	x2, l_.str.1@PAGE
Lloh18:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_av_log
LBB0_14:
	ldr	x2, [x21, #56]
	cbz	x2, LBB0_18
LBB0_15:
	ldr	x3, [x21, #48]
	cbz	x3, LBB0_18
; %bb.16:
Lloh19:
	adrp	x8, _UINT32_MAX@GOTPAGE
Lloh20:
	ldr	x8, [x8, _UINT32_MAX@GOTPAGEOFF]
Lloh21:
	ldr	x8, [x8]
Lloh22:
	adrp	x9, _INT_MAX@GOTPAGE
Lloh23:
	ldr	x9, [x9, _INT_MAX@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	cmp	x8, x9
	csel	x4, x8, x9, gt
	add	x0, sp, #12
	add	x1, sp, #8
	bl	_av_reduce
	ldp	w9, w8, [sp, #8]
	stp	w8, w9, [x19, #8]
	mov	w8, #1
	str	w8, [x19]
	ldr	x9, [x21, #40]
	subs	x9, x9, #1
	b.lt	LBB0_18
; %bb.17:
	str	w8, [x19, #16]
	str	x9, [x19, #24]
LBB0_18:
	mov	w0, #0
	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
	add	sp, sp, #64
	ret
LBB0_19:
	ldr	x8, [x21, #8]
	tbz	x8, #63, LBB0_21
; %bb.20:
	ldr	x9, [x21, #16]
	tbnz	x9, #63, LBB0_5
LBB0_21:
	mov	w9, #1
	str	w9, [x19, #32]
	tbz	x8, #63, LBB0_2
	b	LBB0_3
LBB0_22:
	ldr	w9, [x19, #84]
	cbz	w9, LBB0_13
; %bb.23:
	ldr	w9, [x19, #80]
	cbz	w9, LBB0_13
; %bb.24:
	str	x8, [x19, #72]
	ldr	x2, [x21, #56]
	cbnz	x2, LBB0_15
	b	LBB0_18
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_AVCOL_PRI_BT709,8,3            ; @AVCOL_PRI_BT709
	.comm	_AVCOL_TRC_IEC61966_2_1,8,3     ; @AVCOL_TRC_IEC61966_2_1
	.comm	_AVCOL_SPC_RGB,8,3              ; @AVCOL_SPC_RGB
	.comm	_AV_LOG_WARNING,4,2             ; @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Warning: color_range cannot be set on RGB streams encoded in BT.709 sRGB.\n"

l_.str.1:                               ; @.str.1
	.asciz	"Warning: chroma_sample_position can only be set for 4:2:0 streams.\n"

	.comm	_UINT32_MAX,8,3                 ; @UINT32_MAX
	.comm	_INT_MAX,8,3                    ; @INT_MAX
	.no_dead_strip	_av1_metadata_update_sequence_header
.subsections_via_symbols
