	.file	"extr_tps65911-comparator.c_comp_threshold_set.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	comp_threshold_set, @function
comp_threshold_set:
.LFB0:
	.cfi_startproc
	endbr64
	mov	rax, QWORD PTR tps_comparators[rip]
	movsx	rsi, esi
	lea	rcx, [rsi+rsi*2]
	lea	r9, [rax+rcx*8]
	xor	eax, eax
	mov	esi, DWORD PTR [r9]
	mov	r8, QWORD PTR 8[r9]
	test	esi, esi
	jg	.L3
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L10:
	add	rax, 1
	cmp	esi, ecx
	jle	.L2
.L3:
	mov	ecx, DWORD PTR [r8+rax*4]
	cmp	ecx, edx
	jl	.L10
.L2:
	cmp	ecx, esi
	jle	.L4
	mov	eax, DWORD PTR EINVAL[rip]
	neg	eax
	ret
	.p2align 4,,10
	.p2align 3
.L4:
	mov	esi, DWORD PTR 16[r9]
	lea	rdx, [rax+rax]
	jmp	tps65910_reg_write@PLT
.L6:
	xor	ecx, ecx
	jmp	.L2
	.cfi_endproc
.LFE0:
	.size	comp_threshold_set, .-comp_threshold_set
	.comm	tps_comparators,8,8
	.comm	EINVAL,4,4
	.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_tps65911-comparator.c_comp_threshold_set.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	comp_threshold_set, %function
comp_threshold_set:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, .L12
	add	r1, r1, r1, lsl #1
	ldr	r3, [r3]
	push	{r4, lr}
	ldr	lr, [r3, r1, lsl #2]
	add	r4, r3, r1, lsl #2
	cmp	lr, #0
	mov	ip, #0
	ldr	r1, [r4, #4]
	ble	.L6
	sub	r1, r1, #4
	b	.L3
.L11:
	cmp	lr, r3
	add	ip, ip, #1
	ble	.L2
.L3:
	ldr	r3, [r1, #4]!
	cmp	r3, r2
	blt	.L11
.L2:
	cmp	r3, lr
	ble	.L4
	ldr	r3, .L12+4
	ldr	r0, [r3]
	rsb	r0, r0, #0
	pop	{r4, pc}
.L4:
	ldr	r1, [r4, #8]
	lsl	r2, ip, #1
	pop	{r4, lr}
	b	tps65910_reg_write
.L6:
	mov	r3, ip
	b	.L2
.L13:
	.align	2
.L12:
	.word	tps_comparators
	.word	EINVAL
	.size	comp_threshold_set, .-comp_threshold_set
	.comm	tps_comparators,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
