The attached patch against r5854 adds basic demangling support for D. D: http://www.digitalmars.com/d/ http://www.prowiki.org/wiki4d/wiki.cgi?FrontPage
Created attachment 15656 [details] D demangling support
Created attachment 15744 [details] D demangling support * refactored source * changed license from Eiffel Forum license version 1 to GPL with linking exception
Created attachment 16049 [details] D demangling support fixed size of string allocation
Created attachment 16052 [details] D demangling support removed debugging artefacts ^_^
This would come in very handy for me, because I am working an a D project which desperately needs some profiling. Unfortunately, as the patch is more than two years old, it does not apply cleanly anymore. There seems to be some major issue with valgrind's malloc/realloc replacements. It would be great if you could update this patch, as I have not wrapped my head around the valgrind internals yet. Thanks in advance!
Hmm... I am not sure that putting all kind of demanglers into Valgrind core is the right thing to do. IMHO this should be part of post-processing/pretty-printing the results (and if there is some functionality based on demangled names, it would be better to add a config option to Valgrind to allow to provide the mangled name). Is there a standalone demangler for D (as c++filt for C++)? Perhaps it is enough for profiling to pipe the callgrind.out/cachegrind.out files trough the demangler? On the other hand, I can imagine putting a scripting hook for pretty-printing symbol names into KCachegrind (and the CLI version of it). A demangler would be a perfect usage (aside from customizing shortening of C++ templates).