	.file	"258942.c"
	.intel_syntax noprefix
	.text
	.globl	top
	.data
	.align 4
	.type	top, @object
	.size	top, 4
top:
	.long	-1
	.section	.rodata
.LC0:
	.string	"Stack is full"
	.text
	.globl	push
	.type	push, @function
push:
.LFB6:
	.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	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]
	cmp	eax, 99
	jle	.L2
	lea	rdi, .LC0[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 1
	call	exit@PLT
.L2:
	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
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE6:
	.size	push, .-push
	.section	.rodata
.LC1:
	.string	"Stack is Empty"
	.text
	.globl	pop
	.type	pop, @function
pop:
.LFB7:
	.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	eax, DWORD PTR top[rip]
	cmp	eax, -1
	jne	.L4
	lea	rdi, .LC1[rip]
	mov	eax, 0
	call	printf@PLT
	mov	edi, 1
	call	exit@PLT
.L4:
	mov	eax, DWORD PTR top[rip]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE7:
	.size	pop, .-pop
	.globl	popdisplay
	.type	popdisplay, @function
popdisplay:
.LFB8:
	.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	eax, DWORD PTR top[rip]
	cmp	eax, -1
	jne	.L7
	mov	edi, 1
	call	exit@PLT
.L7:
	mov	eax, DWORD PTR top[rip]
	cdqe
	lea	rdx, 0[0+rax*4]
	mov	rax, QWORD PTR -24[rbp]
	add	rax, rdx
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR -4[rbp], eax
	mov	eax, DWORD PTR top[rip]
	sub	eax, 1
	mov	DWORD PTR top[rip], eax
	mov	eax, DWORD PTR -4[rbp]
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE8:
	.size	popdisplay, .-popdisplay
	.section	.rodata
	.align 8
.LC2:
	.string	"Enter your choice: 1 for pushing into the stack, 2 for popping out of the stack,3 for displaying all the stack elements and 0 to exit:"
.LC3:
	.string	"%d"
	.align 8
.LC4:
	.string	"Enter the element to be inserted:"
.LC5:
	.string	"The popped out element is:"
.LC6:
	.string	"%d\n"
.LC7:
	.string	"The elements are:"
	.text
	.globl	main
	.type	main, @function
main:
.LFB9:
	.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
	mov	DWORD PTR -432[rbp], -1
	jmp	.L10
.L16:
	lea	rdi, .LC2[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -432[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	eax, DWORD PTR -432[rbp]
	cmp	eax, 3
	je	.L11
	cmp	eax, 3
	jg	.L10
	cmp	eax, 1
	je	.L12
	cmp	eax, 2
	je	.L13
	jmp	.L10
.L12:
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -428[rbp]
	mov	rsi, rax
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	__isoc99_scanf@PLT
	mov	edx, DWORD PTR -428[rbp]
	lea	rax, -416[rbp]
	mov	esi, edx
	mov	rdi, rax
	call	push
	nop
	jmp	.L10
.L13:
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	lea	rax, -416[rbp]
	mov	rdi, rax
	call	pop
	mov	DWORD PTR -420[rbp], eax
	mov	eax, DWORD PTR -420[rbp]
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L10
.L11:
	lea	rdi, .LC7[rip]
	call	puts@PLT
	jmp	.L14
.L15:
	lea	rax, -416[rbp]
	mov	rdi, rax
	call	popdisplay
	mov	DWORD PTR -424[rbp], eax
	mov	eax, DWORD PTR -424[rbp]
	mov	esi, eax
	lea	rdi, .LC6[rip]
	mov	eax, 0
	call	printf@PLT
.L14:
	cmp	DWORD PTR -424[rbp], -999
	jne	.L15
	nop
.L10:
	mov	eax, DWORD PTR -432[rbp]
	test	eax, eax
	jne	.L16
	nop
	mov	rax, QWORD PTR -8[rbp]
	sub	rax, QWORD PTR fs:40
	je	.L17
	call	__stack_chk_fail@PLT
.L17:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE9:
	.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	"258942.c"
	.text
	.global	top
	.data
	.align	2
	.type	top, %object
	.size	top, 4
top:
	.word	-1
	.section	.rodata
	.align	2
.LC0:
	.ascii	"Stack is full\000"
	.text
	.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
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #8
	str	r0, [fp, #-8]
	str	r1, [fp, #-12]
	ldr	r3, .L3
	ldr	r3, [r3]
	add	r3, r3, #1
	ldr	r2, .L3
	str	r3, [r2]
	ldr	r3, .L3
	ldr	r3, [r3]
	cmp	r3, #99
	ble	.L2
	ldr	r0, .L3+4
	bl	printf
	mov	r0, #1
	bl	exit
.L2:
	ldr	r3, .L3
	ldr	r3, [r3]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-8]
	add	r3, r2, r3
	ldr	r2, [fp, #-12]
	str	r2, [r3]
	nop
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L4:
	.align	2
.L3:
	.word	top
	.word	.LC0
	.size	push, .-push
	.section	.rodata
	.align	2
.LC1:
	.ascii	"Stack is Empty\000"
	.text
	.align	2
	.global	pop
	.syntax unified
	.arm
	.fpu softvfp
	.type	pop, %function
pop:
	@ 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]
	ldr	r3, .L8
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L6
	ldr	r0, .L8+4
	bl	printf
	mov	r0, #1
	bl	exit
.L6:
	ldr	r3, .L8
	ldr	r3, [r3]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L9:
	.align	2
.L8:
	.word	top
	.word	.LC1
	.size	pop, .-pop
	.align	2
	.global	popdisplay
	.syntax unified
	.arm
	.fpu softvfp
	.type	popdisplay, %function
popdisplay:
	@ 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]
	ldr	r3, .L13
	ldr	r3, [r3]
	cmn	r3, #1
	bne	.L11
	mov	r0, #1
	bl	exit
.L11:
	ldr	r3, .L13
	ldr	r3, [r3]
	lsl	r3, r3, #2
	ldr	r2, [fp, #-16]
	add	r3, r2, r3
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	ldr	r3, .L13
	ldr	r3, [r3]
	sub	r3, r3, #1
	ldr	r2, .L13
	str	r3, [r2]
	ldr	r3, [fp, #-8]
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L14:
	.align	2
.L13:
	.word	top
	.size	popdisplay, .-popdisplay
	.section	.rodata
	.align	2
.LC2:
	.ascii	"Enter your choice: 1 for pushing into the stack, 2 "
	.ascii	"for popping out of the stack,3 for displaying all t"
	.ascii	"he stack elements and 0 to exit:\000"
	.align	2
.LC3:
	.ascii	"%d\000"
	.align	2
.LC4:
	.ascii	"Enter the element to be inserted:\000"
	.align	2
.LC5:
	.ascii	"The popped out element is:\000"
	.align	2
.LC6:
	.ascii	"%d\012\000"
	.align	2
.LC7:
	.ascii	"The elements are:\000"
	.align	2
.LC8:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 424
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #424
	ldr	r3, .L24
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	mvn	r3, #0
	str	r3, [fp, #-424]
	b	.L16
.L22:
	ldr	r0, .L24+4
	bl	printf
	sub	r3, fp, #424
	mov	r1, r3
	ldr	r0, .L24+8
	bl	__isoc99_scanf
	ldr	r3, [fp, #-424]
	cmp	r3, #3
	beq	.L17
	cmp	r3, #3
	bgt	.L16
	cmp	r3, #1
	beq	.L18
	cmp	r3, #2
	beq	.L19
	b	.L16
.L18:
	ldr	r0, .L24+12
	bl	printf
	sub	r3, fp, #420
	mov	r1, r3
	ldr	r0, .L24+8
	bl	__isoc99_scanf
	ldr	r2, [fp, #-420]
	sub	r3, fp, #408
	mov	r1, r2
	mov	r0, r3
	bl	push
	nop
	b	.L16
.L19:
	ldr	r0, .L24+16
	bl	printf
	sub	r3, fp, #408
	mov	r0, r3
	bl	pop
	str	r0, [fp, #-412]
	ldr	r1, [fp, #-412]
	ldr	r0, .L24+20
	bl	printf
	b	.L16
.L17:
	ldr	r0, .L24+24
	bl	puts
	b	.L20
.L21:
	sub	r3, fp, #408
	mov	r0, r3
	bl	popdisplay
	str	r0, [fp, #-416]
	ldr	r1, [fp, #-416]
	ldr	r0, .L24+20
	bl	printf
.L20:
	ldr	r3, [fp, #-416]
	ldr	r2, .L24+28
	cmp	r3, r2
	bne	.L21
	nop
.L16:
	ldr	r3, [fp, #-424]
	cmp	r3, #0
	bne	.L22
	nop
	ldr	r3, .L24
	ldr	r2, [r3]
	ldr	r3, [fp, #-8]
	eors	r2, r3, r2
	mov	r3, #0
	beq	.L23
	bl	__stack_chk_fail
.L23:
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L25:
	.align	2
.L24:
	.word	.LC8
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.word	.LC7
	.word	-999
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
