From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: commenting out a SCHEDULED line does not remove todo from agenda. Date: Thu, 17 Jan 2013 12:42:23 +0100 Message-ID: <3FCB9B91-63EA-4443-A56C-F6BB80AED2D6@gmail.com> References: <8696.1358358500@alphaville> <16014.1358398925@alphaville> <717C030F-136F-46CA-B0C0-5F9CB3560921@gmail.com> <17512.1358412853@alphaville> Mime-Version: 1.0 (Mac OS X Mail 6.2 \(1499\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:51824) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TvnrR-0003P7-Iu for emacs-orgmode@gnu.org; Thu, 17 Jan 2013 06:42:23 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TvnrO-00071z-Sf for emacs-orgmode@gnu.org; Thu, 17 Jan 2013 06:42:21 -0500 Received: from mail-wi0-x22a.google.com ([2a00:1450:400c:c05::22a]:50557) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TvnrO-00071f-Ij for emacs-orgmode@gnu.org; Thu, 17 Jan 2013 06:42:18 -0500 Received: by mail-wi0-f170.google.com with SMTP id hq7so4506162wib.1 for ; Thu, 17 Jan 2013 03:42:17 -0800 (PST) In-Reply-To: <17512.1358412853@alphaville> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: "nicholas.dokos@hp.com Dokos" Cc: Rainer Stengele , emacs-orgmode@gnu.org On 17.1.2013, at 09:54, Nick Dokos wrote: > Carsten Dominik wrote: >=20 >>=20 >> On 17.1.2013, at 06:02, Nick Dokos wrote: >>=20 >>> ... >>> It sets p to the point at the beginning of the line and then >>> checks if the character after it is '#'. Only then does it skip >>> the entry. >>=20 >> And this is done for speed. Maybe Moore's law has progressed enough = to relax this assumption? >>=20 >=20 > For me, probably yes: my agenda is fairly simple. More complicated > agendas still seem to take a fairly substantial time to construct > however - Bastien spent considerable effort recently to speed up the > agenda and might look askance at any attempt to slow it down :-) >=20 > But actual numbers would carry more weight than any guesses I might > make. Here is a (probably stupid) implementation of the generalized > mechanism. In org-agenda-skip, replace >=20 > (if (equal (char-after p) ?#) (throw :skip t)) >=20 > with >=20 > (save-excursion > (goto-char p) > (skip-chars-forward "[:blank:]") > (if (equal (char-after) ?#) (throw :skip t))) >=20 > Assuming it's correct (and no better implementation is suggested), = maybe > somebody with a time-consuming agenda can try profiling with and = without > the generalized mechanism and let us know. >=20 > I tried with my agenda which calls org-agenda-skip 5768 times. Without > the mod, they took 0.13s; with the mod, they took 0.19s, so that's a = 50% > increase - but the overall time was actually shorter in the second = case: > 1.64s vs 1.72s. =20 Did you have a number of commented SCHEDULED items in there, so that = time was saved on those items? Otherwise it would be hard to see why = things should actually go faster. - Carsten > The data look noisy however (I only tried it once in > each case) so it's hard to say anything meaningful. I'd need to run = many > more experiments before I'd trust these numbers. >=20 > Nick >=20 >=20 >=20 >=20