[Mono-list] Re: LCC and CIL

Robert Deviasse rdeviasse@hotmail.com
Mon, 11 Mar 2002 14:08:49 -0500


> > Note that LCC is not "open source software" in the sense defined by
> > www.opensource.org; selling derivative works is not permitted, in 
>general,
> > without buying a separate license from Addison-Wesley.
>
>Yes, we did notice that.  It is unfortunate as you point out.  The idea of 
>this is just an exercise in writing a CIL back-end for LCC as a proof of 
>concept.  And then you could also do neat
>things with it.
>

If that's all you're looking for, why not look into other open source
C compilers.

If you want a quick and dirty subset of C that has good embedded support
the Small C compiler is pretty good.
	http://sdcc.sourceforge.net/
Admittedly, it's a C subset, but it's extremely well documented

Alternately, there's EiC:
	http://www.kd-dev.com/~eic/
It's described as "The embeddable/extensible interactive, pointer-safe,
bytecode C interpreter/compiler."

I know, it's an interpreter, *however*, it may be possible to change the
bytecode so that it matches the CLR's. If that's possible, you'd get a
compiler and the framework for an interpreter for free. No work would be 
lost if a GCC implementation were made later.

>The long term solution would be to do this with gcc, but this is a
>smaller, easier compiler to understand.
>

One more alternative, if you're not concerned about managed extensions,
you could also look at a translator of GCC assembly language for a
simple CPU architecture (e.g. 8086) to CIL. Or take the approach used
in:
	http://www.cminusminus.org/

I'm not sure if any of these are what you're looking for, but please
take a peek before doing any serious work.

Take care,
	Robert


_________________________________________________________________
Join the world’s largest e-mail service with MSN Hotmail. 
http://www.hotmail.com