unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: help-gnu-emacs@gnu.org
Subject: Re: When to choose defsubst
Date: Mon, 02 Apr 2007 13:31:23 -0400	[thread overview]
Message-ID: <jwvwt0uk7q1.fsf-monnier+gnu.emacs.help@gnu.org> (raw)
In-Reply-To: mailman.1675.1175530252.7795.help-gnu-emacs@gnu.org

> I tried to find an easy answer but failed miserably at it :/
> So my question is this: when/why should I use a defsubst ?

Never.


        Stefan


PS: `defsubst' is like `defun' except it additionally tells the
    byte-compiler that this function should be inlined at every call site.
    In some rare cases, it can make a noticeable performance difference,
    but these are very rare, so you should only do that after noticing an
    actual performance problem and finding out where time is spent (with
    elp, typically).
    The reason not to use `defsubst' is that it does not behave well w.r.t
    debug/advice/trace/...

       reply	other threads:[~2007-04-02 17:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <mailman.1675.1175530252.7795.help-gnu-emacs@gnu.org>
2007-04-02 17:31 ` Stefan Monnier [this message]
2007-03-31 15:03 When to choose defsubst Xavier Maillard

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jwvwt0uk7q1.fsf-monnier+gnu.emacs.help@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=help-gnu-emacs@gnu.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).