	.file	"179830493.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"%d\n"
.LC1:
	.string	"-1"
.LC2:
	.string	"2"
.LC3:
	.string	"%lld\n"
	.text
	.globl	factor
	.type	factor, @function
factor:
.LFB0:
	.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	DWORD PTR -12[rbp], 0
	cmp	DWORD PTR -20[rbp], 0
	je	.L2
	cmp	DWORD PTR -20[rbp], 1
	jne	.L3
.L2:
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, eax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L1
.L3:
	cmp	DWORD PTR -20[rbp], 0
	jns	.L6
	neg	DWORD PTR -20[rbp]
	lea	rdi, .LC1[rip]
	call	puts@PLT
	mov	DWORD PTR -12[rbp], 1
	jmp	.L6
.L7:
	mov	eax, DWORD PTR -20[rbp]
	mov	edx, eax
	shr	edx, 31
	add	eax, edx
	sar	eax
	mov	DWORD PTR -20[rbp], eax
	lea	rdi, .LC2[rip]
	call	puts@PLT
	mov	DWORD PTR -12[rbp], 1
.L6:
	mov	eax, DWORD PTR -20[rbp]
	and	eax, 1
	test	eax, eax
	je	.L7
	mov	QWORD PTR -8[rbp], 3
	jmp	.L8
.L10:
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	cqo
	idiv	QWORD PTR -8[rbp]
	mov	DWORD PTR -20[rbp], eax
	mov	rax, QWORD PTR -8[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -12[rbp], 1
.L9:
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	cqo
	idiv	QWORD PTR -8[rbp]
	mov	rax, rdx
	test	rax, rax
	je	.L10
	add	QWORD PTR -8[rbp], 2
.L8:
	mov	rax, QWORD PTR -8[rbp]
	imul	rax, rax
	mov	rdx, rax
	mov	eax, DWORD PTR -20[rbp]
	cdqe
	cmp	rdx, rax
	jle	.L9
	cmp	DWORD PTR -20[rbp], 1
	jg	.L12
	cmp	DWORD PTR -12[rbp], 0
	jne	.L1
.L12:
	mov	eax, DWORD PTR -20[rbp]
	mov	esi, eax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
.L1:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	factor, .-factor
	.section	.rodata
.LC4:
	.string	"%d"
	.text
	.globl	main
	.type	main, @function
main:
.LFB1:
	.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	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	jmp	.L14
.L17:
	mov	eax, DWORD PTR -12[rbp]
	test	eax, eax
	je	.L20
	mov	eax, DWORD PTR -12[rbp]
	mov	edi, eax
	call	factor
.L14:
	lea	rax, -12[rbp]
	mov	rsi, rax
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	cmp	eax, 1
	je	.L17
	jmp	.L16
.L20:
	nop
.L16:
	mov	eax, 0
	mov	rdx, QWORD PTR -8[rbp]
	sub	rdx, QWORD PTR fs:40
	je	.L19
	call	__stack_chk_fail@PLT
.L19:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.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	"179830493.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"%d\012\000"
	.align	2
.LC1:
	.ascii	"-1\000"
	.align	2
.LC2:
	.ascii	"2\000"
	.global	__aeabi_ldivmod
	.align	2
.LC3:
	.ascii	"%lld\012\000"
	.text
	.align	2
	.global	factor
	.syntax unified
	.arm
	.fpu softvfp
	.type	factor, %function
factor:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{r4, r5, fp, lr}
	add	fp, sp, #12
	sub	sp, sp, #24
	str	r0, [fp, #-32]
	mov	r3, #0
	str	r3, [fp, #-24]
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	beq	.L2
	ldr	r3, [fp, #-32]
	cmp	r3, #1
	bne	.L3
.L2:
	ldr	r1, [fp, #-32]
	ldr	r0, .L13
	bl	printf
	b	.L1
.L3:
	ldr	r3, [fp, #-32]
	cmp	r3, #0
	bge	.L6
	ldr	r3, [fp, #-32]
	rsb	r3, r3, #0
	str	r3, [fp, #-32]
	ldr	r0, .L13+4
	bl	puts
	mov	r3, #1
	str	r3, [fp, #-24]
	b	.L6
.L7:
	ldr	r3, [fp, #-32]
	lsr	r2, r3, #31
	add	r3, r2, r3
	asr	r3, r3, #1
	str	r3, [fp, #-32]
	ldr	r0, .L13+8
	bl	puts
	mov	r3, #1
	str	r3, [fp, #-24]
.L6:
	ldr	r3, [fp, #-32]
	and	r3, r3, #1
	cmp	r3, #0
	beq	.L7
	mov	r2, #3
	mov	r3, #0
	str	r2, [fp, #-20]
	str	r3, [fp, #-16]
	b	.L8
.L10:
	ldr	r3, [fp, #-32]
	mov	r0, r3
	asr	r1, r0, #31
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	bl	__aeabi_ldivmod
	mov	r2, r0
	mov	r3, r1
	mov	r3, r2
	str	r3, [fp, #-32]
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	ldr	r0, .L13+12
	bl	printf
	mov	r3, #1
	str	r3, [fp, #-24]
.L9:
	ldr	r3, [fp, #-32]
	mov	r0, r3
	asr	r1, r0, #31
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	bl	__aeabi_ldivmod
	orrs	r3, r2, r3
	beq	.L10
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	adds	r4, r2, #2
	adc	r5, r3, #0
	str	r4, [fp, #-20]
	str	r5, [fp, #-16]
.L8:
	ldr	r3, [fp, #-16]
	ldr	r2, [fp, #-20]
	mul	r2, r3, r2
	ldr	r3, [fp, #-16]
	ldr	r1, [fp, #-20]
	mul	r3, r1, r3
	add	r0, r2, r3
	ldr	r1, [fp, #-20]
	umull	r2, r3, r1, r1
	add	r1, r0, r3
	mov	r3, r1
	ldr	r1, [fp, #-32]
	mov	r0, r1
	asr	r1, r0, #31
	cmp	r0, r2
	sbcs	r3, r1, r3
	bge	.L9
	ldr	r3, [fp, #-32]
	cmp	r3, #1
	bgt	.L12
	ldr	r3, [fp, #-24]
	cmp	r3, #0
	bne	.L1
.L12:
	ldr	r1, [fp, #-32]
	ldr	r0, .L13
	bl	printf
.L1:
	sub	sp, fp, #12
	@ sp needed
	pop	{r4, r5, fp, pc}
.L14:
	.align	2
.L13:
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.size	factor, .-factor
	.section	.rodata
	.align	2
.LC4:
	.ascii	"%d\000"
	.align	2
.LC5:
	.word	__stack_chk_guard
	.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, #8
	ldr	r3, .L23
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	b	.L16
.L19:
	ldr	r3, [fp, #-12]
	cmp	r3, #0
	beq	.L22
	ldr	r3, [fp, #-12]
	mov	r0, r3
	bl	factor
.L16:
	sub	r3, fp, #12
	mov	r1, r3
	ldr	r0, .L23+4
	bl	__isoc99_scanf
	mov	r3, r0
	cmp	r3, #1
	beq	.L19
	b	.L18
.L22:
	nop
.L18:
	mov	r3, #0
	ldr	r2, .L23
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L21
	bl	__stack_chk_fail
.L21:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L24:
	.align	2
.L23:
	.word	.LC5
	.word	.LC4
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
