all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Michael Albinus <michael.albinus@gmx.de>
To: Daniel Colascione <dancol@dancol.org>
Cc: emacs-devel@gnu.org
Subject: Re: trunk r116456: Improve dbus performance on synchronous calls
Date: Mon, 17 Feb 2014 17:06:37 +0100	[thread overview]
Message-ID: <87lhx9lo4y.fsf@gmx.de> (raw)
In-Reply-To: <E1WFMaG-0002WV-8L@vcs.savannah.gnu.org> (Daniel Colascione's message of "Mon, 17 Feb 2014 11:42:00 +0000")

Daniel Colascione <dan.colascione@gmail.com> writes:

>      (with-timeout ((if timeout (/ timeout 1000.0) 25))
>        (while (eq (gethash key dbus-return-values-table :ignore) :ignore)
> -	(let ((event (let ((inhibit-redisplay t) unread-command-events)
> -		       (read-event nil nil 0.1))))
> -	  (when (and event (not (ignore-errors (dbus-check-event event))))
> -	    (setq unread-command-events
> -		  (append unread-command-events (list event)))))))
> +        (let ((event (let ((inhibit-redisplay t) unread-command-events)
> +		       (read-event nil nil check-interval))))
> +          (when event
> +            (push event unread-command-events))
> +          (when (< check-interval 1)
> +            (setf check-interval (* check-interval 1.05))))))

Why `push'? It adds the event on top of `unread-command-events',
changing the event order when there are already events in that list.

Best regards, Michael.



       reply	other threads:[~2014-02-17 16:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <E1WFMaG-0002WV-8L@vcs.savannah.gnu.org>
2014-02-17 16:06 ` Michael Albinus [this message]
2014-02-17 16:17   ` trunk r116456: Improve dbus performance on synchronous calls Daniel Colascione
2014-02-17 16:41     ` dancol
2014-02-17 21:08       ` Michael Albinus
2014-02-17 21:42         ` Daniel Colascione
2014-02-18  0:00         ` Stefan Monnier

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87lhx9lo4y.fsf@gmx.de \
    --to=michael.albinus@gmx.de \
    --cc=dancol@dancol.org \
    --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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.