On 11/29/2015 09:44 AM, Philippe Waroquiers wrote:
> On Sat, 2015-11-28 at 18:42 +0100, Maurice van der Pot wrote:
>> Unfortunately the removal of --db-attach seems to make things less
>> convenient.
> Yes, for simple examination of the error context of one single thread,
> --db-attach=yes was easy.

Very often I met bad context, wrong source line, or inability
to quit the application.  Instead, vgdb gets everything correct.
Good riddance to the demise of --db-attach.

> I am not completely sure how straightforward it would be to launch
> gdb+vgdb from valgrind itself (a.o. I am wondering about the interaction
> for stdin between gdb and the application).

Yes!  Establishing separate stdin, ctty, and process group for signals
is effectively impossible for valgrind to do by itself.  In contrast
it is trivial for the user's favorite terminal emulator environment,
such as graphical desktop, 'screen', 'tmux', etc.
Side note: copy+paste can perform all connections;
"typing" (keystrokes) can be avoided for setup if gdb is on $PATH.
Learn the keyboard commands of your terminal environment for
switching focus (keyboard and/or display).

> [[snip]]
> * with valgrind 3.11 and gdb 7.10, gdb will automatically discover
>    the executable being debugged.

gdb is likely to become confused if there is more than one candidate.
Running two sessions side-by-side for A-B comparison is common.


------------------------------------------------------------------------------
_______________________________________________
Valgrind-users mailing list
Valgrind-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/valgrind-users

Reply via email to