	.file	"extr_km.c_kmoutput.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	kmoutput, @function
kmoutput:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 104
	.cfi_def_cfa_offset 144
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 88[rsp], rax
	xor	eax, eax
	cmp	QWORD PTR 16[rdi], 0
	jle	.L11
	lea	r12, 16[rdi]
	mov	rbx, rsp
	.p2align 4,,10
	.p2align 3
.L9:
	mov	rdi, r12
	xor	esi, esi
	call	ndqb@PLT
	mov	edi, eax
	test	eax, eax
	je	.L3
	mov	esi, 80
	call	min@PLT
	mov	rsi, rbx
	mov	rdi, r12
	mov	r13d, eax
	mov	edx, eax
	call	q_to_b@PLT
	movsx	rdx, r13d
	mov	rax, rbx
	add	rdx, rbx
	cmp	rdx, rbx
	jbe	.L7
	.p2align 4,,10
	.p2align 3
.L4:
	and	BYTE PTR [rax], 127
	add	rax, 1
	cmp	rax, rdx
	jne	.L4
.L7:
	cmp	r13d, 1
	jle	.L20
	mov	esi, r13d
	mov	rdi, rbx
	call	cnputsusr@PLT
.L8:
	cmp	QWORD PTR 16[rbp], 0
	jg	.L9
.L11:
	mov	eax, DWORD PTR TS_BUSY[rip]
	mov	rdx, QWORD PTR 0[rbp]
	mov	rdi, rbp
	not	eax
	and	DWORD PTR 8[rbp], eax
	mov	rax, QWORD PTR linesw[rip]
	call	[QWORD PTR [rax+rdx*8]]
	mov	rax, QWORD PTR 88[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L21
	add	rsp, 104
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	xor	eax, eax
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L20:
	.cfi_restore_state
	movzx	esi, BYTE PTR [rsp]
	mov	edi, DWORD PTR 24[rbp]
	call	kmputc@PLT
	jmp	.L8
.L3:
	cmp	QWORD PTR 16[rbp], 0
	jle	.L11
	mov	edx, DWORD PTR hz[rip]
	mov	edi, DWORD PTR kmtimeout[rip]
	mov	rsi, rbp
	call	timeout@PLT
	jmp	.L11
.L21:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	kmoutput, .-kmoutput
	.comm	linesw,8,8
	.comm	kmtimeout,4,4
	.comm	hz,4,4
	.comm	TS_BUSY,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.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, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_km.c_kmoutput.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	kmoutput, %function
kmoutput:
	@ args = 0, pretend = 0, frame = 88
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, lr}
	ldr	r3, [r0, #8]
	ldr	r2, .L21
	sub	sp, sp, #92
	cmp	r3, #0
	mov	r6, r0
	ldr	r2, [r2]
	str	r2, [sp, #84]
	mov	r2,#0
	ble	.L11
	add	r7, r0, #8
	add	r5, sp, #4
.L9:
	mov	r1, #0
	mov	r0, r7
	bl	ndqb
	cmp	r0, #0
	beq	.L3
	mov	r1, #80
	bl	min
	mov	r4, r0
	mov	r2, r0
	mov	r1, r5
	mov	r0, r7
	bl	q_to_b
	add	ip, r5, r4
	cmp	ip, r5
	movhi	r3, r5
	bls	.L7
.L4:
	ldrb	r1, [r3]	@ zero_extendqisi2
	and	r1, r1, #127
	strb	r1, [r3], #1
	cmp	r3, ip
	bne	.L4
.L7:
	cmp	r4, #1
	ble	.L19
	mov	r1, r4
	mov	r0, r5
	bl	cnputsusr
.L8:
	ldr	r3, [r6, #8]
	cmp	r3, #0
	bgt	.L9
.L11:
	ldr	r3, .L21+4
	ldr	r2, .L21+8
	ldr	r0, [r3]
	ldr	r3, [r6, #4]
	ldr	r2, [r2]
	ldr	r1, [r6]
	bic	r3, r3, r0
	str	r3, [r6, #4]
	mov	r0, r6
	ldr	r3, [r2, r1, lsl #2]
	blx	r3
	ldr	r3, .L21
	ldr	r2, [r3]
	ldr	r3, [sp, #84]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L20
	mov	r0, #0
	add	sp, sp, #92
	@ sp needed
	pop	{r4, r5, r6, r7, pc}
.L19:
	ldrb	r1, [sp, #4]	@ zero_extendqisi2
	ldr	r0, [r6, #12]
	bl	kmputc
	b	.L8
.L3:
	ldr	r3, [r6, #8]
	cmp	r3, #0
	ble	.L11
	ldr	r3, .L21+12
	ldr	r2, .L21+16
	mov	r1, r6
	ldr	r2, [r2]
	ldr	r0, [r3]
	bl	timeout
	b	.L11
.L20:
	bl	__stack_chk_fail
.L22:
	.align	2
.L21:
	.word	.LC0
	.word	TS_BUSY
	.word	linesw
	.word	kmtimeout
	.word	hz
	.size	kmoutput, .-kmoutput
	.comm	linesw,4,4
	.comm	kmtimeout,4,4
	.comm	hz,4,4
	.comm	TS_BUSY,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
