	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function calc_mt9v011_gain
_calc_mt9v011_gain:                     ## @calc_mt9v011_gain
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	xorl	%ecx, %ecx
	testl	%edi, %edi
	cmovgl	%edi, %ecx
	cmpl	$2015, %ecx                     ## imm = 0x7DF
	movl	$2015, %eax                     ## imm = 0x7DF
	cmovbl	%ecx, %eax
	movl	$384, %esi                      ## imm = 0x180
	cmpl	$991, %eax                      ## imm = 0x3DF
	jbe	LBB0_2
## %bb.1:
	movl	$1536, %edx                     ## imm = 0x600
	movl	$4, %ecx
	jmp	LBB0_6
LBB0_2:
	cmpl	$479, %eax                      ## imm = 0x1DF
	jbe	LBB0_4
## %bb.3:
	movl	$512, %edx                      ## imm = 0x200
	movl	$3, %ecx
	jmp	LBB0_6
LBB0_4:
	xorl	%edx, %edx
	movl	$2, %ecx
	cmpl	$223, %eax
	ja	LBB0_6
## %bb.5:
	xorl	%ecx, %ecx
	cmpl	$96, %eax
	setae	%cl
	movl	%ecx, %esi
	shll	$7, %esi
LBB0_6:
	orl	%esi, %edx
	addl	$32, %eax
                                        ## kill: def $cl killed $cl killed $ecx
	shrl	%cl, %eax
	addl	%edx, %eax
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_calc_mt9v011_gain
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function calc_mt9v011_gain
_calc_mt9v011_gain:                     ; @calc_mt9v011_gain
	.cfi_startproc
; %bb.0:
	cmp	w0, #0
	csel	w8, w0, wzr, gt
	mov	w9, #2015
	cmp	w8, #2015
	csel	w8, w8, w9, lo
	mov	w9, #384
	mov	w10, #1536
	mov	w11, #4
	mov	w12, #384
	mov	w13, #512
	mov	w14, #3
	mov	w15, #384
	mov	w16, #2
	cmp	w8, #95
	cset	w17, hi
	lsl	w0, w17, #7
	cmp	w8, #223
	csel	w16, w16, w17, hi
	csel	w17, wzr, wzr, hi
	csel	w15, w15, w0, hi
	cmp	w8, #479
	csel	w14, w14, w16, hi
	csel	w13, w13, w17, hi
	csel	w12, w12, w15, hi
	cmp	w8, #991
	csel	w11, w11, w14, hi
	csel	w10, w10, w13, hi
	csel	w9, w9, w12, hi
	add	w8, w8, #32
	lsr	w8, w8, w11
	orr	w9, w9, w10
	add	w0, w9, w8
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_calc_mt9v011_gain
.subsections_via_symbols
