	.file	"83986.c"
	.intel_syntax noprefix
	.text
	.globl	name
	.data
	.align 16
	.type	name, @object
	.size	name, 20
name:
	.string	"[DEFAULT]"
	.zero	10
	.globl	msg
	.bss
	.align 32
	.type	msg, @object
	.size	msg, 100
msg:
	.zero	100
	.section	.rodata
	.align 8
.LC0:
	.string	"Usage : %s <IP> <port> <name>n"
.LC1:
	.string	"[%s]"
.LC2:
	.string	"connect() error"
	.text
	.globl	main
	.type	main, @function
main:
.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, 80
	mov	DWORD PTR -68[rbp], edi
	mov	QWORD PTR -80[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -68[rbp], 4
	je	.L2
	mov	rax, QWORD PTR -80[rbp]
	mov	rax, QWORD PTR [rax]
	mov	rsi, rax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	mov	rax, QWORD PTR -80[rbp]
	add	rax, 24
	mov	rax, QWORD PTR [rax]
	mov	rdx, rax
	lea	rsi, .LC1[rip]
	lea	rdi, name[rip]
	mov	eax, 0
	call	sprintf@PLT
	mov	edx, 0
	mov	esi, 1
	mov	edi, 2
	call	socket@PLT
	mov	DWORD PTR -60[rbp], eax
	lea	rax, -32[rbp]
	mov	edx, 16
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	mov	WORD PTR -32[rbp], 2
	mov	rax, QWORD PTR -80[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	inet_addr@PLT
	mov	DWORD PTR -28[rbp], eax
	mov	rax, QWORD PTR -80[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	movzx	eax, ax
	mov	edi, eax
	call	htons@PLT
	mov	WORD PTR -30[rbp], ax
	mov	eax, DWORD PTR -60[rbp]
	lea	rcx, -32[rbp]
	mov	edx, 16
	mov	rsi, rcx
	mov	edi, eax
	call	connect@PLT
	cmp	eax, -1
	jne	.L3
	lea	rdi, .LC2[rip]
	call	error_handling
.L3:
	lea	rdx, -60[rbp]
	lea	rax, -56[rbp]
	mov	rcx, rdx
	lea	rdx, send_msg[rip]
	mov	esi, 0
	mov	rdi, rax
	call	pthread_create@PLT
	lea	rdx, -60[rbp]
	lea	rax, -48[rbp]
	mov	rcx, rdx
	lea	rdx, recv_msg[rip]
	mov	esi, 0
	mov	rdi, rax
	call	pthread_create@PLT
	mov	rax, QWORD PTR -56[rbp]
	lea	rdx, -40[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	pthread_join@PLT
	mov	rax, QWORD PTR -48[rbp]
	lea	rdx, -40[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	pthread_join@PLT
	mov	eax, DWORD PTR -60[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L5
	call	__stack_chk_fail@PLT
.L5:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
.LC3:
	.string	"Input room name : "
.LC4:
	.string	"Message : "
.LC5:
	.string	"q\n"
.LC6:
	.string	"Q\n"
.LC7:
	.string	"%s %s"
	.text
	.globl	send_msg
	.type	send_msg, @function
send_msg:
.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, 192
	mov	QWORD PTR -184[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -184[rbp]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -164[rbp], eax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rdx, QWORD PTR stdin[rip]
	lea	rax, -160[rbp]
	mov	esi, 20
	mov	rdi, rax
	call	fgets@PLT
	lea	rax, -160[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rcx, -160[rbp]
	mov	eax, DWORD PTR -164[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
.L9:
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	mov	rax, QWORD PTR stdin[rip]
	mov	rdx, rax
	mov	esi, 100
	lea	rdi, msg[rip]
	call	fgets@PLT
	lea	rsi, .LC5[rip]
	lea	rdi, msg[rip]
	call	strcmp@PLT
	test	eax, eax
	je	.L7
	lea	rsi, .LC6[rip]
	lea	rdi, msg[rip]
	call	strcmp@PLT
	test	eax, eax
	jne	.L8
.L7:
	mov	eax, DWORD PTR -164[rbp]
	mov	edi, eax
	call	close@PLT
	mov	edi, 0
	call	exit@PLT
.L8:
	lea	rax, -128[rbp]
	lea	rcx, msg[rip]
	lea	rdx, name[rip]
	lea	rsi, .LC7[rip]
	mov	rdi, rax
	mov	eax, 0
	call	sprintf@PLT
	lea	rax, -128[rbp]
	mov	rdi, rax
	call	strlen@PLT
	mov	rdx, rax
	lea	rcx, -128[rbp]
	mov	eax, DWORD PTR -164[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	jmp	.L9
	.cfi_endproc
.LFE7:
	.size	send_msg, .-send_msg
	.globl	recv_msg
	.type	recv_msg, @function
recv_msg:
.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, 160
	mov	QWORD PTR -152[rbp], rdi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	rax, QWORD PTR -152[rbp]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -136[rbp], eax
.L14:
	lea	rcx, -128[rbp]
	mov	eax, DWORD PTR -136[rbp]
	mov	edx, 119
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -132[rbp], eax
	cmp	DWORD PTR -132[rbp], -1
	jne	.L12
	mov	rax, -1
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L15
	jmp	.L16
.L12:
	mov	eax, DWORD PTR -132[rbp]
	cdqe
	mov	BYTE PTR -128[rbp+rax], 0
	mov	rdx, QWORD PTR stdout[rip]
	lea	rax, -128[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	fputs@PLT
	jmp	.L14
.L16:
	call	__stack_chk_fail@PLT
.L15:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	recv_msg, .-recv_msg
	.globl	error_handling
	.type	error_handling, @function
error_handling:
.LFB9:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 16
	mov	QWORD PTR -8[rbp], rdi
	mov	rdx, QWORD PTR stderr[rip]
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	fputs@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rsi, rax
	mov	edi, 10
	call	fputc@PLT
	mov	edi, 1
	call	exit@PLT
	.cfi_endproc
.LFE9:
	.size	error_handling, .-error_handling
	.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	"83986.c"
	.text
	.global	name
	.data
	.align	2
	.type	name, %object
	.size	name, 20
name:
	.ascii	"[DEFAULT]\000"
	.space	10
	.comm	msg,100,4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Usage : %s <IP> <port> <name>n\000"
	.align	2
.LC1:
	.ascii	"[%s]\000"
	.align	2
.LC2:
	.ascii	"connect() error\000"
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 48
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #48
	str	r0, [fp, #-48]
	str	r1, [fp, #-52]
	ldr	r3, .L6
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-48]
	cmp	r3, #4
	beq	.L2
	ldr	r3, [fp, #-52]
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L6+4
	bl	printf
	mov	r0, #1
	bl	exit
.L2:
	ldr	r3, [fp, #-52]
	add	r3, r3, #12
	ldr	r3, [r3]
	mov	r2, r3
	ldr	r1, .L6+8
	ldr	r0, .L6+12
	bl	sprintf
	mov	r2, #0
	mov	r1, #1
	mov	r0, #2
	bl	socket
	mov	r3, r0
	str	r3, [fp, #-40]
	sub	r3, fp, #24
	mov	r2, #16
	mov	r1, #0
	mov	r0, r3
	bl	memset
	mov	r3, #2
	strh	r3, [fp, #-24]	@ movhi
	ldr	r3, [fp, #-52]
	add	r3, r3, #4
	ldr	r3, [r3]
	mov	r0, r3
	bl	inet_addr
	mov	r3, r0
	str	r3, [fp, #-20]
	ldr	r3, [fp, #-52]
	add	r3, r3, #8
	ldr	r3, [r3]
	mov	r0, r3
	bl	atoi
	mov	r3, r0
	lsl	r3, r3, #16
	lsr	r3, r3, #16
	mov	r0, r3
	bl	htons
	mov	r3, r0
	strh	r3, [fp, #-22]	@ movhi
	ldr	r3, [fp, #-40]
	sub	r1, fp, #24
	mov	r2, #16
	mov	r0, r3
	bl	connect
	mov	r3, r0
	cmn	r3, #1
	bne	.L3
	ldr	r0, .L6+16
	bl	error_handling
.L3:
	sub	r3, fp, #40
	sub	r0, fp, #36
	ldr	r2, .L6+20
	mov	r1, #0
	bl	pthread_create
	sub	r3, fp, #40
	sub	r0, fp, #32
	ldr	r2, .L6+24
	mov	r1, #0
	bl	pthread_create
	ldr	r3, [fp, #-36]
	sub	r2, fp, #28
	mov	r1, r2
	mov	r0, r3
	bl	pthread_join
	ldr	r3, [fp, #-32]
	sub	r2, fp, #28
	mov	r1, r2
	mov	r0, r3
	bl	pthread_join
	ldr	r3, [fp, #-40]
	mov	r0, r3
	bl	close
	mov	r3, #0
	ldr	r2, .L6
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L5
	bl	__stack_chk_fail
.L5:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L7:
	.align	2
.L6:
	.word	.LC3
	.word	.LC0
	.word	.LC1
	.word	name
	.word	.LC2
	.word	send_msg
	.word	recv_msg
	.size	main, .-main
	.section	.rodata
	.align	2
.LC4:
	.ascii	"Input room name : \000"
	.align	2
.LC5:
	.ascii	"Message : \000"
	.align	2
.LC6:
	.ascii	"q\012\000"
	.align	2
.LC7:
	.ascii	"Q\012\000"
	.align	2
.LC8:
	.ascii	"%s %s\000"
	.align	2
.LC9:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	send_msg
	.syntax unified
	.arm
	.fpu softvfp
	.type	send_msg, %function
send_msg:
	@ args = 0, pretend = 0, frame = 160
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #160
	str	r0, [fp, #-160]
	ldr	r3, .L13
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-160]
	ldr	r3, [r3]
	str	r3, [fp, #-152]
	ldr	r0, .L13+4
	bl	printf
	ldr	r3, .L13+8
	ldr	r2, [r3]
	sub	r3, fp, #148
	mov	r1, #20
	mov	r0, r3
	bl	fgets
	sub	r3, fp, #148
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r3, fp, #148
	mov	r1, r3
	ldr	r0, [fp, #-152]
	bl	write
.L11:
	ldr	r0, .L13+12
	bl	printf
	ldr	r3, .L13+8
	ldr	r3, [r3]
	mov	r2, r3
	mov	r1, #100
	ldr	r0, .L13+16
	bl	fgets
	ldr	r1, .L13+20
	ldr	r0, .L13+16
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	beq	.L9
	ldr	r1, .L13+24
	ldr	r0, .L13+16
	bl	strcmp
	mov	r3, r0
	cmp	r3, #0
	bne	.L10
.L9:
	ldr	r0, [fp, #-152]
	bl	close
	mov	r0, #0
	bl	exit
.L10:
	sub	r0, fp, #128
	ldr	r3, .L13+16
	ldr	r2, .L13+28
	ldr	r1, .L13+32
	bl	sprintf
	sub	r3, fp, #128
	mov	r0, r3
	bl	strlen
	mov	r2, r0
	sub	r3, fp, #128
	mov	r1, r3
	ldr	r0, [fp, #-152]
	bl	write
	b	.L11
.L14:
	.align	2
.L13:
	.word	.LC9
	.word	.LC4
	.word	stdin
	.word	.LC5
	.word	msg
	.word	.LC6
	.word	.LC7
	.word	name
	.word	.LC8
	.size	send_msg, .-send_msg
	.section	.rodata
	.align	2
.LC10:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	recv_msg
	.syntax unified
	.arm
	.fpu softvfp
	.type	recv_msg, %function
recv_msg:
	@ args = 0, pretend = 0, frame = 144
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #144
	str	r0, [fp, #-144]
	ldr	r3, .L21
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, [fp, #-144]
	ldr	r3, [r3]
	str	r3, [fp, #-136]
.L18:
	sub	r3, fp, #128
	mov	r2, #119
	mov	r1, r3
	ldr	r0, [fp, #-136]
	bl	read
	str	r0, [fp, #-132]
	ldr	r3, [fp, #-132]
	cmn	r3, #1
	bne	.L16
	mvn	r3, #0
	ldr	r2, .L21
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L19
	b	.L20
.L16:
	sub	r2, fp, #128
	ldr	r3, [fp, #-132]
	add	r3, r2, r3
	mov	r2, #0
	strb	r2, [r3]
	ldr	r3, .L21+4
	ldr	r2, [r3]
	sub	r3, fp, #128
	mov	r1, r2
	mov	r0, r3
	bl	fputs
	b	.L18
.L20:
	bl	__stack_chk_fail
.L19:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L22:
	.align	2
.L21:
	.word	.LC10
	.word	stdout
	.size	recv_msg, .-recv_msg
	.align	2
	.global	error_handling
	.syntax unified
	.arm
	.fpu softvfp
	.type	error_handling, %function
error_handling:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	ldr	r3, .L24
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, [fp, #-8]
	bl	fputs
	ldr	r3, .L24
	ldr	r3, [r3]
	mov	r1, r3
	mov	r0, #10
	bl	fputc
	mov	r0, #1
	bl	exit
.L25:
	.align	2
.L24:
	.word	stderr
	.size	error_handling, .-error_handling
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
