Lines Matching +full:10 +full:- +full:bits

1  +---------------------------------------------------------------------------+
2 | wm-FPU-emu an FPU emulator for 80386 and 80486SX microprocessors. |
6 | Australia. E-mail billm@melbpc.org.au |
21 +---------------------------------------------------------------------------+
25 wm-FPU-emu is an FPU emulator for Linux. It is derived from wm-emu387
27 msdos); wm-emu387 was in turn based upon emu387 which was written by
31 My target FPU for wm-FPU-emu is that described in the Intel486
40 wm-FPU-emu does not implement all of the behaviour of the 80486 FPU,
52 --Bill Metzenthen
56 ----------------------- Internals of wm-FPU-emu -----------------------
70 (4) The trig, log, and exp functions are based in each case upon quasi-
74 a value of pi which is accurate to more than 128 bits. As a consequence,
75 the reduced argument is accurate to more than 64 bits for arguments up
76 to a few pi, and accurate to more than 64 bits for most arguments,
78 80486, which uses a value of pi which is accurate to 66 bits.
81 account for a limited form of re-entrancy. Normally, the emulator will
95 (apart from those in the kernel's per-process tables). The emulator is
96 therefore now fully re-entrant, rather than having just the restricted
97 form of re-entrancy which is required by the Linux kernel.
99 ----------------------- Limitations of wm-FPU-emu -----------------------
101 There are a number of differences between the current wm-FPU-emu
116 (c) the magnitude of the exact result (before rounding) is less than 2^-16382.
117 (d) the magnitude of the final result (after rounding) is exactly 2^-16382.
118 (e) the magnitude of the exact result would be exactly 2^-16382 if the
125 unsupported by the 80486. They are the Pseudo-NaNs, Pseudoinfinities,
134 The FPU instruction may be (usually will be) loaded into the pre-fetch
139 able to find the instruction which caused the device-not-present
150 protection fault message when run under the MS-DOS prompt of Windows
153 The emulator supports 16-bit protected mode, with one difference from
156 will not allow this in 16-bit protected mode: no instructions are
159 ----------------------- Performance of wm-FPU-emu -----------------------
162 -----
173 ms-dos, the next two columns are for emulators running with the djgpp
174 ms-dos extender. The final column is for wm-FPU-emu in Linux 0.97,
177 function Turbo C djgpp 1.06 WM-emu387 wm-FPU-emu
180 - 61.1-65.5 157.3-160.8 76.2-79.5 142.9-144.7
182 / 61.2-75.0 261.4-266.9 75.3-91.6 142.2-158.1
187 atan() 328.9 4866.4 601.1 419.5-491.9
190 log() 413.1-419.1 5103.4-5354.21 254.7-282.2 409.4-437.1
194 The performance under Linux is improved by the use of look-ahead code.
196 Linux due to the look-ahead code. Also given are the times for the
199 [ Linus' note: I changed look-ahead to be the default under linux, as
203 wm-FPU-emu w original w
204 look-ahead 'soft' lib
206 - 108.6-111.6 192.4-216.2
208 / 108.8-124.4 700.1-706.2
213 atan() 367.2-435.5 2439.4-3396.8
216 log() 358.0-387.5 3359.2-3390.3
220 These figures are now somewhat out-of-date. The emulator has become
225 ----------------------- Accuracy of wm-FPU-emu -----------------------
231 The results of the basic arithmetic functions (+,-,*,/), and fsqrt
239 each function was tested at about 400 points. Ideal worst-case results
240 would be 64 bits. The reduced Turbo C accuracy of cos() and tan() for
242 precision of the argument x; e.g. an argument of pi/2-(1e-10) which is
243 accurate to 64 bits can result in a relative accuracy in cos() of
244 about 64 + log2(cos(x)) = 31 bits.
248 (relative bits)
251 atan(x) 1e-10 .. 200 64.2 62.8
252 cos(x) 0 .. pi/2-(1e-10) 64.4 (x <= pi/4) 62.4
253 64.1 (x = pi/2-(1e-10)) 31.9
254 sin(x) 1e-10 .. pi/2 64.0 62.8
255 tan(x) 1e-10 .. pi/2-(1e-10) 64.0 (x <= pi/4) 62.1
256 64.1 (x = pi/2-(1e-10)) 31.9
258 log(x) 1+1e-6 .. 2 63.8 ** 62.1
266 control is set to 24, 53 or 64 bits, and for 'double' variables (53
267 bit precision numbers) when precision control is set to 53 bits (a
269 variables when precision control is set to 64 bits).
273 for pi which is accurate to more than 128 bits precision. As a
282 (absolute bits)
285 sin(x) 1e-16 .. 9.22e+18 62.1
286 tan(x) 1e-16 .. 9.22e+18 61.8
291 is within about 10e-7 of a multiple of pi. To find the tan (for
292 example) of this number to 64 bits precision it would be necessary to
293 have a value of pi which had about 150 bits precision. The FPU
294 emulator computes the result to about 42.6 bits precision (the correct
295 result is about -9.739715e-8). On the other hand, an 80486 FPU returns
307 worst-case results which are better than the worst-case results given
314 columns shows that an accuracy of between 63.80 and 63.89 bits was
318 result (which is 64 bits)) for about one per cent of all arguments
319 between -pi/2 and +pi/2. The other instructions have a lower
321 the worst accuracy which was found (in bits) and the approximate value
325 ------------------- ---------------
327 bits bits bits bits
328 ----- ------------ ------- ---- ---- ----- ----- --------
334 fyl2xp1 (-.293,.414) 520256 0 0 5678 63.93 0.408542 (x)
335 f2xm1 (-1,1) 538847 4 481 6488 63.79 0.167709
346 instructions return results which are in error for more than 10
350 result of the given accuracy in bits (given in the left-most column)
361 accuracy of the results were less than 62 bits, which occurs quite
367 bits f2xm1 f2xm1 fpatan fcos fcos fyl2x fyl2xp1 fsin fptan fptan
369 62.1 0 0 10 0 894 0 0 0 0 1023
372 62.4 385 0 0 10 1292 0 23 0 0 1178
375 62.7 5086 14 0 646 2315 10 101 35 39 1402
380 63.2 24945 11127 10 6588 8098 1120 4470 2968 2990 4724
395 ------------------------- Contributors -------------------------------