Opened 13 years ago

Last modified 12 years ago

#9114 closed enhancement

crazy taskspeed numbers on IE vs. "pure-dom" version — at Version 1

Reported by: alex Owned by: alex
Priority: high Milestone: 1.4
Component: Core Version: 1.3.0
Keywords: performance, taskspeed, ie, ie6, ie7 Cc: jamestag, dante, wildbill
Blocked By: Blocking:

Description (last modified by Eugene Lazutkin)

There's something really funky going on with our TaskSpeed results on IE 6. It seems that calls like "dojo.byId" are going incredibly slowly when defined inside of Dojo, but when referenced with local aliases, they speed up dramatically. This is most pronounced on the addclass-odd test. The cause deserves more investigation, but the short-term outcome is that creating local aliases for things which don't need "this" references interally can speed up IE dramatically.

Change History (1)

comment:1 Changed 13 years ago by Eugene Lazutkin

Description: modified (diff)

Probably you forgot that Bill complained about a similar problem (or maybe this very problem) during the last dojo meeting. According to him there is a measurable difference between using properties on dojo and mydojo, where the latter is defined something like this:

// let's copy dojo
var mydojo = dojo.mixin({}, dojo);

My uneducated guess was that while building dojo a hash table underneath got overflown several times leading to a degraded structure (e.g., multiple linear lists to hold chunks, overflown hash chains, or excessive holes). Apparently the problem is solved by copying, which leads to some compacting under the hood.

I promised to investigate the problem and get some solid benchmark data first. It looks like you already started on the path to the solution. Let me know if you want to investigate it on your own, so I'll work on something else from my plate.

Note: See TracTickets for help on using tickets.