Closed
Bug 1372014
Opened 7 years ago
Closed 7 years ago
nsWebBrowserPersist::MakeAndStoreLocalFilenameInURIMap does unnecessary hashtable lookups
Categories
(Core :: DOM: Core & HTML, enhancement, P2)
Core
DOM: Core & HTML
Tracking
()
RESOLVED
FIXED
mozilla56
Tracking | Status | |
---|---|---|
firefox56 | --- | fixed |
People
(Reporter: MatsPalmgren_bugz, Assigned: MatsPalmgren_bugz)
References
Details
(Keywords: perf)
Attachments
(1 file)
(deleted),
patch
|
froydnj
:
review+
|
Details | Diff | Splinter Review |
No description provided.
Assignee | ||
Comment 1•7 years ago
|
||
Attachment #8876509 -
Flags: review?(nfroyd)
Assignee | ||
Comment 2•7 years ago
|
||
FYI, there's also a Put call a little later in this function:
http://searchfox.org/mozilla-central/rev/fee636af734a0ce6dc7335691cc94664bafc385d/dom/webbrowserpersist/nsWebBrowserPersist.cpp#2730,2732,2767
I guess we could replace that by using LookupForAdd instead of Get,
but there are some interleaving returns (NS_ENSURE_SUCCESS)
that makes that tricky. I wonder if it would be worth adding
a "dead-mans-switch" thingy to EntryPtr that would automatically
Remove any new entry in the dtor, unless OrInsert was called...
(Could have used that in 1370674 to avoid the manual Removes.)
Anyway, I don't expect this method to be very hot though...
Updated•7 years ago
|
Attachment #8876509 -
Flags: review?(nfroyd) → review+
Assignee | ||
Comment 3•7 years ago
|
||
(Filed bug 1372333 on adding a Remove() method, automatic or not)
Blocks: 1372333
Pushed by mpalmgren@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/2fe892847030
Remove a redundant hashtable Contains call. r=froydnj
Comment 5•7 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 7 years ago
status-firefox56:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
Updated•6 years ago
|
Component: DOM → DOM: Core & HTML
You need to log in
before you can comment on or make changes to this bug.
Description
•