	.file	"3263671.c"
	.intel_syntax noprefix
	.text
	.globl	top
	.data
	.align 4
	.type	top, @object
	.size	top, 4
top:
	.long	-1
	.section	.rodata
.LC0:
	.string	"%d "
	.text
	.globl	Print
	.type	Print, @function
Print:
.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	QWORD PTR -24[rbp], rdi
	mov	DWORD PTR -4[rbp], 0
	jmp	.L2
.L3:
	mov	eax, DWORD PTR -4[rbp]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	mov	esi, eax
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	add	DWORD PTR -4[rbp], 1
.L2:
	mov	eax, DWORD PTR top[rip]
	cmp	DWORD PTR -4[rbp], eax
	jle	.L3
	mov	edi, 10
	call	putchar@PLT
	nop
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	Print, .-Print
	.globl	StackEmpty
	.type	StackEmpty, @function
StackEmpty:
.LFB1:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	eax, DWORD PTR top[rip]
	cmp	eax, -1
	jne	.L5
	mov	eax, 1
	jmp	.L6
.L5:
	mov	eax, 0
.L6:
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE1:
	.size	StackEmpty, .-StackEmpty
	.globl	Push
	.type	Push, @function
Push:
.LFB2:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	mov	QWORD PTR -8[rbp], rdi
	mov	DWORD PTR -12[rbp], esi
	mov	eax, DWORD PTR top[rip]
	add	eax, 1
	mov	DWORD PTR top[rip], eax
	mov	eax, DWORD PTR top[rip]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -8[rbp]
	add	rdx, rax
	mov	eax, DWORD PTR -12[rbp]
	mov	DWORD PTR [rdx], eax
	nop
	pop	rbp
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE2:
	.size	Push, .-Push
	.section	.rodata
.LC1:
	.string	"Underflow."
	.text
	.globl	Pop
	.type	Pop, @function
Pop:
.LFB3:
	.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	QWORD PTR -8[rbp], rdi
	mov	rax, QWORD PTR -8[rbp]
	mov	rdi, rax
	call	StackEmpty
	test	eax, eax
	je	.L9
	lea	rdi, .LC1[rip]
	call	puts@PLT
	nop
	jmp	.L8
