Re: Strange performance behaviour related to <span>

"Sebastian Geerken" <[email protected]>
Newsgroups gmane.comp.web.dillo.devel
Message-ID <[email protected]>
Hi Jorge,

> > Still, Dw should handle this. Look at this example:
> > 
> > (for i in $(seq 1 20); do echo '<div style="float:left"><div></div><div style="display:table"></div>'; done) > tmp.html; src/dillo tmp.html
> > 
> > Here, only some <div>s at the end are open (and it is simple to make
> > the snippet correct HTML), but it still takes much time. This looks
> > still like a Dw problem, especially since it is much faster if you
> > leave the float definition away.
> 
>   Yes, I see.
> 
>   There's indeed a problem in Dw.
> 
>   After some inspired reflections on the exponential nature of the
> time taken, and the corresponding tests&experiments, I got to a simple patch
> that solves all the cases we've seen so far in this thread!
> 
>   It makes all cpu hog cases render as fast as expected, and even makes
> some "unrelated" sites I visit render twice faster or so.
> 
>   I'm not postulating this to be *the* correct solution, but is a strong
> hint as to what is wrong. I didn't want to mess with mustQueueResize
> subtleties, so I'm more than happy with this one-liner:
> 
> 
> diff -r bcf30ff0896c dw/textblock.cc
> --- a/dw/textblock.cc   Thu Jun 16 16:27:56 2016 -0400
> +++ b/dw/textblock.cc   Thu Jun 16 23:21:40 2016 -0400
> @@ -3034,7 +3034,8 @@ void Textblock::queueDrawRange (int inde
> 
>  void Textblock::updateReference (int ref)
>  {
> -   queueResize (ref, false);
> +   if (lines->size ())
> +      queueResize (ref, false);
>  }
> 
> 
>  HTH.

Committed, thanks for the good work!

I've looked at this problem, too, and found out that the interaction
between queueResize and markSizeChange was not perfect. I've not yet
examined how it works now, but the performance problems seem to be
solved (including the original case), so I'll assign a lower priority
to this.

Sebastian

_______________________________________________
Dillo-dev mailing list
[email protected]
http://lists.dillo.org/cgi-bin/mailman/listinfo/dillo-dev
signature.asc (application/pgp-signature, 473 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQEcBAEBAgAGBQJXY76AAAoJEAw7+YHB+ZL6mr4H/2FV5KNduH3UkCI7orUrziX6
MI1BAzo921bhB57n8ClzDBmRmDjMRBMlyS7AJCVvkHqFHcRp8cyYm062hrO7VKDJ
miEy8tHTkS1THCw1zQZBZPKtwojaI3tN0CH4HsX0PSY6ZWnFLWd7L+Zq6j7Q1MqU
D5z3N1ENGHZA5r8hWcTu6EhNi8S3aGXr0A9y/G+5KSagGsrBnfK7aWSVlOeTQcl/
za2P2HSI/mEzVGW/zP+tqrXn6k1Hs1BLvnHV9qKNshDgXRU4QUqjVNfqC7z7v1D/
FGgAu/sBz3jbLKcxNZGLa+yO6dD3ytucagPB0end9TCmg/Azxc30co9EUWC/llI=
=FnIY
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.