edb-debugger icon indicating copy to clipboard operation
edb-debugger copied to clipboard

Allow edb to follow child processes (forks)

Open pykler opened this issue 7 years ago • 3 comments

GDB allows for tracing through forks of a program. GDB has a flag:

  • "set detach-on-fork off" which attaches both processes in gdb.
  1. "set follow-fork-mode parent" (default) the parent process will be debugged and the child will be suspended,
  2. "set follow-fork-mode child" the child process will be debugged and the parent will be held suspended.

The following are links on how GDB handles forks and manages "inferiors".

https://sourceware.org/gdb/onlinedocs/gdb/Forks.html https://sourceware.org/gdb/onlinedocs/gdb/Inferiors-and-Programs.html


Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

pykler avatar Jun 21 '18 15:06 pykler

I think this sounds like a useful feature. I'll start thinking about how this should work in edb from both a technical point of view and from a UI point of view. I think it will be important for this feature to be implemented in such a way that it is easy for users to understand what is going on and which process is currently "in focus".

eteran avatar Jun 22 '18 13:06 eteran

+1 on this. I recently ran into something I needed to debug that used fork() heavily and the lack of this feature was a blocker for me.

gsuberland avatar Sep 19 '18 22:09 gsuberland

+1 for this.

ttufts avatar May 03 '20 19:05 ttufts