	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function xavs2_copy_frame_with_shift
_xavs2_copy_frame_with_shift:           ## @xavs2_copy_frame_with_shift
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r13d
	movq	%rsi, -80(%rbp)                 ## 8-byte Spill
	movq	(%rdi), %rcx
	movq	8(%rdi), %rax
	cmpl	$0, (%rax)
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	jle	LBB0_7
## %bb.1:
	movslq	(%rcx), %rdx
	xorl	%r8d, %r8d
	xorl	%r14d, %r14d
	xorl	%r12d, %r12d
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	incq	%r12
	movq	8(%rdi), %rax
	movslq	(%rax), %rcx
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	addq	%rdx, %r14
	addq	$4, %r8
	cmpq	%rcx, %r12
	jge	LBB0_6
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
	movq	24(%rdi), %rax
	movq	(%rax), %rcx
	movq	%r12, %rax
	imulq	%rdx, %rax
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	leaq	(%rcx,%rax,4), %rdi
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	(%rcx), %rax
	movq	8(%rcx), %rcx
	movq	(%rax), %r15
	movslq	(%rcx), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%esi, %esi
                                        ## kill: def $edx killed $edx killed $rdx
	movq	%r8, %rbx
	callq	_memset
	movq	%rbx, %r8
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movq	16(%rdi), %rax
	cmpl	$0, (%rax)
	jle	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	leaq	(%rcx,%r14,4), %rdx
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	imulq	%r8, %rcx
	addq	%rcx, %r15
	xorl	%esi, %esi
	.p2align	4, 0x90
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r15,%rsi,4), %ebx
	movl	%r13d, %ecx
	shll	%cl, %ebx
	movl	%ebx, (%rdx,%rsi,4)
	incq	%rsi
	movslq	(%rax), %rcx
	cmpq	%rcx, %rsi
	jl	LBB0_4
	jmp	LBB0_5
LBB0_6:
	movq	(%rdi), %rcx
LBB0_7:
	cmpl	$0, 4(%rax)
	jle	LBB0_14
## %bb.8:
	movslq	4(%rcx), %rdx
	xorl	%r8d, %r8d
	xorl	%r14d, %r14d
	xorl	%r12d, %r12d
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_9 Depth=1
	incq	%r12
	movq	8(%rdi), %rax
	movslq	4(%rax), %rcx
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	addq	%rdx, %r14
	addq	$4, %r8
	cmpq	%rcx, %r12
	jge	LBB0_13
LBB0_9:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_11 Depth 2
	movq	24(%rdi), %rax
	movq	8(%rax), %rcx
	movq	%r12, %rax
	imulq	%rdx, %rax
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	leaq	(%rcx,%rax,4), %rdi
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	(%rcx), %rax
	movq	8(%rcx), %rcx
	movq	8(%rax), %r15
	movslq	4(%rcx), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%esi, %esi
                                        ## kill: def $edx killed $edx killed $rdx
	movq	%r8, %rbx
	callq	_memset
	movq	%rbx, %r8
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movq	16(%rdi), %rax
	cmpl	$0, 4(%rax)
	jle	LBB0_12
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	leaq	(%rcx,%r14,4), %rdx
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	imulq	%r8, %rcx
	addq	%rcx, %r15
	xorl	%esi, %esi
	.p2align	4, 0x90
LBB0_11:                                ##   Parent Loop BB0_9 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r15,%rsi,4), %ebx
	movl	%r13d, %ecx
	shll	%cl, %ebx
	movl	%ebx, (%rdx,%rsi,4)
	incq	%rsi
	movslq	4(%rax), %rcx
	cmpq	%rcx, %rsi
	jl	LBB0_11
	jmp	LBB0_12
LBB0_13:
	movq	(%rdi), %rcx
LBB0_14:
	cmpl	$0, 8(%rax)
	jle	LBB0_20
## %bb.15:
	movslq	8(%rcx), %rdx
	xorl	%r8d, %r8d
	xorl	%r14d, %r14d
	xorl	%r12d, %r12d
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_16
	.p2align	4, 0x90
LBB0_19:                                ##   in Loop: Header=BB0_16 Depth=1
	incq	%r12
	movq	8(%rdi), %rax
	movslq	8(%rax), %rax
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	addq	%rdx, %r14
	addq	$4, %r8
	cmpq	%rax, %r12
	jge	LBB0_20
LBB0_16:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_18 Depth 2
	movq	24(%rdi), %rax
	movq	16(%rax), %rcx
	movq	%r12, %rax
	imulq	%rdx, %rax
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	leaq	(%rcx,%rax,4), %rdi
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	(%rcx), %rax
	movq	8(%rcx), %rcx
	movq	16(%rax), %r15
	movslq	8(%rcx), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%esi, %esi
                                        ## kill: def $edx killed $edx killed $rdx
	movq	%r8, %rbx
	callq	_memset
	movq	%rbx, %r8
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movq	16(%rdi), %rax
	cmpl	$0, 8(%rax)
	jle	LBB0_19
## %bb.17:                              ##   in Loop: Header=BB0_16 Depth=1
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	leaq	(%rcx,%r14,4), %rdx
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	imulq	%r8, %rcx
	addq	%rcx, %r15
	xorl	%esi, %esi
	.p2align	4, 0x90
