Devon H. O'Dell wrote:
> Another student I spoke to on IRC spoke of the possibility of
> bootstrapping LLVM for Plan 9 on Linux and getting it to run natively.
> That would give us a whole bunch of different compilers.

Something to watch out for with such a project:

The LLVM back-end for Windows does not support C++ (nicely) because of
issues with exception handling; Windows provides a mechanism for stack
unwinding—especially across DLL boundaries—that neither GCC nor LLVM
handle well.  Porting LLVM to Plan 9 may well have some of the same
troubles.

Those who have dealt with the GCC port can answer this:  What does g++
do on Plan 9?  Does it add DWARF debugging tables to the executable so
that the stack can be unwound?  Does it play games with setjmp/longjmp? 
Does it even work at all?  Otherwise, a large part of an LLVM project
would be a port of some exception mechanism.

Does plan9port’s mach-stack(3) have any precedent in Plan 9? and is that
the correct basis for exception-like stack unwinding?  (I.e., a program
unwinding its own stack, rather than a debugger tracing the stack back.)

—Joel Salomon

P.s.:  I am not raising the question of whether exception handling via
stack unwinding is a good idea—which has been done to death on this
list; see the “Same Functions Everywhere” thread from 2003 at
<http://preview.tinyurl.com/cou63b> and message 56 & responses at
<http://preview.tinyurl.com/cun6vg>—just asking how to implement it
under Plan 9 using the existing tools as far as possible.

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to