	.file	"145066.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
	.align 8
.LC0:
	.string	"\n\n\nI will now calculate the largest palindrome product of 2 three-digit numbers."
.LC1:
	.string	"\n%d x %d = %d"
.LC2:
	.string	"\n\nThe answer is %d.\n\n\n"
	.text
	.globl	main
	.type	main, @function
main:
.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, 16
	mov	DWORD PTR -8[rbp], 0
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -16[rbp], 100
	jmp	.L2
.L6:
	mov	DWORD PTR -12[rbp], 100
	jmp	.L3
.L5:
	mov	eax, DWORD PTR -16[rbp]
	imul	eax, DWORD PTR -12[rbp]
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	mov	edi, eax
	call	isPalindrome
	test	eax, eax
	je	.L4
	mov	eax, DWORD PTR -4[rbp]
	cmp	eax, DWORD PTR -8[rbp]
	jle	.L4
	mov	eax, DWORD PTR -4[rbp]
	mov	DWORD PTR -8[rbp], eax
	mov	ecx, DWORD PTR -4[rbp]
	mov	edx, DWORD PTR -12[rbp]
	mov	eax, DWORD PTR -16[rbp]
	mov	esi, eax
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
.L4:
	add	DWORD PTR -12[rbp], 1
.L3:
	cmp	DWORD PTR -12[rbp], 999
	jle	.L5
	add	DWORD PTR -16[rbp], 1
.L2:
	cmp	DWORD PTR -16[rbp], 999
	jle	.L6
	mov	eax, DWORD PTR -8[rbp]
	mov	esi, eax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.globl	isPalindrome
	.type	isPalindrome, @function
isPalindrome:
.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, 32
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -4[rbp], 1
	mov	eax, DWORD PTR -20[rbp]
	pxor	xmm2, xmm2
	cvtsi2ss	xmm2, eax
	movd	eax, xmm2
	movd	xmm0, eax
	call	numberOfDigits
	mov	DWORD PTR -12[rbp], eax
	jmp	.L9
.L15:
	mov	eax, DWORD PTR -20[rbp]
	mov	DWORD PTR -8[rbp], eax
	jmp	.L10
.L11:
	pxor	xmm1, xmm1
	cvtsi2sd	xmm1, DWORD PTR -8[rbp]
	movsd	xmm0, QWORD PTR .LC3[rip]
	mulsd	xmm0, xmm1
	cvttsd2si	eax, xmm0
	mov	DWORD PTR -8[rbp], eax
.L10:
	cmp	DWORD PTR -8[rbp], 9
	jg	.L11
	mov	ecx, DWORD PTR -20[rbp]
	movsx	rax, ecx
	imul	rax, rax, 1717986919
	shr	rax, 32
	sar	eax, 2
	mov	esi, ecx
	sar	esi, 31
	sub	eax, esi
	mov	edx, eax
	mov	eax, edx
	sal	eax, 2
	add	eax, edx
	add	eax, eax
	sub	ecx, eax
	mov	edx, ecx
	cmp	DWORD PTR -8[rbp], edx
	jne	.L12
	mov	edx, DWORD PTR -12[rbp]
	lea	rax, -20[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	checkZeroes
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -12[rbp]
	sub	eax, 1
	mov	edi, eax
	call	powTen
	imul	eax, DWORD PTR -8[rbp]
	mov	edx, eax
	mov	eax, DWORD PTR -20[rbp]
	sub	eax, edx
	mov	DWORD PTR -20[rbp], eax
	mov	eax, DWORD PTR -20[rbp]
	pxor	xmm1, xmm1
	cvtsi2sd	xmm1, eax
	movsd	xmm0, QWORD PTR .LC3[rip]
	mulsd	xmm0, xmm1
	cvttsd2si	eax, xmm0
	mov	DWORD PTR -20[rbp], eax
	jmp	.L13
.L12:
	mov	DWORD PTR -4[rbp], 0
.L13:
	mov	eax, DWORD PTR -20[rbp]
	pxor	xmm3, xmm3
	cvtsi2ss	xmm3, eax
	movd	eax, xmm3
	movd	xmm0, eax
	call	numberOfDigits
	mov	DWORD PTR -12[rbp], eax
.L9:
	cmp	DWORD PTR -12[rbp], 1
	jle	.L14
	cmp	DWORD PTR -4[rbp], 1
	je	.L15
.L14:
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	isPalindrome, .-isPalindrome
	.globl	numberOfDigits
	.type	numberOfDigits, @function
numberOfDigits:
.LFB2:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	movss	DWORD PTR -20[rbp], xmm0
	mov	DWORD PTR -4[rbp], 0
	jmp	.L18
.L19:
	pxor	xmm1, xmm1
	cvtss2sd	xmm1, DWORD PTR -20[rbp]
	movsd	xmm0, QWORD PTR .LC3[rip]
	mulsd	xmm0, xmm1
	cvtsd2ss	xmm0, xmm0
	movss	DWORD PTR -20[rbp], xmm0
	add	DWORD PTR -4[rbp], 1
.L18:
	movss	xmm0, DWORD PTR -20[rbp]
	movss	xmm1, DWORD PTR .LC4[rip]
	comiss	xmm0, xmm1
	jnb	.L19
	mov	eax, DWORD PTR -4[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	numberOfDigits, .-numberOfDigits
	.globl	powTen
	.type	powTen, @function
powTen:
.LFB3:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	DWORD PTR -20[rbp], edi
	mov	DWORD PTR -8[rbp], 1
	mov	DWORD PTR -4[rbp], 1
	jmp	.L22
.L23:
	mov	edx, DWORD PTR -8[rbp]
	mov	eax, edx
	sal	eax, 2
	add	eax, edx
	add	eax, eax
	mov	DWORD PTR -8[rbp], eax
	add	DWORD PTR -4[rbp], 1
.L22:
	mov	eax, DWORD PTR -4[rbp]
	cmp	eax, DWORD PTR -20[rbp]
	jle	.L23
	mov	eax, DWORD PTR -8[rbp]
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.size	powTen, .-powTen
	.globl	checkZeroes
	.type	checkZeroes, @function
checkZeroes:
.LFB4:
	.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	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -28[rbp], esi
	mov	DWORD PTR -8[rbp], 1
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -4[rbp], eax
	jmp	.L26
.L27:
	pxor	xmm1, xmm1
	cvtsi2sd	xmm1, DWORD PTR -4[rbp]
	movsd	xmm0, QWORD PTR .LC3[rip]
	mulsd	xmm0, xmm1
	cvttsd2si	eax, xmm0
	mov	DWORD PTR -4[rbp], eax
.L26:
	cmp	DWORD PTR -4[rbp], 99
	jg	.L27
	mov	edx, DWORD PTR -4[rbp]
	movsx	rax, edx
	imul	rax, rax, 1717986919
	shr	rax, 32
	sar	eax, 2
	mov	esi, edx
	sar	esi, 31
	sub	eax, esi
	mov	ecx, eax
	mov	eax, ecx
	sal	eax, 2
	add	eax, ecx
	add	eax, eax
	sub	edx, eax
	mov	DWORD PTR -4[rbp], edx
	cmp	DWORD PTR -4[rbp], 0
	jne	.L28
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR [rax]
	movsx	rdx, eax
	imul	rdx, rdx, 1374389535
	shr	rdx, 32
	sar	edx, 5
	mov	ecx, eax
	sar	ecx, 31
	sub	edx, ecx
	imul	ecx, edx, 100
	sub	eax, ecx
	mov	edx, eax
	mov	eax, edx
	add	eax, 9
	cmp	eax, 18
	ja	.L29
	mov	eax, DWORD PTR -28[rbp]
	sub	eax, 2
	mov	edi, eax
	call	powTen
	mov	edx, eax
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR [rax]
	add	edx, eax
	mov	rax, QWORD PTR -24[rbp]
	mov	DWORD PTR [rax], edx
	mov	rax, QWORD PTR -24[rbp]
	mov	eax, DWORD PTR [rax]
	lea	edx, 10[rax]
	mov	rax, QWORD PTR -24[rbp]
	mov	DWORD PTR [rax], edx
	jmp	.L28
.L29:
	mov	DWORD PTR -8[rbp], 0
.L28:
	mov	eax, DWORD PTR -8[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE4:
	.size	checkZeroes, .-checkZeroes
	.section	.rodata
	.align 8
.LC3:
	.long	-1717986918
	.long	1069128089
	.align 4
.LC4:
	.long	1065353216
	.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	"145066.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"\012\012\012I will now calculate the largest palind"
	.ascii	"rome product of 2 three-digit numbers.\000"
	.align	2
.LC1:
	.ascii	"\012%d x %d = %d\000"
	.align	2
.LC2:
	.ascii	"\012\012The answer is %d.\012\012\012\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	mov	r3, #0
	str	r3, [fp, #-12]
	ldr	r0, .L8
	bl	printf
	mov	r3, #100
	str	r3, [fp, #-20]
	b	.L2
.L6:
	mov	r3, #100
	str	r3, [fp, #-16]
	b	.L3
.L5:
	ldr	r3, [fp, #-20]
	ldr	r2, [fp, #-16]
	mul	r3, r2, r3
	str	r3, [fp, #-8]
	ldr	r0, [fp, #-8]
	bl	isPalindrome
	mov	r3, r0
	cmp	r3, #0
	beq	.L4
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-12]
	cmp	r2, r3
	ble	.L4
	ldr	r3, [fp, #-8]
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-8]
	ldr	r2, [fp, #-16]
	ldr	r1, [fp, #-20]
	ldr	r0, .L8+4
	bl	printf
.L4:
	ldr	r3, [fp, #-16]
	add	r3, r3, #1
	str	r3, [fp, #-16]
.L3:
	ldr	r3, [fp, #-16]
	cmp	r3, #1000
	blt	.L5
	ldr	r3, [fp, #-20]
	add	r3, r3, #1
	str	r3, [fp, #-20]
.L2:
	ldr	r3, [fp, #-20]
	cmp	r3, #1000
	blt	.L6
	ldr	r1, [fp, #-12]
	ldr	r0, .L8+8
	bl	printf
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L9:
	.align	2
.L8:
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.size	main, .-main
	.global	__aeabi_i2f
	.global	__aeabi_i2d
	.global	__aeabi_dmul
	.global	__aeabi_d2iz
	.align	2
	.global	isPalindrome
	.syntax unified
	.arm
	.fpu softvfp
	.type	isPalindrome, %function
isPalindrome:
	@ 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, #-24]
	mov	r3, #1
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-24]
	mov	r0, r3
	bl	__aeabi_i2f
	mov	r3, r0
	mov	r0, r3
	bl	numberOfDigits
	str	r0, [fp, #-16]
	b	.L11
.L17:
	ldr	r3, [fp, #-24]
	str	r3, [fp, #-12]
	b	.L12
.L13:
	ldr	r0, [fp, #-12]
	bl	__aeabi_i2d
	ldr	r2, .L19
	ldr	r3, .L19+4
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	mov	r0, r2
	mov	r1, r3
	bl	__aeabi_d2iz
	mov	r3, r0
	str	r3, [fp, #-12]
.L12:
	ldr	r3, [fp, #-12]
	cmp	r3, #9
	bgt	.L13
	ldr	r1, [fp, #-24]
	ldr	r3, .L19+8
	smull	r2, r3, r1, r3
	asr	r2, r3, #2
	asr	r3, r1, #31
	sub	r2, r2, r3
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #1
	sub	r2, r1, r3
	ldr	r3, [fp, #-12]
	cmp	r3, r2
	bne	.L14
	sub	r3, fp, #24
	ldr	r1, [fp, #-16]
	mov	r0, r3
	bl	checkZeroes
	str	r0, [fp, #-8]
	ldr	r3, [fp, #-16]
	sub	r3, r3, #1
	mov	r0, r3
	bl	powTen
	mov	r2, r0
	ldr	r3, [fp, #-12]
	mul	r3, r2, r3
	ldr	r2, [fp, #-24]
	sub	r3, r2, r3
	str	r3, [fp, #-24]
	ldr	r3, [fp, #-24]
	mov	r0, r3
	bl	__aeabi_i2d
	ldr	r2, .L19
	ldr	r3, .L19+4
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	mov	r0, r2
	mov	r1, r3
	bl	__aeabi_d2iz
	mov	r3, r0
	str	r3, [fp, #-24]
	b	.L15
.L14:
	mov	r3, #0
	str	r3, [fp, #-8]
.L15:
	ldr	r3, [fp, #-24]
	mov	r0, r3
	bl	__aeabi_i2f
	mov	r3, r0
	mov	r0, r3
	bl	numberOfDigits
	str	r0, [fp, #-16]
.L11:
	ldr	r3, [fp, #-16]
	cmp	r3, #1
	ble	.L16
	ldr	r3, [fp, #-8]
	cmp	r3, #1
	beq	.L17
.L16:
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L20:
	.align	2
.L19:
	.word	-1717986918
	.word	1069128089
	.word	1717986919
	.size	isPalindrome, .-isPalindrome
	.global	__aeabi_f2d
	.global	__aeabi_d2f
	.global	__aeabi_fcmpge
	.align	2
	.global	numberOfDigits
	.syntax unified
	.arm
	.fpu softvfp
	.type	numberOfDigits, %function
numberOfDigits:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]	@ float
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L22
.L23:
	ldr	r0, [fp, #-16]	@ float
	bl	__aeabi_f2d
	ldr	r2, .L25
	ldr	r3, .L25+4
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	mov	r0, r2
	mov	r1, r3
	bl	__aeabi_d2f
	mov	r3, r0
	str	r3, [fp, #-16]	@ float
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L22:
	mov	r1, #1065353216
	ldr	r0, [fp, #-16]	@ float
	bl	__aeabi_fcmpge
	mov	r3, r0
	cmp	r3, #0
	bne	.L23
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L26:
	.align	2
.L25:
	.word	-1717986918
	.word	1069128089
	.size	numberOfDigits, .-numberOfDigits
	.align	2
	.global	powTen
	.syntax unified
	.arm
	.fpu softvfp
	.type	powTen, %function
powTen:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #20
	str	r0, [fp, #-16]
	mov	r3, #1
	str	r3, [fp, #-12]
	mov	r3, #1
	str	r3, [fp, #-8]
	b	.L28
.L29:
	ldr	r2, [fp, #-12]
	mov	r3, r2
	lsl	r3, r3, #2
	add	r3, r3, r2
	lsl	r3, r3, #1
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L28:
	ldr	r2, [fp, #-8]
	ldr	r3, [fp, #-16]
	cmp	r2, r3
	ble	.L29
	ldr	r3, [fp, #-12]
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
	.size	powTen, .-powTen
	.align	2
	.global	checkZeroes
	.syntax unified
	.arm
	.fpu softvfp
	.type	checkZeroes, %function
checkZeroes:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	str	r0, [fp, #-16]
	str	r1, [fp, #-20]
	mov	r3, #1
	str	r3, [fp, #-12]
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	b	.L32
.L33:
	ldr	r0, [fp, #-8]
	bl	__aeabi_i2d
	ldr	r2, .L37
	ldr	r3, .L37+4
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	mov	r0, r2
	mov	r1, r3
	bl	__aeabi_d2iz
	mov	r3, r0
	str	r3, [fp, #-8]
.L32:
	ldr	r3, [fp, #-8]
	cmp	r3, #99
	bgt	.L33
	ldr	r2, [fp, #-8]
	ldr	r3, .L37+8
	smull	r1, r3, r2, r3
	asr	r1, r3, #2
	asr	r3, r2, #31
	sub	r1, r1, r3
	mov	r3, r1
	lsl	r3, r3, #2
	add	r3, r3, r1
	lsl	r3, r3, #1
	sub	r3, r2, r3
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	cmp	r3, #0
	bne	.L34
	ldr	r3, [fp, #-16]
	ldr	r2, [r3]
	ldr	r3, .L37+12
	smull	r1, r3, r2, r3
	asr	r1, r3, #5
	asr	r3, r2, #31
	sub	r1, r1, r3
	mov	r3, r1
	lsl	r3, r3, #2
	add	r3, r3, r1
	lsl	r1, r3, #2
	add	r3, r3, r1
	lsl	r3, r3, #2
	sub	r1, r2, r3
	mov	r3, r1
	add	r3, r3, #9
	cmp	r3, #18
	bhi	.L35
	ldr	r3, [fp, #-20]
	sub	r3, r3, #2
	mov	r0, r3
	bl	powTen
	mov	r2, r0
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	add	r2, r2, r3
	ldr	r3, [fp, #-16]
	str	r2, [r3]
	ldr	r3, [fp, #-16]
	ldr	r3, [r3]
	add	r2, r3, #10
	ldr	r3, [fp, #-16]
	str	r2, [r3]
	b	.L34
.L35:
	mov	r3, #0
	str	r3, [fp, #-12]
.L34:
	ldr	r3, [fp, #-12]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L38:
	.align	2
.L37:
	.word	-1717986918
	.word	1069128089
	.word	1717986919
	.word	1374389535
	.size	checkZeroes, .-checkZeroes
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
