all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* How can I make GDB run faster on a large program with lots of shared libraries?
@ 2017-05-24 12:49 John Yates
  2017-05-28 18:09 ` Charles A. Roelli
  0 siblings, 1 reply; 2+ messages in thread
From: John Yates @ 2017-05-24 12:49 UTC (permalink / raw)
  To: help-gnu-emacs

I have discovered gdb-create-source-file-list.  Disabling this does
make the start up faster but seem to make the general session more
sluggish and less interactive.  Is there a reason that this list could
not be one of the artifacts delivered by my build process?

/john



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: How can I make GDB run faster on a large program with lots of shared libraries?
  2017-05-24 12:49 How can I make GDB run faster on a large program with lots of shared libraries? John Yates
@ 2017-05-28 18:09 ` Charles A. Roelli
  0 siblings, 0 replies; 2+ messages in thread
From: Charles A. Roelli @ 2017-05-28 18:09 UTC (permalink / raw)
  To: John Yates, help-gnu-emacs

On 24/05/2017 14:49, John Yates wrote:
> I have discovered gdb-create-source-file-list.  Disabling this does
> make the start up faster but seem to make the general session more
> sluggish and less interactive.  Is there a reason that this list could
> not be one of the artifacts delivered by my build process?

The list could be created by the build process.  Not sure it would be
a lot of help, though.

The reason gdb-mi requests the source file list is to run
`gdb-init-buffer' in any buffer that contains one of those files.
This function sets up the toolbar and gud-minor-mode, and if
gud-tooltip-mode is on, does some processing of macros in the
source file:

(defun gdb-init-buffer ()
   (set (make-local-variable 'gud-minor-mode) 'gdbmi)
   (set (make-local-variable 'tool-bar-map) gud-tool-bar-map)
   (when gud-tooltip-mode
     (make-local-variable 'gdb-define-alist)
     (gdb-create-define-alist)
     (add-hook 'after-save-hook 'gdb-create-define-alist nil t)))

(see `gdb-create-define-alist' as well).

If you've been using gud-tooltip-mode, then, turning it off will speed
up startup.  If that doesn't help, benchmark gdb's
"-file-list-exec-source-files" command and see if it's worth caching
the result in Elisp to save some time.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-05-28 18:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-24 12:49 How can I make GDB run faster on a large program with lots of shared libraries? John Yates
2017-05-28 18:09 ` Charles A. Roelli

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.