|
From: Nicholas N. <nj...@cs...> - 2005-04-25 15:42:16
|
On Mon, 25 Apr 2005, Benoit Peccatte wrote: > In my coverage tool, I need to call VG(demangle). However it is not > exported from the core. Is there a way to call it properly from a tool ? It would require making it tool-visible by moving it from core.h to tool.h. Are you printing out function/method names as part of the coverage information? AFAICT a coverage tool will need a couple of other changes to the core/tool interface -- to provide the ability to get all the debug line information about a file, which requires one or two extra functions. > I found that valgrind sometime calls SK_(discard_basic_block_info) . I > don't understand what this means. Is it that there was an error ? Is is > because the corresponding library was unloaded ? Sometimes Valgrind removes code translations from its cache, usually because the code cache has filled up. If a tool maintains extra state about each translation, it needs to be told to flush that state when translations are removed. To enable this, the tool must call VG_(needs_basic_block_discards)(). Cachegrind uses this facility. Your profiler may or may not need to use this facility, depending on how exactly it works. BTW, are you doing this work against the Subversion repository? (See http://www.valgrind.org/devel/cvs_svn.html) You should do so, as the intermediate representation has changed significantly in order to support multiple architectures such as AMD64 and PPC. Sorry I didn't mention this earlier. How far advanced is your tool? I'll be interested to see how it compares with mine :) N |