git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] pack-objects: only throw away data during memory pressure

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Feb 11, 2008, 16:08 UTC
Message-ID
<alpine.LSU.1.00.0802111606440.3870@racer.site>
In-Reply-To
<alpine.LFD.1.00.0802111054080.2732@xanadu.home>
Hi,
On Mon, 11 Feb 2008, Nicolas Pitre wrote:
Show 26 quoted lines
> On Mon, 11 Feb 2008, Johannes Schindelin wrote:
> 
> > On Mon, 11 Feb 2008, Martin Koegler wrote:
> > 
> > > What about this not really tested patch for dealing with memory 
> > > pressure in git-pack-objects?
> > > 
> > > It will slow down the repack in the case of memory pressure, but 
> > > missing memory will not affect the results.
> > 
> > It almost helped:
> > 
> > $ /usr/bin/time git repack -a -d -f --window=250 --depth=250
> > Counting objects: 2477715, done.
> > fatal: Out of memory, malloc failed411764)
> > Command exited with non-zero status 1
> > 10050.12user 240.63system 2:53:37elapsed 98%CPU (0avgtext+0avgdata 
> > 0maxresident)k
> > 0inputs+0outputs (29555major+94032945minor)pagefaults 0swaps
> > 
> > So, it ran longer until it ran out of memory.
> 
> What it can do for you is to limit the window memory usage much more 
> without affecting the end result, say to 128MB.  Of course the repack is 
> then going to progress much slower if active purging of the window 
> memory is involved.

Oh, well. I did not think of setting a smaller windowMemory. Will try that next.

> If you still run out of memory at that point then there is not much more 
> to do besides using a new memory allocator that doesn't suffer as much 
> from memory fragmentation, or find the possible memory leak that no one 
> else found so far.

Completely forgot to say: I am running with ememoa (that is the Google allocator, right?).

Ciao, Dscho

Previous: Nicolas PitreNext: Nicolas Pitre
Message 4 of 12 in “pack-objects: only throw away data during memory pressure”
  1. pack-objects: only throw away data during memory pressureMartin Koegler, Feb 11, 2008
  2. Johannes SchindelinFeb 11, 2008
  3. Nicolas PitreFeb 11, 2008
  4. Johannes SchindelinFeb 11, 2008
  5. Nicolas PitreFeb 11, 2008
  6. Brian DowningFeb 12, 2008
  7. Nicolas PitreFeb 12, 2008
  8. Brian DowningFeb 12, 2008
  9. Brian DowningFeb 12, 2008
  10. Brian DowningFeb 12, 2008
  11. Nicolas PitreFeb 12, 2008
  12. Nicolas PitreFeb 13, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.