	.file	"extr_mc-proxy-merge-extension.c_get_target_conn_simple.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"\r\n"
	.text
	.p2align 4
	.globl	get_target_conn_simple
	.type	get_target_conn_simple, @function
get_target_conn_simple:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	mov	eax, DWORD PTR [rdi]
	test	eax, eax
	je	.L2
	cdq
	xor	edi, edi
	mov	r12, rsi
	xor	eax, edx
	sub	eax, edx
	lea	ebx, -1[rax]
	cmp	ebx, DWORD PTR get_targets[rip]
	setb	dil
	movsx	rbx, ebx
	call	assert@PLT
	mov	rax, QWORD PTR get_target[rip]
	xor	edi, edi
	cmp	QWORD PTR [rax+rbx*8], rbp
	sete	dil
	call	assert@PLT
	mov	rax, QWORD PTR get_connection[rip]
	mov	r13, QWORD PTR [rax+rbx*8]
	mov	eax, DWORD PTR 0[rbp]
	test	eax, eax
	jg	.L10
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	rax, r13
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	.cfi_restore_state
	call	get_target_connection@PLT
	mov	r13, rax
	test	rax, rax
	je	.L1
	mov	rax, QWORD PTR MAX_CLUSTER_SERVERS[rip]
	xor	edi, edi
	cmp	QWORD PTR get_targets[rip], rax
	setl	dil
	call	assert@PLT
	mov	rax, QWORD PTR get_targets[rip]
	lea	rdx, 1[rax]
	mov	QWORD PTR get_targets[rip], rdx
	mov	edx, eax
	cdqe
	not	edx
	mov	DWORD PTR 0[rbp], edx
	mov	rdx, QWORD PTR get_target[rip]
	mov	QWORD PTR [rdx+rax*8], rbp
	mov	rdx, QWORD PTR get_connection[rip]
	mov	QWORD PTR [rdx+rax*8], r13
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	rax, r13
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L10:
	.cfi_restore_state
	neg	eax
	lea	rdi, 16[r13]
	mov	edx, 2
	mov	DWORD PTR 0[rbp], eax
	lea	rsi, .LC0[rip]
	call	write_out@PLT
	pxor	xmm0, xmm0
	mov	rsi, r12
	mov	rdi, r13
	mov	rax, QWORD PTR CC[rip]
	cvtsi2sd	xmm0, QWORD PTR [rax]
	addsd	xmm0, QWORD PTR .LC1[rip]
	cvttsd2si	rdx, xmm0
	call	create_query@PLT
	cmp	QWORD PTR 8[r12], 0
	je	.L4
	or	DWORD PTR [rax], 4096
.L4:
	mov	rdi, r13
	call	flush_output@PLT
	mov	eax, DWORD PTR precise_now[rip]
	mov	rdi, r13
	mov	DWORD PTR 0[r13], eax
	mov	rax, QWORD PTR CC[rip]
	mov	rsi, QWORD PTR [rax]
	call	accumulate_query_timeout@PLT
	add	rsp, 8
	.cfi_def_cfa_offset 40
	mov	rax, r13
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	get_target_conn_simple, .-get_target_conn_simple
	.comm	precise_now,4,4
	.comm	get_targets,8,8
	.comm	get_target,8,8
	.comm	get_connection,8,8
	.comm	MAX_CLUSTER_SERVERS,8,8
	.comm	CC,8,8
	.section	.rodata.cst8,"aM",@progbits,8
	.align 8
.LC1:
	.long	2576980378
	.long	1070176665
	.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_mc-proxy-merge-extension.c_get_target_conn_simple.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"\015\012\000"
	.global	__aeabi_i2d
	.global	__aeabi_dadd
	.global	__aeabi_d2iz
	.text
	.align	2
	.global	get_target_conn_simple
	.syntax unified
	.arm
	.fpu softvfp
	.type	get_target_conn_simple, %function
get_target_conn_simple:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, [r0]
	push	{r4, r5, r6, r7, r8, lr}
	cmp	r3, #0
	mov	r4, r0
	beq	.L2
	ldr	r2, .L14
	cmp	r3, #0
	ldr	r0, [r2]
	rsblt	r3, r3, #0
	sub	r5, r3, #1
	cmp	r5, r0
	movcs	r0, #0
	movcc	r0, #1
	mov	r6, r1
	bl	assert
	ldr	r3, .L14+4
	ldr	r3, [r3]
	ldr	r0, [r3, r5, lsl #2]
	sub	r0, r0, r4
	clz	r0, r0
	lsr	r0, r0, #5
	bl	assert
	ldr	r2, .L14+8
	ldr	r3, [r4]
	ldr	r2, [r2]
	cmp	r3, #0
	ldr	r5, [r2, r5, lsl #2]
	bgt	.L13
.L1:
	mov	r0, r5
	pop	{r4, r5, r6, r7, r8, pc}
.L2:
	bl	get_target_connection
	subs	r5, r0, #0
	beq	.L1
	ldr	r6, .L14
	ldr	r3, .L14+12
	ldr	r0, [r6]
	ldr	r3, [r3]
	cmp	r0, r3
	movge	r0, #0
	movlt	r0, #1
	bl	assert
	ldr	r3, [r6]
	ldr	r2, .L14+4
	mvn	r0, r3
	ldr	r1, [r2]
	ldr	r2, .L14+8
	add	ip, r3, #1
	ldr	r2, [r2]
	str	ip, [r6]
	str	r0, [r4]
	str	r4, [r1, r3, lsl #2]
	mov	r0, r5
	str	r5, [r2, r3, lsl #2]
	pop	{r4, r5, r6, r7, r8, pc}
.L13:
	ldr	r7, .L14+16
	rsb	r3, r3, #0
	mov	r2, #2
	str	r3, [r4]
	ldr	r1, .L14+20
	add	r0, r5, #8
	bl	write_out
	ldr	r3, [r7]
	ldr	r0, [r3]
	bl	__aeabi_i2d
	ldr	r3, .L14+24
	ldr	r2, .L14+28
	bl	__aeabi_dadd
	bl	__aeabi_d2iz
	mov	r1, r6
	mov	r2, r0
	mov	r0, r5
	bl	create_query
	ldr	r3, [r6, #4]
	cmp	r3, #0
	ldrne	r3, [r0]
	orrne	r3, r3, #4096
	strne	r3, [r0]
	mov	r0, r5
	bl	flush_output
	ldr	r3, .L14+32
	ldr	r2, [r7]
	ldr	r3, [r3]
	ldr	r1, [r2]
	mov	r0, r5
	str	r3, [r5]
	bl	accumulate_query_timeout
	mov	r0, r5
	pop	{r4, r5, r6, r7, r8, pc}
.L15:
	.align	2
.L14:
	.word	get_targets
	.word	get_target
	.word	get_connection
	.word	MAX_CLUSTER_SERVERS
	.word	CC
	.word	.LC0
	.word	1070176665
	.word	-1717986918
	.word	precise_now
	.size	get_target_conn_simple, .-get_target_conn_simple
	.comm	precise_now,4,4
	.comm	get_targets,4,4
	.comm	get_target,4,4
	.comm	get_connection,4,4
	.comm	MAX_CLUSTER_SERVERS,4,4
	.comm	CC,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
