	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function decode_rle_bpp2
_decode_rle_bpp2:                       ## @decode_rle_bpp2
	.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
	cmpl	$0, 4(%rdi)
	jle	LBB0_36
## %bb.1:
	movq	%rdx, %rbx
	movl	(%rdi), %r14d
	movq	(%rsi), %rax
	movq	(%rax), %r15
	xorl	%eax, %eax
	movq	%rdx, -56(%rbp)                 ## 8-byte Spill
	movq	%rsi, -80(%rbp)                 ## 8-byte Spill
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_35:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	-80(%rbp), %rsi                 ## 8-byte Reload
	movq	8(%rsi), %rax
	movslq	(%rax), %rax
	leaq	(%r15,%rax,4), %r15
	movl	-60(%rbp), %eax                 ## 4-byte Reload
	incl	%eax
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	cmpl	4(%rdi), %eax
	jge	LBB0_36
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_8 Depth 2
                                        ##       Child Loop BB0_24 Depth 3
                                        ##       Child Loop BB0_11 Depth 3
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	movq	%rbx, %rdi
	cmpl	$804, %r14d                     ## imm = 0x324
	jl	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	callq	_bytestream2_get_be16
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	callq	_bytestream2_get_byte
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %r13d
	movq	%rbx, %rdi
	callq	_bytestream2_get_bytes_left
	cmpl	%r13d, %eax
	jl	LBB0_38
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	testl	%r13d, %r13d
	jle	LBB0_35
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%r12d, %r12d
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_20:                                ##   in Loop: Header=BB0_8 Depth=2
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	subl	%edx, %r13d
	addl	$-2, %r13d
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	testl	%r13d, %r13d
	jle	LBB0_35
LBB0_8:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Loop Header: Depth=2
                                        ##       Child Loop BB0_24 Depth 3
                                        ##       Child Loop BB0_11 Depth 3
	movl	%r13d, -44(%rbp)                ## 4-byte Spill
	movq	%rbx, %rdi
	callq	_bytestream2_get_byte
	movl	%eax, %edx
	testb	$-128, %dl
	movq	%rbx, %r13
	movq	%rdx, %rbx
	jne	LBB0_21
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=2
	testl	%edx, %edx
	js	LBB0_20
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=2
	leal	1(%rdx), %r13d
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_19:                                ##   in Loop: Header=BB0_11 Depth=3
	decl	%r13d
	je	LBB0_20
LBB0_11:                                ##   Parent Loop BB0_2 Depth=1
                                        ##     Parent Loop BB0_8 Depth=2
                                        ## =>    This Inner Loop Header: Depth=3
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_bytestream2_get_byte
	cmpl	%r14d, %r12d
	jl	LBB0_12
## %bb.13:                              ##   in Loop: Header=BB0_11 Depth=3
	cmpl	%r14d, %r12d
	jl	LBB0_14
LBB0_15:                                ##   in Loop: Header=BB0_11 Depth=3
	cmpl	%r14d, %r12d
	jge	LBB0_17
LBB0_16:                                ##   in Loop: Header=BB0_11 Depth=3
	movl	%eax, %ecx
	shrl	$2, %ecx
	andl	$3, %ecx
	movslq	%r12d, %rdx
	incl	%r12d
	movl	%ecx, (%r15,%rdx,4)
LBB0_17:                                ##   in Loop: Header=BB0_11 Depth=3
	movq	%rbx, %rdx
	cmpl	%r14d, %r12d
	jge	LBB0_19
## %bb.18:                              ##   in Loop: Header=BB0_11 Depth=3
	andl	$3, %eax
	movslq	%r12d, %rcx
	incl	%r12d
	movl	%eax, (%r15,%rcx,4)
	jmp	LBB0_19
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_11 Depth=3
	movl	%eax, %ecx
	shrl	$6, %ecx
	andl	$3, %ecx
	movslq	%r12d, %rdx
	incl	%r12d
	movl	%ecx, (%r15,%rdx,4)
	cmpl	%r14d, %r12d
	jge	LBB0_15
LBB0_14:                                ##   in Loop: Header=BB0_11 Depth=3
	movl	%eax, %ecx
	shrl	$4, %ecx
	andl	$3, %ecx
	movslq	%r12d, %rdx
	incl	%r12d
	movl	%ecx, (%r15,%rdx,4)
	cmpl	%r14d, %r12d
	jl	LBB0_16
	jmp	LBB0_17
	.p2align	4, 0x90
LBB0_21:                                ##   in Loop: Header=BB0_8 Depth=2
	movq	%r13, %rdi
	callq	_bytestream2_get_byte
	cmpl	$256, %ebx                      ## imm = 0x100
	jg	LBB0_22
