	.file	"extr_pac7311.c_setexposure.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	setexposure, @function
setexposure:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	edx, 4
	mov	rbp, rdi
	mov	esi, 255
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	imul	ebx, DWORD PTR [rdi], 120
	cmp	ebx, 1999
	jle	.L2
	cmp	ebx, 63999
	jle	.L16
	call	reg_w@PLT
	mov	edx, 63
	mov	esi, 2
	mov	rdi, rbp
	call	reg_w@PLT
	mov	edx, 1
	mov	esi, 255
	mov	rdi, rbp
	call	reg_w@PLT
.L7:
	mov	edx, 8
	mov	esi, 8
	mov	rdi, rbp
	call	reg_w@PLT
.L5:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	mov	rdi, rbp
	mov	edx, 1
	mov	esi, 17
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	jmp	reg_w@PLT
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	call	reg_w@PLT
	mov	edx, 2
	mov	esi, 2
	mov	rdi, rbp
	call	reg_w@PLT
	mov	edx, 1
	mov	esi, 255
	mov	rdi, rbp
	call	reg_w@PLT
	movsx	rdx, DWORD PTR 0[rbp]
	mov	rax, QWORD PTR 8[rbp]
	cmp	QWORD PTR [rax+rdx*8], 0
	je	.L7
.L6:
	mov	edx, 9
	mov	esi, 8
	mov	rdi, rbp
	call	reg_w@PLT
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L16:
	call	reg_w@PLT
	movsx	rdx, ebx
	mov	eax, ebx
	mov	esi, 2
	imul	rdx, rdx, 274877907
	sar	eax, 31
	mov	rdi, rbp
	sar	rdx, 38
	sub	edx, eax
	call	reg_w@PLT
	mov	edx, 1
	mov	esi, 255
	mov	rdi, rbp
	call	reg_w@PLT
	movsx	rdx, DWORD PTR 0[rbp]
	mov	rax, QWORD PTR 8[rbp]
	cmp	QWORD PTR [rax+rdx*8], 0
	je	.L7
	cmp	ebx, 3999
	jg	.L7
	jmp	.L6
	.cfi_endproc
.LFE0:
	.size	setexposure, .-setexposure
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_pac7311.c_setexposure.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	setexposure, %function
setexposure:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	ldr	r5, [r0]
	mov	r4, r0
	rsb	r5, r5, r5, lsl #4
	lsl	r5, r5, #3
	cmp	r5, #2000
	mov	r2, #4
	mov	r1, #255
	blt	.L2
	cmp	r5, #64000
	blt	.L13
	bl	reg_w
	mov	r2, #63
	mov	r1, #2
	mov	r0, r4
	bl	reg_w
	mov	r2, #1
	mov	r1, #255
	mov	r0, r4
	bl	reg_w
.L7:
	mov	r2, #8
	mov	r0, r4
	mov	r1, r2
	bl	reg_w
.L5:
	mov	r0, r4
	pop	{r4, r5, r6, lr}
	mov	r2, #1
	mov	r1, #17
	b	reg_w
.L2:
	bl	reg_w
	mov	r2, #2
	mov	r0, r4
	mov	r1, r2
	bl	reg_w
	mov	r2, #1
	mov	r1, #255
	mov	r0, r4
	bl	reg_w
	ldm	r4, {r2, r3}
	ldr	r3, [r3, r2, lsl #2]
	cmp	r3, #0
	beq	.L7
.L6:
	mov	r2, #9
	mov	r1, #8
	mov	r0, r4
	bl	reg_w
	b	.L5
.L13:
	bl	reg_w
	ldr	r3, .L14
	asr	r2, r5, #31
	smull	r1, r3, r5, r3
	mov	r0, r4
	rsb	r2, r2, r3, asr #6
	mov	r1, #2
	bl	reg_w
	mov	r2, #1
	mov	r1, #255
	mov	r0, r4
	bl	reg_w
	ldm	r4, {r2, r3}
	ldr	r3, [r3, r2, lsl #2]
	cmp	r3, #0
	cmpne	r5, #4000
	bge	.L7
	b	.L6
.L15:
	.align	2
.L14:
	.word	274877907
	.size	setexposure, .-setexposure
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
