i need print own aplication memory usage in c++ (c++11) find memory leak. use shared_ptr program take 4gb, input 1gb output ~0,1gb.
i have 1 big for
for (const std::string & file_name : *files){ try{some_instructions_with_shared_ptr_here}} oudsie have small data structures, inside shared_ptr. may problem other classes or data structures want know when memory leak.
using shared_ptr not leak free mechanism. if have cycles in shared_ptr pointees, then heap never freed. neither valgrind detect it.
perhaps using setrlimit limit apps resources, , see gdb crashes give hints.
Comments
Post a Comment