From: Eli Zaretskii <eliz@gnu.org>
To: Joel Brobecker <brobecker@adacore.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [Windows/RFA/commit] Deprecate windows-specific dll-symbols command and aliases
Date: Fri, 31 Jan 2014 14:33:00 -0000 [thread overview]
Message-ID: <83y51w5igt.fsf@gnu.org> (raw)
In-Reply-To: <20140131122203.GC4101@adacore.com>
> Date: Fri, 31 Jan 2014 16:22:03 +0400
> From: Joel Brobecker <brobecker@adacore.com>
> Cc: gdb-patches@sourceware.org
>
> | Note that before the debugged program has started execution, no DLLs
> | will have been loaded. The easiest way around this problem is simply to
> | start the program --- either by setting a breakpoint or letting the
> | program run once to completion. It is also possible to force
> | @value{GDBN} to load a particular DLL before starting the executable ---
> | see the shared library information in @ref{Files}, or the
> | @code{dll-symbols} command in @ref{Cygwin Native}. Currently,
> | explicitly loading symbols from a DLL with no debugging information will
> | cause the symbol names to be duplicated in @value{GDBN}'s lookup table,
> | which may adversely affect symbol lookup performance.
>
> I think that suggesting the loading of the DLL before getting it
> actually mapped is a little iffy and that it's much better, IMO,
> to ask the user to just run the program the same way we do it
> on all other platforms.
Doesn't "sharedlibrary" have the same effect as dll-symbols in this
scenario?
> You can emulate that behavior using the "symbol-file" command, but I
> don't think this was the intention of that command and that we
> should validate it here.
Intention aside, the important question, I think, is whether we really
want to discourage such uses of "symbol-file", and if so, why.
> --- a/gdb/doc/gdb.texinfo
> +++ b/gdb/doc/gdb.texinfo
> @@ -16919,19 +16919,6 @@ evaluation yields the address of the file's shared object file header.
> For this command to work, you must have used @code{symbol-file} or
> @code{exec-file} commands in advance.
>
> -@kindex add-shared-symbol-files
> -@kindex assf
> -@item add-shared-symbol-files @var{library-file}
> -@itemx assf @var{library-file}
> -The @code{add-shared-symbol-files} command can currently be used only
> -in the Cygwin build of @value{GDBN} on MS-Windows OS, where it is an
> -alias for the @code{dll-symbols} command (@pxref{Cygwin Native}).
> -@value{GDBN} automatically looks for shared libraries, however if
> -@value{GDBN} does not find yours, you can invoke
> -@code{add-shared-symbol-files}. It takes one argument: the shared
> -library's file name. @code{assf} is a shorthand alias for
> -@code{add-shared-symbol-files}.
> -
> @kindex section
> @item section @var{section} @var{addr}
> The @code{section} command changes the base address of the named
> @@ -19899,11 +19886,6 @@ selector for 32-bit programs and @code{$gs} for 64-bit programs).
> @item info dll
> This is a Cygwin-specific alias of @code{info shared}.
>
> -@kindex dll-symbols
> -@item dll-symbols
> -This command loads symbols from a dll similarly to
> -add-sym command but without the need to specify a base address.
> -
> @kindex set cygwin-exceptions
> @cindex debugging the Cygwin DLL
> @cindex Cygwin DLL, debugging
> @@ -19998,13 +19980,7 @@ describes working with such symbols, known internally to @value{GDBN} as
> Note that before the debugged program has started execution, no DLLs
> will have been loaded. The easiest way around this problem is simply to
> start the program --- either by setting a breakpoint or letting the
> -program run once to completion. It is also possible to force
> -@value{GDBN} to load a particular DLL before starting the executable ---
> -see the shared library information in @ref{Files}, or the
> -@code{dll-symbols} command in @ref{Cygwin Native}. Currently,
> -explicitly loading symbols from a DLL with no debugging information will
> -cause the symbol names to be duplicated in @value{GDBN}'s lookup table,
> -which may adversely affect symbol lookup performance.
> +program run once to completion.
I'm OK with this, provided that we really don't want users to know
about this use of "symbol-file".
Also, I'd like to hear at least from Chris and/or Corinna, as I don't
think I ever used dll-symbols myself.
Thanks.
next prev parent reply other threads:[~2014-01-31 14:33 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-31 9:48 Joel Brobecker
2014-01-31 11:30 ` Eli Zaretskii
2014-01-31 11:39 ` Joel Brobecker
2014-01-31 11:49 ` Eli Zaretskii
2014-01-31 12:22 ` Joel Brobecker
2014-01-31 14:33 ` Eli Zaretskii [this message]
2014-02-04 20:20 ` Pedro Alves
2014-02-10 14:34 ` Joel Brobecker
2014-02-12 14:44 ` Pedro Alves
2014-02-12 17:17 ` Joel Brobecker
2014-02-13 12:01 ` Joel Brobecker
2014-02-13 16:02 ` Eli Zaretskii
2014-02-13 16:43 ` Joel Brobecker
2014-02-13 17:03 ` Eli Zaretskii
2014-02-13 17:24 ` Pedro Alves
2014-02-13 17:40 ` Eli Zaretskii
2014-02-19 9:43 ` Joel Brobecker
2014-02-19 16:44 ` Eli Zaretskii
2014-02-20 8:34 ` Joel Brobecker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83y51w5igt.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=brobecker@adacore.com \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox