<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'><font face="Calibri" size="3">I'm moving ahead..will change PPC_DARWIN on my system to generate C.</font><div style="font-family: Calibri; font-size: 12pt; ">My system is 64bit capable MacBook.</div><div style="font-family: Calibri; font-size: 12pt; ">It can run PowerPC (I'm not upgrading the OS to one that omits Rosetta!)</div><div style="font-family: Calibri; font-size: 12pt; ">PowerPC emulation isn't adequate for our preemptive suspend, but ok.</div><div style="font-family: Calibri; font-size: 12pt; "><br></div><div style="font-family: Calibri; font-size: 12pt; "><br></div><div style="font-family: Calibri; font-size: 12pt; ">I suspect PPC_DARWIN is little used enough, that when I'm satisfied that it works,</div><div style="font-family: Calibri; font-size: 12pt; ">I can commit it and nobody will complain.</div><div style="font-family: Calibri; font-size: 12pt; "><br></div><div style="font-family: Calibri; font-size: 12pt; "><br></div><div style="font-family: Calibri; font-size: 12pt; "><br>So then..</div><div style="font-family: Calibri; font-size: 12pt; "><br></div><div style="font-family: Calibri; font-size: 12pt; "><br></div><div><div><font face="Calibri"> M3BackendMode_t =</font></div><div><font face="Calibri"> {</font></div><div><font face="Calibri"> (* The primary modes are currently 0 and 3. *)</font></div><div><font face="Calibri"> IntegratedObject, (* "0" -- don't call m3_backend, M3CG produces object code *)</font></div><div><font face="Calibri"> IntegratedAssembly, (* "1" -- don't call m3_backend, M3CG produces assembly code *)</font></div><div><font face="Calibri"> ExternalObject, (* "2" -- call m3_backend, it produces object code *)</font></div><div><font face="Calibri"> ExternalAssembly (* "3" -- call m3_backend, it produces assembly code *)</font></div><div><font face="Calibri"> };</font></div><div><br></div></div><div><br></div><div>ExternalObject can be made to work w/o changing cm3.</div><div>I would build a separate driver like-m3cgcat.</div><div>I would change the config/quake m3_backend to call it.</div><div>Heck, ExternalAssembly could be made to work. (on Posix. maybe on NT, but pointless) </div><div><br></div><div><br></div><div>But that's not really the right way.</div><div>I should add a new mode called IntegratedC.</div><div>Agreed?</div><div>Or just C.</div><div>ExternalC would be kind of dumb..it'd be to use like-m3cgcat from m3_backend, and then </div><div>in cm3 we'd call compile_c(). You might as well have m3_backend call compile_c and</div><div>call it IntegratedObject.</div><div><br></div><div><br></div><div>Agreed? New mode called "C"?</div><div><br></div><div><br></div><div>Think ahead.</div><div>I want to generate C++, for portable/efficient exception handling.</div><div>But not yet.</div><div><br></div><div><br></div><div>Would that be yet another mode?</div><div><br></div><div><br></div><div>If I don't change cm3 and add a mode, I'm "stuck" writing out the .mc files, reading them back, running a little driver. There is some developer convenience there, but it is needlessly inefficient when things are working.</div><div><br></div><div><br></div><div>I guess I might have a chance with <span style="font-family: Calibri; ">IntegratedObject.</span></div><div><span style="font-family: Calibri; ">M3C.m3 would call out to quake.</span></div><div><br></div><div><br></div><div><font face="Calibri">Think ahead..I need a cross/boot story.</font></div><div><font face="Calibri">That writes out the .c files and stops.</font></div><div><font face="Calibri">Ok..shouldn't be difficult..</font></div><div><font face="Calibri">Seems kind of better therefore to add a mode, so the cm3 knows about this but M3C does not.</font></div><div><font face="Calibri">Having the backend call out to quake is a bit odd. But the way we configure and detect the C compiler is too much quake code to abandon. I don't want to bake that into M3C.m3.</font></div><div><font face="Calibri"><br></font></div><div><font face="Calibri"><br></font></div><div><font face="Calibri"><br></font></div><div><font face="Calibri">Thoughts?</font></div><div><font face="Calibri"><br></font></div><div><span style="font-family: Calibri; "><br></span></div><div><span style="font-family: Calibri; ">Thanks,</span></div><div> - Jay</div><div><br></div> </div></body>
</html>