	.file	"154827103.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
	.align 8
.LC0:
	.string	"usage: binlog <speed> <port> <logfile>\n"
.LC1:
	.string	"invalid speed\n"
.LC2:
	.string	"open"
.LC3:
	.string	"tcsetattr"
.LC4:
	.string	"the_stack_data/154827103.c"
.LC5:
	.string	"write(ofd, buf, l) > 0"
	.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, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 4096
	or	QWORD PTR [rsp], 0
	sub	rsp, 144
	mov	DWORD PTR -8324[rbp], edi
	mov	QWORD PTR -8336[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	cmp	DWORD PTR -8324[rbp], 4
	je	.L2
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 39
	mov	esi, 1
	lea	rdi, .LC0[rip]
	call	fwrite@PLT
	mov	eax, 1
	jmp	.L12
.L2:
	mov	rax, QWORD PTR -8336[rbp]
	add	rax, 8
	mov	rax, QWORD PTR [rax]
	mov	rdi, rax
	call	atoi@PLT
	mov	DWORD PTR -8304[rbp], eax
	cmp	DWORD PTR -8304[rbp], 230400
	je	.L14
	cmp	DWORD PTR -8304[rbp], 230400
	jg	.L5
	cmp	DWORD PTR -8304[rbp], 115200
	je	.L14
	cmp	DWORD PTR -8304[rbp], 115200
	jg	.L5
	cmp	DWORD PTR -8304[rbp], 57600
	je	.L14
	cmp	DWORD PTR -8304[rbp], 57600
	jg	.L5
	cmp	DWORD PTR -8304[rbp], 38400
	je	.L14
	cmp	DWORD PTR -8304[rbp], 38400
	jg	.L5
	cmp	DWORD PTR -8304[rbp], 28800
	je	.L14
	cmp	DWORD PTR -8304[rbp], 28800
	jg	.L5
	cmp	DWORD PTR -8304[rbp], 19200
	je	.L14
	cmp	DWORD PTR -8304[rbp], 19200
	jg	.L5
	cmp	DWORD PTR -8304[rbp], 14400
	je	.L14
	cmp	DWORD PTR -8304[rbp], 14400
	jg	.L5
	cmp	DWORD PTR -8304[rbp], 4800
	je	.L14
	cmp	DWORD PTR -8304[rbp], 9600
	je	.L14
.L5:
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 14
	mov	esi, 1
	lea	rdi, .LC1[rip]
	call	fwrite@PLT
	mov	eax, 1
	jmp	.L12
.L14:
	nop
	mov	rax, QWORD PTR -8336[rbp]
	add	rax, 16
	mov	rax, QWORD PTR [rax]
	mov	edx, 420
	mov	esi, 2306
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -8300[rbp], eax
	cmp	DWORD PTR -8300[rbp], -1
	jne	.L7
	lea	rsi, .LC2[rip]
	mov	edi, 1
	mov	eax, 0
	call	err@PLT
.L7:
	mov	rax, QWORD PTR -8336[rbp]
	add	rax, 24
	mov	rax, QWORD PTR [rax]
	mov	edx, 420
	mov	esi, 1090
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -8296[rbp], eax
	cmp	DWORD PTR -8296[rbp], -1
	jne	.L8
	lea	rsi, .LC2[rip]
	mov	edi, 1
	mov	eax, 0
	call	err@PLT
.L8:
	lea	rdx, -8272[rbp]
	mov	eax, DWORD PTR -8300[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	tcgetattr@PLT
	lea	rax, -8272[rbp]
	mov	rdi, rax
	call	cfmakeraw@PLT
	mov	edx, DWORD PTR -8304[rbp]
	lea	rax, -8272[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	cfsetospeed@PLT
	mov	edx, DWORD PTR -8304[rbp]
	lea	rax, -8272[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	cfsetispeed@PLT
	lea	rdx, -8272[rbp]
	mov	eax, DWORD PTR -8300[rbp]
	mov	esi, 2
	mov	edi, eax
	call	tcsetattr@PLT
	cmp	eax, -1
	jne	.L9
	lea	rsi, .LC3[rip]
	mov	edi, 1
	mov	eax, 0
	call	err@PLT
.L9:
	mov	eax, DWORD PTR -8300[rbp]
	mov	esi, 2
	mov	edi, eax
	call	tcflush@PLT
	mov	DWORD PTR -8308[rbp], 0
.L11:
	lea	rcx, -8208[rbp]
	mov	eax, DWORD PTR -8300[rbp]
	mov	edx, 8192
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -8292[rbp], eax
	cmp	DWORD PTR -8292[rbp], 0
	jle	.L10
	mov	eax, DWORD PTR -8292[rbp]
	movsx	rdx, eax
	lea	rcx, -8208[rbp]
	mov	eax, DWORD PTR -8296[rbp]
	mov	rsi, rcx
	mov	edi, eax
	call	write@PLT
	test	rax, rax
	jg	.L10
	lea	rcx, __PRETTY_FUNCTION__.0[rip]
	mov	edx, 66
	lea	rsi, .LC4[rip]
	lea	rdi, .LC5[rip]
	call	__assert_fail@PLT
.L10:
	mov	QWORD PTR -8288[rbp], 0
	mov	QWORD PTR -8280[rbp], 1000000
	lea	rax, -8288[rbp]
	mov	esi, 0
	mov	rdi, rax
	call	nanosleep@PLT
	lea	rax, -8208[rbp]
	mov	edx, 8192
	mov	esi, 0
	mov	rdi, rax
	call	memset@PLT
	mov	eax, DWORD PTR -8308[rbp]
	lea	edx, 1[rax]
	mov	DWORD PTR -8308[rbp], edx
	mov	edi, eax
	call	spinner
	jmp	.L11
.L12:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L13
	call	__stack_chk_fail@PLT
.L13:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	main, .-main
	.section	.rodata
.LC6:
	.string	"|/-\\"
.LC7:
	.string	"\b\b\b\b\b\b\b\b\b\b\b\b\b"
.LC8:
	.string	"%c %d"
	.text
	.globl	spinner
	.type	spinner, @function
spinner:
.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, 32
	mov	DWORD PTR -20[rbp], edi
	lea	rax, .LC6[rip]
	mov	QWORD PTR -8[rbp], rax
	mov	eax, DWORD PTR -20[rbp]
	and	eax, 3
	test	eax, eax
	jne	.L18
	mov	eax, DWORD PTR -20[rbp]
	lea	edx, 3[rax]
	test	eax, eax
	cmovs	eax, edx
	sar	eax, 2
	mov	DWORD PTR -20[rbp], eax
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 13
	mov	esi, 1
	lea	rdi, .LC7[rip]
	call	fwrite@PLT
	mov	eax, DWORD PTR -20[rbp]
	cdq
	shr	edx, 30
	add	eax, edx
	and	eax, 3
	sub	eax, edx
	movsx	rdx, eax
	mov	rax, QWORD PTR -8[rbp]
	add	rax, rdx
	movzx	eax, BYTE PTR [rax]
	movsx	edx, al
	mov	rax, QWORD PTR stderr[rip]
	mov	ecx, DWORD PTR -20[rbp]
	lea	rsi, .LC8[rip]
	mov	rdi, rax
	mov	eax, 0
	call	fprintf@PLT
	mov	rax, QWORD PTR stderr[rip]
	mov	rdi, rax
	call	fflush@PLT
	jmp	.L15
.L18:
	nop
.L15:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	spinner, .-spinner
	.section	.rodata
	.type	__PRETTY_FUNCTION__.0, @object
	.size	__PRETTY_FUNCTION__.0, 5
__PRETTY_FUNCTION__.0:
	.string	"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	"154827103.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"usage: binlog <speed> <port> <logfile>\012\000"
	.align	2
.LC1:
	.ascii	"invalid speed\012\000"
	.align	2
.LC2:
	.ascii	"open\000"
	.align	2
.LC3:
	.ascii	"tcsetattr\000"
	.align	2
.LC4:
	.ascii	"the_stack_data/154827103.c\000"
	.align	2
.LC5:
	.ascii	"write(ofd, buf, l) > 0\000"
	.align	2
.LC6:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 8296
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #8256
	sub	sp, sp, #44
	sub	r3, fp, #8192
	sub	r3, r3, #12
	str	r0, [r3, #-100]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	str	r1, [r3, #-104]
	ldr	r3, .L15
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-100]
	cmp	r3, #4
	beq	.L2
	ldr	r3, .L15+4
	ldr	r3, [r3]
	mov	r2, #39
	mov	r1, #1
	ldr	r0, .L15+8
	bl	fwrite
	mov	r3, #1
	b	.L12
.L2:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-104]
	add	r3, r3, #4
	ldr	r3, [r3]
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r4, r2
	mov	r0, r3
	bl	atoi
	str	r0, [r4, #-88]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #230400
	beq	.L14
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #230400
	bgt	.L5
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	ldr	r2, .L15+12
	cmp	r3, r2
	beq	.L14
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	ldr	r2, .L15+12
	cmp	r3, r2
	bgt	.L5
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #57600
	beq	.L14
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #57600
	bgt	.L5
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #38400
	beq	.L14
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #38400
	bgt	.L5
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	ldr	r2, .L15+16
	cmp	r3, r2
	beq	.L14
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	ldr	r2, .L15+16
	cmp	r3, r2
	bgt	.L5
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #19200
	beq	.L14
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #19200
	bgt	.L5
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #14400
	beq	.L14
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #14400
	bgt	.L5
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #4800
	beq	.L14
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-88]
	cmp	r3, #9600
	beq	.L14
.L5:
	ldr	r3, .L15+4
	ldr	r3, [r3]
	mov	r2, #14
	mov	r1, #1
	ldr	r0, .L15+20
	bl	fwrite
	mov	r3, #1
	b	.L12
.L14:
	nop
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-104]
	add	r3, r3, #8
	ldr	r3, [r3]
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r4, r2
	mov	r2, #420
	ldr	r1, .L15+24
	mov	r0, r3
	bl	open
	str	r0, [r4, #-84]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-84]
	cmn	r3, #1
	bne	.L7
	ldr	r1, .L15+28
	mov	r0, #1
	bl	err
.L7:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-104]
	add	r3, r3, #12
	ldr	r3, [r3]
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r4, r2
	mov	r2, #420
	ldr	r1, .L15+32
	mov	r0, r3
	bl	open
	str	r0, [r4, #-80]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-80]
	cmn	r3, #1
	bne	.L8
	ldr	r1, .L15+28
	mov	r0, #1
	bl	err
.L8:
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r1, r3
	ldr	r0, [r2, #-84]
	bl	tcgetattr
	sub	r3, fp, #8256
	sub	r3, r3, #12
	mov	r0, r3
	bl	cfmakeraw
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r2, [r3, #-88]
	sub	r3, fp, #8256
	sub	r3, r3, #12
	mov	r1, r2
	mov	r0, r3
	bl	cfsetospeed
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r2, [r3, #-88]
	sub	r3, fp, #8256
	sub	r3, r3, #12
	mov	r1, r2
	mov	r0, r3
	bl	cfsetispeed
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r0, r2
	mov	r2, r3
	mov	r1, #2
	ldr	r0, [r0, #-84]
	bl	tcsetattr
	mov	r3, r0
	cmn	r3, #1
	bne	.L9
	ldr	r1, .L15+36
	mov	r0, #1
	bl	err
.L9:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r1, #2
	ldr	r0, [r3, #-84]
	bl	tcflush
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #-92]
.L11:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r4, r3
	sub	r3, fp, #8192
	sub	r3, r3, #12
	sub	r3, r3, #4
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r0, r2
	mov	r2, #8192
	mov	r1, r3
	ldr	r0, [r0, #-84]
	bl	read
	str	r0, [r4, #-76]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-76]
	cmp	r3, #0
	ble	.L10
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r2, [r3, #-76]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	sub	r3, r3, #4
	sub	r1, fp, #8192
	sub	r1, r1, #12
	mov	r0, r1
	mov	r1, r3
	ldr	r0, [r0, #-80]
	bl	write
	mov	r3, r0
	cmp	r3, #0
	bgt	.L10
	ldr	r3, .L15+40
	mov	r2, #66
	ldr	r1, .L15+44
	ldr	r0, .L15+48
	bl	__assert_fail
.L10:
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r2, r3
	mov	r3, #0
	str	r3, [r2, #-72]
	sub	r3, fp, #8192
	sub	r3, r3, #12
	mov	r2, r3
	ldr	r3, .L15+52
	str	r3, [r2, #-68]
	sub	r3, fp, #8256
	sub	r3, r3, #12
	sub	r3, r3, #8
	mov	r1, #0
	mov	r0, r3
	bl	nanosleep
	sub	r3, fp, #8192
	sub	r3, r3, #12
	sub	r3, r3, #4
	mov	r2, #8192
	mov	r1, #0
	mov	r0, r3
	bl	memset
	sub	r3, fp, #8192
	sub	r3, r3, #12
	ldr	r3, [r3, #-92]
	sub	r2, fp, #8192
	sub	r2, r2, #12
	mov	r1, r2
	add	r2, r3, #1
	str	r2, [r1, #-92]
	mov	r0, r3
	bl	spinner
	b	.L11
.L12:
	ldr	r2, .L15
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L13
	bl	__stack_chk_fail
.L13:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L16:
	.align	2
.L15:
	.word	.LC6
	.word	stderr
	.word	.LC0
	.word	115200
	.word	28800
	.word	.LC1
	.word	2306
	.word	.LC2
	.word	1090
	.word	.LC3
	.word	__PRETTY_FUNCTION__.6168
	.word	.LC4
	.word	.LC5
	.word	1000000
	.size	main, .-main
	.section	.rodata
	.align	2
.LC7:
	.ascii	"|/-\\\000"
	.align	2
.LC8:
	.ascii	"\010\010\010\010\010\010\010\010\010\010\010\010\010"
	.ascii	"\000"
	.align	2
.LC9:
	.ascii	"%c %d\000"
	.text
	.align	2
	.global	spinner
	.syntax unified
	.arm
	.fpu softvfp
	.type	spinner, %function
spinner:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	ldr	r3, .L21
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-16]
	and	r3, r3, #3
	cmp	r3, #0
	bne	.L20
	ldr	r3, [fp, #-16]
	add	r2, r3, #3
	cmp	r3, #0
	movlt	r3, r2
	movge	r3, r3
	asr	r3, r3, #2
	str	r3, [fp, #-16]
	ldr	r3, .L21+4
	ldr	r3, [r3]
	mov	r2, #13
	mov	r1, #1
	ldr	r0, .L21+8
	bl	fwrite
	ldr	r3, .L21+4
	ldr	r0, [r3]
	ldr	r3, [fp, #-16]
	rsbs	r2, r3, #0
	and	r3, r3, #3
	and	r2, r2, #3
	rsbpl	r3, r2, #0
	mov	r2, r3
	ldr	r3, [fp, #-8]
	add	r3, r3, r2
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r2, r3
	ldr	r3, [fp, #-16]
	ldr	r1, .L21+12
	bl	fprintf
	ldr	r3, .L21+4
	ldr	r3, [r3]
	mov	r0, r3
	bl	fflush
	b	.L17
.L20:
	nop
.L17:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L22:
	.align	2
.L21:
	.word	.LC7
	.word	stderr
	.word	.LC8
	.word	.LC9
	.size	spinner, .-spinner
	.section	.rodata
	.align	2
	.type	__PRETTY_FUNCTION__.6168, %object
	.size	__PRETTY_FUNCTION__.6168, 5
__PRETTY_FUNCTION__.6168:
	.ascii	"main\000"
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
