This issue has stayed with us for gcc releases 6.1.1, 6.2.0, 6.3.0, and
7.1.0 .. so I built with BUILD_TYPE=RELWITHDEBINFO and saw that self was
NULL in stack frame #0 (MemorySegmentPool::newSegment), because in stack
frame 1, currentPool was NULL.
I then single-stepped through stack frame #3 (RexxMemory::initialize),
where currentPool is supposed to be set:

(gdb) break MemoryObject::initialize
Breakpoint 1 at 0x7ffff7ab6a60 (2 locations)
(gdb) run
Breakpoint 1, 0x00007ffff7ab6a60 in MemoryObject::initialize(bool)@plt ()
(gdb) step
Single stepping until exit from function _ZN12MemoryObject10initializeEb@plt
,
which has no line number information.
Breakpoint 1, MemoryObject::initialize (this=0x7ffff7dd4260 <memoryObject>,
    restoringImage=false)
    at
/home/erichst/oorexxsvn/main/trunk/interpreter/memory/RexxMemory.cpp:145
145     {
(gdb) step
153         new (this) MemoryObject;
(gdb)

I noticed that the two statements between 145 and 153 ..

    firstPool = MemorySegmentPool::createPool();
    // our first pool is the current one
    currentPool = firstPool;

.. had been completely optimized out. These two statements seem special, as
they are assigning object attributes, before the new constructor is run in
line 153.

I've submitted a fix with revision [r11289
<https://sourceforge.net/p/oorexx/code-0/11289/>]
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Oorexx-devel mailing list
Oorexx-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

Reply via email to