Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!know!sdd.hp.com!elroy.jpl.nasa.gov!usc!orion.oac.uci.edu!cedman From: cedman@golem.ps.uci.edu (Carl Edman) Newsgroups: comp.sys.amiga.tech Subject: Re: Assembler Programming - Costs versus Benefits Message-ID: Date: 29 Nov 90 18:22:30 GMT References: <1990Nov25.040121.10773@zorch.SF-Bay.ORG> <1990Nov25.233007.19698@cs.umu.se> <7139@sugar.hackercorp.com> <1990Nov27.004859.16630@cs.umu.se> <7150@sugar.hackercorp.com> <7160@sugar.hackercorp.com> Organization: University of California, Irvine, USA. Lines: 58 Nntp-Posting-Host: lynx.ps.uci.edu In-reply-to: peter@sugar.hackercorp.com's message of 29 Nov 90 11:51:08 GMT In article <7160@sugar.hackercorp.com> peter@sugar.hackercorp.com (Peter da Silva) writes: In article cedman@golem.ps.uci.edu (Carl Edman) writes: > A correct 68000 program runs unchanged on a 68030. Ah, then explain why Atari ST programs don't run on a 68020. There are lots of instructions that work differently between the 68000 and 68030, and any program that uses them will behave differently on different machines. Oh, you can say "but those aren't correct 68000 programs", which is all well and good but in the real world these instructions exist and are percieved as being useful to the sorts of folks who write manic games in assembler. I haven't heard about the ST in a long time, but last time I checked, the reason why current STs don't work with higher processors (in contrast to the amiga, which has run higher processors almost forever), is that the OS of the ST was written sloppily. OSes sometimes have to use dirty programming, and as long as they do it that is fine. Amiga OS has been written in a way which is compatible with higher processors, ST OS hasn't. User programs for the ST should run unmodified under higher processors. Basically, writing a portable program is harder the lower the level you write the program at. If you do everything through intuition in C, you're unlikely to cause headaches for Amiga 3000 users. If you do everything in assembly, it's a lot harder to keep all the differences between the different processors straight... because they become exposed to the programmer. I really don't know about which "all the differences" you are talking about. I've programmed both and there really aren't any incompatibilities. I'm all for using Intuition and not writing to the screen memory directly. But you can do that just as well in assembler. And intuition.library does not screen you from any processor incompatibilities. I'm not saying "it's impossible to write a portable 68000 program in assembly", but rather "it's a whole lot harder to write one". Quit with the theoretical BS and look at the real world. There are lots of 68030 instructions which don't run on a 68000. Almost all 68000 instructions run on a 68030. The only minor exceptions to this are quite obscure accesses which should only be made in supervisor mode (in which no user programm should run) anyway. If I may quote the "Processor book for the 680x0 family" with respect to the 68020 (the translation is mine): "The 68020 has been extended in many areas. Still it remains program - compatible with the other CPUs in the family. Certain limitations of compatibility affect routines which process exceptions. But on the User-level the 68020 is capable to run all programs written for 680x0 family without changes." Good enough ? Theorectical Physicist,N.:A physicist whose | Send mail existence is postulated, to make the numbers | to balance but who is never actually observed | cedman@golem.ps.uci.edu in the laboratory. | edmanc@uciph0.ps.uci.edu