summaryrefslogtreecommitdiffstats
path: root/courgette/ensemble_apply.cc
Commit message (Collapse)AuthorAgeFilesLines
* Switch out use of std::string and std::vector for large allocations for a ↵tommi@chromium.org2011-04-061-1/+3
| | | | | | | | | | | | | | | | | 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 Review URL: http://codereview.chromium.org/6677141 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80648 0039d316-1c4b-4281-b951-d872f2087c98
* Identifying call sites that need to handle out of memory situations in ↵tommi@chromium.org2011-03-221-2/+5
| | | | | | | | | | | | | | | | | Courgette. There's no functional change here, only interface changes: * Change methods that are known to fail out in the field to return bool instead of void. * Where those methods are called, check the return value and report errors * In debug builds use a specialized template class that forces callers to check return values (this is possible at compile time in gcc, but unfortunately not in VS). The next step will be to change the implementation to not use STL containers. TEST=Run courgette tests. BUG=74777 Review URL: http://codereview.chromium.org/6716006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@79030 0039d316-1c4b-4281-b951-d872f2087c98
* Implementation of an STL compatible allocator for Courgette on Windows.tommi@chromium.org2011-03-011-26/+8
| | | | | | | | | | | | | | | | | This is to better handle low memory situations when applying a differential patch to a large Chrome setup. For reading input files, I'm also switching to using memory mapped files instead of ReadFileToString to reduce the load on the heap. TEST=courgette.exe should succeed in applying a patch between two chrome 10.x archives on an XP machine with 180MB of physical memory and no page file. BUG=72459,73209 Review URL: http://codereview.chromium.org/6597038 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@76320 0039d316-1c4b-4281-b951-d872f2087c98
* Improved memory usage while applying patch.sra@chromium.org2011-02-231-1/+20
| | | | | | | | | | | | | | | | | | | | | | | Reduced total size of allocations from 520MB to 318MB. The general technique is to allocate the correct size rather than grow into the correct size and overshoot. 1. Find file sizes and allocate buffers of that size for the input files. 2. Pre-allocate a buffer for the collected inputs for the final diff. 3. Calculate the size for (2) during compression and include it in the patch header. The courgette.exe command line tool now calls the same ApplyEnsemblePatch entry point that is called by the installer. This ensures measurements of courgette.exe are a better reflection of the installer. BUG=72459 Review URL: http://codereview.chromium.org/6546008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@75787 0039d316-1c4b-4281-b951-d872f2087c98
* Also build a 64-bit exe version of the 32-bit courgettebradnelson@google.com2010-12-211-1/+1
| | | | | | | | | | | | utility + library to support larger input sizes. BUG=63793 TEST=None Review URL: http://codereview.chromium.org/5096007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@69779 0039d316-1c4b-4281-b951-d872f2087c98
* FBTF: Remove unneeded headers from base/ (part 7)thestig@chromium.org2010-08-271-2/+1
| | | | | | | | BUG=none TEST=none Review URL: http://codereview.chromium.org/3176026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@57737 0039d316-1c4b-4281-b951-d872f2087c98
* Code changes to get the code to compile under GCC.sra@google.com2009-07-181-4/+4
| | | | | | | | | | | | Courgette still only knows how to compress Windows x86 executables. But now you can compress them on linux. BUG=none TEST=none Review URL: http://codereview.chromium.org/149597 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21042 0039d316-1c4b-4281-b951-d872f2087c98
* Move Courgettesra@chromium.org2009-05-081-0/+412
from src\third_party\courgette to src\courgette and src\courgette\third_party Fixed #includes Added properties to ignore generated files: C:\c5\src>svn pg svn:ignore courgette courgette.xcodeproj courgette.sln courgette_fuzz.vcproj courgette_lib.vcproj courgette_minimal_tool.vcproj courgette_tool.vcproj courgette.vcproj courgette_unittests.vcproj SConstruct courgette_fuzz.scons courgette_lib.scons courgette_main.scons courgette_minimal_tool.scons courgette.scons courgette_tool.scons courgette_unittests.scons Review URL: http://codereview.chromium.org/115062 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15692 0039d316-1c4b-4281-b951-d872f2087c98