	.file	"162644294.c"
	.intel_syntax noprefix
	.text
	.globl	pair
	.bss
	.align 8
	.type	pair, @object
	.size	pair, 8
pair:
	.zero	8
	.globl	test_okay
	.data
	.align 4
	.type	test_okay, @object
	.size	test_okay, 4
test_okay:
	.long	1
	.globl	called
	.bss
	.align 4
	.type	called, @object
	.size	called, 4
called:
	.zero	4
	.section	.rodata
.LC0:
	.string	"test string"
.LC1:
	.string	""
.LC2:
	.string	" - means EOF"
.LC3:
	.string	"%s: write %d%s\n"
	.text
	.type	write_cb, @function
write_cb:
.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, 32
	mov	DWORD PTR -20[rbp], edi
	mov	eax, esi
	mov	QWORD PTR -32[rbp], rdx
	mov	WORD PTR -24[rbp], ax
	lea	rax, .LC0[rip]
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	strlen@PLT
	lea	rdx, 1[rax]
	mov	rsi, QWORD PTR -8[rbp]
	mov	eax, DWORD PTR -20[rbp]
	mov	ecx, 0
	mov	edi, eax
	call	send@PLT
	mov	DWORD PTR -12[rbp], eax
	cmp	DWORD PTR -12[rbp], 0
	je	.L2
	lea	rax, .LC1[rip]
	jmp	.L3
.L2:
	lea	rax, .LC2[rip]
.L3:
	mov	edx, DWORD PTR -12[rbp]
	mov	rcx, rax
	lea	rsi, __func__.0[rip]
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	cmp	DWORD PTR -12[rbp], 0
	jle	.L4
	mov	eax, DWORD PTR called[rip]
	test	eax, eax
	jne	.L5
	mov	rax, QWORD PTR -32[rbp]
	mov	esi, 0
	mov	rdi, rax
	call	event_add@PLT
.L5:
	mov	eax, DWORD PTR pair[rip]
	mov	edi, eax
	call	evutil_closesocket@PLT
	jmp	.L6
.L4:
	mov	eax, DWORD PTR called[rip]
	cmp	eax, 1
	jne	.L6
	mov	DWORD PTR test_okay[rip], 0
.L6:
	mov	eax, DWORD PTR called[rip]
	add	eax, 1
	mov	DWORD PTR called[rip], eax
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	write_cb, .-write_cb
	.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
	sub	rsp, 160
	mov	DWORD PTR -148[rbp], edi
	mov	QWORD PTR -160[rbp], rsi
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	mov	esi, 1
	mov	edi, 13
	call	signal@PLT
	cmp	rax, -1
	jne	.L8
	mov	eax, 1
	jmp	.L11
.L8:
	lea	rcx, pair[rip]
	mov	edx, 0
	mov	esi, 1
	mov	edi, 1
	call	evutil_socketpair@PLT
	cmp	eax, -1
	jne	.L10
	mov	eax, 1
	jmp	.L11
.L10:
	call	event_init@PLT
	mov	esi, DWORD PTR pair[rip+4]
	lea	rdx, -144[rbp]
	lea	rax, -144[rbp]
	mov	r8, rdx
	lea	rcx, write_cb[rip]
	mov	edx, 4
	mov	rdi, rax
	call	event_set@PLT
	lea	rax, -144[rbp]
	mov	esi, 0
	mov	rdi, rax
	call	event_add@PLT
	call	event_dispatch@PLT
	mov	eax, DWORD PTR test_okay[rip]
.L11:
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L12
	call	__stack_chk_fail@PLT
.L12:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	main, .-main
	.globl	custom_timeout_handling
	.type	custom_timeout_handling, @function
custom_timeout_handling:
.LFB8:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	QWORD PTR -16[rbp], rsi
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	custom_timeout_handling, .-custom_timeout_handling
	.section	.rodata
	.align 8
	.type	__func__.0, @object
	.size	__func__.0, 9
