From: Matthew Mundell <matt@mundell.ukfsn.org>
Subject: Compiling byte code to native
Date: 02 Jun 2004 12:43:41 +0100 [thread overview]
Message-ID: <87u0xuuqvm.fsf@sno.mundell.ukfsn.org> (raw)
The native compilation effort introduced earlier this year is archived
at http://www.mundell.ukfsn.org/native. It can now compile all the
byte codes.
Here are three speed comparisons. The commas in the middle column
separate runs.
microseconds size in bytes
copy-tree
Byte 21, 21, 20, 21, 18 100
Native 28, 14, 14, 16, 17 2332
last
Byte 15, 15, 16, 14, 15, 14 65
Native 12, 12, 12, 13, 19, 9 1605
native-test-info-eg-loop-small [1]
Byte 187, 231, 233, 235, 235, 237, 485 13
Native 113, 158, 164, 172, 173, 186, 225 302
So the speedup over byte code is available, but it seems that in most
cases it will be over-shadowed by the time spent in primitives.
It may be good to update the TODO entry:
** Investigate using GNU Lightning or similar system for incremental
compilation of selected bytecode functions to subrs. [There is an
effort archived at http://www.mundell.ukfsn.org/native that can
compile byte-code functions to native.]
In the future perhaps this work could be a base or reference for
adding compilation of functions to primitives.
Thanks.
[1] Passing 1000 to:
(defun native-test-info-eg-small (n)
"Return time before and after N iterations of a loop.
This is the info manual's byte code speed example."
(let ((t1 (current-time-string)))
(while (> (setq n (1- n))
0))
(list t1 (current-time-string))))
next reply other threads:[~2004-06-02 11:43 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-06-02 11:43 Matthew Mundell [this message]
2004-06-02 14:22 ` Compiling byte code to native Stefan Monnier
2004-06-02 16:30 ` Matthew Mundell
2004-06-02 17:04 ` Stefan Monnier
2004-06-02 18:05 ` Matthew Mundell
2004-06-02 22:56 ` Richard Stallman
2004-06-03 10:32 ` Matthew Mundell
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=87u0xuuqvm.fsf@sno.mundell.ukfsn.org \
--to=matt@mundell.ukfsn.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).