I have a function that I am trying to examine. I want to find all callers of this function, but there are a few issues:
- I am doing this to understand the code because I did not write it, but I need to know exactly how it behaves
- It runs through the STL beforehand, so I can't just use something like
callgrind
to get it's immediate callers
There is a stack trace of 10+ function calls until you get to actual code that is not in the STL that caused this function to be invoked. But those STL entry points vary, as it is a compare
function and calls for is_equal
go through a different sequence than those that go through not_equal
, etc. I will need to do this for at least 10+ different functions, and I want to streamline this as much as possible.
I want a tool that can dump each unique, full backtrace each time the function is called. Does anybody know a tool that can do this?
I am using gdb and c++ on Ubuntu 14.04.