	.file	"134326.c"
	.intel_syntax noprefix
	.text
	.globl	set_avail_conn_id
	.type	set_avail_conn_id, @function
set_avail_conn_id:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR smallest_avail_id[rip], 0
	mov	DWORD PTR -4[rbp], 0
	jmp	.L2
.L6:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, conn_id_list[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, 4
	je	.L3
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, conn_id_list[rip]
	mov	edx, DWORD PTR [rdx+rax]
	mov	eax, DWORD PTR -4[rbp]
	add	eax, 1
	cdqe
	lea	rcx, 0[0+rax*4]
	lea	rax, conn_id_list[rip]
	mov	eax, DWORD PTR [rcx+rax]
	cmp	edx, eax
	je	.L3
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, conn_id_list[rip]
	mov	eax, DWORD PTR [rdx+rax]
	add	eax, 1
	mov	DWORD PTR smallest_avail_id[rip], eax
	jmp	.L4
.L3:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, conn_id_list[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, 4
	jne	.L5
	mov	eax, DWORD PTR -4[rbp]
	add	eax, 1
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, conn_id_list[rip]
	mov	eax, DWORD PTR [rdx+rax]
	cmp	eax, 7
	je	.L5
	mov	DWORD PTR smallest_avail_id[rip], 7
.L5:
	add	DWORD PTR -4[rbp], 1
.L2:
	mov	eax, DWORD PTR num_used_conn_ids[rip]
	sub	eax, 1
	cmp	DWORD PTR -4[rbp], eax
	jl	.L6
.L4:
	mov	eax, DWORD PTR smallest_avail_id[rip]
	test	eax, eax
	jne	.L8
	mov	eax, DWORD PTR num_used_conn_ids[rip]
	sub	eax, 1
	cdqe
	lea	rdx, 0[0+rax*4]
	lea	rax, conn_id_list[rip]
	mov	eax, DWORD PTR [rdx+rax]
	add	eax, 1
	mov	DWORD PTR smallest_avail_id[rip], eax
.L8:
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	set_avail_conn_id, .-set_avail_conn_id
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.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, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"134326.c"
	.text
	.align	2
	.global	set_avail_conn_id
	.syntax unified
	.arm
	.fpu softvfp
	.type	set_avail_conn_id, %function
set_avail_conn_id:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	ldr	r3, .L9
	mov	r2, #0
	str	r2, [r3]
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L2
.L6:
	ldr	r2, .L9+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #4
	beq	.L3
	ldr	r2, .L9+4
	ldr	r3, [fp, #-8]
	ldr	r2, [r2, r3, lsl #2]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	ldr	r1, .L9+4
	ldr	r3, [r1, r3, lsl #2]
	cmp	r2, r3
	beq	.L3
	ldr	r2, .L9+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	add	r3, r3, #1
	ldr	r2, .L9
	str	r3, [r2]
	b	.L4
.L3:
	ldr	r2, .L9+4
	ldr	r3, [fp, #-8]
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #4
	bne	.L5
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	ldr	r2, .L9+4
	ldr	r3, [r2, r3, lsl #2]
	cmp	r3, #7
	beq	.L5
	ldr	r3, .L9
	mov	r2, #7
	str	r2, [r3]
.L5:
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L2:
	ldr	r3, .L9+8
	ldr	r3, [r3]
	sub	r3, r3, #1
	ldr	r2, [fp, #-8]
	cmp	r2, r3
	blt	.L6
.L4:
	ldr	r3, .L9
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L8
	ldr	r3, .L9+8
	ldr	r3, [r3]
	sub	r3, r3, #1
	ldr	r2, .L9+4
	ldr	r3, [r2, r3, lsl #2]
	add	r3, r3, #1
	ldr	r2, .L9
	str	r3, [r2]
.L8:
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L10:
	.align	2
.L9:
	.word	smallest_avail_id
	.word	conn_id_list
	.word	num_used_conn_ids
	.size	set_avail_conn_id, .-set_avail_conn_id
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