LBB0_18:                                ##   Parent Loop BB0_16 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r15,%rsi,4), %ebx
	movl	%r13d, %ecx
	shll	%cl, %ebx
	movl	%ebx, (%rdx,%rsi,4)
	incq	%rsi
	movslq	8(%rax), %rcx
	cmpq	%rcx, %rsi
	jl	LBB0_18
	jmp	LBB0_19
LBB0_20:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_xavs2_copy_frame_with_shift
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function xavs2_copy_frame_with_shift
_xavs2_copy_frame_with_shift:           ; @xavs2_copy_frame_with_shift
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x19, x2
	mov	x20, x1
	mov	x21, x0
	ldp	x9, x8, [x0]
	ldr	w10, [x8]
	cmp	w10, #1
	b.lt	LBB0_7
; %bb.1:
	mov	x23, #0
	mov	x24, #0
	mov	x25, #0
	ldrsw	x22, [x9]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x25, x25, #1
	ldr	x8, [x21, #8]
	ldrsw	x9, [x8]
	add	x24, x24, x22
	add	x23, x23, #4
	cmp	x25, x9
	b.ge	LBB0_6
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
	ldr	x8, [x21, #24]
	ldr	x26, [x8]
	mul	x8, x25, x22
	add	x0, x26, x8, lsl #2
	ldp	x8, x9, [x20]
	ldr	x27, [x8]
	ldrsw	x28, [x9]
	mov	w1, #0
	mov	x2, x22
	bl	_memset
	ldr	x8, [x21, #16]
	ldr	w9, [x8]
	cmp	w9, #1
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x9, #0
	add	x10, x26, x24, lsl #2
	madd	x11, x23, x28, x27
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	lsl	x12, x9, #2
	ldr	w13, [x11, x12]
	lsl	w13, w13, w19
	str	w13, [x10, x12]
	add	x9, x9, #1
	ldrsw	x12, [x8]
	cmp	x9, x12
	b.lt	LBB0_5
	b	LBB0_2
LBB0_6:
	ldr	x9, [x21]
LBB0_7:
	ldr	w10, [x8, #4]
	cmp	w10, #1
	b.lt	LBB0_14
; %bb.8:
	mov	x23, #0
	mov	x24, #0
	mov	x25, #0
	ldrsw	x22, [x9, #4]
	b	LBB0_10
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=1
	add	x25, x25, #1
	ldr	x8, [x21, #8]
	ldrsw	x9, [x8, #4]
	add	x24, x24, x22
	add	x23, x23, #4
	cmp	x25, x9
	b.ge	LBB0_13
LBB0_10:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_12 Depth 2
	ldr	x8, [x21, #24]
	ldr	x26, [x8, #8]
	mul	x8, x25, x22
	add	x0, x26, x8, lsl #2
	ldp	x8, x9, [x20]
	ldr	x27, [x8, #8]
	ldrsw	x28, [x9, #4]
	mov	w1, #0
	mov	x2, x22
	bl	_memset
	ldr	x8, [x21, #16]
	ldr	w9, [x8, #4]
	cmp	w9, #1
	b.lt	LBB0_9
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	mov	x9, #0
	add	x10, x26, x24, lsl #2
	madd	x11, x23, x28, x27
LBB0_12:                                ;   Parent Loop BB0_10 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	lsl	x12, x9, #2
	ldr	w13, [x11, x12]
	lsl	w13, w13, w19
	str	w13, [x10, x12]
	add	x9, x9, #1
	ldrsw	x12, [x8, #4]
	cmp	x9, x12
	b.lt	LBB0_12
	b	LBB0_9
LBB0_13:
	ldr	x9, [x21]
LBB0_14:
	ldr	w8, [x8, #8]
	cmp	w8, #1
	b.lt	LBB0_20
; %bb.15:
	mov	x23, #0
	mov	x24, #0
	mov	x25, #0
	ldrsw	x22, [x9, #8]
	b	LBB0_17
LBB0_16:                                ;   in Loop: Header=BB0_17 Depth=1
	add	x25, x25, #1
	ldr	x8, [x21, #8]
	ldrsw	x8, [x8, #8]
	add	x24, x24, x22
	add	x23, x23, #4
	cmp	x25, x8
	b.ge	LBB0_20
LBB0_17:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_19 Depth 2
	ldr	x8, [x21, #24]
	ldr	x26, [x8, #16]
	mul	x8, x25, x22
	add	x0, x26, x8, lsl #2
	ldp	x8, x9, [x20]
	ldr	x27, [x8, #16]
	ldrsw	x28, [x9, #8]
	mov	w1, #0
	mov	x2, x22
	bl	_memset
	ldr	x8, [x21, #16]
	ldr	w9, [x8, #8]
	cmp	w9, #1
	b.lt	LBB0_16
; %bb.18:                               ;   in Loop: Header=BB0_17 Depth=1
	mov	x9, #0
	add	x10, x26, x24, lsl #2
	madd	x11, x23, x28, x27
LBB0_19:                                ;   Parent Loop BB0_17 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	lsl	x12, x9, #2
	ldr	w13, [x11, x12]
	lsl	w13, w13, w19
	str	w13, [x10, x12]
	add	x9, x9, #1
	ldrsw	x12, [x8, #8]
	cmp	x9, x12
	b.lt	LBB0_19
	b	LBB0_16
LBB0_20:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_xavs2_copy_frame_with_shift
.subsections_via_symbols
