all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Charles A. Roelli" <charles@aurox.ch>
To: John Yates <john@yates-sheets.org>, help-gnu-emacs@gnu.org
Subject: Re: How can I make GDB run faster on a large program with lots of shared libraries?
Date: Sun, 28 May 2017 20:09:57 +0200	[thread overview]
Message-ID: <9b52e17a-f480-4de0-d30c-43bb4a03309c@aurox.ch> (raw)
In-Reply-To: <CAJnXXoi4kCs8AYqkLBZL5NbrJY4zmPCBnnLTkUjbL2aWD6pMoA@mail.gmail.com>

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.



      reply	other threads:[~2017-05-28 18:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
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 [this message]

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=9b52e17a-f480-4de0-d30c-43bb4a03309c@aurox.ch \
    --to=charles@aurox.ch \
    --cc=help-gnu-emacs@gnu.org \
    --cc=john@yates-sheets.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.
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.