	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pwc_dec23_init                 ## -- Begin function pwc_dec23_init
	.p2align	4, 0x90
_pwc_dec23_init:                        ## @pwc_dec23_init
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movl	%esi, %r15d
	movq	(%rdi), %rbx
	testq	%rbx, %rbx
	jne	LBB0_4
## %bb.1:
	movq	%rdi, %r12
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$32, %edi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_2
## %bb.3:
	movq	%rax, %rbx
	movq	%rax, (%r12)
LBB0_4:
	movl	%r15d, %edi
	callq	_DEVICE_USE_CODEC3
	movb	2(%r14), %cl
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	andb	$24, %cl
	xorl	%eax, %eax
	cmpb	$16, %cl
	sete	%al
	addl	%eax, %eax
	addl	$6, %eax
	cmpb	$8, %cl
	movl	$7, %ecx
	cmovnel	%eax, %ecx
	movl	%ecx, (%rbx)
	movzbl	2(%r14), %r14d
	shrq	$5, %r14
	movq	_KiaraRomTable@GOTPCREL(%rip), %r15
	jmp	LBB0_7
LBB0_6:
	andb	$6, %cl
	xorl	%eax, %eax
	cmpb	$4, %cl
	sete	%al
	addl	%eax, %eax
	addl	$6, %eax
	cmpb	$2, %cl
	movl	$7, %ecx
	cmovnel	%eax, %ecx
	movl	%ecx, (%rbx)
	movzbl	2(%r14), %r14d
	shrq	$3, %r14
	movq	_TimonRomTable@GOTPCREL(%rip), %r15
LBB0_7:
	leaq	(,%r14,8), %rax
	addq	(%r15), %rax
	movq	(%rax), %rax
	movl	(%rax), %edi
	movl	24(%rbx), %edx
	movl	28(%rbx), %esi
	callq	_build_table_color
	movq	(%r15), %rax
	movq	(%rax,%r14,8), %rax
	movl	4(%rax), %edi
	movl	16(%rbx), %edx
	movl	20(%rbx), %esi
	callq	_build_table_color
	movslq	(%rbx), %rax
	movl	$8, %ecx
	subq	%rax, %rcx
	movq	_SCALEBITS@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	subq	%rcx, %rax
	movq	%rax, 8(%rbx)
	movl	$255, %eax
                                        ## kill: def $cl killed $cl killed $rcx
	shrl	%cl, %eax
	movl	%eax, 4(%rbx)
	movq	%rbx, %rdi
	callq	_fill_table_dc00_d800
	movq	%rbx, %rdi
	callq	_build_subblock_pattern
	movq	%rbx, %rdi
	callq	_build_bit_powermask_table
	xorl	%eax, %eax
LBB0_8:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_KiaraRomTable,8,3              ## @KiaraRomTable
	.comm	_TimonRomTable,8,3              ## @TimonRomTable
	.comm	_SCALEBITS,8,3                  ## @SCALEBITS
	.comm	_MAX_OUTER_CROP_VALUE,4,2       ## @MAX_OUTER_CROP_VALUE
	.comm	_pwc_crop_table,8,3             ## @pwc_crop_table
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pwc_dec23_init                 ; -- Begin function pwc_dec23_init
	.p2align	2
_pwc_dec23_init:                        ; @pwc_dec23_init
	.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	x20, x2
	mov	x21, x1
	ldr	x19, [x0]
	cbnz	x19, LBB0_3
; %bb.1:
	mov	x22, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #32
	bl	_kmalloc
	cbz	x0, LBB0_8
; %bb.2:
	mov	x19, x0
	str	x0, [x22]
LBB0_3:
	mov	x0, x21
	bl	_DEVICE_USE_CODEC3
	ldrb	w8, [x20, #2]
	cbz	x0, LBB0_5
; %bb.4:
	and	w8, w8, #0x18
	mov	w9, #6
	mov	w10, #8
	cmp	w8, #16
	csel	w9, w10, w9, eq
	mov	w10, #7
	cmp	w8, #8
	csel	w8, w10, w9, eq
	str	w8, [x19]
	ldrb	w8, [x20, #2]
	lsr	x20, x8, #5
Lloh3:
	adrp	x21, _KiaraRomTable@GOTPAGE
Lloh4:
	ldr	x21, [x21, _KiaraRomTable@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:
	and	w8, w8, #0x6
	mov	w9, #6
	mov	w10, #8
	cmp	w8, #4
	csel	w9, w10, w9, eq
	mov	w10, #7
	cmp	w8, #2
	csel	w8, w10, w9, eq
	str	w8, [x19]
	ldrb	w8, [x20, #2]
	lsr	x20, x8, #3
Lloh5:
	adrp	x21, _TimonRomTable@GOTPAGE
Lloh6:
	ldr	x21, [x21, _TimonRomTable@GOTPAGEOFF]
LBB0_6:
	ldr	x8, [x21]
	add	x8, x8, x20, lsl #3
	ldr	x8, [x8]
	ldr	w0, [x8]
	ldp	w2, w1, [x19, #24]
	bl	_build_table_color
	ldr	x8, [x21]
	ldr	x8, [x8, x20, lsl #3]
	ldr	w0, [x8, #4]
	ldp	w2, w1, [x19, #16]
	bl	_build_table_color
	ldrsw	x8, [x19]
	mov	w9, #8
Lloh7:
	adrp	x10, _SCALEBITS@GOTPAGE
Lloh8:
	ldr	x10, [x10, _SCALEBITS@GOTPAGEOFF]
Lloh9:
	ldr	x10, [x10]
	sub	x8, x9, x8
	sub	x9, x10, x8
	str	x9, [x19, #8]
	mov	w9, #255
	lsr	w8, w9, w8
	str	w8, [x19, #4]
	mov	x0, x19
	bl	_fill_table_dc00_d800
	mov	x0, x19
	bl	_build_subblock_pattern
	mov	x0, x19
	bl	_build_bit_powermask_table
	mov	w0, #0
LBB0_7:
	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
LBB0_8:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_KiaraRomTable,8,3              ; @KiaraRomTable
	.comm	_TimonRomTable,8,3              ; @TimonRomTable
	.comm	_SCALEBITS,8,3                  ; @SCALEBITS
	.comm	_MAX_OUTER_CROP_VALUE,4,2       ; @MAX_OUTER_CROP_VALUE
	.comm	_pwc_crop_table,8,3             ; @pwc_crop_table
.subsections_via_symbols
