[M3devel] Linux/ARM? Android?

Jay K jay.krell at cornell.edu
Mon Jun 21 00:40:54 CEST 2010


If you generate C, you get one very portable distribution format -- a bunch of C in .tar.gz.
Far more portable than what we have today.
You get possibly better optimization.
Possibly better debugging.
A much smaller source tree -- no need for m3cc or m3gdb.
You highly likely get more efficient portable exception handling -- generate C++.
  (On Win32, C suffices. Similarly on OSF/1 and VMS I believe.)
Granted, C++ with exception handling is less portable than C -- there could still be an option to use setjmp/longjmp.
I imagine it'd be wrapped up in some #defines.
Consider all the platforms that aren't well supported by gcc or LLVM.


You might get slower compilation, granted.


You could also use this as a hybrid approach. Consider that we already have two sort of backends.
This would be a third.
Anyone want Alpha, ARM, MIPS, IA64 etc. -- already done, or at least signficantly.


Consider how much work it takes to port "Hello world". None.
This would drive us toward that.
With some benefits and maybe some drawbacks.


 - Jay

----------------------------------------
> From: dragisha at m3w.org
> To: jay.krell at cornell.edu
> Date: Sun, 20 Jun 2010 22:38:26 +0200
> CC: m3devel at elegosoft.com
> Subject: Re: [M3devel] Linux/ARM? Android?
>
> It's cheaper to support platforms through m3gc (meaning gcc) than
> through C. Going native so as to get "broader base than gcc"? Do we
> really have that wide userbase? Not to mention developer base...
>
> And why're you looking retro to C? Why not invest yourself on LLVM? JIT
> comes to mind....
>
> On Sun, 2010-06-20 at 19:43 +0000, Jay K wrote:
>> True, that m3cg is "most" buildable by gcc itself. That gets the most
>> testing by gcc developers.
>> Almost any version will do though.
>> But it is buildable by other C compilers, such as Sun cc and OSF/1's C
>> compiler.
>> Going forward, like to gcc 4.6, a C++ compiler might be needed.
>> OpenBSD uses gcc 3.x on most platforms and 2.x on some older ones.
>> gcc 4.4 and 4.5 actually require a C9x compiler but that is an
>> accidental regression and getting fixed.
>> I found it using OSF/1 cc on Mika's machine. :)
> --
> Dragiša Durić 
>
 		 	   		  


More information about the M3devel mailing list