On 22.05.2012 16:43, Niall Douglas wrote:
> Precompiled headers on GCC are basically a dump of state just after 
> processing the headers. As a result, the file is huge. That might 
> help you find out if they're on. I believe bjam defaults them to off.
Well, in that case I'm not using them. They would've sprung into my eyes
if they're located in the default -I-paths (which I assume).

>>> 6. Can you spot where in the assembly it's making a pointer 
>>> dereferencing mistake?
>> That is in the template, but the pointer value changes inside code which
>> is compiled in the boost library.
> 
> Are you saying that the *offset* changes inside the code?
Hm, I was unclear I guess. I'm going to paste some gdb bt output:

#0  0x0000000000405af7 in
boost::python::objects::polymorphic_id_generator<Foo>::execute
(p_=0x40a268) at /usr/include/boost/python/object/inheritance.hpp:43
#1  0x00007ffff7dcb684 in boost::(anonymous namespace)::convert_type (p=
    0x666db0, src_t=..., dst_t=..., polymorphic=true)
    at
/usr/src/debug/boost_1_48_0/libs/python/src/object/inheritance.cpp:405

Here we see that to convert_type, p=0x666db0 has been passed, while
0x40a268 arrived in execute. While the first value is a valid pointer to
a Foo instance, 0x40a268 is anything but that (actually I did not find
out yet what was going on there).
However, p is just passed on to execute without modification (as far as
I can see in the code).

> BTW - can I just clarify you ARE compiling the entire of BPL using 
> C++11 throughout? Linking C++11 to C++03 is *supposed* to work (but 
> not the other way round), but I can see nests of vipers in it.
Ehm, I guess not, so I just downloaded and rebuilt boost 1.48 in the
virtual machine (no fun) with -std=c++11 flag (I added this in the
project-options.jam file at the using line; running ./b2 -d2 showed me
that the flag was passed to the gcc too). Still, the crash occurs at the
same place.

> Given the information so far, you have an excellent chance of getting 
> it fixed.
Okay, so I'm taking you suggest I submit both compilation attempts
(inheritance.cpp and crashtest.cpp) with -save-temps for comparision to
the gcc devs? Of course with all the information I gathered so far.

-- 
Jonas

_______________________________________________
Cplusplus-sig mailing list
Cplusplus-sig@python.org
http://mail.python.org/mailman/listinfo/cplusplus-sig

Reply via email to