2011/6/7 JÄdrzej Dudkiewicz : > > Well, that's the first thing I did, but I just can't figure out what > is happening - I compiled with -O (as without optimization everything > "works") so source code isn't exactly the same as binary code, and > many variables are inlined, so I can't print their values. > Additionally - program core dumps in libstdc++, in locale's operator= > - that's not really deep, but I'm not completely aware of situation, > which makes things even harder. Also, same code works fine when > compiled on Linux, HPUX, MacOSX and SunOS with different versions of > gcc. Valgrind under Linux and MacOSX says nothing at all - so my guess > is that there's something "odd" about AIX. I was hoping for some > pointers, like "check this" or "link against that" or "define A". Build gcc with --enable-libstdcxx-debug so you get a version of libstdc++.so built with debugging symbols and can step into the locale's assignment operator.