canmove, Confirmed users
2,056
edits
(first version of what I learned optimizing the site-specific full zoom setting with DTrace) |
m (→Tips) |
||
| Line 71: | Line 71: | ||
} | } | ||
} | } | ||
* Inline logic that gets called frequently to | * Inline logic that gets called frequently to eliminate the cost of function invocation. | ||
* Dig into costly XBL and native code, since it might be | * Dig into costly XBL and native code, since it might be doing unnecessary work. For example, when optimizing the site-specific full zoom setting, I found that browser.xml wasn't memoizing its frequently-accessed <tt>_docShell</tt> property, even though the value of that property doesn't change over the lifetime of a browser widget, and I also found that <tt>nsPresContext::SetFullZoom</tt> was doing some unnecessary work when the new value was the same as the old one. | ||
== Bugs == | == Bugs == | ||