Ret-unconditional branch instruction-microprocessor, Assembly Language

Assignment Help:

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.

 


Related Discussions:- Ret-unconditional branch instruction-microprocessor

General bus operation-microprocessor, General Bus Operation The 8086 ha...

General Bus Operation The 8086 has a joined data and address bus commonly referred to as a time multiplexed address and data bus. The major reason behind  multiplexing address

Program translation sequence, Program Translation Sequence Developing ...

Program Translation Sequence Developing a software program to accomplish a particular task, the implementer chooses an appropriate language, develops the algorithm (a sequence

Matrices, code to add two matrices

code to add two matrices

Xor-logical instruction-microprocessor, XOR: Logical Exclusive OR: The XOR...

XOR: Logical Exclusive OR: The XOR operation is again carried out in a similar way to the AND and OR operation. The constraint over operands are also similar. The XOR operation pr

Or-logical instruction-microprocessor, OR: Logical OR: The OR instruction ...

OR: Logical OR: The OR instruction carries out the OR operation in the similar way as described in case of the AND operation. The restriction on source and destination operands ar

Selecting array elements, implement the following c++ code in assembly lang...

implement the following c++ code in assembly language using the block-structured .IF and .while directives

Shell script, write shell to calculate basic salary from given .

write shell to calculate basic salary from given .

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd