Summary: | Javascript freeze [abort] issue at linux.org | ||
---|---|---|---|
Product: | [Applications] konqueror | Reporter: | Nick Warne <nick> |
Component: | khtml | Assignee: | Konqueror Developers <konq-bugs> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | maksim |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | preliminary patch |
Description
Nick Warne
2006-10-19 21:46:31 UTC
Not seeing it, though may be your notion of a few seconds is much shorter than mine.. I presume I was supposed to click 'go' after selecting from the boxes, right? (But thanks for this report, BTW -- it's very useful to know if instances where this pops up..) Yes, just click 'go' with all selections left as default 'all matches'. The page produces this error for me after perhaps 10 seconds. Maybe go from the front page: http://www.linux.org/ and select 'distributons' from the left hand frame link. I also got this on 3.5.4, but waited until 3.5.5 was out as I saw a lot of fixes in the pipeline. Nick OK, here is a long gdb output: konqueror: setLocationBarURL : url = http://www.linux.org/dist/ konqueror: KonqMainWindow::setLocationBarURL: url = http://www.linux.org/dist/ konqueror: Creating new konqrun for http://www.linux.org/dist/ req.typedURL= kparts: BrowserRun::scanfile http://www.linux.org/dist/ kparts: slotBrowserMimetype: found text/html for http://www.linux.org/dist/ kio (KIOJob): Job::kill this=0x8465d30 KIO::TransferJob m_progressId=0 quietly=true konqueror: KonqMainWindow::openView text/html http://www.linux.org/dist/ 0x82c9068 req:[forceAutoEmbed] konqueror: changeViewMode: serviceType is text/html serviceName is current service name is khtml konqueror: KonqView::openURL url=http://www.linux.org/dist/ locationBarURL=http://www.linux.org/dist/ konqueror: KonqMainWindow::setLocationBarURL: url = http://www.linux.org/dist/ khtml (part): KHTMLPart(0x839ca48)::openURL http://www.linux.org/dist/ khtml (part): saveState this=0x839ca48 '' saving URL http://www.linux.org/dist/ khtml (part): saveState this=0x85461e0 'linuxhq' saving URL http://www.linuxhq.com/kernel/bin/latest libkonq: ## addToHistory: http://www.linux.org/dist/ Typed URL: http://www.linux.org/dist/, Title: konqueror: KonqMainWindow::openView ok=true bOthersFollowed=false returning true kio (Scheduler): Resume metadata is '' kio (Scheduler): HOLD: Reusing held slave for http://www.linux.org/dist/ konqueror: KonqMainWindow::slotRunFinished() kparts: 0x8544e18 emitting activePartChanged (nil) kparts: Part::~Part 0x85461e0 kparts: deleting widget [KHTMLView pointer (0x8319390) to widget linuxhq, geometry=300x160+2187+2779] linuxhq khtml (html): using compatibility parseMode konqueror: KonqMainWindow::setCaption(Linux Online - Distributions and FTP Sites) khtml (tokenizer): Finished loading an external script khtml (tokenizer): Finished loading an external script khtml (tokenizer): Finished loading an external script khtml: 0x839ca48: KHTMLPart::submitForm target= url=list.html khtml (tokenizer): Finished loading an external script khtml (part): saveState this=0x839ca48 '' saving URL http://www.linux.org/dist/ libkonq: ## addToHistory: http://www.linux.org/dist/ Typed URL: , Title: Linux Online - Distributions and FTP Sites khtml: 0x839ca48: KHTMLPart::submitForm target= url=list.html konqueror: KonqMainWindow::slotOpenURLRequest frameName= konqueror: KonqMainWindow::openURL (from slotOpenURLRequest) url=http://www.linux.org/dist/list.html konqueror: KonqMainWindow::openURL : url = 'http://www.linux.org/dist/list.html' serviceType=' req=[]' view=0x82c9068 khtml (part): saveState this=0x839ca48 '' saving URL http://www.linux.org/dist/ konqueror: trying openView for http://www.linux.org/dist/list.html (serviceType ) konqueror: setLocationBarURL : url = http://www.linux.org/dist/list.html konqueror: KonqMainWindow::setLocationBarURL: url = http://www.linux.org/dist/list.html konqueror: Creating new konqrun for http://www.linux.org/dist/list.html req.typedURL= kparts: BrowserRun::scanfile http://www.linux.org/dist/list.html konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created konqueror: Render Style Declaration created kparts: slotBrowserMimetype: found text/html for http://www.linux.org/dist/list.html kio (KIOJob): Job::kill this=0x850bae0 KIO::TransferJob m_progressId=0 quietly=true konqueror: KonqMainWindow::openView text/html http://www.linux.org/dist/list.html 0x82c9068 req:[forceAutoEmbed] konqueror: changeViewMode: serviceType is text/html serviceName is current service name is khtml konqueror: KonqView::openURL url=http://www.linux.org/dist/list.html locationBarURL=http://www.linux.org/dist/list.html konqueror: KonqMainWindow::setLocationBarURL: url = http://www.linux.org/dist/list.html khtml (part): KHTMLPart(0x839ca48)::openURL http://www.linux.org/dist/list.html khtml (part): saveState this=0x839ca48 '' saving URL http://www.linux.org/dist/list.html libkonq: ## addToHistory: http://www.linux.org/dist/list.html Typed URL: http://www.linux.org/dist/list.html, Title: konqueror: KonqMainWindow::openView ok=true bOthersFollowed=false returning true kio (Scheduler): Resume metadata is '' kio (Scheduler): HOLD: Reusing held slave for http://www.linux.org/dist/list.html konqueror: KonqMainWindow::slotRunFinished() konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed khtml (html): using compatibility parseMode konqueror: KonqMainWindow::setCaption(Linux Online - List of distributions) khtml (tokenizer): Finished loading an external script khtml (tokenizer): Finished loading an external script khtml (tokenizer): Finished loading an external script khtml (tokenizer): Finished loading an external script khtml (jscript): alarmhandler OK, I can confirm it on my laptop if I slow it down to 600MHz. How fast is your machine, and did you build with optimizations? The slowness seems to be due innerText suckage -- I'll try to see that doing speed ups similar to what I did with innerHTML will help... My box is quiet old, circa 2000 - CPU is AMD Athlon-tbird 1200Mhz. I have 1.5GB RAM. I build KDE with Konstruct using one optimisation only: -march=athlon-tbird on gcc version 3.4.6 I can test any patch you create. Thanks for help, Maksim. Nick Created attachment 18211 [details]
preliminary patch
Preliminary patch. This has some debug output, which will be gone in the final
version -- it tells how much time was spent in that method.. On this machine
before this patch it actually took something like 5-7 seconds, and after
something like 20ms (it's an asymptotic fix). Please let me know if it helps...
(The other machine I tried on was sufficiently beefy not to hit it --- 3GHz
Pentium 4..)
Thanks again for reporting this and the help with the testing..
[There is still some slight freeze on the webpage, I'll see whether I can try
catching it...]
Bloody genius - works PERFECT :-) Great stuff!!! I would mark as resolved, but this is a preliminary patch. Nick OK, I don't run debug (I have $ENV set to off) so timing values I can't see unless I reset all... if you need them. But here is gdb output now with patch applied (tail end): konqueror: Render Style Declaration destroyed konqueror: Render Style Declaration destroyed khtml (css): CSSStyleDeclarationImpl::setProperty invalid property: [padding-bottom] value: [1px;] khtml (css): CSSStyleDeclarationImpl::setProperty invalid property: [padding-bottom] value: [1px;] khtml (css): CSSStyleDeclarationImpl::setProperty invalid property: [padding-bottom] value: [1px;] khtml (jscript): WARNING: Script threw exception: TypeError: Attempted to access 'tagName' property on undefined object (result of expression obj.tagName) khtml (css): CSSStyleDeclarationImpl::setProperty invalid property: [padding-bottom] value: [1px;] konqueror: KonqMainWindow::closeEvent begin konqueror: KonqMainWindow::closeEvent end Nick :-) With debug ON, I get this after page is loaded: spent:107 Nick SVN commit 597736 by orlovich: Fix poor scalability of innerText, making it much faster.. BUG:135988 M +3 -2 html_elementimpl.cpp --- branches/KDE/3.5/kdelibs/khtml/html/html_elementimpl.cpp #597735:597736 @@ -460,7 +460,7 @@ DOMString HTMLElementImpl::innerText() const { - DOMString text = ""; + QString text = ""; if(!firstChild()) return text; @@ -481,7 +481,8 @@ n = next; } if(n->isTextNode() ) { - text += static_cast<const TextImpl *>(n)->data(); + DOMStringImpl* data = static_cast<const TextImpl *>(n)->string(); + text += QConstString(data->s, data->l).string(); } } end: |