Closed Bug 599587 Opened 14 years ago Closed 14 years ago

Be smarter about our string buffer caching in document encoder

Categories

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

x86
macOS
defect

Tracking

()

RESOLVED FIXED
mozilla2.0b7

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

(Blocks 1 open bug)

Details

Attachments

(1 file, 1 obsolete file)

Right now we always make a copy into the output string, even if we plan to not cache the stringbuffer.  We should just use it in those cases instead.
Blocks: domperf
Attached patch Proposed fix (obsolete) — Splinter Review
Comment on attachment 478515 [details] [diff] [review]
Proposed fix

This does seem to speed up the Zimbra preferences tests by a percent or maybe two.... hard to tell with all the noise.  :(
Attachment #478515 - Flags: review?(Olli.Pettay)
Priority: -- → P1
Whiteboard: [need review]
Comment on attachment 478515 [details] [diff] [review]
Proposed fix

There is now 2 if (mCachedBuffer) checks.
Could you add an |if (mCachedBuffer)| around the if-else.
Attachment #478515 - Flags: review?(Olli.Pettay) → review+
Attachment #478515 - Attachment is obsolete: true
Attached patch With that changeSplinter Review
Comment on attachment 481150 [details] [diff] [review]
With that change

Looking for approval for this performance fix
Attachment #481150 - Flags: approval2.0?
Whiteboard: [need review] → [need approval]
Attachment #481150 - Flags: approval2.0? → approval2.0+
Whiteboard: [need approval] → [need landing]
Pushed http://hg.mozilla.org/mozilla-central/rev/d2e74747a42f
Status: NEW → RESOLVED
Closed: 14 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b8
Whiteboard: [need landing]
Target Milestone: mozilla2.0b8 → mozilla2.0b7
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: