Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: $Revision: 1.6.2.16 $; site ima.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!think!ima!johnl From: johnl@ima.UUCP Newsgroups: net.unix-wizards Subject: Re: Re: Wierd code Message-ID: <99500003@ima.UUCP> Date: Sun, 3-Nov-85 22:54:00 EST Article-I.D.: ima.99500003 Posted: Sun Nov 3 22:54:00 1985 Date-Received: Thu, 7-Nov-85 03:57:23 EST References: <2390@brl-tgr.UUCP> Lines: 26 Nf-ID: #R:brl-tgr:-239000:ima:99500003:000:1378 Nf-From: ima!johnl Nov 3 22:54:00 1985 > An #ifdef VAX would be superfluous here. The loader is one of the more > machine dependant parts of any system. Assuming you mean the linker, that's not true at all. At Interactive Systems, we came up with a common object format for all of the byte- addressable machines we were working on and a single linker that could link for any of them. PC/IX and VM/IX really use the same linker, and (except for bugs and perhaps old versions) either linker can link code for either machine. Also, there is a single version of nm, strip, and so forth, which makes life much easier. It turned out to be easier than I would have thought, since there seem only to be about a dozen different kind of link-time fixups that any of the machines we know about need. A moderate number of flags, usually passed in from "cc", proved adequate to deal with the various forms of split I/D, segmented addressing and so forth. More work would be needed if we were going to move to, say, shared libraries or dynamic linking, but we thought of reasonable ways to deal with that. There is a paper on the common object format and its tools in one of the Usenix proceedings from about two years ago. John Levine, ima!johnl PS: I figured this would be really great in a system with, say, a 68000 and a 286, where each object module would automatically be run on the processor it was linked for.