Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!rutgers!apple!oliveb!amiga!cbmvax!jesup From: jesup@cbmvax.UUCP (Randell Jesup) Newsgroups: comp.sys.amiga Subject: Re: OS/2 vs AmigaDOS Keywords: Operating Systems, Religion WRT computers Message-ID: <6728@cbmvax.UUCP> Date: 1 May 89 22:46:03 GMT References: <2134@iitmax.IIT.EDU> <5625@microsoft.UUCP> Reply-To: jesup@cbmvax.UUCP (Randell Jesup) Organization: Commodore Technology, West Chester, PA Lines: 50 In article <5625@microsoft.UUCP> w-glenns@microsoft.UUCP (Glenn Steffler) writes: >More intelligent OS's like Windows (r) load only those sections of a programs >code from disk when the program is initially executed. If a dialog box is >chosen from a menu item, it's code may not be in memory, and if so, would >be loaded from disk, possibly replacing another segment of code from memory. >In this way, VERY large programs, like MicroSoft Excell (r), can be usefull >in less memory than the program takes up on disk. The exact same capability exists in AmigaDos: overlays. They aren't used a lot (it's (a little) extra work), but they are there and work fine. I've been told that some versions of DPaint use them. They not only allow a flat overlay structure, but a tree structure to overlays. All automatic, merely specify the tree structure in your alink/blink with file, and add lib:ovs.o. Another way of getting the same results is to use loaded libraries. They even stick around until memory gets tight, and don't require reloading normally. >> After all, they both multitask, have graphics >>based interfaces, etc... Is it maybe because the 68000 assembly language >>is more compact than 80286 or 80386? > >In fact m'boy, it's the other way around. Most often used instructions are >one or two bytes, and are streamlined on the 80x86 (x=2,3). The C compilers >for OS/2 and Windows et all are very efficient, having been around for many >more years, the code produced is more often than not (far pointers excluded) >as fast and compact as pure assembly produced "from scratch". Well, compact and fast are often traded off against each other in processor design: witness RISC. The later generation CPUs, like 030/386, are well-optimized for common instructions - the majority of 030 instructions take 2 cycles or so. 68000 has no 1-byte instructions (which are somewhat holdovers from 8008/8080), but most common instructions are 2 bytes, unless an addressing mode or constant requires more. As to as good as hand-coded output from compilers: hah. Most C compilers on the PCclones either don't have global optimizers, or haven't had them for much longer than the amiga (though they MS C has had one longer). Even global-optimizers do not produce code as well as an expert human can. Close, sometimes. As good as, very rarely, mostly for trivial routines. I would think the bizarre register setup and restrictions would make it even worse on an 80x86, though I could be wrong - there could be too many unusual possibilities for a human to deal with. You'll note I restricted this to comp.sys.amiga, to forstall further xposted arguements. -- Randell Jesup, Commodore Engineering {uunet|rutgers|allegra}!cbmvax!jesup