Bug 133529

Summary: konqueror very slow rendering www.smh.com.au
Product: [Applications] konqueror Reporter: andrewb
Component: khtmlAssignee: Konqueror Developers <konq-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: dpbasti, Stefan.Borggraefe
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Fedora RPMs   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: trace of X calls made by konqueror
The Patch

Description andrewb 2006-09-04 03:16:20 UTC
Version:            (using KDE KDE 3.5.4)
Installed from:    Fedora RPMs
Compiler:          gcc (GCC) 4.1.1 20060525 (Red Hat 4.1.1-1) 
OS:                Linux

Rendering http://www.smh.com.au/ in konqueror is very slow (it seems to take many seconds and a series of redraws to bring the page up), and after the page has loaded scrolling is very jerky. Watching top, each time I scroll the window I see X jump up to 100% CPU for a second or more. The same happens when the page is loaded, or when the dynamic content on the page changes.

My system has a 2.5GHz P4, and free RAM, so I think that isn't an issue. I've only observed this on smh.com.au, and only in konqueror, so I think it isn't an X bug, but rather konqueror making excessive calls to the server.

I have plugins and animated GIFs disabled for the site, so there is no flash banner ad (and nspluginviewer isn't running). I'm running X.org 1.0.1-9.fc5.5. I hope you can reproduce this bug, let me know if I can gather any more info.
Comment 1 Tommi Tervo 2006-09-04 09:00:37 UTC
What video card/driver do you have? Some people have reported that updating NVidia driver fixed their konqueror performance problems. 
Comment 2 andrewb 2006-09-04 10:17:37 UTC
I have a radeon card, and am using the "radeon" driver from X.org.
Comment 3 Dirk Stoecker 2006-09-04 22:02:51 UTC

*** This bug has been marked as a duplicate of 115215 ***
Comment 4 Maksim Orlovich 2006-09-05 01:48:08 UTC
I can confirm this even on an i855... No clue on what we're doing that's killing X so much, though...
Comment 5 andrewb 2006-09-05 04:40:21 UTC
Created attachment 17641 [details]
trace of X calls made by konqueror

I gathered this trace with xtrace (http://xtrace.alioth.debian.org/) that shows
the calls konqueror is making to the X server. This trace shows the result of
running 'konqueror http://www.smh.com.au/', waiting for the page to load,
scrolling up and down a few times, and quitting (with Alt+F4).

I'm not really familiar with X, but I noticed that there are many calls to the
Render extension. I tried disabling that (-e flag to xtrace), but this didn't
change X's high CPU utilisation. Let me know if you'd like to see that trace. I
also checked that render acceleration is enabled in my X log.
Comment 6 Maksim Orlovich 2006-09-05 07:41:41 UTC
That's pretty cool -- we seem to be doing a lot of pointless messing with clipping as per that log.. But anyway, I think I found it. Essentially, the preblend cache could get confused between storing default size as -1x-1 and the actual values. Oops. The attached should fix it, and makes this site a lot better here (we still  have a funny lag when scrolling to the bottom of the page, but I blame it on Flash, not because I know its guilty but just because I have good reasons to dislike it ;-) )
Comment 7 Maksim Orlovich 2006-09-05 07:42:31 UTC
Created attachment 17643 [details]
The Patch
Comment 8 Maksim Orlovich 2006-09-05 07:59:32 UTC
*** Bug 131762 has been marked as a duplicate of this bug. ***
Comment 9 Tommi Tervo 2006-09-05 12:11:41 UTC
With patch konqueror's performance is quite good, about same level as opera. Firefox 1.0.7 is a bit slower. (P3 550Mhz, radeon 9200 using xorg driver)
Comment 10 Maksim Orlovich 2006-09-05 16:06:33 UTC
Applied
Comment 11 andrewb 2006-09-07 05:34:51 UTC
That seems to have fixed it, thanks! Scrolling is still a little jerky, but the site is now usable.
Comment 12 Tommi Tervo 2006-09-10 13:17:06 UTC
*** Bug 131773 has been marked as a duplicate of this bug. ***
Comment 13 Sebastian TurzaƄski 2006-10-14 23:16:23 UTC
still takes 50% of cpu and still is jerky on my p4 with 1,5GB ram with kde 3.5.5