## %bb.23:                              ##   in Loop: Header=BB0_8 Depth=2
	movl	$257, %ecx                      ## imm = 0x101
	subl	%ebx, %ecx
	movl	%eax, %edx
	shrl	$6, %edx
	andl	$3, %edx
	movl	%eax, %esi
	shrl	$4, %esi
	andl	$3, %esi
	movl	%eax, %edi
	shrl	$2, %edi
	andl	$3, %edi
	andl	$3, %eax
	cmpl	$2, %ecx
	movl	$1, %ebx
	cmovll	%ebx, %ecx
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	jmp	LBB0_24
	.p2align	4, 0x90
LBB0_32:                                ##   in Loop: Header=BB0_24 Depth=3
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	decl	%ecx
	je	LBB0_33
LBB0_24:                                ##   Parent Loop BB0_2 Depth=1
                                        ##     Parent Loop BB0_8 Depth=2
                                        ## =>    This Inner Loop Header: Depth=3
	cmpl	%r14d, %r12d
	jl	LBB0_25
## %bb.26:                              ##   in Loop: Header=BB0_24 Depth=3
	cmpl	%r14d, %r12d
	jl	LBB0_27
LBB0_28:                                ##   in Loop: Header=BB0_24 Depth=3
	cmpl	%r14d, %r12d
	jl	LBB0_29
LBB0_30:                                ##   in Loop: Header=BB0_24 Depth=3
	cmpl	%r14d, %r12d
	jge	LBB0_32
	jmp	LBB0_31
	.p2align	4, 0x90
LBB0_25:                                ##   in Loop: Header=BB0_24 Depth=3
	movslq	%r12d, %rbx
	incl	%r12d
	movl	%edx, (%r15,%rbx,4)
	cmpl	%r14d, %r12d
	jge	LBB0_28
LBB0_27:                                ##   in Loop: Header=BB0_24 Depth=3
	movslq	%r12d, %rbx
	incl	%r12d
	movl	%esi, (%r15,%rbx,4)
	cmpl	%r14d, %r12d
	jge	LBB0_30
LBB0_29:                                ##   in Loop: Header=BB0_24 Depth=3
	movslq	%r12d, %rbx
	incl	%r12d
	movl	%edi, (%r15,%rbx,4)
	cmpl	%r14d, %r12d
	jge	LBB0_32
LBB0_31:                                ##   in Loop: Header=BB0_24 Depth=3
	movslq	%r12d, %rbx
	incl	%r12d
	movl	%eax, (%r15,%rbx,4)
	jmp	LBB0_32
	.p2align	4, 0x90
LBB0_22:                                ##   in Loop: Header=BB0_8 Depth=2
	movq	%r13, %rbx
	movl	-44(%rbp), %r13d                ## 4-byte Reload
LBB0_33:                                ##   in Loop: Header=BB0_8 Depth=2
	addl	$-2, %r13d
	testl	%r13d, %r13d
	jg	LBB0_8
	jmp	LBB0_35
LBB0_36:
	xorl	%eax, %eax
	jmp	LBB0_37
