> When I was originally fiddling with using LStrings for the buffering of
> the LaTeX generation I tried extra space of length 4 and 8 and of powers
> of two.  There was almost no difference in performance but a noticeable
> difference in memory use.  For that limited application almost all
> concatenation is of very short strings or single characters.

Could you please try again, and report the memory usage pattern for something
like the User Guide in the three variants:

1. With static increase of 4 chars.
2. With static increase of 8 chars.
3. With doubling of the buffer.

Also, maybe you could report the time it takes to export a LaTeX file ten
times, or something like that which is LString concatenation intensive.  (The
easy way to do this is to insert the User Guide into itself ten times.)

(When we export to LaTeX, we build a relatively large string from many small
bits.  This should be an excellent test of the concatenation code.)

Greets,

Asger

Reply via email to