	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sh_mobile_ceu_set_rect
_sh_mobile_ceu_set_rect:                ## @sh_mobile_ceu_set_rect
	.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
	movl	%edx, %r13d
	movl	%esi, %r15d
	movq	%rdi, %r12
	movl	(%rdi), %edi
	callq	_to_soc_camera_host
	movq	16(%r12), %rbx
	movq	(%rax), %r14
	movl	(%r12), %edi
	movl	(%rbx), %edx
	movl	4(%rbx), %ecx
	movl	8(%rbx), %r8d
	movl	12(%rbx), %r9d
	leaq	L_.str(%rip), %rsi
	callq	_dev_dbg
	movl	8(%rbx), %edi
	cmpq	$0, 16(%r14)
	je	LBB0_2
## %bb.1:
	movl	(%rbx), %edx
	cmpl	$0, 8(%r14)
	sete	%cl
	shll	%cl, %edx
	shll	%cl, %edi
	movl	%r15d, %eax
	movl	%r15d, %ecx
	jmp	LBB0_3
LBB0_2:
	movq	8(%r12), %rcx
	movl	(%rcx), %esi
	addl	$7, %esi
	sarl	$3, %esi
	imull	%esi, %r15d
	movl	%r15d, %r8d
	shrl	%r8d
	cmpl	$0, 8(%r14)
	sete	%cl
	shll	%cl, %esi
	movl	%r15d, %eax
	movl	(%rbx), %edx
	imull	%esi, %edx
	shrl	%edx
	imull	%edi, %esi
	shrl	%esi
	andl	$-2, %eax
	movl	%r8d, %ecx
	movl	%esi, %edi
LBB0_3:
	movq	%r12, %rsi
	movl	12(%rbx), %r12d
	movl	4(%rbx), %r15d
	cmpq	$0, (%r14)
	je	LBB0_5
## %bb.4:
	shrl	%r13d
	shrl	%r15d
	shrl	%r12d
	addl	%eax, %eax
LBB0_5:
	shll	$16, %r12d
	orl	%edi, %r12d
	movl	(%rsi), %edi
	shll	$16, %r15d
	orl	%edx, %r15d
	shll	$16, %r13d
	orl	%ecx, %r13d
	leaq	L_.str.1(%rip), %rsi
	movl	%r12d, %edx
	movl	%r15d, %ecx
	movl	%r13d, %r8d
	movl	%eax, %ebx
	movl	%eax, %r9d
	callq	_dev_geo
	movq	_CAMOR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	%r12d, %edx
	callq	_ceu_write
	movq	_CAPWR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	%r15d, %edx
	callq	_ceu_write
	movq	_CFSZR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	%r13d, %edx
	callq	_ceu_write
	movq	_CDWDR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	%ebx, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ceu_write                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Crop %ux%u@%u:%u\n"

L_.str.1:                               ## @.str.1
	.asciz	"CAMOR 0x%x, CAPWR 0x%x, CFSZR 0x%x, CDWDR 0x%x\n"

	.comm	_CAMOR,4,2                      ## @CAMOR
	.comm	_CAPWR,4,2                      ## @CAPWR
	.comm	_CFSZR,4,2                      ## @CFSZR
	.comm	_CDWDR,4,2                      ## @CDWDR
	.no_dead_strip	_sh_mobile_ceu_set_rect
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sh_mobile_ceu_set_rect
_sh_mobile_ceu_set_rect:                ; @sh_mobile_ceu_set_rect
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x22, x2
	mov	x20, x1
	mov	x21, x0
	ldr	w0, [x0]
	bl	_to_soc_camera_host
	ldr	x23, [x21, #16]
	ldr	x19, [x0]
	ldr	w0, [x21]
	ldp	w2, w3, [x23]
	ldp	w4, w5, [x23, #8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
	ldp	w10, w8, [x23, #8]
	ldr	x9, [x19, #16]
	cbz	x9, LBB0_2
; %bb.1:
	ldr	w9, [x23]
	ldr	w11, [x19, #8]
	cmp	w11, #0
	cset	w11, eq
	lsl	w9, w9, w11
	lsl	w10, w10, w11
	mov	x11, x20
	b	LBB0_3
LBB0_2:
	ldr	x9, [x21, #8]
	ldr	w9, [x9]
	add	w9, w9, #7
	asr	w9, w9, #3
	mul	w11, w9, w20
	lsr	w20, w11, #1
	ldr	w12, [x19, #8]
	cmp	w12, #0
	cset	w12, eq
	lsl	w12, w9, w12
	ldr	w9, [x23]
	mul	w9, w12, w9
	lsr	w9, w9, #1
	mul	w10, w12, w10
	lsr	w10, w10, #1
	and	w11, w11, #0xfffffffe
LBB0_3:
	ldr	w12, [x23, #4]
	lsr	w13, w22, #1
	ldr	x14, [x19]
	lsr	w15, w12, #1
	lsr	w16, w8, #1
	lsl	w17, w11, #1
	cmp	x14, #0
	csel	w23, w11, w17, eq
	csel	w11, w12, w15, eq
	csel	w8, w8, w16, eq
	csel	w12, w22, w13, eq
	orr	w22, w10, w8, lsl #16
	ldr	w0, [x21]
	orr	w21, w9, w11, lsl #16
	orr	w20, w20, w12, lsl #16
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x22
	mov	x3, x21
	mov	x4, x20
	mov	x5, x23
	bl	_dev_geo
Lloh4:
	adrp	x8, _CAMOR@GOTPAGE
Lloh5:
	ldr	x8, [x8, _CAMOR@GOTPAGEOFF]
Lloh6:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x22
	bl	_ceu_write
Lloh7:
	adrp	x8, _CAPWR@GOTPAGE
Lloh8:
	ldr	x8, [x8, _CAPWR@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x21
	bl	_ceu_write
Lloh10:
	adrp	x8, _CFSZR@GOTPAGE
Lloh11:
	ldr	x8, [x8, _CFSZR@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x20
	bl	_ceu_write
Lloh13:
	adrp	x8, _CDWDR@GOTPAGE
Lloh14:
	ldr	x8, [x8, _CDWDR@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x23
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_ceu_write
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Crop %ux%u@%u:%u\n"

l_.str.1:                               ; @.str.1
	.asciz	"CAMOR 0x%x, CAPWR 0x%x, CFSZR 0x%x, CDWDR 0x%x\n"

	.comm	_CAMOR,4,2                      ; @CAMOR
	.comm	_CAPWR,4,2                      ; @CAPWR
	.comm	_CFSZR,4,2                      ; @CFSZR
	.comm	_CDWDR,4,2                      ; @CDWDR
	.no_dead_strip	_sh_mobile_ceu_set_rect
.subsections_via_symbols
