bug-lilypond
[Top][All Lists]
Advanced

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

Re: Long compile times with many empty bars


From: Torsten Hämmerle
Subject: Re: Long compile times with many empty bars
Date: Sat, 7 Apr 2018 03:15:01 -0700 (MST)

Noeck wrote
> I don’t know the internals enough, but isn’t it plausible that things
> like finding the optimal line break etc. have a n² complexity
> ("squared").

Hi Joram,

On the one hand, that sounds plausible, underpinned by David's evaluations.
But I find it very interesting that it takes significantly less time if you
replace the s4. by an R4.
The effect can also be reproduced by using \repeat unfold ..., and thus
using actual music (e.g. b'4. instead of s4.) - this is also considerably
faster.

Using full-bar rests, there basically should be the same line-breaking
issue, one wouldn't expect such a great difference between "nothing" (s4.)
and a rest symbol (R4.).

Using R4. and omitting MultiMeasureRest doesn't have the time problem, but
results in a wider spacing.

So, to me, without deeper knowledge about line and page-breaking algorithms,
it seems to be a special problem of emptiness (even missing spacing
information?) in combination with line-breaking, in a way...
Surprisingly, the excessive time consumption seems to take place is in step 

*"Processing graphical objects..."*

In prior versions of LilyPond (2.18.2 and before), the effect has already
been there, but a bit less pronounced.


A combination of empty (s4.) and non-empty staves doesn't show the problem,
either:
  <<
    \new Staff { \time 3/8  s4.*500 }
    \new Staff { \time 3/8  R4.*500 }
  >>


Conclusion: Something is rotten in the state of Denmark.

All the best,
Torsten




--
Sent from: http://lilypond.1069038.n5.nabble.com/Bugs-f58488.html



reply via email to

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