<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'><div> I disagree. </div><div> The system is working. This isn't speculation.</div><div><br></div><div> </div><div> Using his terminology </div><div><br></div><div> </div><div> C pros: </div><div> - written language (also a con) </div><div> - longevity </div><div> - does not drive me nuts </div><div> - design is very mature </div><div> - looks easy and is easy </div><div> - huge portability of implementation </div><div> - potential portability of object code </div><div> - debugability with stock debuggers </div><div> - large development teams ("back back end")</div><div> - multiple industrial strength "back back ends" </div><div> - likely similar compiled performance as anything else </div><div> - probably similar compiled performance </div><div><br></div><div><br></div><div> C cons: </div><div> - compiler performance </div><div> - debuggability on platforms that have m3gdb support </div><div> - cannot always efficiently express things portably, </div><div> in particular, portable C has the same inefficient exception </div><div> handling; we need to switch to C++ to fix it, or non-portable C </div><div> on some platforms (i.e. win32 __try) </div><div> </div><div><br></div><div> For garbage collection, I believe C, m3cc, and llvm are currently all</div><div> equivalent and not good. </div><div><br></div><div> </div><div> - Jay</div><br><br><br><br><div><hr id="stopSpelling">From: dmuysers@hotmail.com<br>To: jay.krell@cornell.edu; m3devel@elegosoft.com<br>Subject: Re: [M3devel] switching to C backend?<br>Date: Sat, 18 Jul 2015 10:42:14 +0200<br><br>
<style><!--
.ExternalClass .ecxhmmessage P {
padding:0px;
}
.ExternalClass body.ecxhmmessage {
font-size:12pt;
font-family:Calibri;
}
--></style>
<div dir="ltr">
<div style="FONT-SIZE:12pt;FONT-FAMILY:'Arial';COLOR:#000000;">
<div class="ecxpost-text">
<font face="Times New Roman">May I remind you Norman Ramsey’s opinion on the
subject:</font><BR>
<font face="Times New Roman"></font> <BR>
<font face="Times New Roman">Code generation is my business :-)</font><BR>
<font face="Times New Roman">Comments on a few options:</font><BR>
<ul>
<li>
<font face="Times New Roman">CLR: </font><BR>
<ul>
<li><font face="Times New Roman">Pro: industrial support</font>
</li><li><font face="Times New Roman">Con: you have to buy into their type system
pretty much completely; depending on what you want to do with types, this
may not matter</font>
</li><li><font face="Times New Roman">Con: Only Windows platform is really
prime-time quality</font></li></ul>
</li><li>
<font face="Times New Roman">LLVM:</font><BR>
<ul>
<li><font face="Times New Roman">Pro: enthusiastic user community with
charismatic leader</font>
</li><li><font face="Times New Roman">Pro: many interesting performance
improvements</font>
</li><li><font face="Times New Roman">Con: somewhat complex interface</font>
</li><li><font face="Times New Roman">Con: history of holes in the engineering;
as LLVM matures expect the holes in the engineering to be plugged by adding
to the complexity of the interface</font></li></ul>
</li><li>
<a style="" target="_blank"><font face="Times New Roman">C--</font></a><BR>
<ul>
<li><font face="Times New Roman">Pro: target is an actual written language,
not an API; you can easily inspect, debug, and edit your C-- code</font>
</li><li><font face="Times New Roman">Pro: design is reasonably mature and
reasonably clean</font>
</li><li><font face="Times New Roman">Pro: supports accurate garbage
collection</font>
</li><li><font face="Times New Roman">Pro: most users report it is very easy to
use</font>
</li><li><font face="Times New Roman">Con: very small development team</font>
</li><li><font face="Times New Roman">Con: as of early 2009, supports only three
hardware platforms (x86, PPC, ARM)</font>
</li><li><font face="Times New Roman">Con: does not ship with a garbage
collector</font>
</li><li><font face="Times New Roman">Con: future of project is
uncertain</font></li></ul>
</li><li>
<font face="Times New Roman">C as target language</font><BR>
<ul>
<li><font face="Times New Roman">Pro: looks easy</font>
</li><li><font face="Times New Roman">Con: nearly impossible to get decent
performance</font>
</li><li><font face="Times New Roman">Con: will drive you nuts in the long run;
ask the long line of people who have tried to compile Haskell, ML, Modula-3,
Scheme and more using this technique. At some point every one of these
people gave up and built their own native code
generator.</font></li></ul></li></ul>
<font face="Times New Roman">Summary: <strong>anything except C</strong> is a
reasonable choice. For the best combination of flexibility, quality, and
expected longevity, I'd probably recommend LLVM. But your example code is very
close to C--, so that may be an advantage.</font><BR>
<font face="Times New Roman">Full disclosure: I am affiliated with the C--
project.</font><BR></div>
<div style="FONT-SIZE:small;TEXT-DECORATION:none;FONT-FAMILY:"Calibri";FONT-WEIGHT:normal;COLOR:#000000;FONT-STYLE:normal;DISPLAY:inline;">
<div style="FONT:10pt tahoma;">
<div> </div>
<div style="BACKGROUND:#f5f5f5;">
<div style=""><b>From:</b> <a title="jay.krell@cornell.edu" href="mailto:jay.krell@cornell.edu">Jay K</a> </div>
<div><b>Sent:</b> Saturday, July 18, 2015 10:27 AM</div>
<div><b>To:</b> <a title="m3devel@elegosoft.com" href="mailto:m3devel@elegosoft.com">m3devel</a> </div>
<div><b>Subject:</b> [M3devel] switching to C backend?</div></div></div>
<div> </div></div>
<div style="FONT-SIZE:small;TEXT-DECORATION:none;FONT-FAMILY:"Calibri";FONT-WEIGHT:normal;COLOR:#000000;FONT-STYLE:normal;DISPLAY:inline;">
<div dir="ltr">Any objection if I start switching targets to the C backend?
<div> </div>
<div>In par<span style="FONT-SIZE:12pt;">ticular, Darwin does not support m3gdb,
so debuggability is not a factor.</span></div>
<div> </div>
<div>Thanks,</div>
<div>- Jay<br><br></div><br><br></div>
<BR><hr>
_______________________________________________<br>M3devel mailing
list<br>M3devel@elegosoft.com<br>https://mail.elegosoft.com/cgi-bin/mailman/listinfo/m3devel<br></div></div></div></div> </div></body>
</html>