From: Andreas Ericsson <ae@op5.se>
To: Guo Tang <tangguo77@gmail.com>
Cc: Git mailing list <git@vger.kernel.org>
Subject: Re: out of memory problem
Date: Mon, 22 Sep 2008 09:32:07 +0200 [thread overview]
Message-ID: <48D749F7.3030008@op5.se> (raw)
In-Reply-To: <alpine.LFD.2.00.0809211556030.19373@homelinux>
Guo Tang wrote:
> Gentlemen,
>
> I try to run "git gc" on linux kernel tree. The virtual memory keeps
> going up until over 3GB, then crash.
> Tried twice with the v1.6.0.2, same result.
> Then I used the git coming with FC9 (v1.5.5.1), the peak virutal memory
> usage is about 1.5GB. "git gc" finished without any trouble.
>
> Could there be a memory leak in v1.6.0.2?
>
There could be, but most likely it's commit
38bd64979a2a3ffa178af801c6a62e6fcd658274 (Enable threaded delta
search on BSD and Linux). Do you have multiple cpu's in the
computer where 'git gc' was running? If so, and if you've set
pack.threads = 0, or --threads=0 it will autodetect the number
of CPU's you have and then saturate all of them with work. Each
thread will however consume memory close to that of a single
process running the repack, so for large repositories you might
want to set pack.threads = 1 in such large repositories.
It's a shame you didn't save the unpacked repository, or this could
have been properly debugged. While it's possible there is a memory
leak, it's a dismal project trying to locate it by staring at the
code, and the time it takes to repack huge repositories with memory
intensive parameters is sort of prohibitive for finding the possible
leak by bisection.
--
Andreas Ericsson andreas.ericsson@op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
next prev parent reply other threads:[~2008-09-22 7:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-21 22:59 out of memory problem Guo Tang
2008-09-22 7:32 ` Andreas Ericsson [this message]
[not found] ` <4120f6ec0809220828i3b38eda3tfc4974df8a2568cb@mail.gmail.com>
2008-09-23 7:50 ` Andreas Ericsson
2008-09-24 16:45 ` guo tang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=48D749F7.3030008@op5.se \
--to=ae@op5.se \
--cc=git@vger.kernel.org \
--cc=tangguo77@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).