From: Junio C Hamano <gitster@pobox.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Git Mailing List <git@vger.kernel.org>
Subject: Re: [PATCH] Makefile: introduce NO_PTHREADS
Date: Mon, 17 Nov 2008 08:38:20 -0800 [thread overview]
Message-ID: <7vvdumwbnn.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <alpine.LFD.2.00.0811150915240.3468@nehalem.linux-foundation.org> (Linus Torvalds's message of "Sat, 15 Nov 2008 09:15:52 -0800 (PST)")
Linus Torvalds <torvalds@linux-foundation.org> writes:
> On Sat, 15 Nov 2008, Junio C Hamano wrote:
>>
>> This introduces make variable NO_PTHREADS for platforms that lack the
>> support for pthreads library or people who do not want to use it for
>> whatever reason. When defined, it makes the multi-threaded index
>> preloading into a no-op, and also disables threaded delta searching by
>> pack-objects.
>
> Ack. Makes sense.
Hmm, I started getting random segfaults that sometimes reproduces. For
example, this is what I just got from "git diff --stat $some_commit".
#0 0x00002b952568b090 in strlen () from /lib/libc.so.6
#1 0x000000000044ed42 in git_checkattr (path=0x2b95284b3970 "parse-options.c",
num=3, check=0x41000e90) at attr.c:512
#2 0x0000000000458921 in convert_to_git (
path=0x2b95284b3970 "parse-options.c",
src=0x2aaaaaabb000 <Address 0x2aaaaaabb000 out of bounds>, len=12594,
dst=0x41000f30, checksafe=SAFE_CRLF_FALSE) at convert.c:578
#3 0x0000000000489ac3 in index_mem (
sha1=0x41000ff0 "\210f�⽡x�\207�� 7R}\217\032��", buf=0x2aaaaaabb000,
size=12594, write_object=0, type=<value optimized out>,
path=0x2f2f2f2f2f2f2f2f <Address 0x2f2f2f2f2f2f2f2f out of bounds>)
at sha1_file.c:2451
#4 0x0000000000489c3d in index_fd (
sha1=0x41000ff0 "\210f�⽡x�\207�� 7R}\217\032��", fd=5,
st=<value optimized out>, write_object=0, type=OBJ_BLOB,
path=0x2b95284b3970 "parse-options.c") at sha1_file.c:2483
#5 0x000000000047857a in ce_modified_check_fs (ce=0x2b95284b3930,
st=0x41001080) at read-cache.c:92
#6 0x00000000004786a2 in ie_match_stat (istate=0x71c860, ce=0x2b95284b3930,
st=0x41001080, options=<value optimized out>) at read-cache.c:282
#7 0x0000000000497e65 in preload_thread (_data=<value optimized out>)
at preload-index.c:46
#8 0x00002b9525964017 in start_thread () from /lib/libpthread.so.0
#9 0x00002b95256da5bd in clone () from /lib/libc.so.6
#10 0x0000000000000000 in ?? ()
I suspect that the callpath around ce_modified_check_fs() uses a buffer
obtained from path.c:get_pathname() and parallel threads stomp on each
other, but I do not have time to debug this right now (I will be on a
14-hour flight in a few hours).
next prev parent reply other threads:[~2008-11-17 16:41 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-12 9:29 hosting git on a nfs Thomas Koch
2008-11-12 10:10 ` Julian Phillips
2008-11-12 20:31 ` Brandon Casey
2008-11-12 17:36 ` David Brown
2008-11-12 18:14 ` Linus Torvalds
2008-11-13 18:18 ` J. Bruce Fields
2008-11-13 18:32 ` James Pickens
2008-11-13 20:18 ` Linus Torvalds
2008-11-13 21:05 ` Linus Torvalds
2008-11-13 23:23 ` James Pickens
2008-11-13 23:48 ` Linus Torvalds
2008-11-13 23:23 ` Julian Phillips
2008-11-13 23:42 ` Linus Torvalds
2008-11-14 0:04 ` Julian Phillips
2008-11-14 0:14 ` Brandon Casey
2008-11-14 0:38 ` Linus Torvalds
2008-11-14 0:59 ` Pieter de Bie
2008-11-14 1:15 ` Linus Torvalds
2008-11-14 3:33 ` James Pickens
2008-11-14 5:01 ` Linus Torvalds
2008-11-14 13:01 ` Michael J Gruber
2008-11-14 14:31 ` Kyle Moffett
2008-11-14 18:32 ` Brandon Casey
2008-11-14 19:23 ` Linus Torvalds
2008-11-14 20:14 ` Junio C Hamano
2008-11-14 23:10 ` Linus Torvalds
2008-11-15 12:08 ` [PATCH] Makefile: introduce NO_PTHREADS Junio C Hamano
2008-11-15 17:15 ` Linus Torvalds
2008-11-17 10:03 ` Mike Ralphson
2008-11-17 10:18 ` Junio C Hamano
2008-11-17 10:34 ` Johannes Sixt
2008-11-17 10:45 ` Mike Ralphson
2008-11-17 11:25 ` Johannes Sixt
2008-12-01 8:29 ` Johannes Sixt
2008-12-01 8:48 ` dhruva
2008-12-01 9:57 ` Mike Ralphson
2008-12-01 16:09 ` Mike Ralphson
2008-12-01 16:13 ` Mike Ralphson
2008-12-02 7:41 ` Johannes Sixt
2008-12-03 2:18 ` Junio C Hamano
2008-11-17 16:38 ` Junio C Hamano [this message]
2008-11-17 16:47 ` Linus Torvalds
2008-11-17 17:01 ` Fix index preloading for racy dirty case Linus Torvalds
2008-11-17 16:41 ` [PATCH] Makefile: introduce NO_PTHREADS Junio C Hamano
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=7vvdumwbnn.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=torvalds@linux-foundation.org \
/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).