16-01-2013, 04:50 PM
PROGRAM MEMORY ADDRESSING MODE
1PROGRAM MEMORY.ppt (Size: 150 KB / Downloads: 20)
Direct program Memory Addressing
Intersegment Jump: A Jump to any memory location within the entire memory segment
Far jump : It can jump to any memory location for the the next Instruction
Real Mode: 1M byte of Memory using CS & IP
Protected Mode: 4G address range
The Stack
The stack is implemented for temporary storage of information such as data or addresses.
The stack is 64KBytes long and is organized from a software point of view as 32K words.
The contents of the SP and BP registers are used as offsets into the stack segment memory while the segment base value is in the SS register.
Push instructions (PUSH) and pop instructions (POP)
Top of the stack (TOS) and bottom of the stack (BOS)
STACK MEMORY ADDRESSING MODES
- LIFO [ Last-in, First- Out ]
- PUSH instruction : Data are placed onto the stack
- High order 8-bits are placed in the location addressed by SP-1
-Low order 8-bits are placed in the location addressed by SP-2
-SP is decremented by 2 so that the next word of data is stored
- POP instruction : Data are removed from the stack
-Low order 8-bits are removed from the location addressed by SP
-High order 8-bits are removed from the location addressed by SP+1
-SP register is then incremented by 2
- CALL Instruction : uses stack to hold the return address for procedures
-- RET (return Instruction):to remove the return address from the stack