Re: commit: Lots of stuff.


Subject: Re: commit: Lots of stuff.
From: Martin Sevior (msevior@mccubbin.ph.unimelb.edu.au)
Date: Mon Jul 09 2001 - 11:59:58 CDT


On Mon, 9 Jul 2001, Joaquin Cuenca Abela wrote:

>
> --- Martin Sevior <msevior@mccubbin.ph.unimelb.edu.au>
> wrote:
> >
> > To fix 1 I went back to the semantics of "Dirty
> > Document" I previously
> > used. ie A simple boolean set to dirty if anything
> > about the Frags sizes
> > or structure changes. Joaquin did stuff that might
> > have allowed us to
> > eventually only clean some fraction of the document.
> > I'm not sure this
> > will be a big win for us and was causing the
> > segfault.
>
> ops, sorry about the segfault
>
> I hope that we will be able to clean only a fraction
> of the document, because if I remember right, right
> now we're cleanning and reallocating all the vector of
> frags each time it gets dirty (for instance, each time
> the user enters a new character).
>
> For big documents, that may mean a desallocation and
> reallocation of ~50kb per inserted character.
>
> So I really hope that we could fix this "problem"...
> ;-)
>

You're right of course. Regarding the insertion of 1 char, we have to
change every Frag following the frag with the char in it.

We can almost certainly work out a way of avoiding the wholesale
allocation and deallocation of the vector though. Maybe we can just grow
and shrink it in response to Frag insertions and unlinks.

I just wanted to get Abi up to being ready for 0.90 release. My test docs
of about 100 pages were still nice and fast even with the vector
alloc/dealloc stuff.

Cheers

Martin



This archive was generated by hypermail 2b25 : Mon Jul 09 2001 - 12:00:03 CDT