lilypond-devel
[Top][All Lists]
Advanced

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

Re: anyone notice speed of 2.17.95 on Windows ?


From: Mike Solomon
Subject: Re: anyone notice speed of 2.17.95 on Windows ?
Date: Sat, 14 Dec 2013 10:37:45 +0200

On Dec 14, 2013, at 9:21 AM, Keith OHara <address@hidden> wrote:

On Fri, 13 Dec 2013 23:05:49 -0800, David Kastrup <address@hidden> wrote:

That does not make sense.  If you want call-once behavior, you can just
use a callback.

At the moment, the decision on whether to preserve the callback pointer in the grob property, or fill the property with the returned value, depends on the method used to request the property, get_pure_property() versus get_property().   A callback would be called multiple times (and it would have to support the unpure-pure calling convention).

The information of whether the callback is providing a value that /should/ be kept as final is better stored in the Grob itself, so I am thinking of ways to reorganize.


Excellent observation.

Currently, unpure-pure-containers to which one passes one function/argument use that function/constant for both the pure and unpure parts.
What you want to do is cache the pure result, not unlike Item::cache_pure_height (Interval height) [line 247 of item.cc].  I’m a fan of:
  • doing caching for more grobs (not just items)
  • doing caching for more properties (not just heights)
  • doing conditional caching, meaning caching a result after having finished X or Y

It’d be nice to have a general mechanism for all this.

Cheers,
MS

reply via email to

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