Div-idiv-arithmetic instruction-microprocessor, Assembly Language

DIV: Unsigned Division:- This instruction performs unsigned division operation. It divides an unsigned word or double word by a 16-bit or 8-bit operand. The dividend might be in the register AX for 16-bit operation and divisor might be specified  by using any one of the addressing modes accept immediate. The result will be in the register AL (quotient) while register AH will contain the remainder. If the result is too big to fit in register AL, type 0 (divide by zero) interrupt is produced. In case of a double word dividend (32-bit), the higher word should be in register DX and lower word should be in the register AX. The divisor might be specified as already explained. The remainder and quotient , in this type of case, will be in AX and DX respectively. This instruction does not make any affect on any flag.

IDIV:  Signed Division:- This instruction performs the similar  operation  as the DIV  instruction, but with signed operands. The results are stored similarly as in case of DIV instruction in both cases of word and double word divisions. The results will be also signed numbers. The operands are also specified in the similar way as DIV instruction. Divide by 0 interrupt is produced, if the result is too big to fit in register AX (16-bit dividend operation) or register AX and register DX (32-bit  dividend  operation). All the flags are undefined after IDIV instruction. 


Posted Date: 10/12/2012 2:11:35 AM | Location : United States

Related Discussions:- Div-idiv-arithmetic instruction-microprocessor, Assignment Help, Ask Question on Div-idiv-arithmetic instruction-microprocessor, Get Answer, Expert's Help, Div-idiv-arithmetic instruction-microprocessor Discussions

Write discussion on Div-idiv-arithmetic instruction-microprocessor
Your posts are moderated
Related Questions
DAS: Decimal Adjust after Subtraction:- This instruction converts the result of subtraction operation of 2 packed BCD numbers to a valid BCD number. The subtraction operation has

code to add two matrices

ROR : Rotate Right without Carry: This instruction rotates the contents of destination operand to the bit-wise right either by one or by the count specified in register CL, exclud

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

I need to estimate the value of a definite integral using Riemann Sums and For our estimation let f(x) = x2 ,a=0, b=10 and n=5. Where a is the lower bound, b is the upper bound and

Flag Register : 8086 has a 16-bit flag register which is divided into 2 parts, viz. (a)machine control flagsand (b)condition code or status flags. The condition code flag regi

how we can take permission

Segment Registers The 8086 addresses a segmented memory unlike 8085. The complete 1 megabyte memory, which 8086 is capable to address is divided into 16 logical segments.Thusea

write an assembly language program to find average of odd numbers from an array of 8 bit numbers

Read Architecture : Look Aside Cache In "look aside" cache architecture the main memory is located conflictingthe system interface. Both the cache main memory sees a bus cycle