Floating Point Operations
Floating point hardware was standard throughout the 7090/94 family. The 7090 had single precision (36-bit) floating point operations while the 7094/7094 II machines also provided double precision (72-bit) floating point instructions.
The floating point formats were as follows:
Single Precision Floating Point Format (36-Bits)
|Algebraic Sign of Fraction (1-Bit)||Characteristic (Bits 1-8)||Fraction (Bits 9-35)|
Double Precision Floating Point Format (In Two Adjacent Words - 72-Bits)
|Algebraic Sign of Fraction (1-Bit)||Characteristic (Bits 1-17)||Fraction (Bits 18-71)|
The fraction was considered normalized if Bit-9 (or Bit-18 in Double Precision) contained the first 1-bit of the fraction so that the floating point word was positioned to have no leading zero bits.
The characteristic for single precision numbers consisted of eight bits (Bits 1-8) and defined the exponent of the number. Since the exponent could either be positive or negative, but the hardware sign bit was already allocated for the fraction, then the exponent was algebraically signed in so-called excess form where the characteristic was formed by subtracting +128 from the exponent (e.g., an exponent of +12 would be coded as 140 and -30 would be coded as 98). The allowable range for the single precision exponent was -128 (decimal) to +127 (decimal) which yielded a floating point range between approximately 10E-39 to 10E+39 (decimal).
As example, single precision floating point 10.00 (decimal) was represented as 204500000000 (octal) which yielded a sign bit of 0; a characteristic of 204 (octal); and a mantissa of 500000000 (octal). The zero sign bit indicated an algebraically positive number; the 204 (octal) or 132 (decimal) characteristic indicated, after subtracting 128 (decimal), an exponent of 4; and the mantissa of 500000000 (octal) indicated a fraction of (2 ** -2) + (2 ** -3) or 0.63 (decimal). Therefore, the floating point number was (2 ** 4) * (0.63) or 10.00.
Other floating point examples: 0.00390625 (decimal) was represented by 171400000000 (octal); 44.00 (decimal) was represented by 206510000000 (octal); and -20.00 (decimal) was represented by 605500000000 (octal).
Five basic floating point operations were supported:
Floating Point Instructions (Single Precision)
See Instruction Set for Details (Does not include Double Precision Instructions)
|Floating Add ('FAD')||Floating Subtract ('FSB')||Floating Round ('FRN')||Floating Multiply ('FMP')||Floating Divide or Halt ('FDH')|
|Floating Add Magnitude ('FAM')||Floating Subtract Magnitude ('FSM')||Unnormalized Floating Multiply ('UFM')||Floating Divide or Proceed ('FDP')|
|Unnormalized Floating Add ('UFA')||Unnormalized Floating Subtract ('UFS')|
|Unnormalized Add Magnitude ('UAM')||Unnormalized Floating Subtract Magnitude ('USM')|
In general, the floating point instructions used both the AC and MQ registers to develop the results. The unnormalized instructions (UFA, UAM, UFS, USM, UFM) left the results in unnormalized form with correct scaling but, possibly, with leading zeros in the fraction.
Example: Assume Z, X, Y, ALPHA, and BETA are normalized floating point numbers. Compute the following and assume that the numbers will remain within allowable limits:
Z = (X + 2Y) * ALPHA / BETA
If a floating point operation yielded a result with an exponent greater than +127 (decimal) or less than -128 (decimal) then an exponent overflow or underflow occurred that resulted in error conditions (the nature of floating point operations eliminated the possibility of overflow or underflow in the fractional part of the word -- though, certainly not the possibility of roundoff errors). In the event of such overflow or underflow, the machine automatically responded by placing the address, plus one, of the offending floating point instruction, into the address portion of location 00000 and an identifying code (called a spill code) into the decrement portion of location 00000. The computer then continued by automatically executing the instruction at location 00010 (octal). Such an event was called a floating point trap.
CLA X Load Floating Point X into Accumulator (X... )
FAD Y Add Floating Point Y (X + Y)
FAD Y Add Floating Point Y (X + 2Y)
XCA Put Intermediate Results into MQ for Multiplication
FMP ALPHA Multiply by ALPHA: (X + 2Y) * ALPHA
FDH BETA Divide Result by BETA: (X + 2Y) * ALPHA / BETA
STO Z Z = (X + 2Y) * ALPHA / BETA
Floating Point Spill Codes
|FLOATING POINT OPERATION||AC||MQ||DECREMENT of 00000 Loaded with...|
|Addition, Subtraction||Underflow||01 (octal)|
http://www.frobenius.com/Floating-Point.htm -- Last Revision: 23 August 2001
Copyright © 1996 - 2018 Jack Harper (unless otherwise noted)