On 2016/01/28 7:06, Philippe Waroquiers wrote: > On Thu, 2016-01-28 at 02:19 +0900, ISHIKAWA,chiaki wrote: >> c++11 runtime seems to use |new| operation to create some data in a very >> primitive internal string handling function, and these string data are >> "free"ed by many other functions that my application (mozilla >> thunderbird) use. So delete vs free issues are reported. I suspect c++11 >> ought to use "malloc()" for the internal string operation, but then >> maybe other parts of c++11 library may complain about malloc vs delete >> mismatch then :-( > Some such false positive of 'mismatched malloc/free/new/delete' > were found in the past due to one operation being inlined > (e.g. the new) but the delete not being inlined. > The matching code does not understand inlining, and so the false > positive. > > Maybe that is your case ? > (you might check this by showing the stacktrace for the allocation > and deallocation using e.g. gdb+vgdb, and see if inlining enters in > the game). > > Philippe
Thank you for the tips. I will investigate this issue further along your suggestions. I can whitelist typical noises by using suppression file, but to think the valgrind/memcheck needs to check this and notice the anomaly, check the backtrace of calls to malloc/new to report it and only then learns it is whitelisted, and moves on to the original execution: such a waste of runtime CPU (!). Actually, I think I already notice a significant slowdown due to this added mismatches. Or maybe I am hallucinating and in need of a faster CPU :-) But if the issue is the unbalanced inlining, there is a hope that I can either fix the local build environment to inline both new/delete, etc., or try contacting the library builders to fix their toolchain setup. CI ------------------------------------------------------------------------------ Site24x7 APM Insight: Get Deep Visibility into Application Performance APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month Monitor end-to-end web transactions and take corrective actions now Troubleshoot faster and improve end-user experience. Signup Now! http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140 _______________________________________________ Valgrind-users mailing list Valgrind-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/valgrind-users