Closed Bug 91669 Opened 24 years ago Closed 24 years ago

Don't use sprintf to convert int->string

Categories

(Core :: Layout, defect)

defect
Not set
trivial

Tracking

()

VERIFIED FIXED
mozilla0.9.4

People

(Reporter: bratell, Assigned: bratell)

Details

(Keywords: perf, Whiteboard: [fix in hand needing review] (three liner))

Attachments

(1 file)

sprintf is used in nsGfxScrollFrame to convert from int to string. There is an excellent AppendInt method that does it much faster. This saves like 1 or even 2(!) ms of a typical page load. Patch coming up. I can take a r= and sr= any day.
Severity: normal → trivial
Keywords: perf
Target Milestone: --- → mozilla0.9.3
[s]r=attinas on patch 43021 - thanks!
Keywords: review
Whiteboard: [fix in hand needing review] (three liner)
I need to sleep and the tree closes before I'm up again so this will have to wait for the next train. -> 0.9.4
Status: NEW → ASSIGNED
Target Milestone: mozilla0.9.3 → mozilla0.9.4
r=dbaron, although AppendInt is part of string/obsolete, so it may go away at some time (hopefully with some replacement in string/public). However, cc:ing scc to note that there is a demand for it for peformance reasons.
Fix checked in
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Since I 'm not exactly sure how to test this, I'm marking verified based on the last comments.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: