	.file	"278855.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	" is not a number."
	.align 8
.LC1:
	.string	"Please enter a number, such as 2.5, -1.78E8, or 11: "
.LC2:
	.string	"%lf"
	.text
	.globl	getNumber
	.type	getNumber, @function
getNumber:
.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	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	jmp	.L2
.L4:
	nop
.L3:
	call	getchar@PLT
	cmp	eax, 10
	jne	.L4
	lea	rdi, .LC0[rip]
	call	puts@PLT
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
.L2:
	lea	rax, -16[rbp]
	mov	rsi, rax
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	cmp	eax, 1
	jne	.L3
	movsd	xmm0, QWORD PTR -16[rbp]
	movq	rax, xmm0
	mov	rdx, QWORD PTR -8[rbp]
	sub	rdx, QWORD PTR fs:40
	je	.L7
	call	__stack_chk_fail@PLT
.L7:
	movq	xmm0, rax
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	getNumber, .-getNumber
	.section	.rodata
.LC3:
	.string	"%f + %f = %f\n"
.LC4:
	.string	"%f - %f = %f\n"
.LC5:
	.string	"%f * %f = %f\n"
.LC7:
	.string	"%f / %f = %f\n"
.LC8:
	.string	"division by 0 is not allowed."
	.text
	.globl	calculator
	.type	calculator, @function
calculator:
.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	eax, edi
	movsd	QWORD PTR -16[rbp], xmm0
	movsd	QWORD PTR -24[rbp], xmm1
	mov	BYTE PTR -4[rbp], al
	movsx	eax, BYTE PTR -4[rbp]
	cmp	eax, 115
	je	.L9
	cmp	eax, 115
	jg	.L19
	cmp	eax, 109
	je	.L11
	cmp	eax, 109
	jg	.L19
	cmp	eax, 97
	je	.L12
	cmp	eax, 100
	je	.L13
	jmp	.L19
.L12:
	movsd	xmm0, QWORD PTR -16[rbp]
	movapd	xmm1, xmm0
	addsd	xmm1, QWORD PTR -24[rbp]
	movsd	xmm0, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -16[rbp]
	movapd	xmm2, xmm1
	movapd	xmm1, xmm0
	movq	xmm0, rax
	lea	rdi, .LC3[rip]
	mov	eax, 3
	call	printf@PLT
	jmp	.L10
.L9:
	movsd	xmm0, QWORD PTR -16[rbp]
	movapd	xmm1, xmm0
	subsd	xmm1, QWORD PTR -24[rbp]
	movsd	xmm0, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -16[rbp]
	movapd	xmm2, xmm1
	movapd	xmm1, xmm0
	movq	xmm0, rax
	lea	rdi, .LC4[rip]
	mov	eax, 3
	call	printf@PLT
	jmp	.L10
.L11:
	movsd	xmm0, QWORD PTR -16[rbp]
	movapd	xmm1, xmm0
	mulsd	xmm1, QWORD PTR -24[rbp]
	movsd	xmm0, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -16[rbp]
	movapd	xmm2, xmm1
	movapd	xmm1, xmm0
	movq	xmm0, rax
	lea	rdi, .LC5[rip]
	mov	eax, 3
	call	printf@PLT
	jmp	.L10
.L13:
	pxor	xmm0, xmm0
	ucomisd	xmm0, QWORD PTR -24[rbp]
	jp	.L17
	pxor	xmm0, xmm0
	comisd	xmm0, QWORD PTR -24[rbp]
	je	.L18
.L17:
	movsd	xmm0, QWORD PTR -16[rbp]
	movapd	xmm1, xmm0
	divsd	xmm1, QWORD PTR -24[rbp]
	movsd	xmm0, QWORD PTR -24[rbp]
	mov	rax, QWORD PTR -16[rbp]
	movapd	xmm2, xmm1
	movapd	xmm1, xmm0
	movq	xmm0, rax
	lea	rdi, .LC7[rip]
	mov	eax, 3
	call	printf@PLT
	jmp	.L20
.L18:
	lea	rdi, .LC8[rip]
	call	puts@PLT
.L20:
	nop
.L10:
.L19:
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	calculator, .-calculator
	.section	.rodata
	.align 8
.LC9:
	.string	"Enter the operation of your choice:"
	.align 8
.LC10:
	.string	"a. add\ns. subtract\nm. multiply\nd. divide\nq. quit"
.LC11:
	.string	"Bye."
.LC12:
	.string	"Enter first number:"
.LC13:
	.string	"Enter second number:"
.LC14:
	.string	"Invalid input."
.LC15:
	.string	"Let's do this again."
	.text
	.globl	main
	.type	main, @function
main:
.LFB2:
	.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
.L29:
	lea	rdi, .LC9[rip]
	call	puts@PLT
	lea	rdi, .LC10[rip]
	call	puts@PLT
	call	getchar@PLT
	mov	BYTE PTR -17[rbp], al
	cmp	BYTE PTR -17[rbp], 113
	jne	.L22
	lea	rdi, .LC11[rip]
	call	puts@PLT
	jmp	.L31
.L22:
	cmp	BYTE PTR -17[rbp], 97
	je	.L24
	cmp	BYTE PTR -17[rbp], 115
	je	.L24
	cmp	BYTE PTR -17[rbp], 109
	je	.L24
	cmp	BYTE PTR -17[rbp], 100
	jne	.L25
.L24:
	lea	rdi, .LC12[rip]
	mov	eax, 0
	call	printf@PLT
	call	getNumber
	movq	rax, xmm0
	mov	QWORD PTR -16[rbp], rax
	lea	rdi, .LC13[rip]
	mov	eax, 0
	call	printf@PLT
	call	getNumber
	movq	rax, xmm0
	mov	QWORD PTR -8[rbp], rax
	movsx	eax, BYTE PTR -17[rbp]
	movsd	xmm0, QWORD PTR -8[rbp]
	mov	rdx, QWORD PTR -16[rbp]
	movapd	xmm1, xmm0
	movq	xmm0, rdx
	mov	edi, eax
	call	calculator
	jmp	.L26
.L25:
	lea	rdi, .LC14[rip]
	call	puts@PLT
.L26:
	jmp	.L27
.L28:
	nop
.L27:
	call	getchar@PLT
	cmp	eax, 10
	jne	.L28
	lea	rdi, .LC15[rip]
	call	puts@PLT
	jmp	.L29
.L31:
	mov	eax, 0
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.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	"278855.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	" is not a number.\000"
	.align	2
.LC1:
	.ascii	"Please enter a number, such as 2.5, -1.78E8, or 11:"
	.ascii	" \000"
	.align	2
.LC2:
	.ascii	"%lf\000"
	.align	2
.LC3:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	getNumber
	.syntax unified
	.arm
	.fpu softvfp
	.type	getNumber, %function
getNumber:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #16
	ldr	r3, .L8
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	b	.L2
.L4:
	nop
.L3:
	bl	getchar
	mov	r3, r0
	cmp	r3, #10
	bne	.L4
	ldr	r0, .L8+4
	bl	puts
	ldr	r0, .L8+8
	bl	printf
.L2:
	sub	r3, fp, #20
	mov	r1, r3
	ldr	r0, .L8+12
	bl	__isoc99_scanf
	mov	r3, r0
	cmp	r3, #1
	bne	.L3
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	ldr	r1, .L8
	ldr	r0, [r1]
	ldr	r1, [fp, #-8]
	eors	r0, r1, r0
	mov	r1, #0
	beq	.L7
	bl	__stack_chk_fail
.L7:
	mov	r0, r2
	mov	r1, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L9:
	.align	2
.L8:
	.word	.LC3
	.word	.LC0
	.word	.LC1
	.word	.LC2
	.size	getNumber, .-getNumber
	.global	__aeabi_dadd
	.section	.rodata
	.align	2
.LC4:
	.ascii	"%f + %f = %f\012\000"
	.global	__aeabi_dsub
	.align	2
.LC5:
	.ascii	"%f - %f = %f\012\000"
	.global	__aeabi_dmul
	.align	2
.LC6:
	.ascii	"%f * %f = %f\012\000"
	.global	__aeabi_dcmpeq
	.global	__aeabi_ddiv
	.align	2
.LC7:
	.ascii	"%f / %f = %f\012\000"
	.align	2
.LC8:
	.ascii	"division by 0 is not allowed.\000"
	.text
	.align	2
	.global	calculator
	.syntax unified
	.arm
	.fpu softvfp
	.type	calculator, %function
calculator:
	@ args = 8, pretend = 0, frame = 16
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
	mov	r1, r0
	str	r2, [fp, #-20]
	str	r3, [fp, #-16]
	mov	r3, r1
	strb	r3, [fp, #-5]
	ldrb	r3, [fp, #-5]	@ zero_extendqisi2
	sub	r3, r3, #97
	cmp	r3, #18
	ldrls	pc, [pc, r3, asl #2]
	b	.L22
.L13:
	.word	.L16
	.word	.L22
	.word	.L22
	.word	.L15
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L14
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L22
	.word	.L12
.L16:
	ldmib	fp, {r2-r3}
	sub	r1, fp, #20
	ldmia	r1, {r0-r1}
	bl	__aeabi_dadd
	mov	r2, r0
	mov	r3, r1
	str	r2, [sp, #8]
	str	r3, [sp, #12]
	ldmib	fp, {r2-r3}
	stm	sp, {r2-r3}
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	ldr	r0, .L24
	bl	printf
	b	.L11
.L12:
	ldmib	fp, {r2-r3}
	sub	r1, fp, #20
	ldmia	r1, {r0-r1}
	bl	__aeabi_dsub
	mov	r2, r0
	mov	r3, r1
	str	r2, [sp, #8]
	str	r3, [sp, #12]
	ldmib	fp, {r2-r3}
	stm	sp, {r2-r3}
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	ldr	r0, .L24+4
	bl	printf
	b	.L11
.L14:
	ldmib	fp, {r2-r3}
	sub	r1, fp, #20
	ldmia	r1, {r0-r1}
	bl	__aeabi_dmul
	mov	r2, r0
	mov	r3, r1
	str	r2, [sp, #8]
	str	r3, [sp, #12]
	ldmib	fp, {r2-r3}
	stm	sp, {r2-r3}
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	ldr	r0, .L24+8
	bl	printf
	b	.L11
.L15:
	mov	r2, #0
	mov	r3, #0
	ldmib	fp, {r0-r1}
	bl	__aeabi_dcmpeq
	mov	r3, r0
	cmp	r3, #0
	bne	.L21
	ldmib	fp, {r2-r3}
	sub	r1, fp, #20
	ldmia	r1, {r0-r1}
	bl	__aeabi_ddiv
	mov	r2, r0
	mov	r3, r1
	str	r2, [sp, #8]
	str	r3, [sp, #12]
	ldmib	fp, {r2-r3}
	stm	sp, {r2-r3}
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	ldr	r0, .L24+12
	bl	printf
	b	.L23
.L21:
	ldr	r0, .L24+16
	bl	puts
.L23:
	nop
.L11:
.L22:
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L25:
	.align	2
.L24:
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.size	calculator, .-calculator
	.section	.rodata
	.align	2
.LC9:
	.ascii	"Enter the operation of your choice:\000"
	.align	2
.LC10:
	.ascii	"a. add\012s. subtract\012m. multiply\012d. divide\012"
	.ascii	"q. quit\000"
	.align	2
.LC11:
	.ascii	"Bye.\000"
	.align	2
.LC12:
	.ascii	"Enter first number:\000"
	.align	2
.LC13:
	.ascii	"Enter second number:\000"
	.align	2
.LC14:
	.ascii	"Invalid input.\000"
	.align	2
.LC15:
	.ascii	"Let's do this again.\000"
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 24
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #32
.L34:
	ldr	r0, .L37
	bl	puts
	ldr	r0, .L37+4
	bl	puts
	bl	getchar
	mov	r3, r0
	strb	r3, [fp, #-21]
	ldrb	r3, [fp, #-21]	@ zero_extendqisi2
	cmp	r3, #113
	bne	.L27
	ldr	r0, .L37+8
	bl	puts
	b	.L36
.L27:
	ldrb	r3, [fp, #-21]	@ zero_extendqisi2
	cmp	r3, #97
	beq	.L29
	ldrb	r3, [fp, #-21]	@ zero_extendqisi2
	cmp	r3, #115
	beq	.L29
	ldrb	r3, [fp, #-21]	@ zero_extendqisi2
	cmp	r3, #109
	beq	.L29
	ldrb	r3, [fp, #-21]	@ zero_extendqisi2
	cmp	r3, #100
	bne	.L30
.L29:
	ldr	r0, .L37+12
	bl	printf
	bl	getNumber
	str	r0, [fp, #-20]
	str	r1, [fp, #-16]
	ldr	r0, .L37+16
	bl	printf
	bl	getNumber
	str	r0, [fp, #-12]
	str	r1, [fp, #-8]
	ldrb	r1, [fp, #-21]	@ zero_extendqisi2
	sub	r3, fp, #12
	ldmia	r3, {r2-r3}
	stm	sp, {r2-r3}
	sub	r3, fp, #20
	ldmia	r3, {r2-r3}
	mov	r0, r1
	bl	calculator
	b	.L31
.L30:
	ldr	r0, .L37+20
	bl	puts
.L31:
	b	.L32
.L33:
	nop
.L32:
	bl	getchar
	mov	r3, r0
	cmp	r3, #10
	bne	.L33
	ldr	r0, .L37+24
	bl	puts
	b	.L34
.L36:
	mov	r3, #0
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L38:
	.align	2
.L37:
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.word	.LC13
	.word	.LC14
	.word	.LC15
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
