[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Benchmarking (was: 78% speed up in CC Mode scrolling.)
From: |
Nicolas Richard |
Subject: |
Benchmarking (was: 78% speed up in CC Mode scrolling.) |
Date: |
Tue, 05 Jul 2016 11:27:18 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.92 (gnu/linux) |
Hello,
Alan Mackenzie <address@hidden> writes:
> (defmacro time-it (&rest forms)
> "Time the running of a sequence of forms using `float-time'.
> Call like this: \"M-: (time-it (foo ...) (bar ...) ...)\"."
> `(let ((start (float-time)))
> ,@forms
> (- (float-time) start)))
FWIW there's a macro called benchmark-run for this kind of job, and
there's also an interactive version: M-x benchmark
--
Nicolas