From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Thread: 1164f8,1f0ed186713c1bdb X-Google-NewGroupId: yes X-Google-Thread: ffc31,1f0ed186713c1bdb X-Google-NewGroupId: yes X-Google-Attributes: gidd180ab3bd8,gidf4c4f7386e,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!fu-berlin.de!news-zh.switch.ch!kanaga.switch.ch!switch.ch!news.tele.dk!news.tele.dk!small.news.tele.dk!feed118.news.tele.dk!dotsrc.org!filter.dotsrc.org!news.dotsrc.org!not-for-mail Date: Sun, 12 Jun 2011 22:46:51 -0400 From: "Jerome H. Fine" Organization: Just Sufficient User-Agent: Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.7.2) Gecko/20040804 Netscape/7.2 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: alt.sys.pdp11,comp.sys.dec,vmsnet.pdp-11 Subject: Re: Source for RT-11 TECO V36 References: <4df2176d$0$312$14726298@news.sunsite.dk> <3ab4c070-9402-4749-8dc7-49310abd7f29@g28g2000yqa.googlegroups.com> <9da7ce8b-1acb-40a0-a232-d73935cc9ffe@x3g2000yqj.googlegroups.com> In-Reply-To: <9da7ce8b-1acb-40a0-a232-d73935cc9ffe@x3g2000yqj.googlegroups.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Message-ID: <4df579eb$0$305$14726298@news.sunsite.dk> NNTP-Posting-Host: 206.248.171.217 X-Trace: news.sunsite.dk DXC=^g^2iM9M0Z5:YiKBaBLXD=YSB=nbEKnk;jONaABCfSP=PPfk^U[HX;?N1>V8bAJTI>3eOPKWXlde4Qa4_jgFW[9?BVXLW10cf`6]01T`Rm1cH8 X-Complaints-To: staff@sunsite.dk Xref: g2news1.google.com alt.sys.pdp11:2262 comp.sys.dec:3527 vmsnet.pdp-11:640 >John Wallace wrote: >Quite possibly true in general, but when considering the particular >case of RT11 executables, as we were here, I believe matters are a bit >simpler than the general case. My recollection of RT11 executables >(not that I've checked recently, though it is documented) is that the >format is *very* very simple, which makes the comparison simpler and >potentially more meaningful. My recollection says there is an image >code/data area and a relocation bitmap and not a great deal else; I >may well have the detail wrong, but the general principle of "it's >very simple" applied to much of RT11. And what is an overlay but some >subroutines and some IO? > > In my experience, I don't really see that the mixed code and data in an RT-11 SAV file will be easier to compare than separate code (an execute ONLY area) and data (read / write ONLY) areas in a VMS environment. In fact, it might actually be easier. >Whether it's worth writing such a comparison tool is a different >question, especially when you add the possibility of disassembling the >RT11 executable using one of the various disassemblers on DECUS tapes >and the like. Disassessembling overlay calls might be "interesting". > > A disassembly is not trivial, even with an OBJ file as UnMAC is an example. The original version in DECUS could not even UnMac itself. It took a reasonable effort to enhance UnMac to do so. Of course, since the code / data was generated by FORTRAN, it looked quite different from MACRO-11 type programs. As for SAV => MAC files, the only one I have that handles an odd address .Ascii directive is the enhanced version that I have for myself. Even then, it usually takes a few passes before I sort out the code and data areas. As for disassembling overlays, I started on the code, but never finished it. Too many other interesting things to do. >[Background: I have spent far too much time at work writing and >understanding assemblers and linkers and object and executable related >things; not for PDP11 as target, but sometimes using PDP11 or VMS as >host, and/or PDP11 or VMS file formats]. > I am still working on RT-11 systems as well. Recently, I wanted to reduce the size of low memory that the editor program uses as a system job under a Mapped Monitor (RT11XM) which has multi-terminal support. Normally, I use 4 DL ports to run 4 system jobs which are the KEX editor as in: SRUN KEX.SAV/LEVEL:n/TERMINAL:n/NAME:Kn The 801 words needed for each system job was causing problems when I also used SDX.SYS to debug programs. I found that as a system job, one of the data structures in low memory was never needed. The one time initialization code in low memory was abandoned as well. The solution was to reduce the initial size of the stack, then modify the stack address after initialization to also include the now (about to be) abandoned initialization code. So I lowered the base address to 600 and linked the overlay handler into the addresses between 600 and 1000 ("/B:1000"), then changed the stack address to 1000 before I called the only overlay at virtual 20002 (well, the overlay handler called the overlay. At that point, the root section was one block less (1 instead of 2 blocks). Comparing the two SAV files required making the comparison starting at block 2 on the original SAV file and block 1 on the revised SAV file. Fortunately, I have a enhanced version of BINCOM which allows: RUN DU0:BINCOM *DU0:FOOBAR.SAV/S:1.,DU0:FOOBAR.OLD/S:2. There were only about 6 differences which pertained to the size of the root - which no longer mattered. So there is another problem when two different binary files are compared. If the start of one portion begins at a different block, the files may compare, but there must be some easy way of telling the program. DEC did this for DUP via: COPY/DEVICE VM0:/START:25./END:34. DU0:/START:155. but not BINCOM. I often do this when I want to copy a changed file over the original location. It requires being extremely careful!! Jerome Fine Jerome Fine