From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Thien-Thi Nguyen Newsgroups: gmane.emacs.devel Subject: Re: run-with-timer vs run-with-idle-timer Date: Sat, 12 May 2018 19:57:43 +0200 Message-ID: <87d0y07o4o.fsf@gnuvola.org> References: <87tvrgd972.fsf@gmail.com> <87a7t74tsf.fsf@gnuvola.org> <87603v4a5x.fsf@gnuvola.org> <871seiqxwr.fsf@gmail.com> <87k1sapi43.fsf@gmail.com> Reply-To: emacs-devel NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-Trace: blaine.gmane.org 1526147483 2868 195.159.176.226 (12 May 2018 17:51:23 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 12 May 2018 17:51:23 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: =?utf-8?B?Sm/Do28gVMOhdm9yYQ==?= To: emacs-devel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat May 12 19:51:19 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fHYfu-0000dN-KY for ged-emacs-devel@m.gmane.org; Sat, 12 May 2018 19:51:18 +0200 Original-Received: from localhost ([::1]:60158 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fHYi1-0006tt-ME for ged-emacs-devel@m.gmane.org; Sat, 12 May 2018 13:53:29 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45910) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fHYgx-0006kt-6m for emacs-devel@gnu.org; Sat, 12 May 2018 13:52:24 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fHYgs-0000yW-CG for emacs-devel@gnu.org; Sat, 12 May 2018 13:52:23 -0400 Original-Received: from mail.agora-net.com ([67.59.132.6]:57938) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fHYgs-0000xV-7p for emacs-devel@gnu.org; Sat, 12 May 2018 13:52:18 -0400 Original-Received: from ttn by mail.agora-net.com with local (Exim 4.82) (envelope-from ) id 1fHYgq-0007nM-Ne; Sat, 12 May 2018 13:52:16 -0400 Original-Received: from ttn by zigzag.favinet with local (Exim 4.80) (envelope-from ) id 1fHYmH-0001lx-I4; Sat, 12 May 2018 19:57:53 +0200 In-Reply-To: <87k1sapi43.fsf@gmail.com> (=?utf-8?Q?=22Jo=C3=A3o_T=C3=A1vor?= =?utf-8?Q?a=22's?= message of "Fri, 11 May 2018 12:05:48 +0100") Mail-Followup-To: emacs-devel X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: ttn@gnuvola.org X-SA-Exim-Scanned: No (on mail.agora-net.com); SAEximRunCond expanded to false X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 67.59.132.6 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:225271 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable () Jo=C3=A3o T=C3=A1vora () Fri, 11 May 2018 12:05:48 +0100 > I suppose it's a matter of style. Just to clarify, since I've just realised we're talking about two independent things here: 1. "catch/loop/throw" vs "let/test/loop/set" is indeed a matter of style (but you've probably convinced me to prefer the latter). Yeah, that was my meaning. I look forward to learning why =E2=80=98run-with-idle-timer=E2=80=99 is even necessary (my only experience= w/ that is in zone.el func =E2=80=98zone-when-idle=E2=80=99). 2. It's the short timeout to accept-process-output that I'm supposing hurts performance, but it can also be lengthened using the first idiom. Why does a short timeout hurt performance? My understanding is: large timeout =3D> more time for subproc to do its thing =3D> bigger and fewer chunks of input =3D> less overhead relatively =3D> better overall performance. [timeout value gyrations] Sounds somewhat cargo-cult. Just like Emacs, i suppose... :-D =2D-=20 Thien-Thi Nguyen ----------------------------------------------- (defun responsep (query) (pcase (context query) (`(technical ,ml) (correctp ml)) ...)) 748E A0E8 1CB8 A748 9BFA =2D-------------------------------------- 6CE4 6703 2224 4C80 7502 --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iEYEARECAAYFAlr3KxoACgkQZwMiJEyAdQKKJgCgsPyEoA+k66dWoOWJRI5HgJ6n zukAmwRUb90Z2Fgdx799wMyjYMehhvGS =fPs0 -----END PGP SIGNATURE----- --=-=-=--