Ret-unconditional branch instruction-microprocessor, Assembly Language

RET : Return from the Procedure:-

At each CALL instruction, the register IP and register CS of the next instruction is pushed to stack, before the control is transferred to the process. In the ending of the procedure, the RET instruction ought to be executed. When it is executed, previously stored content of register IP and CS along with the flags is retrieved into the CS register, IP register and flag registers from the stack and the execution of the main program continues further. The procedure can be a far or a near procedure. In the case of a FAR procedure, the existing contents of SP points to IP and CS register at the time of return. While in the case of a NEAR procedure, it points to only IP. Depending on the type of procedure and the SP contents, the RET instruction has four types.

1. Return within the segment.

2. Return within the segment adding 16-bit immediate displacement to the SP contents.

3. Return the intersegment.

4. Return the intersegment adding 16-bit immediate displacement to the SP contents.

 

Posted Date: 10/12/2012 3:58:04 AM | Location : United States







Related Discussions:- Ret-unconditional branch instruction-microprocessor, Assignment Help, Ask Question on Ret-unconditional branch instruction-microprocessor, Get Answer, Expert's Help, Ret-unconditional branch instruction-microprocessor Discussions

Write discussion on Ret-unconditional branch instruction-microprocessor
Your posts are moderated
Related Questions
Interrupt System Based on Single 8259 A The 8259A is contained in a 28-pin dual-in-line package that need only a + 5-V supply voltage.  Its organization is shown in given figur

Difference between div and idiv

) What is the difference between re-locatable program and re-locatable data?

General terms for Cache : Cache Hits : When the cache consisted the information requested, the transaction is said to be a cache hit. Cache Miss : When the cache does n

8251 Programmable/Communication Interface As an instance of a serial interface device let us suppose Intel's 8251 A programmable communication interfaces. The 8251A is diagram


Compute the Fibonacci sequence - assembly program: Problem: Fibonacci   In this problem you will write a program that will compute the first 20 numbers in the Fibonacci sequ

programs

IInd Generation Microprocessor : The second generation microprocessor by using n MOS technology seemed in the market in 1973.   The Intel  8080, of nMOS  technology