.L9:
	mov	eax, DWORD PTR top[rip]
	sub	eax, 1
	mov	DWORD PTR top[rip], eax
	mov	eax, DWORD PTR top[rip]
	cdqe
	add	rax, 1
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -8[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
.L8:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE3:
	.size	Pop, .-Pop
	.section	.rodata
.LC2:
	.string	"1. Print Stack"
.LC3:
	.string	"2. Push Stack"
.LC4:
	.string	"3. Pop Stack"
.LC5:
	.string	"0. Exit"
.LC6:
	.string	"Input: "
.LC7:
	.string	"%d"
.LC8:
	.string	"Enter Key: "
.LC9:
	.string	"Invalid Input. Try Again."
	.text
	.globl	main
	.type	main, @function
main:
.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, 432
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
.L18:
	lea	rdi, .LC2[rip]
	call	puts@PLT
	lea	rdi, .LC3[rip]
	call	puts@PLT
	lea	rdi, .LC4[rip]
	call	puts@PLT
	lea	rdi, .LC5[rip]
	call	puts@PLT
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -424[rbp]
	mov	rsi, rax
	lea	rdi, .LC7[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	eax, DWORD PTR -424[rbp]
	cmp	eax, 3
	je	.L13
	cmp	eax, 3
	jg	.L14
	cmp	eax, 2
	je	.L15
	cmp	eax, 2
	jg	.L14
	test	eax, eax
	je	.L21
	cmp	eax, 1
	jne	.L14
	lea	rax, -416[rbp]
	mov	rdi, rax
	call	Print
	jmp	.L17
.L15:
	lea	rdi, .LC8[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -420[rbp]
	mov	rsi, rax
	lea	rdi, .LC7[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	edx, DWORD PTR -420[rbp]
	lea	rax, -416[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	Push
	lea	rax, -416[rbp]
	mov	rdi, rax
	call	Print
	jmp	.L17
.L13:
	lea	rax, -416[rbp]
	mov	rdi, rax
	call	Pop
	lea	rax, -416[rbp]
	mov	rdi, rax
	call	Print
	jmp	.L17
.L14:
	lea	rdi, .LC9[rip]
	call	puts@PLT
	jmp	.L17
.L21:
	nop
.L17:
	mov	eax, DWORD PTR -424[rbp]
	test	eax, eax
	jne	.L18
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L20
	call	__stack_chk_fail@PLT
.L20:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE4:
	.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	"3263671.c"
	.text
	.global	top
	.data
	.align	2
	.type	top, %object
	.size	top, 4
top:
	.word	-1
	.section	.rodata
	.align	2
.LC0:
	.ascii	"%d \000"
	.text
	.align	2
	.global	Print
	.syntax unified
	.arm
	.fpu softvfp
	.type	Print, %function
Print:
	@ 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]
	mov	r3, #0
	str	r3, [fp, #-8]
	b	.L2
.L3:
	ldr	r3, [fp, #-8]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	ldr	r3, [r3]
	mov	r1, r3
	ldr	r0, .L4
	bl	printf
	ldr	r3, [fp, #-8]
	add	r3, r3, #1
	str	r3, [fp, #-8]
.L2:
	ldr	r3, .L4+4
	ldr	r3, [r3]
	ldr	r2, [fp, #-8]
	cmp	r2, r3
	ble	.L3
	mov	r0, #10
	bl	putchar
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L5:
	.align	2
.L4:
	.word	.LC0
	.word	top
	.size	Print, .-Print
	.align	2
	.global	StackEmpty
	.syntax unified
	.arm
	.fpu softvfp
	.type	StackEmpty, %function
StackEmpty:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	ldr	r3, .L9
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L7
	mov	r3, #1
	b	.L8
.L7:
	mov	r3, #0
.L8:
	mov	r0, r3
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L10:
	.align	2
.L9:
	.word	top
	.size	StackEmpty, .-StackEmpty
	.align	2
	.global	Push
	.syntax unified
	.arm
	.fpu softvfp
	.type	Push, %function
Push:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 1, uses_anonymous_args = 0
	@ link register save eliminated.
	str	fp, [sp, #-4]!
	add	fp, sp, #0
	sub	sp, sp, #12
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	ldr	r3, .L12
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L12
	str	r3, [r2]
	ldr	r3, .L12
	ldr	r3, [r3]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	ldr	r2, [fp, #-12]
	str	r2, [r3]
	nop
	add	sp, fp, #0
	@ sp needed
	ldr	fp, [sp], #4
	bx	lr
.L13:
	.align	2
.L12:
	.word	top
	.size	Push, .-Push
	.section	.rodata
	.align	2
.LC1:
	.ascii	"Underflow.\000"
	.text
	.align	2
	.global	Pop
	.syntax unified
	.arm
	.fpu softvfp
	.type	Pop, %function
Pop:
	@ 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]
	ldr	r0, [fp, #-8]
	bl	StackEmpty
	mov	r3, r0
	cmp	r3, #0
	beq	.L15
	ldr	r0, .L18
	bl	puts
	nop
	b	.L14
.L15:
	ldr	r3, .L18+4
	ldr	r3, [r3]
	sub	r3, r3, #1
	ldr	r2, .L18+4
	str	r3, [r2]
	ldr	r3, .L18+4
	ldr	r3, [r3]
	add	r3, r3, #1
	lsl	r3, r3, #2
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	ldr	r3, [r3]
.L14:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L19:
	.align	2
.L18:
	.word	.LC1
	.word	top
	.size	Pop, .-Pop
	.section	.rodata
	.align	2
.LC2:
	.ascii	"1. Print Stack\000"
	.align	2
.LC3:
	.ascii	"2. Push Stack\000"
	.align	2
.LC4:
	.ascii	"3. Pop Stack\000"
	.align	2
.LC5:
	.ascii	"0. Exit\000"
	.align	2
.LC6:
	.ascii	"Input: \000"
	.align	2
.LC7:
	.ascii	"%d\000"
	.align	2
.LC8:
	.ascii	"Enter Key: \000"
	.align	2
.LC9:
	.ascii	"Invalid Input. Try Again.\000"
	.align	2
.LC10:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 416
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #416
	ldr	r3, .L32
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
.L28:
	ldr	r0, .L32+4
	bl	puts
	ldr	r0, .L32+8
	bl	puts
	ldr	r0, .L32+12
	bl	puts
	ldr	r0, .L32+16
	bl	puts
	ldr	r0, .L32+20
	bl	printf
	sub	r3, fp, #416
	mov	r1, r3
	ldr	r0, .L32+24
	bl	__isoc99_scanf
	ldr	r3, [fp, #-416]
	cmp	r3, #3
	ldrls	pc, [pc, r3, asl #2]
	b	.L21
.L23:
	.word	.L31
	.word	.L25
	.word	.L24
	.word	.L22
.L25:
	sub	r3, fp, #408
	mov	r0, r3
	bl	Print
	b	.L27
.L24:
	ldr	r0, .L32+28
	bl	printf
	sub	r3, fp, #412
	mov	r1, r3
	ldr	r0, .L32+24
	bl	__isoc99_scanf
	ldr	r2, [fp, #-412]
	sub	r3, fp, #408
	mov	r1, r2
	mov	r0, r3
	bl	Push
	sub	r3, fp, #408
	mov	r0, r3
	bl	Print
	b	.L27
.L22:
	sub	r3, fp, #408
	mov	r0, r3
	bl	Pop
	sub	r3, fp, #408
	mov	r0, r3
	bl	Print
	b	.L27
.L21:
	ldr	r0, .L32+32
	bl	puts
	b	.L27
.L31:
	nop
.L27:
	ldr	r3, [fp, #-416]
	cmp	r3, #0
	bne	.L28
	mov	r3, #0
	ldr	r2, .L32
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L30
	bl	__stack_chk_fail
.L30:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L33:
	.align	2
.L32:
	.word	.LC10
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	.LC8
	.word	.LC9
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
