Did some debugging with valgrind today. Discovered a few things that I fixed, but there are still a lot of issues reported that seen to come from Python. Reading some more about valgrind and Python, it seems that the two do not play nicely together. More info here:
http://svn.python.org/projects/python/trunk/Misc/README.valgrind I might look further into this when I find the time, but for now I think I'll concentrate on other things. Might be that some of the issues are actually caused by SWIG. Stuff like this, for example: ==3000== 280 bytes in 1 blocks are possibly lost in loss record 538 of 760 ==3000== at 0x4C2B6CD: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) ==3000== by 0x74E8578: _PyObject_GC_Malloc (in /usr/lib/libpython2.7.so.1.0) ==3000== by 0x74E9BEC: _PyObject_GC_New (in /usr/lib/libpython2.7.so.1.0) ==3000== by 0x74A9043: PyDict_New (in /usr/lib/libpython2.7.so.1.0) ==3000== by 0x7F32F84: SWIG_Python_NewShadowInstance (py_runtime.cc:2462) ==3000== by 0x7F331C3: SWIG_Python_NewPointerObj (py_runtime.cc:2599) ==3000== by 0x7F33CE4: cxx_to_py (py_runtime.cc:3192) ==3000== by 0x632B4D6: rpg::faction::create_instance(std::string const&, _object*) (python.h:156) ==3000== by 0x632C175: rpg::faction::get_state(base::flat&) (faction.cc:202) ==3000== by 0x632C60C: rpg::faction::load() (faction.cc:128) ==3000== by 0x5F03536: base::savegame::load(int const&) (callback.h:174) ==3000== by 0x40348E: world_test::main() (worldtest.cc:148) Perhaps there's some SWIG cleanup code that we do need to trigger. So perhaps there's the chance to improve things even more without having to compile your own Python :-). Kai _______________________________________________ Adonthell-devel mailing list Adonthell-devel@nongnu.org https://lists.nongnu.org/mailman/listinfo/adonthell-devel