Minimal changes to get m6502 to compile (won't work)
[Apout.git] / CHANGES
1 2.3 Beta1: to 10th June 2002
2 ----------------------------
3
4 Changed debug statements in cpu.c to be TrapDebug statements as I was
5 seeing output from these in the output file of 2.11BSD /lib/cpp.
6
7 The problem with scripts has also been fixed, finally. I was passing
8 the wrong path into the shell arguments.
9
10 On a 1.6GHz Pentium 4 running FreeBSD 4.5, a make depend; make of the
11 2.11BSD GENERIC kernel takes 72 seconds.
12
13 2.3 Alpha3: to 1st June 2001
14 ----------------------------
15
16 Added patches from Wilhelm B. Kloke wb@vestein.arb-phys.uni-dortmund.de
17 to get Apout to run the Algol 68 binaries found which were added into
18 the Unix Archive.
19
20 A few changes for better Linux compilation. However, stream buffering
21 doesn't seem to work on Linux, at least RedHat 6.2.
22
23 2.3 Alpha2: to 10th Jan 2000
24 ----------------------------
25
26 Added partial support for 0407-magic binaries from 2nd Edition. At
27 present, this is enough for the C compiler on Dennis Ritchie's s2.tar
28 archive to work. It's also good enough for the C compiler to recompile
29 the last1120c compiler, and for the last1120c compiler to recompile itself.
30
31 Added code to support 512-byte block seeks on /dev files for 1st Edition
32 binaries. This was required to get tap(1) to work. This should really
33 only force 512-byte seeks on specific /dev/files, not all of them.
34
35 A significant rearrangement of the code in aout.c was done to make it
36 more logical. I wouldn't say it was much tidier than before, though.
37
38 A redefinition of sigset_t in NetBSD stopped Apout from being compiled
39 there. Thanks to Soren, bsdsignal.c was modified to fix this problem.
40
41 Some small changes to the output from -inst to make it look better.
42 Added a WRITEBASE #define to help improve performance just a bit more.
43
44 2.3 Alpha1: to 2nd Jan 2000
45 ---------------------------
46
47 Added nearly complete support for 0405-magic binaries from 1st Edition,
48 including emulating the KE11A extended arithmetic element. Still some
49 work needed here on both the trap handling and KE11A support. Thanks to
50 Tim Shoppa (shoppa@trailing-edge.com) for his eae code. The 0407-magic
51 binaries from Dennis Ritchie's s2.tar archive are not yet supported. I
52 need the V2/V3 manuals from Norman Wilson for this.
53
54 Some tidying up of the code has been done, using LCLINT and by hand.
55 I've made a Debug() macro which make the code look a bit cleaner.
56
57 Some memory leaks removed. Natives exec()s now inherit the original
58 environment, not the emulated one. Some mov() functions split into
59 separate functions to help improve performance. Added a workaround
60 for date handling in V5/V6 ctime(): see tail of v7trap.c.
61
62 Stream buffering variables consolidated into main.c and some bugs
63 removed (e.g "rw" -> "w+"). 2.11BSD emulation now has stream buffering,
64 but it is turned off by default as it doesn't seem to provide any
65 improvement in performance.
66
67 2.2 Alpha9: to 2nd Mar 1999
68 ---------------------------
69
70 I've added magic numbers for some 2.9BSD binaries: all 2.9 binaries
71 run in the V7 environment, which seems to work but I'm sure that
72 2.9 != V7.
73
74 With help from Jonathan Naylor (g4klx@g4klx.demon.co.uk), and some work
75 myself, I've managed to compile Apout under RedHat Linux 2.2. There are
76 some 2.11BSD syscalls not implemented as a result, but I can recompile
77 the V7 and the 2.11BSD kernels, which is a good indicator.
78
79
80 2.2 Alpha8: to 15th Jan 1999
81 ----------------------------
82
83 These changes came about due to my attempt to compile the UNIX `nsys'
84 kernel source code, dated 1973, with the 5th Edition development tools.
85
86 Added better detection of some special UNIX a.out binaries: the
87 environment for these binaries was being incorrectly set by aout.c.
88 There is now a magic.c which fixes the problem. See also LIMITATIONS
89 for a note of bugs in some a.out binaries.
90
91 Modified v7trap.c to be much cleaner, and to look a bit more like
92 bsdtrap.c. Introduced several small bugs in V5/V6/V7 syscall emulation,
93 notably pipe() and dup(), by the cleanup. These are fixed.
94
95
96 2.2 Alpha7: to 11th Jan 1999
97 ----------------------------
98
99 Modified the code to handle the syscall differences between
100 V6 and V7: note that V5 and V6 are syscall identical. V6 has
101 a different seek() and stat() to V7.
102
103 Added a new file for 2.11BSD ioctls, did many of the terminal
104 ioctls, and a few more syscalls. Now 2.11 vi runs. However,
105 longjmp() doesn't work yet, because it requires working signals.
106
107 Changed some types and #ifdefs for NetBSD and OpenBSD: thanks Soren!
108
109
110 2.2 Alpha6: to 6th Jan 1999
111 ---------------------------
112
113 Bugfixes: none that I can think of.
114
115 Enhancements: tidied the code up somewhat. Changed uint -> u_int
116 throughout. Added support for execution of native binaries: now I can
117 run vi from inside 2.11 bin/sh, yay! Finally wrote the long-overdue
118 manual page. Added RCS tags to all sources. Ensured that it compiled on
119 FreeBSD 3.x and 2.1.x: I need to take it home for FreeBSD 2.2.x.
120
121
122 2.2 Alpha5: to 5th Jan 1999
123 ---------------------------
124
125 Bugfixes: fixed malloc bug, which was a too-large blksize from stat/fstat.
126 Fixed the gtty/stty emulation, which was causing make to break.
127
128 Enhancements: Apout can now run shell scripts. 2.11BSD overlay binaries
129 are now supported, which is good news. I can now compile the 2.11 GENERIC
130 kernel with no manual intervention. On a Pentium II 350MHz, this takes
131 4:16secs with an optimised Apout.
132
133
134 2.2 Alpha4: to 2nd Jan 1999
135 ---------------------------
136
137 Fixed more deficiencies in the 2.11BSD emulation, in particular
138 fork(), vfork() and sbrk(). The argv/envp environment is better
139 but still not totally correct, I think. Finally got the correct
140 code for 2.11 readdir().
141
142 We now have a semi-working FP emulation. It's enough to keep 2.11
143 happy, but it isn't very good. It will do for now.
144
145 Many of the 2.11BSD syscalls are now implemented. Most are not
146 verified, but a lot of 2.11BSD commands run, including sh, make,
147 cc, date, cal. ls(1) goes into an infinite loop when doing ls -l,
148 the inf. loop is in malloc(3). By substituting malloc(3) from
149 Minix 1.3, this problem goes away. I don't know if it's a bug
150 in the emulator, or in the 2.11 malloc() code.
151
152
153 2.2 Alpha3 to 5th Dec 1998
154 --------------------------
155
156 Reorganised bsdtrap.[ch], and started work on the
157 2.11BSD emulated syscalls; this is surprisingly
158 easy for many of them.
159
160
161 Changes from 2.1 to 2.2
162 -----------------------
163
164  + General code tidying up and niggling bug removal.
165  + Code optimisation to speed things up, although
166    I haven't quantified the improvement yet.
167  + Separation of the binary loader and trap handlers
168    from the main program. This doesn't do anything now,
169    but it will make the emulation of several PDP-11
170    environments (e.g 2.11BSD, RT-11) much easier to do.
171  + Finished getting the stream buffering of I/O to work.
172    I still don't know why fdopen doesn't work on "rw".
173  + Some extra trap functionality, e.g basic signal handling.