xref: /OK3568_Linux_fs/kernel/Documentation/arm/nwfpe/nwfpe.rst (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593SmuzhiyunIntroduction
2*4882a593Smuzhiyun============
3*4882a593Smuzhiyun
4*4882a593SmuzhiyunThis directory contains the version 0.92 test release of the NetWinder
5*4882a593SmuzhiyunFloating Point Emulator.
6*4882a593Smuzhiyun
7*4882a593SmuzhiyunThe majority of the code was written by me, Scott Bambrough It is
8*4882a593Smuzhiyunwritten in C, with a small number of routines in inline assembler
9*4882a593Smuzhiyunwhere required.  It was written quickly, with a goal of implementing a
10*4882a593Smuzhiyunworking version of all the floating point instructions the compiler
11*4882a593Smuzhiyunemits as the first target.  I have attempted to be as optimal as
12*4882a593Smuzhiyunpossible, but there remains much room for improvement.
13*4882a593Smuzhiyun
14*4882a593SmuzhiyunI have attempted to make the emulator as portable as possible.  One of
15*4882a593Smuzhiyunthe problems is with leading underscores on kernel symbols.  Elf
16*4882a593Smuzhiyunkernels have no leading underscores, a.out compiled kernels do.  I
17*4882a593Smuzhiyunhave attempted to use the C_SYMBOL_NAME macro wherever this may be
18*4882a593Smuzhiyunimportant.
19*4882a593Smuzhiyun
20*4882a593SmuzhiyunAnother choice I made was in the file structure.  I have attempted to
21*4882a593Smuzhiyuncontain all operating system specific code in one module (fpmodule.*).
22*4882a593SmuzhiyunAll the other files contain emulator specific code.  This should allow
23*4882a593Smuzhiyunothers to port the emulator to NetBSD for instance relatively easily.
24*4882a593Smuzhiyun
25*4882a593SmuzhiyunThe floating point operations are based on SoftFloat Release 2, by
26*4882a593SmuzhiyunJohn Hauser.  SoftFloat is a software implementation of floating-point
27*4882a593Smuzhiyunthat conforms to the IEC/IEEE Standard for Binary Floating-point
28*4882a593SmuzhiyunArithmetic.  As many as four formats are supported: single precision,
29*4882a593Smuzhiyundouble precision, extended double precision, and quadruple precision.
30*4882a593SmuzhiyunAll operations required by the standard are implemented, except for
31*4882a593Smuzhiyunconversions to and from decimal.  We use only the single precision,
32*4882a593Smuzhiyundouble precision and extended double precision formats.  The port of
33*4882a593SmuzhiyunSoftFloat to the ARM was done by Phil Blundell, based on an earlier
34*4882a593Smuzhiyunport of SoftFloat version 1 by Neil Carson for NetBSD/arm32.
35*4882a593Smuzhiyun
36*4882a593SmuzhiyunThe file README.FPE contains a description of what has been implemented
37*4882a593Smuzhiyunso far in the emulator.  The file TODO contains a information on what
38*4882a593Smuzhiyunremains to be done, and other ideas for the emulator.
39*4882a593Smuzhiyun
40*4882a593SmuzhiyunBug reports, comments, suggestions should be directed to me at
41*4882a593Smuzhiyun<scottb@netwinder.org>.  General reports of "this program doesn't
42*4882a593Smuzhiyunwork correctly when your emulator is installed" are useful for
43*4882a593Smuzhiyundetermining that bugs still exist; but are virtually useless when
44*4882a593Smuzhiyunattempting to isolate the problem.  Please report them, but don't
45*4882a593Smuzhiyunexpect quick action.  Bugs still exist.  The problem remains in isolating
46*4882a593Smuzhiyunwhich instruction contains the bug.  Small programs illustrating a specific
47*4882a593Smuzhiyunproblem are a godsend.
48*4882a593Smuzhiyun
49*4882a593SmuzhiyunLegal Notices
50*4882a593Smuzhiyun-------------
51*4882a593Smuzhiyun
52*4882a593SmuzhiyunThe NetWinder Floating Point Emulator is free software.  Everything Rebel.com
53*4882a593Smuzhiyunhas written is provided under the GNU GPL.  See the file COPYING for copying
54*4882a593Smuzhiyunconditions.  Excluded from the above is the SoftFloat code.  John Hauser's
55*4882a593Smuzhiyunlegal notice for SoftFloat is included below.
56*4882a593Smuzhiyun
57*4882a593Smuzhiyun-------------------------------------------------------------------------------
58*4882a593Smuzhiyun
59*4882a593SmuzhiyunSoftFloat Legal Notice
60*4882a593Smuzhiyun
61*4882a593SmuzhiyunSoftFloat was written by John R. Hauser.  This work was made possible in
62*4882a593Smuzhiyunpart by the International Computer Science Institute, located at Suite 600,
63*4882a593Smuzhiyun1947 Center Street, Berkeley, California 94704.  Funding was partially
64*4882a593Smuzhiyunprovided by the National Science Foundation under grant MIP-9311980.  The
65*4882a593Smuzhiyunoriginal version of this code was written as part of a project to build
66*4882a593Smuzhiyuna fixed-point vector processor in collaboration with the University of
67*4882a593SmuzhiyunCalifornia at Berkeley, overseen by Profs. Nelson Morgan and John Wawrzynek.
68*4882a593Smuzhiyun
69*4882a593SmuzhiyunTHIS SOFTWARE IS DISTRIBUTED AS IS, FOR FREE.  Although reasonable effort
70*4882a593Smuzhiyunhas been made to avoid it, THIS SOFTWARE MAY CONTAIN FAULTS THAT WILL AT
71*4882a593SmuzhiyunTIMES RESULT IN INCORRECT BEHAVIOR.  USE OF THIS SOFTWARE IS RESTRICTED TO
72*4882a593SmuzhiyunPERSONS AND ORGANIZATIONS WHO CAN AND WILL TAKE FULL RESPONSIBILITY FOR ANY
73*4882a593SmuzhiyunAND ALL LOSSES, COSTS, OR OTHER PROBLEMS ARISING FROM ITS USE.
74*4882a593Smuzhiyun-------------------------------------------------------------------------------
75