	.file	"39949.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"client2"
	.align 8
.LC1:
	.string	"\nClient 2 reads the message: %s\n"
	.text
	.globl	read_thread
	.type	read_thread, @function
read_thread:
.LFB6:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 1072
	mov	QWORD PTR -1064[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
.L3:
	mov	esi, 0
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -1048[rbp], eax
	lea	rcx, -1040[rbp]
	mov	eax, DWORD PTR -1048[rbp]
	mov	edx, 1024
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -1044[rbp], eax
	cmp	DWORD PTR -1044[rbp], 0
	jle	.L2
	lea	rax, -1040[rbp]
	mov	rsi, rax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
.L2:
	mov	eax, DWORD PTR -1048[rbp]
	mov	edi, eax
	call	close@PLT
	jmp	.L3
	.cfi_endproc
.LFE6:
	.size	read_thread, .-read_thread
	.section	.rodata
.LC2:
	.string	"server"
.LC3:
	.string	"%s"
	.text
	.globl	write_thread
	.type	write_thread, @function
write_thread:
.LFB7:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 1072
	mov	QWORD PTR -1064[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
.L6:
	mov	esi, 1
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -1052[rbp], eax
	lea	rax, -1040[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	DWORD PTR -1045[rbp], 540684867
	mov	BYTE PTR -1041[rbp], 0
	lea	rdx, -1040[rbp]
	lea	rax, -1045[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	strcat@PLT
	lea	rax, -1045[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rcx, -1045[rbp]
	mov	eax, DWORD PTR -1052[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	mov	eax, DWORD PTR -1052[rbp]
	mov	edi, eax
	call	close@PLT
	jmp	.L6
	.cfi_endproc
.LFE7:
	.size	write_thread, .-write_thread
	.globl	main
	.type	main, @function
main:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 32
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	esi, 438
	lea	rdi, .LC2[rip]
	call	mkfifo@PLT
	mov	esi, 438
	lea	rdi, .LC0[rip]
	call	mkfifo@PLT
	lea	rax, -24[rbp]
	mov	ecx, 0
	lea	rdx, read_thread[rip]
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	pthread_create@PLT
	lea	rax, -16[rbp]
	mov	ecx, 0
	lea	rdx, write_thread[rip]
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	pthread_create@PLT
	mov	rax, QWORD PTR -24[rbp]
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	pthread_join@PLT
	mov	rax, QWORD PTR -16[rbp]
	mov	esi, 0
	mov	rdi, rax
	mov	eax, 0
	call	pthread_join@PLT
	mov	eax, 0
	mov	rdx, QWORD PTR -8[rbp]
	sub	rdx, QWORD PTR fs:40
	je	.L10
	call	__stack_chk_fail@PLT
.L10:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	main, .-main
	.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	"39949.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"client2\000"
	.align	2
.LC1:
	.ascii	"\012Client 2 reads the message: %s\012\000"
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	read_thread
	.syntax unified
	.arm
	.fpu softvfp
	.type	read_thread, %function
read_thread:
	@ args = 0, pretend = 0, frame = 1048
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #1040
	sub	sp, sp, #8
	str	r0, [fp, #-1048]
	ldr	r3, .L5
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
.L3:
	mov	r1, #0
	ldr	r0, .L5+4
	bl	open
	str	r0, [fp, #-1040]
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r2, #1024
	mov	r1, r3
	ldr	r0, [fp, #-1040]
	bl	read
	str	r0, [fp, #-1036]
	ldr	r3, [fp, #-1036]
	cmp	r3, #0
	ble	.L2
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r3
	ldr	r0, .L5+8
	bl	printf
.L2:
	ldr	r0, [fp, #-1040]
	bl	close
	b	.L3
.L6:
	.align	2
.L5:
	.word	.LC2
	.word	.LC0
	.word	.LC1
	.size	read_thread, .-read_thread
	.section	.rodata
	.align	2
.LC3:
	.ascii	"server\000"
	.align	2
.LC4:
	.ascii	"%s\000"
	.align	2
.LC5:
	.ascii	"C2: \000"
	.align	2
.LC6:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	write_thread
	.syntax unified
	.arm
	.fpu softvfp
	.type	write_thread, %function
write_thread:
	@ args = 0, pretend = 0, frame = 1048
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #1040
	sub	sp, sp, #8
	str	r0, [fp, #-1048]
	ldr	r3, .L10
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
.L8:
	mov	r1, #1
	ldr	r0, .L10+4
	bl	open
	str	r0, [fp, #-1044]
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #4
	mov	r1, r3
	ldr	r0, .L10+8
	bl	__isoc99_scanf
	ldr	r2, .L10+12
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #12
	ldm	r2, {r0, r1}
	str	r0, [r3]
	add	r3, r3, #4
	strb	r1, [r3]
	sub	r2, fp, #1024
	sub	r2, r2, #4
	sub	r2, r2, #4
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #12
	mov	r1, r2
	mov	r0, r3
	bl	strcat
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #12
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r3, fp, #1024
	sub	r3, r3, #4
	sub	r3, r3, #12
	mov	r1, r3
	ldr	r0, [fp, #-1044]
	bl	write
	ldr	r0, [fp, #-1044]
	bl	close
	b	.L8
.L11:
	.align	2
.L10:
	.word	.LC6
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.size	write_thread, .-write_thread
	.section	.rodata
	.align	2
.LC7:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	ldr	r3, .L15
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r1, .L15+4
	ldr	r0, .L15+8
	bl	mkfifo
	ldr	r1, .L15+4
	ldr	r0, .L15+12
	bl	mkfifo
	sub	r0, fp, #16
	mov	r3, #0
	ldr	r2, .L15+16
	mov	r1, #0
	bl	pthread_create
	sub	r0, fp, #12
	mov	r3, #0
	ldr	r2, .L15+20
	mov	r1, #0
	bl	pthread_create
	ldr	r3, [fp, #-16]
	mov	r1, #0
	mov	r0, r3
	bl	pthread_join
	ldr	r3, [fp, #-12]
	mov	r1, #0
	mov	r0, r3
	bl	pthread_join
	mov	r3, #0
	ldr	r2, .L15
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L14
	bl	__stack_chk_fail
.L14:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L16:
	.align	2
.L15:
	.word	.LC7
	.word	438
	.word	.LC3
	.word	.LC0
	.word	read_thread
	.word	write_thread
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
