You can use reverse debugging using this one:
(gdb) fin
(gdb) reverse-step
Question
I know the function name which is called. But not from where it is called. I want to put a breakpoint using gdb at return of this function. How to proceed?
Is there any specific command, or some series of steps?
Solution 2
You can use reverse debugging using this one:
(gdb) fin
(gdb) reverse-step
OTHER TIPS
If you are merely want to know what parent function called your specific function, put a breakpoint at the top of the child function in question. Once it breaks, use backtrace
(or just bt
) to see a full trace of the calls made to get to that point in execution.