bug-lilypond
[Top][All Lists]
Advanced

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

Re: Error when compiling a large file


From: David Kastrup
Subject: Re: Error when compiling a large file
Date: Tue, 19 Feb 2013 12:39:32 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

"Phil Holmes" <address@hidden> writes:

> Lilypond has always used a lot of memory.

That does not mean that this was correct.

> If I run the test file Eluze created on 2.12 it goes up to just shy of
> a gig.  I'd assume there are minor variations in the amount of memory
> the various layout systems use, and 2.12 was just too little to cause
> memory to be allocated, and subsequent 2.13 versions just too much.

For every potential page break point, there is a sequence of optimal
page break points before it.  To evaluate its score, I _only_ need to
evaluate the score of the page between the currently considered
breakpoint and all possible _immediately_ preceding breakpoints since
those already _have_ been scored.

So as the number of pages grows, the optimal page break point sequences
coalesce.

If there are potentially 100 possible page break points on a single
page, there will not be more than 100 page break point sequences under
consideration at any step if we use _optimal_ page breaking.

So after something like 5 pages, memory usage should not grow more than
linear with the length of the document.  If it does, we are doing
something wrong.

-- 
David Kastrup




reply via email to

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