<br><br><div class="gmail_quote">On Thu, Jul 21, 2011 at 3:43 PM, Igor Stasenko <span dir="ltr"><<a href="mailto:siguctua@gmail.com">siguctua@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im"><br>
On 22 July 2011 01:33, Eliot Miranda <<a href="mailto:eliot.miranda@gmail.com">eliot.miranda@gmail.com</a>> wrote:<br>
><br>
><br>
><br>
> On Thu, Jul 21, 2011 at 3:29 PM, Igor Stasenko <<a href="mailto:siguctua@gmail.com">siguctua@gmail.com</a>> wrote:<br>
>><br>
>> On 22 July 2011 02:04, <<a href="mailto:squeak-dev-noreply@lists.squeakfoundation.org">squeak-dev-noreply@lists.squeakfoundation.org</a>> wrote:<br>
>> ><br>
>> > Eliot Miranda uploaded a new version of VMMaker to project VM Maker:<br>
>> > <a href="http://www.squeaksource.com/VMMaker/VMMaker.oscog-eem.108.mcz" target="_blank">http://www.squeaksource.com/VMMaker/VMMaker.oscog-eem.108.mcz</a><br>
>> ><br>
>> > ==================== Summary ====================<br>
>> ><br>
>> > Name: VMMaker.oscog-eem.108<br>
>> > Author: eem<br>
>> > Time: 21 July 2011, 1:45:28 am<br>
>> > UUID: 06af30e4-7c67-4259-88dc-8ee2a10499c4<br>
>> > Ancestors: VMMaker.oscog-eem.107<br>
>> ><br>
>> > Nuke ReentrantFFIPlugin in favour of ThreadedFFIPlugin, using<br>
>> > cppIf: COGMTVM to select threading-specific code. This so that<br>
>> > there only needs to be one SqueakFFIPrims.c for the reentrant<br>
>> > (non-threaded) and threaded FFI plugins. This is a much easier<br>
>> > fix than somehow allowing the two files to exist side-by-side in<br>
>> > the file system.<br>
>> ><br>
>> ><br>
>><br>
>> :)<br>
>> in cmake configs we dealt with this by simply including proper plugin class.<br>
>> But indeed there's a lot of XyZFFIPlugins out there..<br>
><br>
> You may have missed the point. Both of these plugins emit a source file called src/vm/plugins/SqueakFFIPrims/SqueakFFIPrims.c sicne they are both different versions of the FFI plugin, one for a non-threaded VM, one for a threaded VM. If I were to generate both of them at the same time one would overwrite the other.<br>
<br>
</div>Exactly. That's why i making sure to include only right plugin :)<br>
<div class="im"><br>
> If I were to change the name of one of them then all the builds would be affected and have to be modified to choose a different source depending on whether COGMTVM=1 or COGMTVM=0. [Note it was difficult enough to get the builds to choose either cointerp.c cointerpmt.c gcc3x-cointerp.c or gcc3x-cointerpmt.c]. So the easiest way to be able to select these different variants is to collapse them into one class and use cppIf: to choose between non-threaded and threaded code based on COGMTVM.<br>
<br>
</div>I know. But its a pity that nice and elegant inheritance scheme has to<br>
be broken to serve pervasive needs of C :)<br></blockquote><div><br></div><div>except that inheritance only gives you one axis of change. For example I have inheritance giving me the axis from less sophisticated to more sophisticated code generator in Cogit SimpleStackBasedCogit StackToRegisterMappingCogit Sista StackToRegisterMappingCogit. But in adding Newspeak I needed another axis. Mixins and/or traits would have worked, but I'm not ready to trust the traits system, and we don't have mixins. For that reason and the file collision issue I used cppIf: :(</div>
<div><br></div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im"><br>
> HTH<br>
>><br>
>> --<br>
>> Best regards,<br>
>> Igor Stasenko AKA sig.<br>
><br>
><br>
><br>
> --<br>
> best,<br>
> Eliot<br>
><br>
><br>
<br>
<br>
<br>
</div>--<br>
<div><div></div><div class="h5">Best regards,<br>
Igor Stasenko AKA sig.<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>best,<div>Eliot</div><br>