Path: utzoo!mnetor!uunet!husc6!cca!mirror!ima!johnl From: rcodi@yabbie.rmit.oz.au (Ian Donaldson) Newsgroups: comp.compilers Subject: Re: Assemblers can be fast Message-ID: <833@ima.ISC.COM> Date: 4 Jan 88 23:54:17 GMT References: <813@ima.ISC.COM> Sender: johnl@ima.ISC.COM Reply-To: rcodi@yabbie.rmit.oz.au (Ian Donaldson) Organization: RMIT Comm & Elec Eng, Melbourne, Australia. Lines: 27 Approved: compilers@ima.UUCP in article <813@ima.ISC.COM>, says: > Real computers aren't limited to 640K :-). And if anybody wrote a 640K > assembly language program all in one file, and really expected my > assembler to assemble the darn thing, I'd have to say that they got > what they deserved :-). There's always a limit, somewhere -- if it ... Compilers that emit assembly language -often- create megabyte sized files for the assembler. > But, seriously... one-pass assembling isn't extremely difficult. What > you do is, on the first pass, emit object code with "fillers" for > expressions you couldn't evaluate, and in memory, you keep a symbol > ... This is easy if you don't have to worry about instructions that change their size depending on the expresison value (eg long, short and medium branch instructions). Many assemblers spend time optimizing such branches, and this generally requires an extra pass to do it properly. The gains of optimizing such branches are really worthwhile. Ian D -- Send compilers articles to ima!compilers or, in a pinch, to Levine@YALE.EDU Plausible paths are { ihnp4 | decvax | cbosgd | harvard | yale | bbn}!ima Please send responses to the originator of the message -- I cannot forward mail accidentally sent back to compilers. Meta-mail to ima!compilers-request