All Exams Test series for 1 year @ ₹349 only
Question

Which stack is used in 8085 microprocessors?

The correct answer is

LIFO

8085 Microprocessor Stack: LIFO Principle Explained

The 8085 microprocessor utilizes a specific memory structure known as a 'stack' for managing data during program execution. This structure is fundamental for handling tasks like subroutine calls and responding to interrupts.

Understanding Stack Operation Principles

Stacks in computing operate based on how data is added and retrieved. The two main principles are:

  • LIFO (Last-In, First-Out): This principle means the most recently added item is the first one to be removed. Imagine a stack of plates: the last plate placed on top is the first one taken off.
  • FIFO (First-In, First-Out): This principle means the first item added is the first one to be removed. This is similar to a queue or line; the first person in line is the first person served.

Stack Implementation in the 8085 Microprocessor

The 8085 microprocessor specifically implements its stack using the LIFO principle. This is crucial for its operational logic.

How LIFO works in the 8085:

  • Push Operation: When data is "pushed" onto the stack, it is stored at the memory location indicated by the Stack Pointer (SP) register, and the SP is then typically decremented to point to the next available stack location.
  • Pop Operation: When data is "popped" from the stack, it is retrieved from the memory location currently pointed to by the SP, and the SP is then typically incremented.

Why LIFO is Used in the 8085

The LIFO structure is ideal for the 8085 microprocessor for several key reasons:

  • Subroutine Calls: When a subroutine is called using the CALL instruction, the address of the instruction immediately following the CALL (the return address) needs to be saved so the program knows where to resume after the subroutine completes. This return address is pushed onto the stack. When the subroutine finishes with a RET instruction, the most recently saved return address (the LIFO principle) is popped off the stack and loaded into the Program Counter (PC).
  • Interrupt Handling: Similarly, when an interrupt occurs, the current state of the processor, including the Program Counter, is often pushed onto the stack before the interrupt service routine begins. This ensures the processor can correctly resume its original task after the interrupt is handled.

Instructions like PUSH and POP directly manipulate the stack using the SP register, reinforcing the LIFO behavior. Therefore, the stack mechanism employed by the 8085 microprocessor adheres strictly to the Last-In, First-Out model.

Was this answer helpful?

Important Questions from Architecture of 8085

  1. What is the maximum addressing capability of Intel 8085?

  2. Which of the following interrupts is non-maskable in 8085 microprocessor?

  3. In a microprocessor, the term 'pipelining' refers to

  4. The clock frequency of an 8085 microprocessor is 5 MHz. If the time required to execute an instruction is 1.4 μs, then the number of T-states needed for executing the instruction is

  5. In an 8085 microprocessor, which one of the following instructions changes the content of the accumulator?

Need Expert Advice?

Start Your Preparation with Prepp Mobile App

Download the app from Google Play & App Store
Download the app from Google Play & App Store
Prepp Mobile App