[valgrind] [Bug 371471] Valgrind complains about non legit memory leaks on placement new (C++)
https://bugs.kde.org/show_bug.cgi?id=371471 Tom Hughes changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |FIXED --- Comment #6 from Tom Hughes --- So this is the leak it is reporting: ==24123== 72,704 bytes in 1 blocks are still reachable in loss record 1 of 1 ==24123==at 0x62228BAD: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so) ==24123==by 0x624C0A5F: ??? (in /usr/lib64/libstdc++.so.6.0.22) ==24123==by 0x6160CD89: call_init.part.0 (in /usr/lib64/ld-2.23.so) ==24123==by 0x6160CE9A: _dl_init (in /usr/lib64/ld-2.23.so) ==24123==by 0x615FDCB9: ??? (in /usr/lib64/ld-2.23.so) So it's nothing to do with the placement new but rather is some initialisation inside the standard library. It's also still reachable when the program terminates, so not really a leak at all, which is why the details aren't shown by default. In the newly released 3.12.0 it goes away anyway because we now call the libstdc++ cleanup routine at exit by default. -- You are receiving this mail because: You are watching all bug changes.
[valgrind] [Bug 371471] Valgrind complains about non legit memory leaks on placement new (C++)
https://bugs.kde.org/show_bug.cgi?id=371471 --- Comment #5 from Brian Teixeira --- Sorry, I forgot to mention that you need to include to make it compile. -- You are receiving this mail because: You are watching all bug changes.
[valgrind] [Bug 371471] Valgrind complains about non legit memory leaks on placement new (C++)
https://bugs.kde.org/show_bug.cgi?id=371471 --- Comment #4 from Tom Hughes --- I'm pretty sure it's not the same anyway as the other bug is about static objects, and there are none here. This is almost certainly something different - the fact that it is reporting two allocations suggests that it is trapping the placement new and treating it as a real allocation that is then never freed. -- You are receiving this mail because: You are watching all bug changes.
[valgrind] [Bug 371471] Valgrind complains about non legit memory leaks on placement new (C++)
https://bugs.kde.org/show_bug.cgi?id=371471 --- Comment #3 from Tom Hughes --- Also that code doesn't even compile: bericote [/tmp] % g++ -std=c++14 -o x x.cpp x.cpp: In function ‘int main()’: x.cpp:12:17: error: no matching function for call to ‘operator new(sizetype, A*&)’ new (obj) A(20); ^ : note: candidate: void* operator new(long unsigned int) : note: candidate expects 1 argument, 2 provided -- You are receiving this mail because: You are watching all bug changes.
[valgrind] [Bug 371471] Valgrind complains about non legit memory leaks on placement new (C++)
https://bugs.kde.org/show_bug.cgi?id=371471 Tom Hughes changed: What|Removed |Added CC||t...@compton.nu --- Comment #2 from Tom Hughes --- Well it might be the same as that or it might not - it's hard to tell because the leak details have been suppressed from the log. -- You are receiving this mail because: You are watching all bug changes.
[valgrind] [Bug 371471] Valgrind complains about non legit memory leaks on placement new (C++)
https://bugs.kde.org/show_bug.cgi?id=371471 Markus Trippelsdorf changed: What|Removed |Added CC||octopl...@yandex.com --- Comment #1 from Markus Trippelsdorf --- Not a bug. See https://bugs.kde.org/show_bug.cgi?id=345307 for an explanation. -- You are receiving this mail because: You are watching all bug changes.