Re: [PATCH 09/10] read-cache.c: remove #ifdef NO_PTHREADS

2018-10-29 Thread Junio C Hamano
Duy Nguyen writes: >> This shouldn't be needed either. My assumption was that if someone >> explicitly asked for multiple threads we're better off failing than >> silently ignoring their request. The default/automatic setting will >> detect the number of cpus and behave correctly. > > No. I can

Re: [PATCH 09/10] read-cache.c: remove #ifdef NO_PTHREADS

2018-10-29 Thread Ben Peart
On 10/29/2018 1:21 PM, Duy Nguyen wrote: On Mon, Oct 29, 2018 at 6:05 PM Ben Peart wrote: @@ -2756,8 +2745,11 @@ static int do_write_index(struct index_state *istate, struct tempfile *tempfile, if (ce_write(&c, newfd, &hdr, sizeof(hdr)) < 0) return -1; -#ifndef NO_PTH

Re: [PATCH 09/10] read-cache.c: remove #ifdef NO_PTHREADS

2018-10-29 Thread Duy Nguyen
On Mon, Oct 29, 2018 at 6:05 PM Ben Peart wrote: > > @@ -2756,8 +2745,11 @@ static int do_write_index(struct index_state > > *istate, struct tempfile *tempfile, > > if (ce_write(&c, newfd, &hdr, sizeof(hdr)) < 0) > > return -1; > > > > -#ifndef NO_PTHREADS > > - nr_threads

Re: [PATCH 09/10] read-cache.c: remove #ifdef NO_PTHREADS

2018-10-29 Thread Ben Peart
On 10/27/2018 3:10 AM, Nguyễn Thái Ngọc Duy wrote: Signed-off-by: Nguyễn Thái Ngọc Duy --- read-cache.c | 49 ++--- 1 file changed, 18 insertions(+), 31 deletions(-) diff --git a/read-cache.c b/read-cache.c index d57958233e..ba870bc3fd 100644 --

[PATCH 09/10] read-cache.c: remove #ifdef NO_PTHREADS

2018-10-27 Thread Nguyễn Thái Ngọc Duy
Signed-off-by: Nguyễn Thái Ngọc Duy --- read-cache.c | 49 ++--- 1 file changed, 18 insertions(+), 31 deletions(-) diff --git a/read-cache.c b/read-cache.c index d57958233e..ba870bc3fd 100644 --- a/read-cache.c +++ b/read-cache.c @@ -1920,19 +1920,15 @