OK - wasn't kenc ported to Linux for bootstrapping the early
Go compilers? Is that version general, or not worth my trying to use?

Thanks,

Arnold

Charles Forsyth <charles.fors...@gmail.com> wrote:

> >
> > I doubt very much that using the Plan 9 C compilers will bring much
> > additional benefit for finding bugs (except bugs in the compiler!).
>
>
> The cross-file type-checking does sometimes pick up unpleasantness caused
> by type mismatches.
> It was originally added to allow dynamically-loaded object modules to be
> checked against the loading specification.
> It has found a few problems elsewhere, including one in Python where one .c
> file included a .h with a certain #define
> in scope that another .c file didn't define by accident, causing the two .c
> files to have completely different memory layouts
> for a structure.
>
>
> > Out of curiousity, why is linking against the system libraries so
> > hard?  I assume a port of kenc to Linux would have a driver program
> > that would just invoke the system ld(1).  I'd think that getting
> > the ABI and generation of ELF (or of standard Linux assembly language)
> > correct would be the hard part.
> > What am I missing?
> 
> 
> It works very differently from what you expect
> http://9p.io/sys/doc/compiler.html  <http://9p.io/sys/doc/compiler.html>:
> 
> The compiler is a single program that produces an object file. Combined in
> the compiler are the traditional roles of preprocessor, lexical analyzer,
> parser, code generator, local optimizer, and first half of the assembler.
> The object files are binary forms of assembly language, similar to what
> might be passed between the first and second passes of an assembler.
> 
> Object files and libraries are combined by a loader program to produce the
> executable binary. The loader combines the roles of second half of the
> assembler, global optimizer, and loader.

------------------------------------------
9fans: 9fans
Permalink: 
https://9fans.topicbox.com/groups/9fans/T4d77cc95ab4ed70c-M6a254c61dea5a9cdc6797bc2
Delivery options: https://9fans.topicbox.com/groups/9fans/subscription

Reply via email to