Re: Make the git codebase thread-safe

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Feb 15, 2014 at 8:15 AM, Zachary Turner <zturner@xxxxxxxxxxxx> wrote:
> Even if we make that change to use TLS for this case, the
> implementation of pread() will still change in such a way that the
> semantics of pread() are different on Windows.  Is that ok?
>
> Just to summarize, here's the viable approaches I've seen discussed so far:
>
> 1) Use _WINVER at compile time to select either a thread-safe or
> non-thread-safe implementation of pread.  This is the easiest possible
> code change, but would necessitate 2 binary distributions of git for
> windows.
> 2) Use TLS as you suggest and have one fd per pack thread.  Probably
> the most complicated code change (at least for me, being a first-time
> contributor)

It's not so complicated. I suggested a patch [1] before (surprise!).

> 3) Use Karsten's suggested implementation from earlier in the thread.
> Seems to work, but it's a little confusing from a readability
> standpoint since the implementation is not-thread safe except in this
> specific usage contex

[1] http://article.gmane.org/gmane.comp.version-control.git/196042
-- 
Duy
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]