LBB0_38:
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_37:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
	.no_dead_strip	_decode_rle_bpp2
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function decode_rle_bpp2
_decode_rle_bpp2:                       ; @decode_rle_bpp2
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	ldr	w8, [x0, #4]
	cmp	w8, #1
	b.lt	LBB0_34
; %bb.1:
	mov	x19, x2
	mov	x21, x1
	mov	w24, #0
	ldr	w25, [x0]
	ldr	x8, [x1]
	ldr	x26, [x8]
	mov	w27, #257
	str	x0, [sp, #8]                    ; 8-byte Folded Spill
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x21, #8]
	ldrsw	x8, [x8]
	add	x26, x26, x8, lsl #2
	add	w24, w24, #1
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
	ldr	w8, [x0, #4]
	cmp	w24, w8
	b.ge	LBB0_34
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_10 Depth 2
                                        ;       Child Loop BB0_25 Depth 3
                                        ;       Child Loop BB0_14 Depth 3
	mov	x0, x19
	cmp	w25, #804
	b.lt	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	bl	_bytestream2_get_be16
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_3 Depth=1
	bl	_bytestream2_get_byte
LBB0_6:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	x22, x0
	mov	x0, x19
	bl	_bytestream2_get_bytes_left
	cmp	w0, w22
	b.lt	LBB0_35
; %bb.7:                                ;   in Loop: Header=BB0_3 Depth=1
	cmp	w22, #1
	b.lt	LBB0_2
; %bb.8:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	w28, #0
	b	LBB0_10
LBB0_9:                                 ;   in Loop: Header=BB0_10 Depth=2
	sub	w22, w22, #2
	cmp	w22, #0
	b.le	LBB0_2
LBB0_10:                                ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Loop Header: Depth=2
                                        ;       Child Loop BB0_25 Depth 3
                                        ;       Child Loop BB0_14 Depth 3
	mov	x0, x19
	bl	_bytestream2_get_byte
	mov	x23, x0
	tbnz	w0, #7, LBB0_22
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=2
	tbnz	w23, #31, LBB0_33
; %bb.12:                               ;   in Loop: Header=BB0_10 Depth=2
	add	w20, w23, #1
	b	LBB0_14
LBB0_13:                                ;   in Loop: Header=BB0_14 Depth=3
	subs	w20, w20, #1
	b.eq	LBB0_33
LBB0_14:                                ;   Parent Loop BB0_3 Depth=1
                                        ;     Parent Loop BB0_10 Depth=2
                                        ; =>    This Inner Loop Header: Depth=3
	mov	x0, x19
	bl	_bytestream2_get_byte
	cmp	w28, w25
	b.lt	LBB0_18
; %bb.15:                               ;   in Loop: Header=BB0_14 Depth=3
	cmp	w28, w25
	b.lt	LBB0_19
LBB0_16:                                ;   in Loop: Header=BB0_14 Depth=3
	cmp	w28, w25
	b.lt	LBB0_20
LBB0_17:                                ;   in Loop: Header=BB0_14 Depth=3
	cmp	w28, w25
	b.ge	LBB0_13
	b	LBB0_21
LBB0_18:                                ;   in Loop: Header=BB0_14 Depth=3
	ubfx	w8, w0, #6, #2
	str	w8, [x26, w28, sxtw #2]
	add	w28, w28, #1
	cmp	w28, w25
	b.ge	LBB0_16
LBB0_19:                                ;   in Loop: Header=BB0_14 Depth=3
	ubfx	w8, w0, #4, #2
	str	w8, [x26, w28, sxtw #2]
	add	w28, w28, #1
	cmp	w28, w25
	b.ge	LBB0_17
LBB0_20:                                ;   in Loop: Header=BB0_14 Depth=3
	ubfx	w8, w0, #2, #2
	str	w8, [x26, w28, sxtw #2]
	add	w28, w28, #1
	cmp	w28, w25
	b.ge	LBB0_13
LBB0_21:                                ;   in Loop: Header=BB0_14 Depth=3
	and	w8, w0, #0x3
	str	w8, [x26, w28, sxtw #2]
	add	w28, w28, #1
	b	LBB0_13
LBB0_22:                                ;   in Loop: Header=BB0_10 Depth=2
	mov	x0, x19
	bl	_bytestream2_get_byte
	cmp	w23, #256
	b.gt	LBB0_9
; %bb.23:                               ;   in Loop: Header=BB0_10 Depth=2
	sub	w12, w27, w23
	ubfx	w8, w0, #6, #2
	ubfx	w9, w0, #4, #2
	ubfx	w10, w0, #2, #2
	and	w11, w0, #0x3
	cmp	w12, #1
	csinc	w12, w12, wzr, gt
	b	LBB0_25
LBB0_24:                                ;   in Loop: Header=BB0_25 Depth=3
	subs	w12, w12, #1
	b.eq	LBB0_9
LBB0_25:                                ;   Parent Loop BB0_3 Depth=1
                                        ;     Parent Loop BB0_10 Depth=2
                                        ; =>    This Inner Loop Header: Depth=3
	cmp	w28, w25
	b.lt	LBB0_29
; %bb.26:                               ;   in Loop: Header=BB0_25 Depth=3
	cmp	w28, w25
	b.lt	LBB0_30
LBB0_27:                                ;   in Loop: Header=BB0_25 Depth=3
	cmp	w28, w25
	b.lt	LBB0_31
LBB0_28:                                ;   in Loop: Header=BB0_25 Depth=3
	cmp	w28, w25
	b.ge	LBB0_24
	b	LBB0_32
LBB0_29:                                ;   in Loop: Header=BB0_25 Depth=3
	str	w8, [x26, w28, sxtw #2]
	add	w28, w28, #1
	cmp	w28, w25
	b.ge	LBB0_27
LBB0_30:                                ;   in Loop: Header=BB0_25 Depth=3
	str	w9, [x26, w28, sxtw #2]
	add	w28, w28, #1
	cmp	w28, w25
	b.ge	LBB0_28
LBB0_31:                                ;   in Loop: Header=BB0_25 Depth=3
	str	w10, [x26, w28, sxtw #2]
	add	w28, w28, #1
	cmp	w28, w25
	b.ge	LBB0_24
LBB0_32:                                ;   in Loop: Header=BB0_25 Depth=3
	str	w11, [x26, w28, sxtw #2]
	add	w28, w28, #1
	b	LBB0_24
LBB0_33:                                ;   in Loop: Header=BB0_10 Depth=2
	sub	w8, w22, w23
	sub	w22, w8, #2
	cmp	w22, #0
	b.gt	LBB0_10
	b	LBB0_2
LBB0_34:
	mov	w0, #0
	b	LBB0_36
LBB0_35:
Lloh0:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
LBB0_36:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
	.no_dead_strip	_decode_rle_bpp2
.subsections_via_symbols
