Closed Bug 130295 Opened 23 years ago Closed 21 years ago

Mozilla loads this site very slowly; 100% CPU for >30 secs

Categories

(Core :: DOM: Core & HTML, defect)

x86
All
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME

People

(Reporter: marka, Unassigned)

References

()

Details

(Keywords: perf)

Attachments

(1 file)

Build ID: 2002031008 (Mozilla 0.9.9 release build) To reproduce: ============= Surf to www.home.se. What happens? ============= Mozilla hangs in "transferring" mode, when having layed out most of the page. When moving the window, it doesn't get repainted.
The page has two nested <body> tags. Yuck!
well... in 2002031103/WinXP the page is usable and scollable and get repainted very well. still the status bar always states 'transferring' which certainly is a bug. still it does not break anything. but comment 1 it is true: the page is assembled via JSP, and it seems to me, that the author(s) just embed a complete HTML-page as content into a framework of links and such stuff. this is because the page contains a complete 2nd set of html and body tags (and their corresponding closing tags). (it is completly invalid html... as we find too much on the web), and the point (unusability of the page) does not exist (at least on WinXP). it's only the status bar message. so i will leave this bug as it is and leave it for someone else to check with a newer linux-build and then think about what to do.
Sorry for not being clear in my bug description. This is a serious browser hang (on linux). I just meant that the statusbar says 'transferrring', but that's not too strange since the browser is completely hanged.
Keywords: hang
I just noticed that the browser gets usable again after ~1 minute of ~85% cpu utilization (it is *NOT* responsive at all during this time).
I found this to be a javascript problem on the specified site. It uses a lot of javascript in order to create menus and submenus etc. I can no longer reproduce this when having commented out the foldInit() function in home_ns.js (downloaded site locally). The question is wheather this type of browser behaviour is acceptable, but that's another matter.
Keywords: hang
happens in linux and win NT Phil, I think this is a problem with the site but not sure.
Status: UNCONFIRMED → NEW
Component: Networking → JavaScript Engine
Ever confirmed: true
OS: Linux → All
-> JavaScript Engine
Assignee: new-network-bugs → rogerl
QA Contact: benc → pschwartau
By stepping through this in the JS Debugger, most of the time seems to be taken up by this function: /******************************************************************** Initiating the page and making the menu *********************************************************************/ function foldInit(){ //Creating the foldoutmenu oFold=new Array(); y=0 for(i=0;i<mainmenus;i++){ oFold[i]=new makeMenu('divFold'+i,'divFoldCont') oFold[i].moveIt(0,y); oFold[i].size=oFold[i].height y+=oFold[i].height+pxbetweenmain oFold[i].sub=new Array() oFold[i].subs=top_subs; suby=oFold[i].height+pxbetweensub for(j=0;j<submenus[i];j++){ oFold[i].sub[j]=new makeMenu('divFoldSub'+i+'_'+j,'divFoldCont.document.divFold'+i) oFold[i].sub[j].sub=new makeMenu('divFoldSub'+i+'_'+j+'_0','divFoldCont.document.divFold'+i+'.document.d ivFoldSub'+i+'_'+j) oFold[i].sub[j].hideIt(); oFold[i].sub[j].sub.hideIt() oFold[i].sub[j].moveIt(10,suby) suby+=oFold[i].sub[j].height+pxbetweensub } } oFoldCont=new makeMenu('divFoldCont') oFoldCont.showIt() //Showing the menu when the menu have been "created" if (location.search.indexOf("menu=") != 0) foldmenu(location.search[location.search.indexOf("menu=")+5]); } where we have: function makeMenu(obj,nest){ nest=(!nest) ? '':'document.'+nest+'.' this.css=bw.dom? document.getElementById(obj).style:bw.ie4?document.all[obj].style:bw.ns4?eval(ne st+"document.layers." +obj):0; this.el=bw.dom?document.getElementById(obj):bw.ie4?document.all[obj]:bw.ns4?eval (nest+'document.'+obj):0; this.ref=bw.dom || bw.ie4? document:bw.ns4?eval(nest+"document.layers." +obj+".document"):0; this.x=(bw.ns4 || bw.ns5)? this.css.left:this.css.pixelLeft; this.y=(bw.ns4 || bw.ns5)? this.css.top:this.css.pixelTop; this.height=bw.ns4?this.ref.height:this.el.offsetHeight; this.hideIt=b_hideIt; this.showIt=b_showIt; this.moveIt=b_moveIt this.status=0; return this }
I will attach the JS file below which contains this function. Meanwhile, I'm going to reassign this as a DHMTL performance issue. AFAICT in the JS Debugger, I don't see pure JS Engine problems. cc'ing self -
Assignee: rogerl → jst
Component: JavaScript Engine → DOM Level 0
Keywords: perf
QA Contact: pschwartau → desale
Summary: Mozilla hangs on home.se → Mozilla loads this site very slowly; 100% CPU for >30 secs
Attached file home_ns.js
-> js debugger.
Component: DOM Level 0 → JavaScript Debugger
OS: All → Linux
Back to DOM 0; this has nothing to do with the JS Debugger.
Component: JavaScript Debugger → DOM Level 0
OS: Linux → All
Mass-reassigning bugs to dom_bugs@netscape.com
Assignee: jst → dom_bugs
The HTML is still horrible but Firebird0.6.1 loads it in 2 seconds for me on win2k. Can anyone on linux re-test this please? Thanks!
The HTML appears to have been cleared up; Marking WFM as there are no issues with it on this build : Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7) Gecko/20040510 Firefox/0.8.0+ (Lohvarn); reporter- please re-open if you see the issues with a more recent build + new profile.
Status: NEW → RESOLVED
Closed: 21 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: