A86 allows floating point numbers as the operands to DD, DQ, and
DT directives. The numbers are encoded according to the IEEE
standard, followed by the 8087 and 287 coprocessors. The format
for floating point constants is as follows: First, there is a
decimal number containing a decimal point. There must be a
decimal point, or else the number is interpreted as an integer.
There must also be at least one decimal digit, either to the left
or right of the decimal point, or else the decimal point is
interpreted as an addition (structure element) operator.
Optionally, there may follow immediately after the decimal number
the letter E followed by a decimal number. The E stands for
"exponent", and means "times 10 raised to the power of". You may
provide a + or - between the E and its number. Examples:
0.1 constant one-tenth
.1 the same
300. floating point three hundred
30.E1 30 * 10**1; i.e., three hundred
30.E+1 the same
30.E-1 30 * 10**-1; i.e., three
30E1 not floating point: hex integer 030E1
1.234E20 scientific notation: 1.234 times 10 to the 20th
1.234E-20 a tiny number: 1.234 divided by 10 to the 20th
You might be also interested in:
:: Find Square Root of a hexadecimal number in assembly language
:: common intreview questions on 8086
:: Assembly Language Source Codes
:: why there are two ground pins in 8086
No comments:
Post a Comment