	.file	"804243.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"couldn't grab pointer:"
.LC1:
	.string	"couldn't grab keyboard:"
	.align 8
.LC2:
	.string	"RECT_WIDTH=%d \nRECT_HEIGHT=%d \nRECT_X=%d \nRECT_Y=%d \n"
	.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
	push	rbx
	sub	rsp, 440
	.cfi_offset 3, -24
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -24[rbp], rax
	xor	eax, eax
	mov	DWORD PTR -440[rbp], 0
	mov	DWORD PTR -436[rbp], 0
	mov	DWORD PTR -432[rbp], 0
	mov	DWORD PTR -428[rbp], 0
	mov	DWORD PTR -424[rbp], 0
	mov	DWORD PTR -420[rbp], 0
	mov	DWORD PTR -416[rbp], 0
	mov	DWORD PTR -412[rbp], 0
	mov	DWORD PTR -408[rbp], 0
	mov	DWORD PTR -404[rbp], 0
	mov	edi, 0
	call	XOpenDisplay@PLT
	mov	QWORD PTR -400[rbp], rax
	cmp	QWORD PTR -400[rbp], 0
	jne	.L2
	mov	eax, 1
	jmp	.L21
.L2:
	mov	QWORD PTR -392[rbp], 0
	mov	rax, QWORD PTR -400[rbp]
	mov	rdx, QWORD PTR 232[rax]
	mov	rax, QWORD PTR -400[rbp]
	mov	eax, DWORD PTR 224[rax]
	cdqe
	sal	rax, 7
	add	rax, rdx
	mov	QWORD PTR -392[rbp], rax
	mov	QWORD PTR -384[rbp], 0
	mov	rax, QWORD PTR -400[rbp]
	mov	rbx, QWORD PTR 232[rax]
	mov	rax, QWORD PTR -392[rbp]
	mov	rdi, rax
	call	XScreenNumberOfScreen@PLT
	cdqe
	sal	rax, 7
	add	rax, rbx
	mov	rax, QWORD PTR 16[rax]
	mov	QWORD PTR -384[rbp], rax
	mov	rax, QWORD PTR -400[rbp]
	mov	esi, 68
	mov	rdi, rax
	call	XCreateFontCursor@PLT
	mov	QWORD PTR -376[rbp], rax
	mov	rax, QWORD PTR -400[rbp]
	mov	esi, 78
	mov	rdi, rax
	call	XCreateFontCursor@PLT
	mov	QWORD PTR -368[rbp], rax
	mov	rax, QWORD PTR -400[rbp]
	mov	esi, 0
	mov	rdi, rax
	call	XWhitePixel@PLT
	mov	QWORD PTR -336[rbp], rax
	mov	DWORD PTR -352[rbp], 6
	mov	rax, QWORD PTR -400[rbp]
	mov	esi, 0
	mov	rdi, rax
	call	XBlackPixel@PLT
	mov	QWORD PTR -328[rbp], rax
	mov	rdx, QWORD PTR -328[rbp]
	mov	rax, QWORD PTR -336[rbp]
	xor	rax, rdx
	mov	QWORD PTR -344[rbp], rax
	mov	DWORD PTR -256[rbp], 1
	lea	rdx, -352[rbp]
	mov	rsi, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -400[rbp]
	mov	rcx, rdx
	mov	edx, 32781
	mov	rdi, rax
	call	XCreateGC@PLT
	mov	QWORD PTR -360[rbp], rax
	mov	rsi, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -400[rbp]
	sub	rsp, 8
	push	0
	push	QWORD PTR -376[rbp]
	push	QWORD PTR -384[rbp]
	mov	r9d, 1
	mov	r8d, 1
	mov	ecx, 8204
	mov	edx, 0
	mov	rdi, rax
	call	XGrabPointer@PLT
	add	rsp, 32
	test	eax, eax
	je	.L4
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
.L4:
	mov	rsi, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -400[rbp]
	mov	r9d, 0
	mov	r8d, 1
	mov	ecx, 1
	mov	edx, 0
	mov	rdi, rax
	call	XGrabKeyboard@PLT
	test	eax, eax
	je	.L6
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L6
.L16:
	lea	rdx, -224[rbp]
	mov	rax, QWORD PTR -400[rbp]
	mov	rsi, rdx
	mov	rdi, rax
	call	XNextEvent@PLT
	mov	eax, DWORD PTR -224[rbp]
	cmp	eax, 6
	je	.L8
	cmp	eax, 6
	jg	.L7
	cmp	eax, 4
	je	.L9
	cmp	eax, 5
	je	.L10
	jmp	.L7
.L8:
	cmp	DWORD PTR -408[rbp], 0
	je	.L7
	cmp	DWORD PTR -416[rbp], 0
	je	.L12
	mov	edi, DWORD PTR -412[rbp]
	mov	r9d, DWORD PTR -416[rbp]
	mov	r8d, DWORD PTR -420[rbp]
	mov	ecx, DWORD PTR -424[rbp]
	mov	rdx, QWORD PTR -360[rbp]
	mov	rsi, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -400[rbp]
	sub	rsp, 8
	push	rdi
	mov	rdi, rax
	call	XDrawRectangle@PLT
	add	rsp, 16
	jmp	.L13
.L12:
	mov	rdx, QWORD PTR -368[rbp]
	mov	rax, QWORD PTR -400[rbp]
	mov	ecx, 0
	mov	esi, 8200
	mov	rdi, rax
	call	XChangeActivePointerGrab@PLT
.L13:
	mov	eax, DWORD PTR -440[rbp]
	mov	DWORD PTR -424[rbp], eax
	mov	eax, DWORD PTR -436[rbp]
	mov	DWORD PTR -420[rbp], eax
	mov	eax, DWORD PTR -160[rbp]
	sub	eax, DWORD PTR -424[rbp]
	mov	DWORD PTR -416[rbp], eax
	mov	eax, DWORD PTR -156[rbp]
	sub	eax, DWORD PTR -420[rbp]
	mov	DWORD PTR -412[rbp], eax
	cmp	DWORD PTR -416[rbp], 0
	jns	.L14
	mov	eax, DWORD PTR -416[rbp]
	add	DWORD PTR -424[rbp], eax
	neg	DWORD PTR -416[rbp]
.L14:
	cmp	DWORD PTR -412[rbp], 0
	jns	.L15
	mov	eax, DWORD PTR -412[rbp]
	add	DWORD PTR -420[rbp], eax
	neg	DWORD PTR -412[rbp]
.L15:
	mov	edi, DWORD PTR -412[rbp]
	mov	r9d, DWORD PTR -416[rbp]
	mov	r8d, DWORD PTR -420[rbp]
	mov	ecx, DWORD PTR -424[rbp]
	mov	rdx, QWORD PTR -360[rbp]
	mov	rsi, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -400[rbp]
	sub	rsp, 8
	push	rdi
	mov	rdi, rax
	call	XDrawRectangle@PLT
	add	rsp, 16
	mov	rax, QWORD PTR -400[rbp]
	mov	rdi, rax
	call	XFlush@PLT
	jmp	.L7
.L9:
	mov	DWORD PTR -408[rbp], 1
	mov	eax, DWORD PTR -160[rbp]
	mov	DWORD PTR -440[rbp], eax
	mov	eax, DWORD PTR -156[rbp]
	mov	DWORD PTR -436[rbp], eax
	jmp	.L7
.L10:
	mov	DWORD PTR -404[rbp], 1
	nop
.L7:
	cmp	DWORD PTR -404[rbp], 0
	jne	.L6
	mov	rax, QWORD PTR -400[rbp]
	mov	rdi, rax
	call	XPending@PLT
	test	eax, eax
	jne	.L16
.L6:
	cmp	DWORD PTR -404[rbp], 0
	je	.L7
	cmp	DWORD PTR -416[rbp], 0
	je	.L18
	mov	edi, DWORD PTR -412[rbp]
	mov	r9d, DWORD PTR -416[rbp]
	mov	r8d, DWORD PTR -420[rbp]
	mov	ecx, DWORD PTR -424[rbp]
	mov	rdx, QWORD PTR -360[rbp]
	mov	rsi, QWORD PTR -384[rbp]
	mov	rax, QWORD PTR -400[rbp]
	sub	rsp, 8
	push	rdi
	mov	rdi, rax
	call	XDrawRectangle@PLT
	add	rsp, 16
	mov	rax, QWORD PTR -400[rbp]
	mov	rdi, rax
	call	XFlush@PLT
.L18:
	mov	eax, DWORD PTR -160[rbp]
	sub	eax, DWORD PTR -440[rbp]
	mov	DWORD PTR -432[rbp], eax
	mov	eax, DWORD PTR -156[rbp]
	sub	eax, DWORD PTR -436[rbp]
	mov	DWORD PTR -428[rbp], eax
	cmp	DWORD PTR -432[rbp], 0
	jns	.L19
	mov	eax, DWORD PTR -432[rbp]
	add	DWORD PTR -440[rbp], eax
	neg	DWORD PTR -432[rbp]
.L19:
	cmp	DWORD PTR -428[rbp], 0
	jns	.L20
	mov	eax, DWORD PTR -428[rbp]
	add	DWORD PTR -436[rbp], eax
	neg	DWORD PTR -428[rbp]
.L20:
	mov	rax, QWORD PTR -400[rbp]
	mov	rdi, rax
	call	XCloseDisplay@PLT
	mov	esi, DWORD PTR -436[rbp]
	mov	ecx, DWORD PTR -440[rbp]
	mov	edx, DWORD PTR -428[rbp]
	mov	eax, DWORD PTR -432[rbp]
	mov	r8d, esi
	mov	esi, eax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 0
.L21:
	mov	rbx, QWORD PTR -24[rbp]
	sub	rbx, QWORD PTR fs:40
	je	.L22
	call	__stack_chk_fail@PLT
.L22:
	mov	rbx, QWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.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	"804243.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"couldn't grab pointer:\000"
	.align	2
.LC1:
	.ascii	"couldn't grab keyboard:\000"
	.align	2
