emacs-devel
[Top][All Lists]
Advanced

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

Re: [Emacs-diffs] /srv/bzr/emacs/trunk r109187: Adjust consing_since_gc


From: Dmitry Antipov
Subject: Re: [Emacs-diffs] /srv/bzr/emacs/trunk r109187: Adjust consing_since_gc when objects are explicitly freed.
Date: Wed, 25 Jul 2012 13:55:59 +0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20120713 Thunderbird/14.0

On 07/25/2012 01:59 AM, Stefan Monnier wrote:

What about the overall running time.  How much is saved by your patch,
and how much additional is saved by the "decrement consing_since_gc in
free_marker"?

Hm. The test is:

(defun scroll-benchmark ()
  (interactive)
  (let ((oldgc gcs-done)
        (oldtime (float-time)))
    (condition-case nil (while t (scroll-up) (redisplay))
      (error (message "GCs: %d Elapsed time: %f seconds"
                      (- gcs-done oldgc) (- (float-time) oldtime))))))

For xdisp.c, the original results are 600 GCs and 32.65 seconds.

When free_cons and free_misc subtracts from consing_since_gc,
and save_restriction_restore frees it's data explicitly, results
are 560 GCs and 31.95 seconds.

Of course, explicit free in  save_restriction_restore makes no sense
if we fool GC with consing_since_gc: 600 GCs and 32.95 seconds.

I don't understand why we're still wast^W^Wspending our time with
such a simple and almost obvious thing.

Dmitry




reply via email to

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