Re: Why do we still assemble?

preston@noel.cs.rice.edu (Preston Briggs)
Thu, 7 Apr 1994 15:11:34 GMT

          From comp.compilers

Related articles
Why do we still assemble? jimcamel@rogers.com (Jim Camelford) (2006-10-20)
Re: Why do we still assemble? idknow@gmail.com (idknow@gmail.com) (2006-10-21)
Why do we still assemble? hbaker@netcom.com (1994-04-06)
Re: Why do we still assemble? djohnson@arnold.ucsd.edu (1994-04-07)
Re: Why do we still assemble? jpab+@andrew.cmu.edu (Josh N. Pritikin) (1994-04-07)
Re: Why do we still assemble? preston@noel.cs.rice.edu (1994-04-07)
Re: Why do we still assemble? Nand.Mulchandani@Eng.Sun.COM (1994-04-07)
Re: Why do we still assemble? pardo@cs.washington.edu (1994-04-08)
Re: Why do we still assemble? pardo@cs.washington.edu (1994-04-08)
Re: Why do we still assemble? law@snake.cs.utah.edu (1994-04-08)
Re: Why do we still assemble? steve@cegelecproj.co.uk (1994-04-08)
Re: Why do we still assemble? bill@amber.csd.harris.com (1994-04-08)
[28 later articles]
| List of all articles for this month |
Newsgroups: comp.compilers
From: preston@noel.cs.rice.edu (Preston Briggs)
Keywords: assembler, design
Organization: Rice University, Houston
References: 94-04-032
Date: Thu, 7 Apr 1994 15:11:34 GMT

hbaker@netcom.com (Henry G. Baker) writes:
>Other than sheer institutional inertia, why do we continue to compile into
>assembler code, then assemble the code into relocatable binary?


Who's this "we"?


Plenty of people produce object directly. (On the other hand, several
reasearch compilers produce C :-). Sometimes they'll also have a way to
produce assembly, for people who want to see what's happened to their
code, but it'll be a side step from the main compilation path.


A recent paper describing a fast C compiler is


A New C Compiler
Ken Thompson


I'm not sure it's been published. I pulled it from an ftp archive of
material on the Plan 9 OS.


Thompson achieves speed by combining the preprocessor with the parser, by
hand-coding the back end, by building object code directly, and by using a
special (slow) loader.


It's also interesting to compare with lcc, another fast compiler


    author="Christopher W. Fraser and David R. Hanson",
    title="A Retargetable Compiler for {{\small ANSI} C}",
    year=1991,
    month=oct,
    journal="SIGPLAN Notices",
    volume=26,
    number=10,
    pages="29--43"


Fraser and Hanson don't include a preprocessor, use a hand written scanner
and parser and a machine-generated back end. On the other hand, I can't
tell from the paper if they generate object directly. I suspect not.
Why? Portability, probably.


Preston Briggs
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.