If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

UpdateEditableState is expensive during subtree appends

NEW
Unassigned

Status

()

Core
DOM: Core & HTML
6 years ago
6 years ago

People

(Reporter: bz, Unassigned)

Tracking

({perf})

Trunk
x86
Mac OS X
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

When appending large subtrees, the UpdateEditableState calls we do on each node are pretty expensive.  In my profiling, they're about 17% of the cost of the append.  The testcases in bug 700981 show it pretty nicely.  This is on gcc-4.2, though.

The issue is that we have to do a virtual call, land in nsGenericHTMLElement::UpdateEditableState, have to call up to nsGenericElement::UpdateEditableState, etc.  Most of the cost is the various function call overhead.  Not sure what we can do here; ideally we'd get to the point where we can effectively inline UpdateEditableState at compile time into nsGenericElement::BindToTree...
Blocks: 700981
Keywords: perf
You need to log in before you can comment on or make changes to this bug.