	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cx231xx_copy_video_line        ## -- Begin function cx231xx_copy_video_line
	.p2align	4, 0x90
_cx231xx_copy_video_line:               ## @cx231xx_copy_video_line
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, %r14d
	movq	%rcx, %r13
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movslq	(%rdi), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	cmpl	%r8d, (%rsi)
	je	LBB0_2
## %bb.1:
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movq	%rdx, %r12
	callq	_cx231xx_reset_video_buffer
	movq	%r12, %rdx
LBB0_2:
	xorl	%eax, %eax
	cmpq	$0, 24(%r15)
	setne	%al
	movq	8(%r15,%rax,8), %r12
	movl	%r14d, (%rbx)
	movq	8(%rbx), %rax
	movq	16(%rbx), %rcx
	cmpq	%r13, %rax
	movq	%r13, %r14
	cmovlq	%rax, %r14
	cmpq	24(%rbx), %rcx
	jge	LBB0_3
## %bb.4:
	movl	$1, 32(%rbx)
	testq	%r12, %r12
	je	LBB0_5
## %bb.6:
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movq	%r14, %rcx
	callq	_cx231xx_do_copy
	addq	%r14, 40(%rbx)
	subq	%r14, 8(%rbx)
	jne	LBB0_9
## %bb.7:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	addq	%rax, %rax
	movq	%rax, 8(%rbx)
	incq	16(%rbx)
	movl	$0, 32(%rbx)
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_cx231xx_is_buffer_done
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movq	%r12, %rdx
	callq	_buffer_filled
	movq	$0, 40(%rbx)
	movq	$0, 16(%rbx)
	jmp	LBB0_9
LBB0_3:
	xorl	%ecx, %ecx
	cmpq	%r13, %rax
	setg	%cl
	subq	%r14, %rax
	movq	%rax, 8(%rbx)
	movl	%ecx, 32(%rbx)
	xorl	%r14d, %r14d
	jmp	LBB0_9
LBB0_5:
	xorl	%ecx, %ecx
	cmpq	%r13, %rax
	setg	%cl
	subq	%r14, %rax
	movq	%rax, 8(%rbx)
	movl	%ecx, 32(%rbx)
LBB0_9:
	movq	%r14, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cx231xx_copy_video_line        ; -- Begin function cx231xx_copy_video_line
	.p2align	2
_cx231xx_copy_video_line:               ; @cx231xx_copy_video_line
	.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	x20, x4
	mov	x24, x3
	mov	x23, x2
	mov	x19, x1
	mov	x21, x0
	ldrsw	x25, [x0]
	ldr	w8, [x1]
	cmp	w8, w4
	b.eq	LBB0_2
; %bb.1:
	mov	x0, x21
	mov	x1, x19
	bl	_cx231xx_reset_video_buffer
LBB0_2:
	ldr	x8, [x21, #24]
	mov	w9, #16
	mov	w10, #8
	cmp	x8, #0
	csel	x8, x10, x9, eq
	ldr	x22, [x21, x8]
	str	w20, [x19]
	ldp	x8, x9, [x19, #8]
	cmp	x8, x24
	csel	x20, x8, x24, lt
	ldr	x10, [x19, #24]
	cmp	x9, x10
	b.ge	LBB0_7
; %bb.3:
	mov	w9, #1
	str	w9, [x19, #32]
	cbz	x22, LBB0_8
; %bb.4:
	mov	x0, x21
	mov	x1, x19
	mov	x2, x23
	mov	x3, x20
	bl	_cx231xx_do_copy
	ldr	x8, [x19, #40]
	add	x8, x8, x20
	str	x8, [x19, #40]
	ldr	x8, [x19, #8]
	subs	x8, x8, x20
	str	x8, [x19, #8]
	b.ne	LBB0_9
; %bb.5:
	lsl	x8, x25, #1
	ldr	x9, [x19, #16]
	add	x9, x9, #1
	stp	x8, x9, [x19, #8]
	str	wzr, [x19, #32]
	mov	x0, x21
	mov	x1, x19
	bl	_cx231xx_is_buffer_done
	cbz	x0, LBB0_9
; %bb.6:
	mov	x0, x21
	mov	x1, x19
	mov	x2, x22
	bl	_buffer_filled
	str	xzr, [x19, #40]
	str	xzr, [x19, #16]
	b	LBB0_9
LBB0_7:
	cmp	x8, x24
	cset	w9, gt
	sub	x8, x8, x20
	str	x8, [x19, #8]
	str	w9, [x19, #32]
	mov	x20, #0
	b	LBB0_9
LBB0_8:
	cmp	x8, x24
	cset	w9, gt
	sub	x8, x8, x20
	str	x8, [x19, #8]
	str	w9, [x19, #32]
LBB0_9:
	mov	x0, x20
	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
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
