[Vm-dev] debugging the garbage collector

Eliot Miranda eliot.miranda at gmail.com
Fri Feb 15 23:13:29 UTC 2013


OK, so I want to poll the VM implementors/maintainers on this.

On Fri, Feb 15, 2013 at 9:02 AM, Noah Evans <noah.evans at gmail.com> wrote:
>
> I've gotten all the necessary files in the VM compiling however in the
> link phase I am running into problems because different functions have
> different signatures in different files (Plan 9 does not do dynamic
> linking).
>
> For example tenuringIncrementalGC has the following definition in
> sqVirtualMachine.c
>
> platforms/Cross/vm/sqVirtualMachine.c:80: sqInt tenuringIncrementalGC(void);
>
> and the following in cointerp.c
>
> src/vm/cointerp.c:1150: void tenuringIncrementalGC(void);
>
> Would anyone object if I tried to regularize the function signatures
> between files?

Hang on.  The issue is which way?  The signature in cointerp.c is
correct in the sense that tenuringIncrementalGC doesn't return a
result.  The signature in platforms/Cross/vm/sqVirtualMachine.h is the
canonical one that has been the standard API for plugins since the
beginning of the VM.

So should we keep the backward-compatible, but incorrect signatures,
and hack the VMMaker source to comply with them, or change the
signatures and risk breaking plugin and support code?

>
> Noah
>
>
> On Fri, Feb 15, 2013 at 4:50 PM, Noah Evans <noah.evans at gmail.com> wrote:
>> Aaaah... I see. Any documentation on the differences between the two
>> or I should I just factor out the functions that differ between the
>> two when the time comes?
>>
>> Noah
>>
>>
>> On Fri, Feb 15, 2013 at 4:49 PM, Bert Freudenberg <bert at freudenbergs.de> wrote:
>>>
>>>
>>> On 2013-02-15, at 16:42, Noah Evans <noah.evans at gmail.com> wrote:
>>>
>>>>
>>>> My goal is to have general squeak support, I started with Spoon but
>>>> I'd like it to work across VMs. As I understand it the svn tree is
>>>> canonical, which makes it a good place to start.
>>>>
>>>> Noah
>>>
>>> It is, but you need to be aware that we have two different VMs: the interpreter (http://squeakvm.org/svn/squeak/trunk/) and Cog (http://squeakvm.org/svn/squeak/branches/Cog/). And the Spoon VM is based on the interpreter.
>>>
>>> - Bert -
>>>
>>>> On Fri, Feb 15, 2013 at 4:34 PM, David T. Lewis <lewis at mail.msen.com> wrote:
>>>>>
>>>>> On Fri, Feb 15, 2013 at 02:52:45PM +0100, Noah Evans wrote:
>>>>>>
>>>>>> I've taken bert's advice and gotten the canonical svn tree. For the
>>>>>> moment I've gone away from VMMaker sources and started with the svn
>>>>>> tree's cointerp.c. Once I have that working (most of it already
>>>>>> compiles, I just need to decide what to do with alloca--it's
>>>>>> unimplemented in Plan9 posix emulation) I'll go back and work with
>>>>>> Spoon. I'm just trying to minimize the number of variables for the
>>>>>> moment. The svn tree has been really great in this regard.
>>>>>>
>>>>>> Can anyone point me to a contributing page for how to submit patches?
>>>>>> Or just to the mailing list proper?
>>>>>>
>>>>>> Noah
>>>>>
>>>>> The mailing list for sure. And depending on which branch you end up
>>>>> working with, maybe some other procedures. But definitely post to this
>>>>> list :)
>>>>>
>>>>> I still worry that Craig seems to be saying that he is working with sources
>>>>> from trunk, and you seem to be saying that you are working with sources
>>>>> from the Cog branch. Assuming your goal is to get a VM for running Spoon,
>>>>> you should make sure that you're on the same page with Craig, otherwise
>>>>> you're going to be in for a lot of extra work.
>>>>>
>>>>> Dave
>>>>>
>>>>>>
>>>>>>
>>>>>> On Fri, Feb 15, 2013 at 2:47 PM, David T. Lewis <lewis at mail.msen.com> wrote:
>>>>>>>
>>>>>>> On Fri, Feb 15, 2013 at 01:14:17PM +0100, Bert Freudenberg wrote:
>>>>>>>>
>>>>>>>> On 2013-02-15, at 11:27, Noah Evans <noah.evans at gmail.com> wrote:
>>>>>>>>
>>>>>>>>> Craig, which version of Cog are you using? I'm using the tip of the
>>>>>>>>> gitorious tree.
>>>>>>>>
>>>>>>>> Eliot's canonical sources are in subversion:
>>>>>>>>
>>>>>>>> http://squeakvm.org/svn/squeak/branches/Cog/
>>>>>>>>
>>>>>>>
>>>>>>> Oh dear, I suspect we may have some confusion here. Craig says:
>>>>>>>
>>>>>>>
>>>>>>>>     The current release of Spoon is 3 beta 3 (23 October 2012),
>>>>>>>> available at:
>>>>>>>>
>>>>>>>>     http://netjam.org/spoon/releases/current
>>>>>>>>
>>>>>>>>     It includes a Squeak 4.2 object memory (4 February 2011) with
>>>>>>>> VMMaker dtl.237 (23 May 2011) installed, and the Spoon VM changes
>>>>>>>> applied to that, and with remote browsing support installed. It runs on
>>>>>>>> the VM it generates, which is the only one supplied in the release (Mac
>>>>>>>> OS, Linux and win32).
>>>>>>>
>>>>>>> Noah, what platform sources did you start with? The VM that Craig
>>>>>>> describes would have been compiled with platform sources from the
>>>>>>> trunk VM (not branches/Cog). Those sources are at:
>>>>>>>
>>>>>>>  http://squeakvm.org/svn/squeak/trunk
>>>>>>>
>>>>>>> You would need to use a version of those sources from the early 2011
>>>>>>> time frame. But I would suggest very stongly that you get an exact
>>>>>>> copy of sources from Craig so that you are starting from exactly the
>>>>>>> same code base that he is using (or maybe that's what you meant in your
>>>>>>> question to Craig the about gitorious tree).
>>>>>>>
>>>>>>> Mixing generated source code from VMMaker trunk (e.g. VMMaker-dtl.237)
>>>>>>> with platform sources from branches/Cog will definitely not work.
>>>>>>> And mixing generated sources (from VMMaker) with platform sources
>>>>>>> (from Subversion) that are not from the same general time frame will
>>>>>>> probably not work.
>>>>>>>
>>>>>>> Dave
>>>>>>>
>>>



-- 
best,
Eliot


More information about the Vm-dev mailing list