emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Execution speed


From: Mark Oteiza
Subject: Re: Execution speed
Date: Sun, 19 Mar 2017 11:26:27 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

Stefan Monnier <address@hidden> writes:

> Someone on SO reported a surprising behavior where a recursive
> implementation of `gcd` turned out faster than the iterative version:
>
>     http://stackoverflow.com/questions/42792988/
>
> The more surprising thing is that when I try it I get the
> opposite result, even though it's basically on the same kind of system
> (GNU/Linx x86).
>
> I'm curious where the difference might come from.  Could you guys try
> out the test?
>
> Just do `emacs -Q --batch -l .../ir-test.el`.  Here's what I got:
>
>     % emacs24 -Q --batch -l ~/tmp/ir-test.el
>     Interpreted:  Iterative=1.770s; Recursive=1.937s
>     Bytecompiled: Iterative=1.187s; Recursive=1.496s
>     % .../src/emacs -Q --batch -l ~/tmp/ir-test.el
>     Interpreted:  Iterative=4.496s; Recursive=4.595s
>     Bytecompiled: Iterative=2.471s; Recursive=2.983s
>
> where `emacs24` is Debian's whereas the other one is my locally
> built&hacked version with debugging assertions and stuff.

Interesting.  Arch Linux's repo emacs 25:

$ emacs -Q --batch -l ir-test.el
Interpreted:  Iterative=2.302s; Recursive=1.956s
Bytecompiled: Iterative=1.349s; Recursive=1.214s



reply via email to

[Prev in Thread] Current Thread [Next in Thread]