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

Issue 6677141: Switch out use of std::string and std::vector for large allocations for a buffer class that doesn... (Closed)

Created:
9 years, 8 months ago by tommi (sloooow) - chröme
Modified:
9 years, 7 months ago
Reviewers:
grt (UTC plus 2)
CC:
chromium-reviews, Paweł Hajdan Jr.
Visibility:
Public.

Description

Switch out use of std::string and std::vector for large allocations for a buffer class that doesn't throw exceptions. The new buffer class is pretty simple and relies on the MemoryAllocator class that I previously to back large allocations with mapped files when memory is scarce. That reduced the number of crashes quite a bit but we still crash on machines that are simply out of diskspace as well. So, the right thing to do is to expect and handle failures which is what this cl is all about. What we should see once this has landed is that crash dumps due to courgette running out of disk space should disappear from crash/ and instead we should see the number of users that run into this particular problem in dashboards. TEST=Courgette out-of-memory/out-of-diskspace errors should disappear from crash/ BUG=74777 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=80648

Patch Set 1 #

Total comments: 42

Patch Set 2 : '' #

Total comments: 6

Patch Set 3 : '' #

Patch Set 4 : fix linux build error. remove unnecessary call #

Unified diffs Side-by-side diffs Delta from patch set Stats (+565 lines, -298 lines) Patch
M chrome/installer/setup/setup_main.cc View 1 1 chunk +2 lines, -1 line 0 comments Download
M chrome/installer/setup/setup_util.cc View 1 chunk +10 lines, -1 line 0 comments Download
M chrome/installer/util/util_constants.h View 1 1 chunk +1 line, -0 lines 0 comments Download
M courgette/adjustment_method.cc View 1 3 chunks +3 lines, -3 lines 0 comments Download
M courgette/adjustment_method_2.cc View 1 2 chunks +2 lines, -2 lines 0 comments Download
M courgette/adjustment_method_unittest.cc View 1 2 chunks +7 lines, -7 lines 0 comments Download
M courgette/assembly_program.h View 1 2 7 chunks +15 lines, -11 lines 0 comments Download
M courgette/assembly_program.cc View 1 5 chunks +40 lines, -20 lines 0 comments Download
M courgette/courgette_tool.cc View 1 2 chunks +29 lines, -10 lines 0 comments Download
M courgette/disassembler.cc View 1 2 9 chunks +42 lines, -26 lines 0 comments Download
M courgette/encode_decode_unittest.cc View 1 2 chunks +2 lines, -2 lines 0 comments Download
M courgette/encoded_program.h View 1 2 4 chunks +18 lines, -16 lines 0 comments Download
M courgette/encoded_program.cc View 1 2 8 chunks +70 lines, -84 lines 0 comments Download
M courgette/ensemble_apply.cc View 1 2 chunks +3 lines, -1 line 0 comments Download
M courgette/ensemble_create.cc View 1 3 chunks +14 lines, -13 lines 0 comments Download
M courgette/memory_allocator.h View 1 2 12 chunks +252 lines, -29 lines 0 comments Download
M courgette/memory_allocator.cc View 1 6 chunks +33 lines, -42 lines 0 comments Download
M courgette/streams.h View 1 2 4 chunks +13 lines, -19 lines 0 comments Download
M courgette/streams.cc View 1 2 3 4 chunks +3 lines, -6 lines 0 comments Download
M courgette/win32_x86_generator.h View 1 chunk +5 lines, -2 lines 0 comments Download
M courgette/win32_x86_patcher.h View 1 2 chunks +1 line, -3 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
tommi (sloooow) - chröme
9 years, 8 months ago (2011-04-04 20:49:55 UTC) #1
grt (UTC plus 2)
Looks good. It'll be nice to have proper dashboard reporting of the memory problems rather ...
9 years, 8 months ago (2011-04-05 17:10:08 UTC) #2
tommi (sloooow) - chröme
In addition to addressing comments I have added two installer files to the cl as ...
9 years, 8 months ago (2011-04-05 19:06:53 UTC) #3
tommi (sloooow) - chröme
ok - changes uploaded. ptal. On Tue, Apr 5, 2011 at 3:06 PM, <tommi@chromium.org> wrote: ...
9 years, 8 months ago (2011-04-05 21:50:15 UTC) #4
grt (UTC plus 2)
Would you be terribly annoyed if I asked you to use WARN_UNUSED_RESULT on all methods ...
9 years, 8 months ago (2011-04-06 02:46:38 UTC) #5
tommi (sloooow) - chröme
not at all. done. http://codereview.chromium.org/6677141/diff/6006/courgette/memory_allocator.h File courgette/memory_allocator.h (right): http://codereview.chromium.org/6677141/diff/6006/courgette/memory_allocator.h#newcode102 courgette/memory_allocator.h:102: __declspec(noinline) On 2011/04/06 02:46:38, grt ...
9 years, 8 months ago (2011-04-06 13:50:02 UTC) #6
grt (UTC plus 2)
9 years, 8 months ago (2011-04-06 17:27:47 UTC) #7
LGTM

Powered by Google App Engine
This is Rietveld 408576698