.LC2:
	.ascii	"RECT_WIDTH=%d \012RECT_HEIGHT=%d \012RECT_X=%d \012"
	.ascii	"RECT_Y=%d \012\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 = 256
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, fp, lr}
	add	fp, sp, #8
	sub	sp, sp, #284
	ldr	r3, .L23
	ldr	r3, [r3]
	str	r3, [fp, #-16]
	mov	r3,#0
	mov	r3, #0
	str	r3, [fp, #-268]
	mov	r3, #0
	str	r3, [fp, #-264]
	mov	r3, #0
	str	r3, [fp, #-260]
	mov	r3, #0
	str	r3, [fp, #-256]
	mov	r3, #0
	str	r3, [fp, #-252]
	mov	r3, #0
	str	r3, [fp, #-248]
	mov	r3, #0
	str	r3, [fp, #-244]
	mov	r3, #0
	str	r3, [fp, #-240]
	mov	r3, #0
	str	r3, [fp, #-236]
	mov	r3, #0
	str	r3, [fp, #-232]
	mov	r0, #0
	bl	XOpenDisplay
	str	r0, [fp, #-228]
	ldr	r3, [fp, #-228]
	cmp	r3, #0
	bne	.L2
	mov	r3, #1
	b	.L21
.L2:
	mov	r3, #0
	str	r3, [fp, #-224]
	ldr	r3, [fp, #-228]
	ldr	r2, [r3, #140]
	ldr	r3, [fp, #-228]
	ldr	r3, [r3, #132]
	mov	r1, r3
	mov	r3, r1
	lsl	r3, r3, #2
	add	r3, r3, r1
	lsl	r3, r3, #4
	add	r3, r2, r3
	str	r3, [fp, #-224]
	mov	r3, #0
	str	r3, [fp, #-220]
	ldr	r3, [fp, #-228]
	ldr	r4, [r3, #140]
	ldr	r0, [fp, #-224]
	bl	XScreenNumberOfScreen
	mov	r3, r0
	mov	r2, r3
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #4
	add	r3, r4, r3
	ldr	r3, [r3, #8]
	str	r3, [fp, #-220]
	mov	r1, #68
	ldr	r0, [fp, #-228]
	bl	XCreateFontCursor
	str	r0, [fp, #-216]
	mov	r1, #78
	ldr	r0, [fp, #-228]
	bl	XCreateFontCursor
	str	r0, [fp, #-212]
	mov	r1, #0
	ldr	r0, [fp, #-228]
	bl	XWhitePixel
	mov	r3, r0
	str	r3, [fp, #-196]
	mov	r3, #6
	str	r3, [fp, #-204]
	mov	r1, #0
	ldr	r0, [fp, #-228]
	bl	XBlackPixel
	mov	r3, r0
	str	r3, [fp, #-192]
	ldr	r2, [fp, #-192]
	ldr	r3, [fp, #-196]
	eor	r3, r3, r2
	str	r3, [fp, #-200]
	mov	r3, #1
	str	r3, [fp, #-140]
	sub	r3, fp, #204
	ldr	r2, .L23+4
	ldr	r1, [fp, #-220]
	ldr	r0, [fp, #-228]
	bl	XCreateGC
	str	r0, [fp, #-208]
	mov	r3, #0
	str	r3, [sp, #16]
	ldr	r3, [fp, #-216]
	str	r3, [sp, #12]
	ldr	r3, [fp, #-220]
	str	r3, [sp, #8]
	mov	r3, #1
	str	r3, [sp, #4]
	mov	r3, #1
	str	r3, [sp]
	ldr	r3, .L23+8
	mov	r2, #0
	ldr	r1, [fp, #-220]
	ldr	r0, [fp, #-228]
	bl	XGrabPointer
	mov	r3, r0
	cmp	r3, #0
	beq	.L4
	ldr	r0, .L23+12
	bl	printf
.L4:
	mov	r3, #0
	str	r3, [sp, #4]
	mov	r3, #1
	str	r3, [sp]
	mov	r3, #1
	mov	r2, #0
	ldr	r1, [fp, #-220]
	ldr	r0, [fp, #-228]
	bl	XGrabKeyboard
	mov	r3, r0
	cmp	r3, #0
	beq	.L6
	ldr	r0, .L23+16
	bl	printf
	b	.L6
.L16:
	sub	r3, fp, #112
	mov	r1, r3
	ldr	r0, [fp, #-228]
	bl	XNextEvent
	ldr	r3, [fp, #-112]
	cmp	r3, #6
	beq	.L8
	cmp	r3, #6
	bgt	.L7
	cmp	r3, #4
	beq	.L9
	cmp	r3, #5
	beq	.L10
	b	.L7
.L8:
	ldr	r3, [fp, #-236]
	cmp	r3, #0
	beq	.L7
	ldr	r3, [fp, #-244]
	cmp	r3, #0
	beq	.L12
	ldr	r3, [fp, #-244]
	ldr	r2, [fp, #-240]
	str	r2, [sp, #8]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-248]
	str	r3, [sp]
	ldr	r3, [fp, #-252]
	ldr	r2, [fp, #-208]
	ldr	r1, [fp, #-220]
	ldr	r0, [fp, #-228]
	bl	XDrawRectangle
	b	.L13
.L12:
	mov	r3, #0
	ldr	r2, [fp, #-212]
	ldr	r1, .L23+20
	ldr	r0, [fp, #-228]
	bl	XChangeActivePointerGrab
.L13:
	ldr	r3, [fp, #-268]
	str	r3, [fp, #-252]
	ldr	r3, [fp, #-264]
	str	r3, [fp, #-248]
	ldr	r2, [fp, #-80]
	ldr	r3, [fp, #-252]
	sub	r3, r2, r3
	str	r3, [fp, #-244]
	ldr	r2, [fp, #-76]
	ldr	r3, [fp, #-248]
	sub	r3, r2, r3
	str	r3, [fp, #-240]
	ldr	r3, [fp, #-244]
	cmp	r3, #0
	bge	.L14
	ldr	r2, [fp, #-252]
	ldr	r3, [fp, #-244]
	add	r3, r2, r3
	str	r3, [fp, #-252]
	ldr	r3, [fp, #-244]
	rsb	r3, r3, #0
	str	r3, [fp, #-244]
.L14:
	ldr	r3, [fp, #-240]
	cmp	r3, #0
	bge	.L15
	ldr	r2, [fp, #-248]
	ldr	r3, [fp, #-240]
	add	r3, r2, r3
	str	r3, [fp, #-248]
	ldr	r3, [fp, #-240]
	rsb	r3, r3, #0
	str	r3, [fp, #-240]
.L15:
	ldr	r3, [fp, #-244]
	ldr	r2, [fp, #-240]
	str	r2, [sp, #8]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-248]
	str	r3, [sp]
	ldr	r3, [fp, #-252]
	ldr	r2, [fp, #-208]
	ldr	r1, [fp, #-220]
	ldr	r0, [fp, #-228]
	bl	XDrawRectangle
	ldr	r0, [fp, #-228]
	bl	XFlush
	b	.L7
.L9:
	mov	r3, #1
	str	r3, [fp, #-236]
	ldr	r3, [fp, #-80]
	str	r3, [fp, #-268]
	ldr	r3, [fp, #-76]
	str	r3, [fp, #-264]
	b	.L7
.L10:
	mov	r3, #1
	str	r3, [fp, #-232]
	nop
.L7:
	ldr	r3, [fp, #-232]
	cmp	r3, #0
	bne	.L6
	ldr	r0, [fp, #-228]
	bl	XPending
	mov	r3, r0
	cmp	r3, #0
	bne	.L16
.L6:
	ldr	r3, [fp, #-232]
	cmp	r3, #0
	beq	.L7
	ldr	r3, [fp, #-244]
	cmp	r3, #0
	beq	.L18
	ldr	r3, [fp, #-244]
	ldr	r2, [fp, #-240]
	str	r2, [sp, #8]
	str	r3, [sp, #4]
	ldr	r3, [fp, #-248]
	str	r3, [sp]
	ldr	r3, [fp, #-252]
	ldr	r2, [fp, #-208]
	ldr	r1, [fp, #-220]
	ldr	r0, [fp, #-228]
	bl	XDrawRectangle
	ldr	r0, [fp, #-228]
	bl	XFlush
.L18:
	ldr	r2, [fp, #-80]
	ldr	r3, [fp, #-268]
	sub	r3, r2, r3
	str	r3, [fp, #-260]
	ldr	r2, [fp, #-76]
	ldr	r3, [fp, #-264]
	sub	r3, r2, r3
	str	r3, [fp, #-256]
	ldr	r3, [fp, #-260]
	cmp	r3, #0
	bge	.L19
	ldr	r2, [fp, #-268]
	ldr	r3, [fp, #-260]
	add	r3, r2, r3
	str	r3, [fp, #-268]
	ldr	r3, [fp, #-260]
	rsb	r3, r3, #0
	str	r3, [fp, #-260]
.L19:
	ldr	r3, [fp, #-256]
	cmp	r3, #0
	bge	.L20
	ldr	r2, [fp, #-264]
	ldr	r3, [fp, #-256]
	add	r3, r2, r3
	str	r3, [fp, #-264]
	ldr	r3, [fp, #-256]
	rsb	r3, r3, #0
	str	r3, [fp, #-256]
.L20:
	ldr	r0, [fp, #-228]
	bl	XCloseDisplay
	ldr	r3, [fp, #-264]
	str	r3, [sp]
	ldr	r3, [fp, #-268]
	ldr	r2, [fp, #-256]
	ldr	r1, [fp, #-260]
	ldr	r0, .L23+24
	bl	printf
	mov	r3, #0
.L21:
	ldr	r2, .L23
	ldr	r1, [r2]
	ldr	r2, [fp, #-16]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L22
	bl	__stack_chk_fail
.L22:
	mov	r0, r3
	sub	sp, fp, #8
	@ sp needed
	pop	{r4, fp, pc}
.L24:
	.align	2
.L23:
	.word	.LC3
	.word	32781
	.word	8204
	.word	.LC0
	.word	.LC1
	.word	8200
	.word	.LC2
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
