Aad-arithmetic instruction-microprocessor, Assembly Language

AAD: ASCII Adjust for Division though the names of these 2 instructions (AAM and AAD) seem to be same, there is many difference between their functions. The AAD instruction converts 2 unpacked BCD digits in AL and AH to the corresponding binary number in AL. This adjustment might be made before dividing the 2 unpacked BCD digits in the AX by an unpacked BCD byte. SF, PF, ZF are modified whereas CF, AF, OF are not defined, after the execution of the instruction AAD. The instance describes the execution of the instruction. This instruction seems before DIV instruction unlike the AAM seems after MUL in the instruction sequence. Assume AX has 0508 unpacked BCD for 58 decimal, and DH consist 02H.

Example :

1629_AAD.jpg

The conclusion of the AAD execution will give the hexadecimal number 3A in the AL and 00 in the AH. Notice that 3A is the hexadecimal correspondent of 58 (decimal). Now, the instruction DIV DH can be executed. So rather than ASCII adjust for division, it is ASCII adjust before division operation.  All the ASCII adjust instructions are also known as unpacked BCD arithmetic instructions.  Now, we will consider the two instructions related to the packed BCD arithmetic.

 

Posted Date: 10/12/2012 1:47:03 AM | Location : United States







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

Write discussion on Aad-arithmetic instruction-microprocessor
Your posts are moderated
Related Questions
AAA: ASCII Adjust after Addition operation the AAA instruction is executed after an ADD instruction that adds 2 ASCII coded operands to give a byte of outcome in the AL. The AAA i

8255 Programmable Peripheral Interface Intel's 8255 A programmable peripheral interface provides a nice instance of a parallel  interface. As shown the interface have a control

Program : Write an assembly program to find out the number of positive numbers and negative numbers from a given series of signed numbers. Solution : Take the i th num

Why is the capability to relocate processes desirable?

Description Write a MIPS program that reads a string from user input, reverse each word (defined as a sequence of English alphabetic letters or numeric digits without any punctu

The 486 Introduced in the year 1989 the 80486 did not feature any radically new processor technology. Instead, it joints a 386 processor, a cache memory controller and a math c

HELLO I AM TRYING TO ADD AND SUBTRACT BUT I SEEM CAN''T FIND THE CORRECT REGISTER TO PUT IN

write an assembly program to display triangular star like shape

Write a procedure to read a text file and copy its contents to another text file using 8086 assembly language .

Write a MC68H12 assembly language program to find the largest number in an array of ten 8-bit numbers. The array is stored in memory locations starting at address $1100. Use branch