Open
Bug 585621
Opened 14 years ago
Updated 1 year ago
Stop doing 1-byte detection for the text passed to createTextNode
Categories
(Core :: DOM: Core & HTML, defect, P5)
Tracking
()
NEW
People
(Reporter: bzbarsky, Unassigned)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
(deleted),
patch
|
bzbarsky
:
review-
|
Details | Diff | Splinter Review |
This is meant to be a memory and layout-time optimization, but it hurts us on DOM benchmarks, and it's not common to have large amounts of text passed to createTextNode and then rendered, which is when the optimization would perhaps matter.
We should just assume that text passed to createTextNode should be stored as 2-byte text.
Comment 1•14 years ago
|
||
So, what's the scope of this bug? nsDocument::CreateTextNode just calls NS_NewTextNode and then calls SetText on it. Is this going to be similar to bug 582858?
Reporter | ||
Comment 2•14 years ago
|
||
> So, what's the scope of this bug?
Storing the text passed to createTextNode as UTF-16. Nothing else.
> Is this going to be similar to bug 582858?
That bug subsumes this one, but not vice versa, clearly.
I ran the numbers; our current score on dromaeo's createTextNode is 80. With this patch it goes up to 100. Safari is at 280 or so, but it doesn't do any string copying at all during this operation (well past perhaps flattening their js string), unlike us.
Reporter | ||
Comment 3•14 years ago
|
||
Attachment #464097 -
Flags: review?(jst)
Reporter | ||
Comment 4•14 years ago
|
||
And clearly, if we decide to do bug 582858 we don't need this.
Comment 5•14 years ago
|
||
Comment on attachment 464097 [details] [diff] [review]
Patch that I was testing
I assume this doesn't handle bidi properly.
Reporter | ||
Comment 6•14 years ago
|
||
Comment on attachment 464097 [details] [diff] [review]
Patch that I was testing
Ah, indeed. We should just make the bidi stuff a tristate and call SetBidiStatus in BindToTree if we want to make that work, imo.
Attachment #464097 -
Flags: review?(jst) → review-
Comment 7•6 years ago
|
||
https://bugzilla.mozilla.org/show_bug.cgi?id=1472046
Move all DOM bugs that haven’t been updated in more than 3 years and has no one currently assigned to P5.
If you have questions, please contact :mdaly.
Priority: -- → P5
Assignee | ||
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•