On Mar 1, 2007, at 11:00, Andreas L Delmelle wrote:

<snip />
It seems that our text-layout-algorithm works perfectly well on small to medium-sized blocks, but there is a slight problem with the scalability.


Some further follow-up:
Traced it down to the main loop in BreakingAlgorithm.findBreakingPoints() (line 456). If I debug the process, and place the breakpoint at finish() right after the main loop, the OOMError happens somewhere before that.

The base Paragraph's size is roughly 81000 elements (for roughly 125K characters), and with a heap of 512MB, the loop does not make it to index 71000. activeLines grows to 5120 elements.

OTOH, to relieve the fears a bit:
Simply changing the FO to use linefeed-treatment="preserve", which is a lot more common in case you have large preformatted text-blocks, already helps a great deal. Switching to linefeed-preservation alone makes the example pass with default heap settings.

Case closed FTM.

Cheers,

Andreas


Reply via email to