Closed
Bug 149702
Opened 23 years ago
Closed 23 years ago
[PATCH] Pre-Size nsXMLMIMEDataSource::mInfoArray before appending elements to it
Categories
(SeaMonkey :: General, defect)
SeaMonkey
General
Tracking
(Not tracked)
VERIFIED
INVALID
People
(Reporter: paper, Assigned: paper)
Details
(Keywords: perf)
Attachments
(1 file, 1 obsolete file)
|
1.58 KB,
patch
|
Biesinger
:
review+
|
Details | Diff | Splinter Review |
mInfoArray currently contains 24 elements (23 ifndef MOZ_SVG). This list is
static, so why not init the array to 24 before appending. nsSupportsArray grows
its array size by increments of 8. This'll save 2 grow calls.
I really don't know what impact removing 2 grow calls have, but it's a
optimization, nonetheless!
| Assignee | ||
Comment 1•23 years ago
|
||
| Assignee | ||
Updated•23 years ago
|
Summary: Pre-Size mInfoArray before appending elements to it → Pre-Size nsXMLMIMEDataSource::mInfoArray before appending elements to it
Comment 2•23 years ago
|
||
Thanks for the patch...Marking NEW for patch review and goodness.
| Assignee | ||
Comment 4•23 years ago
|
||
Benjamin, I put it in Networking only because nsXMLMIMEDataSource is in
the /mozilla/netwerk/ directory. If you have a better component for it, don't
hesitate to move it! :)
-> browser-general, b/c matti knows all.
Assignee: new-network-bugs → Matti
Component: Networking → Browser-General
QA Contact: benc → imajes-qa
| Assignee | ||
Comment 6•23 years ago
|
||
Attachment #86680 -
Attachment is obsolete: true
Comment 7•23 years ago
|
||
Comment on attachment 87268 [details] [diff] [review]
Set Initial Size of mInfoObjects and mInfoArray to size of static list
r=biesi
I trust that you your count is correct
Attachment #87268 -
Flags: review+
Comment 9•23 years ago
|
||
Comment on attachment 87268 [details] [diff] [review]
Set Initial Size of mInfoObjects and mInfoArray to size of static list
patch seems fine, but is this code actually run?
uriloader/exthandler/nsExternalHelperAppService overrides necko's impl of
nsIMIMEService, which is the only code that uses nsXMLMIMEDataSource (or so i
thought).
sr=darin if you verify that this code is actually used by mozilla.
| Assignee | ||
Comment 10•23 years ago
|
||
Darin, I asked that same question a day after I created the patch. I haven't
had time yet to look into it, but it's on my list of todos. I always assumed
it ran, but haven't seen any obvious way it is. If it isn't run, the static
list is just silly and causes one more step in adding a mimetype (a image
decoder, for example)
Comment 11•23 years ago
|
||
per bug 172963 sounds like this file is indeed unused. could be WONTFIX or
INVALID, going for the second.
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → INVALID
| Assignee | ||
Comment 12•22 years ago
|
||
nsXMLMIMEDataSource.cpp is now been cvs removed.. verifying invalid :)
Status: RESOLVED → VERIFIED
Updated•20 years ago
|
Product: Browser → Seamonkey
You need to log in
before you can comment on or make changes to this bug.
Description
•