Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(380)

Issue 8005001: Reserve space before building potentially large vectors in safe-browsing. (Closed)

Created:
9 years, 3 months ago by Scott Hess - ex-Googler
Modified:
9 years, 3 months ago
CC:
chromium-reviews
Visibility:
Public.

Description

Reserve space before building potentially large vectors in safe-browsing. In cases where we can approximate the vector size in advance, reserve() that much space rather than building organically. BUG=97102 TEST=Reduction in crash rate for that bug. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=102435

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+11 lines, -0 lines) Patch
M chrome/browser/safe_browsing/prefix_set.cc View 2 chunks +9 lines, -0 lines 0 comments Download
M chrome/browser/safe_browsing/safe_browsing_database.cc View 2 chunks +2 lines, -0 lines 2 comments Download

Messages

Total messages: 6 (0 generated)
Scott Hess - ex-Googler
The change in PrefixSetFromAddPrefixes() is the main one, it's almost certain that it's doing like ...
9 years, 3 months ago (2011-09-22 20:39:41 UTC) #1
noelutz
lgtm http://codereview.chromium.org/8005001/diff/1/chrome/browser/safe_browsing/safe_browsing_database.cc File chrome/browser/safe_browsing/safe_browsing_database.cc (right): http://codereview.chromium.org/8005001/diff/1/chrome/browser/safe_browsing/safe_browsing_database.cc#newcode1189 chrome/browser/safe_browsing/safe_browsing_database.cc:1189: std::vector<SBAddFullHash> pending_add_hashes; What about this vector? Were you ...
9 years, 3 months ago (2011-09-22 21:14:09 UTC) #2
Scott Hess - ex-Googler
thanks! http://codereview.chromium.org/8005001/diff/1/chrome/browser/safe_browsing/safe_browsing_database.cc File chrome/browser/safe_browsing/safe_browsing_database.cc (right): http://codereview.chromium.org/8005001/diff/1/chrome/browser/safe_browsing/safe_browsing_database.cc#newcode1189 chrome/browser/safe_browsing/safe_browsing_database.cc:1189: std::vector<SBAddFullHash> pending_add_hashes; On 2011/09/22 21:14:09, noelutz wrote: > ...
9 years, 3 months ago (2011-09-22 21:23:09 UTC) #3
noelutz
lgtm On Thu, Sep 22, 2011 at 2:23 PM, <shess@chromium.org> wrote: > thanks! > > ...
9 years, 3 months ago (2011-09-22 21:30:57 UTC) #4
commit-bot: I haz the power
CQ is trying tha patch. Follow status at https://chromium-status.appspot.com/cq/shess@chromium.org/8005001/1
9 years, 3 months ago (2011-09-23 01:07:00 UTC) #5
commit-bot: I haz the power
9 years, 3 months ago (2011-09-23 03:27:57 UTC) #6
Change committed as 102435

Powered by Google App Engine
This is Rietveld 408576698