	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function jpeg2000_decode_tile
_jpeg2000_decode_tile:                  ## @jpeg2000_decode_tile
	.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
	movq	%rsi, %r14
	movq	(%rdi), %rbx
	movq	24(%rbx), %r12
	movslq	%edx, %r13
	leaq	(%r12,%r13,8), %r15
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_tile_codeblocks
	movq	(%r12,%r13,8), %rax
	cmpq	$0, (%rax)
	je	LBB0_2
## %bb.1:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_mct_decode
LBB0_2:
	movl	(%rbx), %ecx
	testl	%ecx, %ecx
	jle	LBB0_10
## %bb.3:
	movq	8(%rbx), %rax
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$0, (%rax,%rdx,4)
	js	LBB0_6
## %bb.4:                               ##   in Loop: Header=BB0_5 Depth=1
	incq	%rdx
	cmpq	%rdx, %rcx
	jne	LBB0_5
	jmp	LBB0_10
LBB0_6:
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	leaq	1(%rdx), %rsi
	movl	%esi, (%rax,%rdx,4)
	movslq	(%rbx), %rcx
	movq	%rsi, %rdx
	cmpq	%rcx, %rsi
	jl	LBB0_7
## %bb.8:
	testb	$1, %cl
	jne	LBB0_10
## %bb.9:
	movl	$0, -4(%rax,%rcx,4)
LBB0_10:
	movl	16(%rbx), %ecx
	cmpl	$8, %ecx
	jg	LBB0_12
## %bb.11:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movq	%r14, %rdx
	movl	$8, %ecx
	callq	_write_frame_8
	jmp	LBB0_13
LBB0_12:
	movq	(%r14), %rax
	movq	_AV_PIX_FMT_XYZ12@GOTPCREL(%rip), %r8
	movq	_AV_PIX_FMT_RGB48@GOTPCREL(%rip), %rsi
	movq	_AV_PIX_FMT_GRAY16@GOTPCREL(%rip), %rdi
	cmpq	(%rdi), %rax
	movq	_AV_PIX_FMT_RGBA64@GOTPCREL(%rip), %rdi
	movl	$16, %edx
	cmovel	%edx, %ecx
	cmpq	(%rdi), %rax
	cmovel	%edx, %ecx
	cmpq	(%rsi), %rax
	cmovel	%edx, %ecx
	cmpq	(%r8), %rax
	cmovel	%edx, %ecx
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movq	%r14, %rdx
	callq	_write_frame_16
LBB0_13:
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_PIX_FMT_XYZ12,8,3           ## @AV_PIX_FMT_XYZ12
	.comm	_AV_PIX_FMT_RGB48,8,3           ## @AV_PIX_FMT_RGB48
	.comm	_AV_PIX_FMT_RGBA64,8,3          ## @AV_PIX_FMT_RGBA64
	.comm	_AV_PIX_FMT_GRAY16,8,3          ## @AV_PIX_FMT_GRAY16
	.no_dead_strip	_jpeg2000_decode_tile
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function jpeg2000_decode_tile
_jpeg2000_decode_tile:                  ; @jpeg2000_decode_tile
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	ldr	x20, [x0]
	ldr	x8, [x20, #24]
	add	x21, x8, w2, sxtw #3
	mov	x0, x20
	mov	x1, x21
	bl	_tile_codeblocks
	ldr	x8, [x21]
	ldr	x8, [x8]
	cbz	x8, LBB0_2
; %bb.1:
	mov	x0, x20
	mov	x1, x21
	bl	_mct_decode
LBB0_2:
	ldr	w9, [x20]
	cmp	w9, #1
	b.lt	LBB0_10
; %bb.3:
	ldr	x8, [x20, #8]
	mov	x10, x8
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w11, [x10]
	tbnz	w11, #31, LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	add	x10, x10, #4
	subs	x9, x9, #1
	b.ne	LBB0_4
	b	LBB0_10
LBB0_6:
	mov	x10, #0
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	add	x11, x10, #1
	str	w11, [x8, x10, lsl #2]
	ldrsw	x9, [x20]
	mov	x10, x11
	cmp	x11, x9
	b.lt	LBB0_7
; %bb.8:
	tbnz	w9, #0, LBB0_10
; %bb.9:
	sub	w9, w9, #1
	str	wzr, [x8, w9, sxtw #2]
LBB0_10:
	ldr	w8, [x20, #16]
	cmp	w8, #8
	b.gt	LBB0_12
; %bb.11:
	mov	x0, x20
	mov	x1, x21
	mov	x2, x19
	mov	w3, #8
	bl	_write_frame_8
	b	LBB0_13
LBB0_12:
	ldr	x9, [x19]
Lloh0:
	adrp	x10, _AV_PIX_FMT_XYZ12@GOTPAGE
Lloh1:
	ldr	x10, [x10, _AV_PIX_FMT_XYZ12@GOTPAGEOFF]
Lloh2:
	ldr	x10, [x10]
Lloh3:
	adrp	x11, _AV_PIX_FMT_RGB48@GOTPAGE
Lloh4:
	ldr	x11, [x11, _AV_PIX_FMT_RGB48@GOTPAGEOFF]
Lloh5:
	ldr	x11, [x11]
Lloh6:
	adrp	x12, _AV_PIX_FMT_RGBA64@GOTPAGE
Lloh7:
	ldr	x12, [x12, _AV_PIX_FMT_RGBA64@GOTPAGEOFF]
Lloh8:
	ldr	x12, [x12]
Lloh9:
	adrp	x13, _AV_PIX_FMT_GRAY16@GOTPAGE
Lloh10:
	ldr	x13, [x13, _AV_PIX_FMT_GRAY16@GOTPAGEOFF]
Lloh11:
	ldr	x13, [x13]
	cmp	x9, x13
	ccmp	x9, x12, #4, ne
	ccmp	x9, x11, #4, ne
	ccmp	x9, x10, #4, ne
	mov	w9, #16
	csel	w3, w9, w8, eq
	mov	x0, x20
	mov	x1, x21
	mov	x2, x19
	bl	_write_frame_16
LBB0_13:
	mov	w0, #0
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_PIX_FMT_XYZ12,8,3           ; @AV_PIX_FMT_XYZ12
	.comm	_AV_PIX_FMT_RGB48,8,3           ; @AV_PIX_FMT_RGB48
	.comm	_AV_PIX_FMT_RGBA64,8,3          ; @AV_PIX_FMT_RGBA64
	.comm	_AV_PIX_FMT_GRAY16,8,3          ; @AV_PIX_FMT_GRAY16
	.no_dead_strip	_jpeg2000_decode_tile
.subsections_via_symbols
