	.file	"97125.c"
	.intel_syntax noprefix
	.text
	.globl	die
	.type	die, @function
die:
.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, 16
	mov	DWORD PTR -4[rbp], edi
	mov	eax, DWORD PTR -4[rbp]
	mov	esi, 1
	mov	edi, eax
	call	signal@PLT
	mov	rax, QWORD PTR stdscr[rip]
	mov	rdi, rax
	call	wclear@PLT
	mov	rax, QWORD PTR stdscr[rip]
	mov	rdi, rax
	call	wrefresh@PLT
	call	endwin@PLT
	mov	edi, 0
	call	exit@PLT
	.cfi_endproc
.LFE6:
	.size	die, .-die
	.section	.rodata
.LC0:
	.string	"Sorry, unknown terminal.\n"
.LC1:
	.string	"This is window 1"
.LC2:
	.string	"This is window 2"
	.text
	.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, 16
	call	initscr@PLT
	test	rax, rax
	jne	.L3
	mov	rax, QWORD PTR stderr[rip]
	mov	rcx, rax
	mov	edx, 25
	mov	esi, 1
	lea	rdi, .LC0[rip]
	call	fwrite@PLT
	mov	edi, 1
	call	exit@PLT
.L3:
	lea	rsi, die[rip]
	mov	edi, 2
	call	signal@PLT
	lea	rsi, die[rip]
	mov	edi, 3
	call	signal@PLT
	lea	rsi, die[rip]
	mov	edi, 1
	call	signal@PLT
	call	noecho@PLT
	mov	eax, DWORD PTR COLS[rip]
	sub	eax, 30
	mov	edx, eax
	shr	edx, 31
	add	eax, edx
	sar	eax
	mov	edx, eax
	mov	eax, DWORD PTR LINES[rip]
	sub	eax, 10
	mov	ecx, eax
	shr	ecx, 31
	add	eax, ecx
	sar	eax
	mov	ecx, edx
	mov	edx, eax
	mov	esi, 30
	mov	edi, 10
	call	newwin@PLT
	mov	QWORD PTR -16[rbp], rax
	mov	eax, DWORD PTR COLS[rip]
	sub	eax, 30
	mov	edx, eax
	shr	edx, 31
	add	eax, edx
	sar	eax
	lea	edx, 10[rax]
	mov	eax, DWORD PTR LINES[rip]
	sub	eax, 10
	mov	ecx, eax
	shr	ecx, 31
	add	eax, ecx
	sar	eax
	add	eax, 4
	mov	ecx, edx
	mov	edx, eax
	mov	esi, 30
	mov	edi, 10
	call	newwin@PLT
	mov	QWORD PTR -8[rbp], rax
	mov	rax, QWORD PTR -16[rbp]
	mov	esi, 0
	mov	rdi, rax
	call	scrollok@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	esi, 0
	mov	rdi, rax
	call	scrollok@PLT
	mov	rax, QWORD PTR -16[rbp]
	sub	rsp, 8
	push	0
	push	0
	push	0
	mov	r9d, 0
	mov	r8d, 42
	mov	ecx, 42
	mov	edx, 42
	mov	esi, 42
	mov	rdi, rax
	call	wborder@PLT
	add	rsp, 32
	mov	rax, QWORD PTR -8[rbp]
	sub	rsp, 8
	push	0
	push	0
	push	0
	mov	r9d, 0
	mov	r8d, 42
	mov	ecx, 42
	mov	edx, 42
	mov	esi, 42
	mov	rdi, rax
	call	wborder@PLT
	add	rsp, 32
	mov	rax, QWORD PTR -16[rbp]
	mov	edx, 7
	mov	esi, 3
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L5
	mov	rax, QWORD PTR -16[rbp]
	mov	edx, -1
	lea	rsi, .LC1[rip]
	mov	rdi, rax
	call	waddnstr@PLT
.L5:
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, 7
	mov	esi, 3
	mov	rdi, rax
	call	wmove@PLT
	cmp	eax, -1
	je	.L12
	mov	rax, QWORD PTR -8[rbp]
	mov	edx, -1
	lea	rsi, .LC2[rip]
	mov	rdi, rax
	call	waddnstr@PLT
.L12:
	mov	rax, QWORD PTR -16[rbp]
	mov	rdi, rax
	call	wrefresh@PLT
	cmp	QWORD PTR -16[rbp], 0
	je	.L8
	mov	rax, QWORD PTR -16[rbp]
	movzx	eax, WORD PTR 4[rax]
	cwde
	lea	edx, 1[rax]
	jmp	.L9
.L8:
	mov	edx, -1
.L9:
	mov	rax, QWORD PTR -16[rbp]
	mov	ecx, 1
	mov	esi, 0
	mov	rdi, rax
	call	wtouchln@PLT
	mov	edi, 200000
	call	usleep@PLT
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	wrefresh@PLT
	cmp	QWORD PTR -8[rbp], 0
	je	.L10
	mov	rax, QWORD PTR -8[rbp]
	movzx	eax, WORD PTR 4[rax]
	cwde
	lea	edx, 1[rax]
	jmp	.L11
.L10:
	mov	edx, -1
