[Vm-dev] [CRAZY IDEA] "Breakpoints" in the VM from SLANG

Mariano Martinez Peck marianopeck at gmail.com
Tue Apr 12 15:46:04 UTC 2011


On Tue, Apr 12, 2011 at 1:42 PM, Igor Stasenko <siguctua at gmail.com> wrote:

>
> well, you can use
> self flag: #abdede
>
> and then find this in source code and put break there.
>

yes, true, that works :)


>
> On 12 April 2011 13:40, Mariano Martinez Peck <marianopeck at gmail.com>
> wrote:
> >
> > Probably not crazy but stupid or impossible to achieve...but anyway, I
> want to ask..
> >
> > Scenario: I find myself navigating the VMMaker code (SLANG) and I want to
> put a "self halt" somewhere there. Forget the simulator for the moment.
> So...I need to go to C, and "translate in my mind" what that part of SLANG
> should look like in C, and search it in the C code. XCode is FAAAR to slow
> to browe the interp.c . Morever, with inlined methods it is even more
> difficult to find...
> >
> > Anyway, I was thinking how cool could be to create breakpoints from
> VMMaker. I think it is not possible to put breakpoints in C code, but what
> about doing something like:
> >
> > Interpreter >> haltVM
> > "find a better name for this method"
> > self cCode: 'raise(SIGINT); '
> >
> > Of course, we need to add a
> > #include <csignal> // or signal.h if C code
> >
> > I have NO IDEA the implicance or side effects of doing this. I haven't
> tried either.
> >
> > And it is complicated to do it cross platform..etc. Here is a link to do
> more or less this idea:
> http://stackoverflow.com/questions/4326414/set-breakpoint-in-c-or-c-code-programmatically-for-gdb-on-linux
> >
> > What I want is that if we are running with GDB and the VM calls haltVM()
> then the GDB is paused so that I can do bt, etc...
> >
> > What do you think?
> >
> > --
> > Mariano
> > http://marianopeck.wordpress.com
> >
> >
> >
>
>
>
> --
> Best regards,
> Igor Stasenko AKA sig.
>



-- 
Mariano
http://marianopeck.wordpress.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20110412/c6cb9c8c/attachment.htm


More information about the Vm-dev mailing list