__func__.0:
	.string	"write_cb"
	.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	"162644294.c"
	.text
	.comm	pair,8,4
	.global	test_okay
	.data
	.align	2
	.type	test_okay, %object
	.size	test_okay, 4
test_okay:
	.word	1
	.global	called
	.bss
	.align	2
	.type	called, %object
	.size	called, 4
called:
	.space	4
	.section	.rodata
	.align	2
.LC0:
	.ascii	"test string\000"
	.align	2
.LC1:
	.ascii	"\000"
	.align	2
.LC2:
	.ascii	" - means EOF\000"
	.align	2
.LC3:
	.ascii	"%s: write %d%s\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	write_cb, %function
write_cb:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #24
	str	r0, [fp, #-16]
	mov	r3, r1
	str	r2, [fp, #-24]
	strh	r3, [fp, #-18]	@ movhi
	ldr	r3, .L7
	str	r3, [fp, #-12]
	ldr	r0, [fp, #-12]
	bl	strlen
	mov	r3, r0
	add	r2, r3, #1
	mov	r3, #0
	ldr	r1, [fp, #-12]
	ldr	r0, [fp, #-16]
	bl	send
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L2
	ldr	r3, .L7+4
	b	.L3
.L2:
	ldr	r3, .L7+8
.L3:
	ldr	r2, [fp, #-8]
	ldr	r1, .L7+12
	ldr	r0, .L7+16
	bl	printf
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	ble	.L4
	ldr	r3, .L7+20
	ldr	r3, [r3]
	cmp	r3, #0
	bne	.L5
	mov	r1, #0
	ldr	r0, [fp, #-24]
	bl	event_add
.L5:
	ldr	r3, .L7+24
	ldr	r3, [r3]
	mov	r0, r3
	bl	evutil_closesocket
	b	.L6
.L4:
	ldr	r3, .L7+20
	ldr	r3, [r3]
	cmp	r3, #1
	bne	.L6
	ldr	r3, .L7+28
	mov	r2, #0
	str	r2, [r3]
.L6:
	ldr	r3, .L7+20
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L7+20
	str	r3, [r2]
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L8:
	.align	2
.L7:
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	__func__.7580
	.word	.LC3
	.word	called
	.word	pair
	.word	test_okay
	.size	write_cb, .-write_cb
	.section	.rodata
	.align	2
.LC4:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 80
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #88
	str	r0, [fp, #-80]
	str	r1, [fp, #-84]
	ldr	r3, .L15
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mov	r1, #1
	mov	r0, #13
	bl	signal
	mov	r3, r0
	cmn	r3, #1
	bne	.L10
	mov	r3, #1
	b	.L13
.L10:
	ldr	r3, .L15+4
	mov	r2, #0
	mov	r1, #1
	mov	r0, #1
	bl	evutil_socketpair
	mov	r3, r0
	cmn	r3, #1
	bne	.L12
	mov	r3, #1
	b	.L13
.L12:
	bl	event_init
	ldr	r3, .L15+4
	ldr	r1, [r3, #4]
	sub	r0, fp, #72
	sub	r3, fp, #72
	str	r3, [sp]
	ldr	r3, .L15+8
	mov	r2, #4
	bl	event_set
	sub	r3, fp, #72
	mov	r1, #0
	mov	r0, r3
	bl	event_add
	bl	event_dispatch
	ldr	r3, .L15+12
	ldr	r3, [r3]
.L13:
	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	.LC4
	.word	pair
	.word	write_cb
	.word	test_okay
	.size	main, .-main
	.align	2
	.global	custom_timeout_handling
	.syntax unified
	.arm
	.fpu softvfp
	.type	custom_timeout_handling, %function
custom_timeout_handling:
	@ 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
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	custom_timeout_handling, .-custom_timeout_handling
	.section	.rodata
	.align	2
	.type	__func__.7580, %object
	.size	__func__.7580, 9
__func__.7580:
	.ascii	"write_cb\000"
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
