	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ipu_ic_task_init_rsc           ## -- Begin function ipu_ic_task_init_rsc
	.p2align	4, 0x90
_ipu_ic_task_init_rsc:                  ## @ipu_ic_task_init_rsc
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %rbx
	movl	16(%rbp), %r12d
	movq	16(%rdi), %r14
	testl	%r12d, %r12d
	je	LBB0_1
LBB0_4:
	movq	%r14, %rdi
	callq	_spin_lock_irqsave
	movq	8(%rbx), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	movl	%r12d, %esi
	callq	_ipu_ic_write
	movl	4(%r15), %eax
	movl	%eax, 4(%rbx)
	movl	(%r15), %eax
	movl	%eax, (%rbx)
	movq	%rbx, %rdi
	movq	%r15, %rsi
	xorl	%edx, %edx
	callq	_init_csc
	movl	%eax, %r13d
	movq	%r14, %rdi
	callq	_spin_unlock_irqrestore
	jmp	LBB0_5
LBB0_1:
	movl	%edx, -56(%rbp)                 ## 4-byte Spill
	movl	%r8d, -60(%rbp)                 ## 4-byte Spill
	leaq	-44(%rbp), %rax
	leaq	-48(%rbp), %r8
	movq	%rbx, %rdi
	movl	%ecx, %esi
	movl	%r9d, %edx
	movq	%rax, %rcx
	callq	_calc_resize_coeffs
	movl	%eax, %r13d
	testl	%eax, %eax
	jne	LBB0_5
## %bb.2:
	movl	-48(%rbp), %eax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movl	-44(%rbp), %r12d
	leaq	-44(%rbp), %rcx
	leaq	-48(%rbp), %r8
	movq	%rbx, %rdi
	movl	-56(%rbp), %esi                 ## 4-byte Reload
	movl	-60(%rbp), %edx                 ## 4-byte Reload
	callq	_calc_resize_coeffs
	movl	%eax, %r13d
	testl	%eax, %eax
	je	LBB0_3
LBB0_5:
	movl	%r13d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movl	-52(%rbp), %eax                 ## 4-byte Reload
	shll	$30, %eax
	shll	$16, %r12d
	orl	%eax, %r12d
	movl	-48(%rbp), %eax
	shll	$14, %eax
	orl	-44(%rbp), %r12d
	orl	%eax, %r12d
	jmp	LBB0_4
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ipu_ic_task_init_rsc           ; -- Begin function ipu_ic_task_init_rsc
	.p2align	2
_ipu_ic_task_init_rsc:                  ; @ipu_ic_task_init_rsc
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.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
	mov	x24, x6
	mov	x20, x1
	mov	x21, x0
	ldr	x19, [x0, #16]
	cbz	w6, LBB0_2
LBB0_1:
	mov	x0, x19
	bl	_spin_lock_irqsave
	ldr	x8, [x21, #8]
	ldr	w2, [x8]
	mov	x0, x21
	mov	x1, x24
	bl	_ipu_ic_write
	ldr	d0, [x20]
	str	d0, [x21]
	mov	x0, x21
	mov	x1, x20
	mov	w2, #0
	bl	_init_csc
	mov	x24, x0
	mov	x0, x19
	bl	_spin_unlock_irqrestore
	b	LBB0_4
LBB0_2:
	mov	x22, x4
	mov	x8, x3
	mov	x23, x2
	add	x3, sp, #8
	add	x4, sp, #12
	mov	x0, x21
	mov	x1, x8
	mov	x2, x5
	bl	_calc_resize_coeffs
	mov	x24, x0
	cbnz	w0, LBB0_4
; %bb.3:
	ldp	w26, w25, [sp, #8]
	add	x3, sp, #8
	add	x4, sp, #12
	mov	x0, x21
	mov	x1, x23
	mov	x2, x22
	bl	_calc_resize_coeffs
	mov	x24, x0
	cbz	w0, LBB0_5
LBB0_4:
	mov	x0, x24
	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
	add	sp, sp, #96
	ret
LBB0_5:
	lsl	w8, w26, #16
	ldp	w10, w9, [sp, #8]
	orr	w8, w8, w25, lsl #30
	orr	w8, w8, w10
	orr	w24, w8, w9, lsl #14
	b	LBB0_1
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
