unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Alan Mackenzie <acm@muc.de>
To: emacs-devel@gnu.org
Subject: Lexical binding: why?
Date: Tue, 28 May 2019 10:08:50 +0000	[thread overview]
Message-ID: <20190528100850.GA5296@ACM> (raw)

Hello, Emacs.

What is the purpose of converting Lisp files to use lexical binding?

I always thought the idea was to speed the SW up.  However, when I tried
converting CC Mode to lexical binding, I got the following timings for
two of my personal benchmarks:

                  Dynamic binding             Lexical binding

Benchmark 1           7.249s                      7.423s 

Benchmark 2          16.743s                     16.691s

.  I thus see no speedup from the use of lexical binding.

Have I, perhaps, made some mistake somewhere?  Does anybody else see
significant speed increases through the use of lexical binding?

-- 
Alan Mackenzie (Nuremberg, Germany).



             reply	other threads:[~2019-05-28 10:08 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-28 10:08 Alan Mackenzie [this message]
2019-05-28 12:01 ` Lexical binding: why? Tadeus Prastowo
2019-05-28 12:26 ` Stefan Monnier
2019-05-28 13:02   ` Dmitry Gutov
2019-05-28 13:25     ` Stefan Monnier
2019-05-28 13:46       ` Dmitry Gutov
2019-05-28 13:44   ` Alan Mackenzie
2019-05-28 17:21     ` Stefan Monnier
2019-05-28 17:41       ` Alan Mackenzie
2019-05-28 17:58         ` Stefan Monnier
2019-05-28 15:19 ` John Wiegley

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=20190528100850.GA5296@ACM \
    --to=acm@muc.de \
    --cc=emacs-devel@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.
Code repositories for project(s) associated with this public inbox

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

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).