	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function write_sei
_write_sei:                             ## @write_sei
	.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
	testq	%rcx, %rcx
	je	LBB0_14
## %bb.1:
	movq	%rcx, %r8
	movl	%esi, %eax
	movq	(%rdi), %rsi
	movq	%rcx, %r10
	movq	%rdx, %r14
	testl	%eax, %eax
	je	LBB0_4
## %bb.2:
	movq	%rdx, %r14
	movq	%r8, %rcx
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$255, %eax
	movl	$255, %ebx
	cmovll	%eax, %ebx
	movl	%ebx, (%r14)
	addq	$4, %r14
	leaq	-1(%rcx), %r10
	subl	%ebx, %eax
	je	LBB0_4
## %bb.8:                               ##   in Loop: Header=BB0_3 Depth=1
	cmpq	$1, %rcx
	movq	%r10, %rcx
	jne	LBB0_3
LBB0_4:
	testq	%rsi, %rsi
	je	LBB0_5
## %bb.6:
	testq	%r10, %r10
	je	LBB0_7
## %bb.9:
	movq	%rsi, %rax
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	cmpq	$255, %rax
	movl	$255, %ecx
	cmovbq	%rax, %rcx
	movl	%ecx, (%r14)
	addq	$4, %r14
	leaq	-1(%r10), %r9
	subq	%rcx, %rax
	je	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	cmpq	$1, %r10
	movq	%r9, %r10
	jne	LBB0_10
	jmp	LBB0_12
LBB0_5:
	movq	%r10, %r9
LBB0_12:
	cmpq	%rsi, %r9
	jae	LBB0_13
	jmp	LBB0_14
LBB0_7:
	movq	%r10, %r9
	cmpq	%rsi, %r9
	jb	LBB0_14
LBB0_13:
	subq	%rdx, %r14
	shrq	$2, %r14
	movl	8(%rdi), %edi
	movl	%r14d, %ecx
	callq	_copy_emulation_prev
	testl	%eax, %eax
	js	LBB0_14
## %bb.15:
	addl	%r14d, %eax
	jmp	LBB0_16
LBB0_14:
	movq	_AVERROR_BUFFER_TOO_SMALL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_16:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AVERROR_BUFFER_TOO_SMALL,4,2   ## @AVERROR_BUFFER_TOO_SMALL
	.no_dead_strip	_write_sei
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function write_sei
_write_sei:                             ; @write_sei
	.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
	cbz	x3, LBB0_13
; %bb.1:
	mov	x4, x3
	mov	x8, x1
	ldr	x1, [x0]
	mov	x10, x3
	mov	x9, x2
	cbz	w8, LBB0_4
; %bb.2:
	mov	w11, #255
	mov	x9, x2
	mov	x12, x4
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	cmp	w8, #255
	csel	w10, w8, w11, lt
	str	w10, [x9], #4
	sub	w8, w8, w10
	sub	x10, x12, #1
	cmp	w8, #0
	ccmp	x12, #1, #4, ne
	mov	x12, x10
	b.ne	LBB0_3
LBB0_4:
	cbz	x1, LBB0_8
; %bb.5:
	cbz	x10, LBB0_10
; %bb.6:
	mov	w8, #255
	mov	x11, x1
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	cmp	x11, #255
	csel	x12, x11, x8, lo
	str	w12, [x9], #4
	sub	x11, x11, x12
	sub	x12, x10, #1
	cmp	x11, #0
	ccmp	x10, #1, #4, ne
	mov	x10, x12
	b.ne	LBB0_7
	b	LBB0_9
LBB0_8:
	mov	x12, x10
LBB0_9:
	cmp	x12, x1
	b.hs	LBB0_11
	b	LBB0_13
LBB0_10:
	mov	x12, x10
	cmp	x12, x1
	b.lo	LBB0_13
LBB0_11:
	sub	x8, x9, x2
	lsr	x19, x8, #2
	ldr	w0, [x0, #8]
	mov	x3, x19
	bl	_copy_emulation_prev
	tbnz	w0, #31, LBB0_13
; %bb.12:
	add	w0, w0, w19
	b	LBB0_14
LBB0_13:
Lloh0:
	adrp	x8, _AVERROR_BUFFER_TOO_SMALL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AVERROR_BUFFER_TOO_SMALL@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
LBB0_14:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_AVERROR_BUFFER_TOO_SMALL,4,2   ; @AVERROR_BUFFER_TOO_SMALL
	.no_dead_strip	_write_sei
.subsections_via_symbols
