On Aug 9, 2006, at 22:32, Jeremias Maerki wrote:

<snip />
Now, if we can free some objects even sooner FOP might even handle files
like the one from Luis Ferro with under 256MB one day. For that we'll
need to know reliably when an FO is completely processed (including area
generation). That's something that we'll also need for
page-number-citation-last, too, BTW.

Just thought about this some more, and I wonder...
When is that exactly? After LM.addAreas()? Could we make the LMs clean up after themselves? After they're done, they signal the AreaTreeHandler that the FO may be released --it is ultimately up to the layout algorithm to decide if the element list and area generation would need to be repeated, and even then, it may suffice to keep certain state information about the FObj alive, rather than the whole FObj itself.

Also, we may even free objects in the FOTree sooner, as long as the LM references them, they won't be released anyway. We can release them in the FOTree before the LM itself lets go of them.

Also a requirement, or at least very convenient, to be able to free the FOs sooner, would be to have the LM-tree creation and initialization begin sooner --much sooner. Time to implement AreaTreeHandler.endBlock() or startFlow()? So that, by the time endPageSequence() occurs, the LM tree will already be constructed, maybe even some of the element lists could already be made partially available (?)



Cheers,

Andreas

Reply via email to