Login  Register

Re: COG VM and Locale

Posted by Igor Stasenko on Mar 04, 2011; 10:19am
URL: https://forum.world.st/COG-VM-and-Locale-tp3331775p3334981.html

On 3 March 2011 21:43, Eliot Miranda <[hidden email]> wrote:

>
>
> On Thu, Mar 3, 2011 at 12:31 PM, Hilaire Fernandes
> <[hidden email]> wrote:
>>
>> Le 03/03/2011 20:57, Hilaire Fernandes a écrit :
>> > Le 02/03/2011 18:23, Eliot Miranda a écrit :
>> >> /branches/Cog/unixbuild/HowToBuild
>> >> <http://www.squeakvm.org/svn/squeak/branches/Cog/unixbuild/HowToBuild>.
>> >>  If it loads, put a breakpoint in initialiseModule and step through it.
>>
>> Okay, strangely setting a break point to initialiseModule, put it on
>> SurfacePlugin
>>
>> (gdb) break initialiseModule
>> Breakpoint 1 at 0x811acc8: file
>>
>> /home/hilaire/Travaux/pharo/temp/COG/platforms/Cross/plugins/SurfacePlugin/SurfacePlugin.c,
>> line 204.
>>
>>
>> I have to start the VM then quit, then adding again a break point on
>> initialiseModule set it to locale:
>>
>> Program exited normally.
>> (gdb) break initialiseModule
>> Breakpoint 5 at 0x559542: file
>>
>> /home/hilaire/Travaux/pharo/temp/COG/src/plugins/LocalePlugin/LocalePlugin.c,
>> line 112.
>>
>>
>> step throught the function is:
>>
>> (gdb) r
>> Starting program:
>> /home/hilaire/Travaux/pharo/temp/COG/target/lib/squeak/3.9-7/squeak
>> drgeo.image
>> [Thread debugging using libthread_db enabled]
>> [New Thread 0x77f88b70 (LWP 27787)]
>>
>> Breakpoint 5, initialiseModule () at
>>
>> /home/hilaire/Travaux/pharo/temp/COG/src/plugins/LocalePlugin/LocalePlugin.c:112
>> 112             return sqLocInitialize();
>> (gdb) s
>> heartbeat_handler (sig=14, sig_info=0x33, context=0x0) at
>>
>> /home/hilaire/Travaux/pharo/temp/COG/platforms/unix/vm/sqUnixHeartbeat.c:475
>> 475     {
>> (gdb) s
>> 476             if
>> (!ioOSThreadsEqual(ioCurrentOSThread(),getVMOSThread())) {
>> (gdb) s
>>
>> Program received signal SIGTRAP, Trace/breakpoint trap.
>> 0x0013cdc6 in pthread_self () from /lib/tls/i686/cmov/libpthread.so.0
>
> You'll need to state
> (gdb) handle SIGALRM nostop noprint noignore
> first.  In fact, do that for most signals.  What's happening below is gdb
> stopping on delivery of the 1KHz heartbeat, so you won't get far without
> ignoring it.
>

yeah.. i also were stuck with this cruelty before.. trying to step
instruction-wise
and was always interfered by heartbeat thread :)

>>
>> Hilaire
>>
>>
>> --
>> Education 0.2 -- http://blog.ofset.org/hilaire
>>
>>
>
>



--
Best regards,
Igor Stasenko AKA sig.