emacs-orgmode
[Top][All Lists]
Advanced

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

Re: [O] commenting out a SCHEDULED line does not remove todo from agenda


From: Carsten Dominik
Subject: Re: [O] commenting out a SCHEDULED line does not remove todo from agenda.
Date: Thu, 17 Jan 2013 12:42:23 +0100

On 17.1.2013, at 09:54, Nick Dokos <address@hidden> wrote:

> Carsten Dominik <address@hidden> wrote:
> 
>> 
>> On 17.1.2013, at 06:02, Nick Dokos <address@hidden> wrote:
>> 
>>> ...
>>> 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.
>> 
>> And this is done for speed.  Maybe Moore's law has progressed enough to 
>> relax this assumption?
>> 
> 
> 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 :-)
> 
> 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
> 
>     (if (equal (char-after p) ?#) (throw :skip t))
> 
> with
> 
>     (save-excursion
>      (goto-char p)
>      (skip-chars-forward "[:blank:]")
>      (if (equal (char-after) ?#) (throw :skip t)))
> 
> 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.
> 
> 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.  

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.
> 
> Nick
> 
> 
> 
> 




reply via email to

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