.L11:
	mov	rax, QWORD PTR -8[rbp]
	mov	ecx, 1
	mov	esi, 0
	mov	rdi, rax
	call	wtouchln@PLT
	mov	edi, 200000
	call	usleep@PLT
	jmp	.L12
	.cfi_endproc
.LFE7:
	.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	"97125.c"
	.text
	.align	2
	.global	die
	.syntax unified
	.arm
	.fpu softvfp
	.type	die, %function
die:
	@ 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]
	mov	r1, #1
	ldr	r0, [fp, #-8]
	bl	signal
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r0, r3
	bl	wclear
	ldr	r3, .L2
	ldr	r3, [r3]
	mov	r0, r3
	bl	wrefresh
	bl	endwin
	mov	r0, #0
	bl	exit
.L3:
	.align	2
.L2:
	.word	stdscr
	.size	die, .-die
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Sorry, unknown terminal.\012\000"
	.align	2
.LC1:
	.ascii	"This is window 1\000"
	.align	2
.LC2:
	.ascii	"This is window 2\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	bl	initscr
	mov	r3, r0
	cmp	r3, #0
	bne	.L5
	ldr	r3, .L15
	ldr	r3, [r3]
	mov	r2, #25
	mov	r1, #1
	ldr	r0, .L15+4
	bl	fwrite
	mov	r0, #1
	bl	exit
.L5:
	ldr	r1, .L15+8
	mov	r0, #2
	bl	signal
	ldr	r1, .L15+8
	mov	r0, #3
	bl	signal
	ldr	r1, .L15+8
	mov	r0, #1
	bl	signal
	bl	noecho
	ldr	r3, .L15+12
	ldr	r3, [r3]
	sub	r3, r3, #10
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r1, r3
	ldr	r3, .L15+16
	ldr	r3, [r3]
	sub	r3, r3, #30
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	mov	r2, r1
	mov	r1, #30
	mov	r0, #10
	bl	newwin
	str	r0, [fp, #-12]
	ldr	r3, .L15+12
	ldr	r3, [r3]
	sub	r3, r3, #10
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	add	r1, r3, #4
	ldr	r3, .L15+16
	ldr	r3, [r3]
	sub	r3, r3, #30
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	add	r3, r3, #10
	mov	r2, r1
	mov	r1, #30
	mov	r0, #10
	bl	newwin
	str	r0, [fp, #-8]
	mov	r1, #0
	ldr	r0, [fp, #-12]
	bl	scrollok
	mov	r1, #0
	ldr	r0, [fp, #-8]
	bl	scrollok
	mov	r3, #0
	str	r3, [sp, #16]
	mov	r3, #0
	str	r3, [sp, #12]
	mov	r3, #0
	str	r3, [sp, #8]
	mov	r3, #0
	str	r3, [sp, #4]
	mov	r3, #42
	str	r3, [sp]
	mov	r3, #42
	mov	r2, #42
	mov	r1, #42
	ldr	r0, [fp, #-12]
	bl	wborder
	mov	r3, #0
	str	r3, [sp, #16]
	mov	r3, #0
	str	r3, [sp, #12]
	mov	r3, #0
	str	r3, [sp, #8]
	mov	r3, #0
	str	r3, [sp, #4]
	mov	r3, #42
	str	r3, [sp]
	mov	r3, #42
	mov	r2, #42
	mov	r1, #42
	ldr	r0, [fp, #-8]
	bl	wborder
	mov	r2, #7
	mov	r1, #3
	ldr	r0, [fp, #-12]
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L7
	mvn	r2, #0
	ldr	r1, .L15+20
	ldr	r0, [fp, #-12]
	bl	waddnstr
.L7:
	mov	r2, #7
	mov	r1, #3
	ldr	r0, [fp, #-8]
	bl	wmove
	mov	r3, r0
	cmn	r3, #1
	beq	.L14
	mvn	r2, #0
	ldr	r1, .L15+24
	ldr	r0, [fp, #-8]
	bl	waddnstr
.L14:
	ldr	r0, [fp, #-12]
	bl	wrefresh
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	beq	.L10
	ldr	r3, [fp, #-12]
	ldrsh	r3, [r3, #4]
	add	r2, r3, #1
	b	.L11
.L10:
	mvn	r2, #0
.L11:
	mov	r3, #1
	mov	r1, #0
	ldr	r0, [fp, #-12]
	bl	wtouchln
	ldr	r0, .L15+28
	bl	usleep
	ldr	r0, [fp, #-8]
	bl	wrefresh
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	beq	.L12
	ldr	r3, [fp, #-8]
	ldrsh	r3, [r3, #4]
	add	r2, r3, #1
	b	.L13
.L12:
	mvn	r2, #0
.L13:
	mov	r3, #1
	mov	r1, #0
	ldr	r0, [fp, #-8]
	bl	wtouchln
	ldr	r0, .L15+28
	bl	usleep
	b	.L14
.L16:
	.align	2
.L15:
	.word	stderr
	.word	.LC0
	.word	die
	.word	LINES
	.word	COLS
	.word	.LC1
	.word	.LC2
	.word	200000
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
