	.file	"144989.c"
	.intel_syntax noprefix
	.text
	.globl	fib
	.type	fib, @function
fib:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	eax, DWORD PTR i.2[rip]
	add	eax, 1
	mov	DWORD PTR i.2[rip], eax
	mov	eax, DWORD PTR i.2[rip]
	cmp	eax, 1
	je	.L2
	mov	eax, DWORD PTR i.2[rip]
	cmp	eax, 2
	jne	.L3
.L2:
	mov	eax, 1
	jmp	.L4
.L3:
	mov	eax, DWORD PTR prev.1[rip]
	mov	DWORD PTR -8[rbp], eax
	mov	eax, DWORD PTR next.0[rip]
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR next.0[rip]
	mov	DWORD PTR prev.1[rip], eax
	mov	edx, DWORD PTR -8[rbp]
	mov	eax, DWORD PTR -4[rbp]
	add	eax, edx
	mov	DWORD PTR next.0[rip], eax
	mov	edx, DWORD PTR -8[rbp]
	mov	eax, DWORD PTR -4[rbp]
	add	eax, edx
.L4:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	fib, .-fib
	.section	.rodata
.LC0:
	.string	"create socket error"
.LC1:
	.string	"127.0.0.1"
.LC2:
	.string	"socket: %s , errno %d\n"
.LC3:
	.string	"listen socket error"
.LC4:
	.string	"accept socket error"
.LC5:
	.string	"Socket creation error "
.LC6:
	.string	"%d\n"
.LC7:
	.string	"fork failed"
	.text
	.globl	main
	.type	main, @function
main:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	push	rbx
	sub	rsp, 104
	.cfi_offset 3, -24
	mov	DWORD PTR -100[rbp], edi
	mov	QWORD PTR -112[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -100[rbp], 1
	jg	.L6
	mov	eax, 1
	jmp	.L7
.L6:
	mov	rax, QWORD PTR -112[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR -64[rbp], eax
	mov	edi, 0
	call	time@PLT
	mov	edi, eax
	call	srand@PLT
	call	fork@PLT
	mov	DWORD PTR -60[rbp], eax
	cmp	DWORD PTR -60[rbp], 0
	jne	.L8
	mov	edx, 0
	mov	esi, 1
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -56[rbp], eax
	cmp	DWORD PTR -56[rbp], -1
	jne	.L9
	lea	rdi, .LC0[rip]
	call	puts@PLT
	mov	eax, 0
	jmp	.L7
.L9:
	mov	DWORD PTR -88[rbp], 1
	lea	rdx, -88[rbp]
	mov	eax, DWORD PTR -56[rbp]
	mov	r8d, 4
	mov	rcx, rdx
	mov	edx, 2
	mov	esi, 1
	mov	edi, eax
	call	setsockopt@PLT
	lea	rax, -48[rbp]
	mov	edx, 16
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	mov	WORD PTR -48[rbp], 2
	lea	rdi, .LC1[rip]
	call	inet_addr@PLT
	mov	DWORD PTR -44[rbp], eax
	mov	edi, 6666
	call	htons@PLT
	mov	WORD PTR -46[rbp], ax
	lea	rcx, -48[rbp]
	mov	eax, DWORD PTR -56[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	edi, eax
	call	bind@PLT
	test	eax, eax
	je	.L11
	call	__errno_location@PLT
	mov	ebx, DWORD PTR [rax]
	call	__errno_location@PLT
	mov	eax, DWORD PTR [rax]
	mov	edi, eax
	call	strerror@PLT
	mov	rdx, rax
	mov	rax, QWORD PTR stderr[rip]
	mov	ecx, ebx
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	eax, DWORD PTR -56[rbp]
	mov	edi, eax
	call	close@PLT
	mov	edi, -1
	call	exit@PLT
.L11:
	call	rand@PLT
	movsx	rdx, eax
	imul	rdx, rdx, 1717986919
	shr	rdx, 32
	sar	edx
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	mov	ecx, edx
	sal	ecx, 2
	add	ecx, edx
	sub	eax, ecx
	mov	edx, eax
	lea	eax, 1[rdx]
	mov	edi, eax
	call	sleep@PLT
	mov	eax, DWORD PTR -56[rbp]
	mov	esi, 10
	mov	edi, eax
	call	listen@PLT
	cmp	eax, -1
	jne	.L12
	lea	rdi, .LC3[rip]
	call	puts@PLT
	mov	edi, -1
	call	exit@PLT
.L12:
	call	rand@PLT
	movsx	rdx, eax
	imul	rdx, rdx, 1717986919
	shr	rdx, 32
	sar	edx
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	mov	ecx, edx
	sal	ecx, 2
	add	ecx, edx
	sub	eax, ecx
	mov	edx, eax
	lea	eax, 1[rdx]
	mov	edi, eax
	call	sleep@PLT
	mov	eax, DWORD PTR -56[rbp]
	mov	edx, 0
	mov	esi, 0
	mov	edi, eax
	call	accept@PLT
	mov	DWORD PTR -52[rbp], eax
	cmp	DWORD PTR -52[rbp], -1
	jne	.L13
	lea	rdi, .LC4[rip]
	call	puts@PLT
.L13:
	mov	DWORD PTR -80[rbp], 0
	jmp	.L14
.L15:
	mov	eax, 0
	call	fib
	mov	DWORD PTR -84[rbp], eax
	call	rand@PLT
	cdq
	shr	edx, 31
	add	eax, edx
	and	eax, 1
	sub	eax, edx
	mov	edi, eax
	call	sleep@PLT
	lea	rcx, -84[rbp]
	mov	eax, DWORD PTR -52[rbp]
	mov	edx, 4
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	add	DWORD PTR -80[rbp], 1
.L14:
	mov	eax, DWORD PTR -80[rbp]
	cmp	eax, DWORD PTR -64[rbp]
	jl	.L15
	mov	eax, DWORD PTR -52[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, DWORD PTR -56[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 0
	jmp	.L7
.L8:
	cmp	DWORD PTR -60[rbp], 0
	jle	.L16
	mov	DWORD PTR -76[rbp], 0
	mov	WORD PTR -48[rbp], 2
	mov	edi, 6666
	call	htons@PLT
	mov	WORD PTR -46[rbp], ax
	lea	rdi, .LC1[rip]
	call	inet_addr@PLT
	mov	DWORD PTR -44[rbp], eax
	mov	DWORD PTR -72[rbp], -1
	jmp	.L17
.L20:
	mov	edx, 0
	mov	esi, 1
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -76[rbp], eax
	cmp	DWORD PTR -76[rbp], 0
	jns	.L18
	lea	rdi, .LC5[rip]
	call	puts@PLT
	mov	eax, -1
	jmp	.L7
.L18:
	lea	rcx, -48[rbp]
	mov	eax, DWORD PTR -76[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	edi, eax
	call	connect@PLT
	mov	DWORD PTR -72[rbp], eax
	cmp	DWORD PTR -72[rbp], 0
	jns	.L17
	mov	eax, DWORD PTR -76[rbp]
	mov	edi, eax
	call	close@PLT
	mov	edi, 100000
	call	usleep@PLT
.L17:
	cmp	DWORD PTR -72[rbp], 0
	js	.L20
	mov	DWORD PTR -68[rbp], 0
	jmp	.L21
.L22:
	lea	rcx, -84[rbp]
	mov	eax, DWORD PTR -76[rbp]
	mov	edx, 4
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	eax, DWORD PTR -84[rbp]
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -68[rbp], 1
.L21:
	mov	eax, DWORD PTR -68[rbp]
	cmp	eax, DWORD PTR -64[rbp]
	jl	.L22
	mov	eax, DWORD PTR -76[rbp]
	mov	edi, eax
	call	close@PLT
	lea	rax, -84[rbp]
	mov	rdi, rax
	mov	eax, 0
	call	wait@PLT
	mov	eax, 0
	jmp	.L7
.L16:
	lea	rdi, .LC7[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 0
.L7:
	mov	rbx, QWORD PTR -24[rbp]
	sub	rbx, QWORD PTR fs:40
	je	.L23
	call	__stack_chk_fail@PLT
.L23:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	main, .-main
	.local	i.2
	.comm	i.2,4,4
	.data
	.align 4
	.type	prev.1, @object
	.size	prev.1, 4
prev.1:
	.long	1
	.align 4
	.type	next.0, @object
	.size	next.0, 4
next.0:
	.long	1
	.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	"144989.c"
	.text
	.align	2
	.global	fib
	.syntax unified
	.arm
	.fpu softvfp
	.type	fib, %function
fib:
	@ 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, .L5
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L5
	str	r3, [r2]
	ldr	r3, .L5
	ldr	r3, [r3]
	cmp	r3, #1
	beq	.L2
	ldr	r3, .L5
	ldr	r3, [r3]
	cmp	r3, #2
	bne	.L3
.L2:
	mov	r3, #1
	b	.L4
.L3:
	ldr	r3, .L5+4
	ldr	r3, [r3]
	str	r3, [fp, #-12]
	ldr	r3, .L5+8
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	ldr	r3, .L5+8
	ldr	r3, [r3]
	ldr	r2, .L5+4
	str	r3, [r2]
	ldr	r2, [fp, #-12]
	ldr	r3, [fp, #-8]
	add	r3, r2, r3
	ldr	r2, .L5+8
	str	r3, [r2]
	ldr	r2, [fp, #-12]
	ldr	r3, [fp, #-8]
	add	r3, r2, r3
.L4:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L6:
	.align	2
.L5:
	.word	i.6507
	.word	prev.6508
	.word	next.6509
	.size	fib, .-fib
	.section	.rodata
	.align	2
.LC0:
	.ascii	"create socket error\000"
	.align	2
.LC1:
	.ascii	"127.0.0.1\000"
	.align	2
.LC2:
	.ascii	"socket: %s , errno %d\012\000"
	.align	2
.LC3:
	.ascii	"listen socket error\000"
	.align	2
.LC4:
	.ascii	"accept socket error\000"
	.align	2
.LC5:
	.ascii	"Socket creation error \000"
	.align	2
.LC6:
	.ascii	"%d\012\000"
	.align	2
.LC7:
	.ascii	"fork failed\000"
	.align	2
.LC8:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 72
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #80
	str	r0, [fp, #-80]
	str	r1, [fp, #-84]
	ldr	r3, .L26
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	ldr	r3, [fp, #-80]
	cmp	r3, #1
	bgt	.L8
	mov	r3, #1
	b	.L9
.L8:
	ldr	r3, [fp, #-84]
	add	r3, r3, #4
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	str	r0, [fp, #-48]
	mov	r0, #0
	bl	time
	mov	r3, r0
	mov	r0, r3
	bl	srand
	bl	fork
	mov	r3, r0
	str	r3, [fp, #-44]
	ldr	r3, [fp, #-44]
	cmp	r3, #0
	bne	.L10
	mov	r2, #0
	mov	r1, #1
	mov	r0, #2
	bl	socket
	str	r0, [fp, #-40]
	ldr	r3, [fp, #-40]
	cmn	r3, #1
	bne	.L11
	ldr	r0, .L26+4
	bl	puts
	mov	r3, #0
	b	.L9
.L11:
	mov	r3, #1
	str	r3, [fp, #-72]
	sub	r3, fp, #72
	mov	r2, #4
	str	r2, [sp]
	mov	r2, #2
	mov	r1, #1
	ldr	r0, [fp, #-40]
	bl	setsockopt
	sub	r3, fp, #32
	mov	r2, #16
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r3, #2
	strh	r3, [fp, #-32]	@ movhi
	ldr	r0, .L26+8
	bl	inet_addr
	mov	r3, r0
	str	r3, [fp, #-28]
	ldr	r0, .L26+12
	bl	htons
	mov	r3, r0
	strh	r3, [fp, #-30]	@ movhi
	sub	r3, fp, #32
	mov	r2, #16
	mov	r1, r3
	ldr	r0, [fp, #-40]
	bl	bind
	mov	r3, r0
	cmp	r3, #0
	beq	.L13
	ldr	r3, .L26+16
	ldr	r4, [r3]
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r0, r3
	bl	strerror
	mov	r5, r0
	bl	__errno_location
	mov	r3, r0
	ldr	r3, [r3]
	mov	r2, r5
	ldr	r1, .L26+20
	mov	r0, r4
	bl	fprintf
	ldr	r0, [fp, #-40]
	bl	close
	mvn	r0, #0
	bl	exit
.L13:
	bl	rand
	mov	r1, r0
	ldr	r3, .L26+24
	smull	r2, r3, r1, r3
	asr	r2, r3, #1
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	sub	r2, r1, r3
	add	r3, r2, #1
	mov	r0, r3
	bl	sleep
	mov	r1, #10
	ldr	r0, [fp, #-40]
	bl	listen
	mov	r3, r0
	cmn	r3, #1
	bne	.L14
	ldr	r0, .L26+28
	bl	puts
	mvn	r0, #0
	bl	exit
.L14:
	bl	rand
	mov	r1, r0
	ldr	r3, .L26+24
	smull	r2, r3, r1, r3
	asr	r2, r3, #1
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	sub	r2, r1, r3
	add	r3, r2, #1
	mov	r0, r3
	bl	sleep
	mov	r2, #0
	mov	r1, #0
	ldr	r0, [fp, #-40]
	bl	accept
	str	r0, [fp, #-36]
	ldr	r3, [fp, #-36]
	cmn	r3, #1
	bne	.L15
	ldr	r0, .L26+32
	bl	puts
.L15:
	mov	r3, #0
	str	r3, [fp, #-64]
	b	.L16
.L17:
	bl	fib
	mov	r3, r0
	str	r3, [fp, #-68]
	bl	rand
	mov	r3, r0
	cmp	r3, #0
	and	r3, r3, #1
	rsblt	r3, r3, #0
	mov	r0, r3
	bl	sleep
	sub	r3, fp, #68
	mov	r2, #4
	mov	r1, r3
	ldr	r0, [fp, #-36]
	bl	write
	ldr	r3, [fp, #-64]
	add	r3, r3, #1
	str	r3, [fp, #-64]
.L16:
	ldr	r2, [fp, #-64]
	ldr	r3, [fp, #-48]
	cmp	r2, r3
	blt	.L17
	ldr	r0, [fp, #-36]
	bl	close
	ldr	r0, [fp, #-40]
	bl	close
	mov	r3, #0
	b	.L9
.L10:
	ldr	r3, [fp, #-44]
	cmp	r3, #0
	ble	.L18
	mov	r3, #0
	str	r3, [fp, #-60]
	mov	r3, #2
	strh	r3, [fp, #-32]	@ movhi
	ldr	r0, .L26+12
	bl	htons
	mov	r3, r0
	strh	r3, [fp, #-30]	@ movhi
	ldr	r0, .L26+8
	bl	inet_addr
	mov	r3, r0
	str	r3, [fp, #-28]
	mvn	r3, #0
	str	r3, [fp, #-56]
	b	.L19
.L22:
	mov	r2, #0
	mov	r1, #1
	mov	r0, #2
	bl	socket
	str	r0, [fp, #-60]
	ldr	r3, [fp, #-60]
	cmp	r3, #0
	bge	.L20
	ldr	r0, .L26+36
	bl	puts
	mvn	r3, #0
	b	.L9
.L20:
	sub	r3, fp, #32
	mov	r2, #16
	mov	r1, r3
	ldr	r0, [fp, #-60]
	bl	connect
	str	r0, [fp, #-56]
	ldr	r3, [fp, #-56]
	cmp	r3, #0
	bge	.L19
	ldr	r0, [fp, #-60]
	bl	close
	ldr	r0, .L26+40
	bl	usleep
.L19:
	ldr	r3, [fp, #-56]
	cmp	r3, #0
	blt	.L22
	mov	r3, #0
	str	r3, [fp, #-52]
	b	.L23
.L24:
	sub	r3, fp, #68
	mov	r2, #4
	mov	r1, r3
	ldr	r0, [fp, #-60]
	bl	read
	ldr	r3, [fp, #-68]
	mov	r1, r3
	ldr	r0, .L26+44
	bl	printf
	ldr	r3, [fp, #-52]
	add	r3, r3, #1
	str	r3, [fp, #-52]
.L23:
	ldr	r2, [fp, #-52]
	ldr	r3, [fp, #-48]
	cmp	r2, r3
	blt	.L24
	ldr	r0, [fp, #-60]
	bl	close
	sub	r3, fp, #68
	mov	r0, r3
	bl	wait
	mov	r3, #0
	b	.L9
.L18:
	ldr	r0, .L26+48
	bl	printf
	mov	r3, #0
.L9:
	ldr	r2, .L26
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L25
	bl	__stack_chk_fail
.L25:
	mov	r0, r3
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L27:
	.align	2
.L26:
	.word	.LC8
	.word	.LC0
	.word	.LC1
	.word	6666
	.word	stderr
	.word	.LC2
	.word	1717986919
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	100000
	.word	.LC6
	.word	.LC7
	.size	main, .-main
	.local	i.6507
	.comm	i.6507,4,4
	.data
	.align	2
	.type	prev.6508, %object
	.size	prev.6508, 4
prev.6508:
	.word	1
	.align	2
	.type	next.6509, %object
	.size	next.6509, 4
next.6509:
	.word	1
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
