Re: js/mingw-http-ssl, was Re: What's cooking in git.git (Oct 2018, #05; Fri, 26)

2018-10-29 Thread Kaartic Sivaraam
Hi Junio, On 30 October 2018 11:07:39 GMT+05:30, Junio C Hamano wrote: >Eric Sunshine writes: >>> On platforms with recent cURL library, http.sslBackend >configuration >>> variable can be used to choose different SSL backend at runtime. >> >> s/choose/& a/ >> >>> The Windows port

Re: js/mingw-http-ssl, was Re: What's cooking in git.git (Oct 2018, #05; Fri, 26)

2018-10-29 Thread Junio C Hamano
Eric Sunshine writes: > On Mon, Oct 29, 2018 at 10:10 PM Junio C Hamano wrote: >> How's this? >> >> On platforms with recent cURL library, http.sslBackend configuration >> variable can be used to choose different SSL backend at runtime. > > s/choose/& a/ > >> The Windows port uses

Re: [RFC] Generation Number v2

2018-10-29 Thread Junio C Hamano
Derrick Stolee writes: > **V3: Corrected Commit Date.** > For a commit C, let its _corrected commit date_ (denoted by cdate(C)) > be the maximum of the commit date of C and the commit dates of its > parents. "maximum of the commit date of C and the corrected commit dates of its parents"? We've

Re: [PATCH] completion: use builtin completion for format-patch

2018-10-29 Thread Denton Liu
On Tue, Oct 30, 2018 at 11:20:45AM +0900, Junio C Hamano wrote: > We saw a similar change proposed and then found out it was not such > a good idea in: > > https://public-inbox.org/git/cacsjy8durvju0hn7kuceo4iv5aimwbytr+e-7kenpvdx90d...@mail.gmail.com/ > > It seems that this one loses options

Re: [PATCH 0/4] index-pack: optionally turn off SHA-1 collision checking

2018-10-29 Thread Geert Jansen
On Sun, Oct 28, 2018 at 10:50:19PM +, Ævar Arnfjörð Bjarmason wrote: > I left the door open for that in the new config option 4/4 implements, > but I suspect for Geert's purposes this is something he'd prefer to > turn off in git on clone entirely, i.e. because it may be running on > some

Re: Lost changes after merge

2018-10-29 Thread Gray King
Sorry, seems the link has been expired, here is the new one: * Before merge run `git log --format="%h %p %d" -n 20 --all --graph`: https://cfp.vim-cn.com/cbfq6 * After merged run `git log --format="%h %p %d" -n 20 --all --graph`: https://cfp.vim-cn.com/cbfq7 在 2018年10月29日 下午10:18:07, Jeff

Re: [PATCH v1] speed up refresh_index() by utilizing preload_index()

2018-10-29 Thread Junio C Hamano
Ben Peart writes: > From: Ben Peart > > Speed up refresh_index() by utilizing preload_index() to do most of the work > spread across multiple threads. This works because most cache entries will > get marked CE_UPTODATE so that refresh_cache_ent() can bail out early when > called from within

Re: js/mingw-http-ssl, was Re: What's cooking in git.git (Oct 2018, #05; Fri, 26)

2018-10-29 Thread Eric Sunshine
On Mon, Oct 29, 2018 at 10:10 PM Junio C Hamano wrote: > How's this? > > On platforms with recent cURL library, http.sslBackend configuration > variable can be used to choose different SSL backend at runtime. s/choose/& a/ > The Windows port uses this mechanism to switch between

Re: [PATCH] completion: use builtin completion for format-patch

2018-10-29 Thread Junio C Hamano
Denton Liu writes: > Signed-off-by: Denton Liu > --- > contrib/completion/git-completion.bash | 11 +-- > 1 file changed, 1 insertion(+), 10 deletions(-) We saw a similar change proposed and then found out it was not such a good idea in:

Re: js/mingw-http-ssl, was Re: What's cooking in git.git (Oct 2018, #05; Fri, 26)

2018-10-29 Thread Junio C Hamano
Johannes Schindelin writes: >> >> On Windows with recent enough cURL library, the configuration >> >> variable http.sslBackend can be used to choose between OpenSSL and >> >> Secure Channel at runtime as the SSL backend while talking over >> >> the HTTPS protocol. >> ... >> Yeah, but

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

Re: [PATCH 06/10] grep: remove #ifdef NO_PTHREADS

2018-10-29 Thread Junio C Hamano
Jeff King writes: > On Mon, Oct 29, 2018 at 05:01:41PM +0100, Duy Nguyen wrote: > >> On Mon, Oct 29, 2018 at 3:25 PM Jeff King wrote: >> > But if the problem is simply that we are not quite there yet in the grep >> > code, I am OK with taking this as the first pass, and knowing that there >> >

Re: [PATCH 3/3] commit-reach.h: add missing declarations (hdr-check)

2018-10-29 Thread Ramsay Jones
On 29/10/2018 01:13, Junio C Hamano wrote: > Ramsay Jones writes: > >> ... >>24 clear_contains_cache >> $ >> >> you will find 24 copies of the commit-slab routines for the contains_cache. >> Of course, when you enable optimizations again, these duplicate static >> functions (mostly)

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 03:35:58PM -0700, Stefan Beller wrote: > On Mon, Oct 29, 2018 at 3:27 PM Jeff King wrote: > > > So yeah, that's the other thing I'm thinking about regarding having a > > maximum loose cache size. > > tangent: > This preloading/caching could be used for a more precise

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 08:36:07PM +0100, Ævar Arnfjörð Bjarmason wrote: > > Yeah, especially given recent advances in SHA-1 attacks, I'm not super > > comfortable with the idea of disabling the duplicate-object check at > > this point. > > I'd be comfortable with it in my setup since it's been

Re: [PATCH] pretty: Add %(trailer:X) to display single trailer

2018-10-29 Thread Anders Waldenborg
On Mon, Oct 29, 2018 at 3:14 PM Jeff King wrote: > Junio's review already covered my biggest question, which is why not > something like "%(trailers:key=ticket)". And likewise making things like > comma-separation options. Jeff, Junio, thanks! Your questions pretty much matches what I (and a

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Stefan Beller
On Mon, Oct 29, 2018 at 3:27 PM Jeff King wrote: > So yeah, that's the other thing I'm thinking about regarding having a > maximum loose cache size. tangent: This preloading/caching could be used for a more precise approach to decide when to gc instead of using some statistical sampling of

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 09:34:53PM +, Geert Jansen wrote: > As an example, this means that when you're recieving a pack file with 1K > objects in a repository with 10K loose objects that the loose-object-cache > patch has roughly the same performance as the current git. I'm not sure if >

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Geert Jansen
On Mon, Oct 29, 2018 at 05:50:50PM -0400, Jeff King wrote: > > I believe the loose-object-cache approach would have a performance > > regression > > when you're receiving a small pack file and there's many loose objects in > > the > > repo. Basically you're trading off > > > > MIN(256,

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 09:34:53PM +, Geert Jansen wrote: > On Mon, Oct 29, 2018 at 09:48:02AM +0900, Junio C Hamano wrote: > > > A real question is how much performance gain, relative to ".cloning" > > thing, this approach gives us. If it gives us 80% or more of the > > gain compared to

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Geert Jansen
On Mon, Oct 29, 2018 at 09:48:02AM +0900, Junio C Hamano wrote: > A real question is how much performance gain, relative to ".cloning" > thing, this approach gives us. If it gives us 80% or more of the > gain compared to doing no checking, I'd say we have a clear winner. I've tested Jeff's

Re: [PATCH v3 2/3] shallow: offer to prune only non-existing entries

2018-10-29 Thread Johannes Schindelin
Hi Jonathan, On Fri, 26 Oct 2018, Jonathan Tan wrote: > > So even better would be to use `is_promisor_object(oid) || > > has_object_file(oid)`, right? > > > > This is something that is probably not even needed: as I mentioned, > > the shallow commits are *expected* to be local. It should not

[PATCH v1] speed up refresh_index() by utilizing preload_index()

2018-10-29 Thread Ben Peart
From: Ben Peart Speed up refresh_index() by utilizing preload_index() to do most of the work spread across multiple threads. This works because most cache entries will get marked CE_UPTODATE so that refresh_cache_ent() can bail out early when called from within refresh_index(). On a Windows

Re: [RFC] Generation Number v2

2018-10-29 Thread Derrick Stolee
Here is a re-formatted version of the tables I introduced earlier. The tables were too wide for public-inbox to render correctly (when paired with my email client). Hopefully this bulleted-list format works better. Thanks, Stefan, for pointing out the rendering problems! ### Test 1: `git log

Re: [PATCH v2 06/10] preload-index.c: remove #ifdef NO_PTHREADS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 02:05:58PM -0400, Ben Peart wrote: > On 10/29/2018 1:26 PM, Duy Nguyen wrote: > > On Mon, Oct 29, 2018 at 6:21 PM Ben Peart wrote: > > > @@ -114,6 +104,9 @@ static void preload_index(struct index_state *index, > > > threads = index->cache_nr / THREAD_COST; > > >

Re: [RFC] Generation Number v2

2018-10-29 Thread Derrick Stolee
On 10/29/2018 3:22 PM, Stefan Beller wrote: Based on the performance results alone, we should remove minimum generation numbers, (epoch, date) pairs, and FELINE index from consideration. There are enough examples of these indexes performing poorly. In contrast, maximum generation numbers and

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Ævar Arnfjörð Bjarmason
On Mon, Oct 29 2018, Jeff King wrote: > On Sat, Oct 27, 2018 at 01:22:16PM +0200, Ævar Arnfjörð Bjarmason wrote: > >> > Taking one step back, the root problem in this thread is that stat() on >> > non-existing files is slow (which makes has_sha1_file slow). >> > >> > One solution there is to

Re: [RFC] Generation Number v2

2018-10-29 Thread Stefan Beller
> Based on the performance results alone, we should remove minimum > generation numbers, (epoch, date) pairs, and FELINE index from > consideration. There are enough examples of these indexes performing > poorly. > > In contrast, maximum generation numbers and corrected commit > dates both

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Ævar Arnfjörð Bjarmason
On Mon, Oct 29 2018, Jeff King wrote: > On Mon, Oct 29, 2018 at 09:48:02AM +0900, Junio C Hamano wrote: > >> > Of course any cache raises questions of cache invalidation, but I think >> > we've already dealt with that for this case. When we use >> > OBJECT_INFO_QUICK, that is a sign that we

Re: [PATCH v2 06/10] preload-index.c: remove #ifdef NO_PTHREADS

2018-10-29 Thread Ben Peart
On 10/29/2018 1:26 PM, Duy Nguyen wrote: On Mon, Oct 29, 2018 at 6:21 PM Ben Peart wrote: @@ -114,6 +104,9 @@ static void preload_index(struct index_state *index, threads = index->cache_nr / THREAD_COST; if ((index->cache_nr > 1) && (threads < 2) &&

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(, newfd, , sizeof(hdr)) < 0) return -1; -#ifndef NO_PTHREADS

[PATCH] completion: use builtin completion for format-patch

2018-10-29 Thread Denton Liu
Signed-off-by: Denton Liu --- contrib/completion/git-completion.bash | 11 +-- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash index d63d2dffd..da77da481 100644 ---

Re: [PATCH 12/12] fsck: mark strings for translation

2018-10-29 Thread Ævar Arnfjörð Bjarmason
On Mon, Oct 29 2018, Ævar Arnfjörð Bjarmason wrote: > On Mon, Oct 29 2018, Duy Nguyen wrote: > >> On Mon, Oct 29, 2018 at 3:09 PM Junio C Hamano wrote: >>> >>> SZEDER Gábor writes: >>> >>> >> -fprintf(stderr, "%s in %s %s: %s\n", >>> >> -msg_type, printable_type(obj),

Re: [PATCH 12/12] fsck: mark strings for translation

2018-10-29 Thread Ævar Arnfjörð Bjarmason
On Mon, Oct 29 2018, Duy Nguyen wrote: > On Mon, Oct 29, 2018 at 3:09 PM Junio C Hamano wrote: >> >> SZEDER Gábor writes: >> >> >> -fprintf(stderr, "%s in %s %s: %s\n", >> >> -msg_type, printable_type(obj), describe_object(obj), err); >> >> +fprintf_ln(stderr, _("%s in %s

Re: [PATCH v2 06/10] preload-index.c: remove #ifdef NO_PTHREADS

2018-10-29 Thread Duy Nguyen
On Mon, Oct 29, 2018 at 6:21 PM Ben Peart wrote: > @@ -114,6 +104,9 @@ static void preload_index(struct index_state *index, > threads = index->cache_nr / THREAD_COST; > if ((index->cache_nr > 1) && (threads < 2) && > git_env_bool("GIT_TEST_PRELOAD_INDEX", 0)) >

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

2018-10-29 Thread Ben Peart
On 10/29/2018 10:30 AM, Jeff King wrote: On Sat, Oct 27, 2018 at 07:30:06PM +0200, Nguyễn Thái Ngọc Duy wrote: -#ifndef NO_PTHREADS - nr_threads = git_config_get_index_threads(); + if (HAVE_THREADS) { + nr_threads = git_config_get_index_threads(); - /* TODO:

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(, newfd, , sizeof(hdr)) < 0) > > return -1; > > > > -#ifndef NO_PTHREADS > > - nr_threads =

Re: [PATCH v2 06/10] preload-index.c: remove #ifdef NO_PTHREADS

2018-10-29 Thread Ben Peart
On 10/27/2018 1:30 PM, Nguyễn Thái Ngọc Duy wrote: Signed-off-by: Nguyễn Thái Ngọc Duy --- preload-index.c | 15 ++- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/preload-index.c b/preload-index.c index 9e7152ab14..0e24886aca 100644 --- a/preload-index.c +++

Re: [PATCH v3 2/8] Add a place for (not) sharing stuff between worktrees

2018-10-29 Thread Duy Nguyen
On Mon, Oct 22, 2018 at 6:28 AM Junio C Hamano wrote: > > When multiple worktrees are used, we need rules to determine if > > something belongs to one worktree or all of them. Instead of keeping > > adding rules when new stuff comes (*), have a generic rule: > > > > - Inside $GIT_DIR, which is

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

2018-10-29 Thread Ben Peart
On 10/29/2018 10:30 AM, Jeff King wrote: On Sat, Oct 27, 2018 at 07:30:06PM +0200, Nguyễn Thái Ngọc Duy wrote: -#ifndef NO_PTHREADS - nr_threads = git_config_get_index_threads(); + if (HAVE_THREADS) { + nr_threads = git_config_get_index_threads(); - /* TODO:

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 v2 1/1] remote-curl.c: xcurl_off_t is not portable (on 32 bit platfoms)

2018-10-29 Thread tboegi
From: Torsten Bögershausen When setting DEVELOPER = 1 DEVOPTS = extra-all "gcc (Raspbian 6.3.0-18+rpi1+deb9u1) 6.3.0 20170516" errors out with "comparison is always false due to limited range of data type" "[-Werror=type-limits]" It turns out that the function xcurl_off_t() has 2 flavours: -

[RFC] Generation Number v2

2018-10-29 Thread Derrick Stolee
We've discussed in several places how to improve upon generation numbers. This RFC is a report based on my investigation into a few new options, and how they compare for Git's purposes on several existing open-source repos. You can find this report and the associated test scripts at

Re: [PATCH 07/10] preload-index.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 --- preload-index.c | 15 ++- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/preload-index.c b/preload-index.c index 9e7152ab14..0e24886aca 100644 --- a/preload-index.c +++

Re: [PATCH/WIP 00/19] Kill the_index, final part

2018-10-29 Thread Duy Nguyen
On Fri, Oct 19, 2018 at 7:38 PM Stefan Beller wrote: > > On Fri, Oct 19, 2018 at 7:52 AM Nguyễn Thái Ngọc Duy > wrote: > > > > Stefan I see you start removing more references of the_repository in > > another series (haven't really looked at it yet) so this is just heads > > up so we could

Re: [PATCH] Prevent warning

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 03:39:30PM +, Pete wrote: > Prevent the following warning in the web server error log: > gitweb.cgi: Odd number of elements in anonymous hash at > /usr/share/gitweb/gitweb.cgi line 3305 > [...] > - $remotes{$remote} ||= { 'heads' => () }; > +

Re: [PATCH 06/10] grep: remove #ifdef NO_PTHREADS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 05:01:41PM +0100, Duy Nguyen wrote: > On Mon, Oct 29, 2018 at 3:25 PM Jeff King wrote: > > But if the problem is simply that we are not quite there yet in the grep > > code, I am OK with taking this as the first pass, and knowing that there > > is more cleanup to be done

Re: t7405.17 breakage vanishes with GETTEXT_POISON=1

2018-10-29 Thread Duy Nguyen
On Sun, Oct 28, 2018 at 1:15 PM SZEDER Gábor wrote: > > On Sun, Oct 28, 2018 at 06:41:06AM +0100, Duy Nguyen wrote: > > Something fishy is going on but I don't think I'll spend time hunting > > it down so I post here in case somebody else is interested. It might > > also indicate a problem with

Re: [PATCH 08/12] remote.c: mark messages for translation

2018-10-29 Thread Duy Nguyen
On Mon, Oct 29, 2018 at 8:56 AM Junio C Hamano wrote: > There are other series in flight that touch the same area of code > and in different ways, causing unnecessary conflicts, which does not > help us either X-<. I will of course fix all other comments, but I can hold this off if it's causing

Re: [PATCH 12/12] fsck: mark strings for translation

2018-10-29 Thread Duy Nguyen
On Mon, Oct 29, 2018 at 3:09 PM Junio C Hamano wrote: > > SZEDER Gábor writes: > > >> -fprintf(stderr, "%s in %s %s: %s\n", > >> -msg_type, printable_type(obj), describe_object(obj), err); > >> +fprintf_ln(stderr, _("%s in %s %s: %s"), > > > > Are the (f)printf() ->

Re: [PATCH 06/10] grep: remove #ifdef NO_PTHREADS

2018-10-29 Thread Duy Nguyen
On Mon, Oct 29, 2018 at 3:25 PM Jeff King wrote: > But if the problem is simply that we are not quite there yet in the grep > code, I am OK with taking this as the first pass, and knowing that there > is more cleanup to be done later (though that sort of thing is IMHO very > useful in a commit

Re: [PATCH] Prevent warning

2018-10-29 Thread Torsten Bögershausen
Thanks for the patch. Could you please sign it off ? The other remark would be if the header line could be written longer than just "Prevent warning". to give people digging into the Git history an initial information, where the warning occured and from which module it was caused. May be something

Re: [PATCH] wildmatch: change behavior of "foo**bar" in WM_PATHNAME mode

2018-10-29 Thread Duy Nguyen
On Mon, Oct 29, 2018 at 2:24 PM Ævar Arnfjörð Bjarmason wrote: > This patch looks good to me, but I think it's a bad state of affairs to > keep changing these semantics and not having something like a > "gitwildmatch" doc were we document this matching syntax. While we don't have a separate

Re: [PATCH] test-lib: introduce the '-V' short option for '--verbose-log'

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 02:53:35PM +0100, SZEDER Gábor wrote: > > Interesting. I'm not opposed to something like this, but I added > > "--verbose-log" specifically for scripted cases, like running an > > unattended "prove" that needs to preserve stdout. When running > > individual tests, I'd just

[PATCH] Prevent warning

2018-10-29 Thread Pete
Prevent the following warning in the web server error log: gitweb.cgi: Odd number of elements in anonymous hash at /usr/share/gitweb/gitweb.cgi line 3305 --- gitweb/gitweb.perl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl index

Re: [PATCH v2 00/16] sequencer: refactor functions working on a todo_list

2018-10-29 Thread Alban Gruin
Hi Junio, Le 29/10/2018 à 04:05, Junio C Hamano a écrit : > Alban Gruin writes: […] >> It is based onto ag/rebase-i-in-c (34b4731, "rebase -i: move >> rebase--helper modes to rebase--interactive"). > > As there are quite a lot of fixes to the sequencer machinery since > that topic forked from

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 09:48:02AM +0900, Junio C Hamano wrote: > > Of course any cache raises questions of cache invalidation, but I think > > we've already dealt with that for this case. When we use > > OBJECT_INFO_QUICK, that is a sign that we want to make this kind of > > accuracy/speed

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Jeff King
On Sat, Oct 27, 2018 at 04:04:32PM +0200, Duy Nguyen wrote: > > Of course any cache raises questions of cache invalidation, but I think > > we've already dealt with that for this case. When we use > > OBJECT_INFO_QUICK, that is a sign that we want to make this kind of > > accuracy/speed tradeoff

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 11:04:53AM -0400, Jeff King wrote: > > Even if someone wants to make the argument that this is behavior that we > > absolutely *MUST* keep and not make configurable, there's still much > > smarter ways to do it. > > I don't have any real object to a configuration like

Re: [RFC PATCH] index-pack: improve performance on NFS

2018-10-29 Thread Jeff King
On Sat, Oct 27, 2018 at 01:22:16PM +0200, Ævar Arnfjörð Bjarmason wrote: > > Taking one step back, the root problem in this thread is that stat() on > > non-existing files is slow (which makes has_sha1_file slow). > > > > One solution there is to cache the results of looking in .git/objects > >

Re: [PATCH] test-lib: introduce the '-V' short option for '--verbose-log'

2018-10-29 Thread SZEDER Gábor
On Mon, Oct 29, 2018 at 10:21:08AM -0400, Jeff King wrote: > On Mon, Oct 29, 2018 at 01:13:59PM +0100, SZEDER Gábor wrote: > > > '--verbose-log' is one of the most useful and thus most frequently > > used test options, but due to its length it's a pain to type on the > > command line. > > > >

Re: [PATCH v2 10/10] read-cache.c: initialize copy_len to shut up gcc 8

2018-10-29 Thread Jeff King
On Sat, Oct 27, 2018 at 07:30:08PM +0200, Nguyễn Thái Ngọc Duy wrote: > It was reported that when building with NO_PTHREADS=1, > -Wmaybe-uninitialized is triggered. Just initialize the variable from > the beginning to shut the compiler up (because this warning is enabled > in config.dev) > >

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

2018-10-29 Thread Jeff King
On Sat, Oct 27, 2018 at 07:30:06PM +0200, Nguyễn Thái Ngọc Duy wrote: > -#ifndef NO_PTHREADS > - nr_threads = git_config_get_index_threads(); > + if (HAVE_THREADS) { > + nr_threads = git_config_get_index_threads(); > > - /* TODO: does creating more threads than cores

Re: [PATCH 06/10] grep: remove #ifdef NO_PTHREADS

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 11:16:39AM +0900, Junio C Hamano wrote: > Jeff King writes: > > > Cases like this are kind of weird. I'd expect to see wait_all() return > > immediately when !HAVE_THREADS. But we don't need to, because later we > > do this: > > > >> - if (num_threads) > >> + if

Re: [PATCH] test-lib: introduce the '-V' short option for '--verbose-log'

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 01:13:59PM +0100, SZEDER Gábor wrote: > '--verbose-log' is one of the most useful and thus most frequently > used test options, but due to its length it's a pain to type on the > command line. > > Let's introduce the corresponding short option '-V' to save some >

Re: Lost changes after merge

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 09:49:20AM +0100, Gray King wrote: > Hello, > >   I have a very strange issue described below: > > * Here is the tree before I merge via `git log --format="%h %p %d" -n > 20 --all --graph`: > > https://upaste.de/9Pe FWIW, neither this nor the other paste link in your

Re: [PATCH] alias: detect loops in mixed execution mode

2018-10-29 Thread Jeff King
On Mon, Oct 29, 2018 at 12:44:58PM +0900, Junio C Hamano wrote: > Jeff King writes: > > > Hmph. So I was speaking before purely hypothetically, but now that your > > patch is in 'next', it is part of my daily build. And indeed, I hit a > > false positive within 5 minutes of building it. ;) > >

Re: [PATCH] pretty: Add %(trailer:X) to display single trailer

2018-10-29 Thread Jeff King
On Sun, Oct 28, 2018 at 01:50:25PM +0100, Anders Waldenborg wrote: > This new format placeholder allows displaying only a single > trailer. The formatting done is similar to what is done for > --decorate/%d using parentheses and comma separation. Displaying a single trailer makes sense as a

Re: [PATCH 12/12] fsck: mark strings for translation

2018-10-29 Thread Junio C Hamano
SZEDER Gábor writes: >> -fprintf(stderr, "%s in %s %s: %s\n", >> -msg_type, printable_type(obj), describe_object(obj), err); >> +fprintf_ln(stderr, _("%s in %s %s: %s"), > > Are the (f)printf() -> (f)printf_ln() changes all over > 'builtin/fsck.c' really necessary to mark

Re: [PATCH] wildmatch: change behavior of "foo**bar" in WM_PATHNAME mode

2018-10-29 Thread Ævar Arnfjörð Bjarmason
On Sat, Oct 27 2018, Nguyễn Thái Ngọc Duy wrote: > In WM_PATHNAME mode (or FNM_PATHNAME), '*' does not match '/' and '**' > can but only in three patterns: > > - '**/' matches zero or more leading directories > - '/**/' matches zero or more directories in between > - '/**' matches zero or more

Re: js/mingw-http-ssl, was Re: What's cooking in git.git (Oct 2018, #05; Fri, 26)

2018-10-29 Thread Johannes Schindelin
Hi Junio, On Fri, 26 Oct 2018, Junio C Hamano wrote: > Johannes Schindelin writes: > > > On Fri, 26 Oct 2018, Junio C Hamano wrote: > > > >> * js/mingw-http-ssl (2018-10-26) 3 commits > >> (merged to 'next' on 2018-10-26 at 318e82e101) > >> + http: when using Secure Channel, ignore

Re: [PATCH] packfile: close multi-pack-index in close_all_packs

2018-10-29 Thread Derrick Stolee
On 10/29/2018 7:10 AM, SZEDER Gábor wrote: On Thu, Oct 25, 2018 at 12:54:05PM +, Derrick Stolee wrote: Whenever we delete pack-files from the object directory, we need to also delete the multi-pack-index that may refer to those objects. Sometimes, this connection is obvious, like during a

[PATCH] test-lib: introduce the '-V' short option for '--verbose-log'

2018-10-29 Thread SZEDER Gábor
'--verbose-log' is one of the most useful and thus most frequently used test options, but due to its length it's a pain to type on the command line. Let's introduce the corresponding short option '-V' to save some keystrokes. Signed-off-by: SZEDER Gábor --- Or it could be '-L', to emphasize

Re: 'ds/test-multi-pack-index' vs. 'ab/commit-graph-progress'

2018-10-29 Thread SZEDER Gábor
On Thu, Oct 25, 2018 at 11:11:55PM +0200, Ævar Arnfjörð Bjarmason wrote: > > Anyway, this test seems to be too fragile, because that > > > > test_line_count = 1 stderr > > Yeah maybe it's too fragile, on the other hand it caught what seems to > be a bug under GIT_TEST_MULTI_PACK_INDEX=true, and

Re: [PATCH] packfile: close multi-pack-index in close_all_packs

2018-10-29 Thread SZEDER Gábor
On Thu, Oct 25, 2018 at 12:54:05PM +, Derrick Stolee wrote: > Whenever we delete pack-files from the object directory, we need > to also delete the multi-pack-index that may refer to those > objects. Sometimes, this connection is obvious, like during a > repack. Other times, this is less

Re: [PATCH 12/12] fsck: mark strings for translation

2018-10-29 Thread SZEDER Gábor
On Sun, Oct 28, 2018 at 07:51:57AM +0100, Nguyễn Thái Ngọc Duy wrote: > Signed-off-by: Nguyễn Thái Ngọc Duy > --- > builtin/fsck.c | 113 - > t/t1410-reflog.sh | 6 +- > t/t1450-fsck.sh| 50 >

Re: Lost changes after merge

2018-10-29 Thread Gray King
After merged, the latest commit(a008c4d580) has lost and the second commit(a274b6e7ca) has been the latest, and changes missed too. 在 2018年10月29日 下午4:49:20, Gray King (graykin...@gmail.com(mailto:graykin...@gmail.com)) 写到: > > > Hello, > > I have a very strange issue described below: > > *

Lost changes after merge

2018-10-29 Thread Gray King
Hello,   I have a very strange issue described below: * Here is the tree before I merge via `git log --format="%h %p %d" -n 20 --all --graph`: https://upaste.de/9Pe * Here is the output of `git log --format="%h %p %d" -2 path/to/file`: a008c4d580 c61f96eb5d a274b6e7ca 67c1000ca3 * Here is

Re: [PATCH v3 7/8] push: add DWYM support for "git push refs/remotes/...:"

2018-10-29 Thread Ævar Arnfjörð Bjarmason
On Mon, Oct 29 2018, Junio C Hamano wrote: > Ævar Arnfjörð Bjarmason writes: > >> Add DWYM support for pushing a ref in refs/remotes/* when the > > I think most people call it do-what-*I*-mean, not do-what-you-mean. FWIW I picked this up from the perl list where both are used depending on

Re: [PATCH v3 7/8] push: add DWYM support for "git push refs/remotes/...:"

2018-10-29 Thread Ævar Arnfjörð Bjarmason
On Mon, Oct 29 2018, Junio C Hamano wrote: > Ævar Arnfjörð Bjarmason writes: > >> This is the first use of the %N$ style of printf format in >> the *.[ch] files in our codebase. It's supported by POSIX[2] and >> there's existing uses for it in po/*.po files,... > > For now, I'll eject this

Re: [PATCH v3 7/8] push: add DWYM support for "git push refs/remotes/...:"

2018-10-29 Thread Junio C Hamano
Junio C Hamano writes: > Ævar Arnfjörð Bjarmason writes: > >> This is the first use of the %N$ style of printf format in >> the *.[ch] files in our codebase. It's supported by POSIX[2] and >> there's existing uses for it in po/*.po files,... > > For now, I'll eject this from 'pu', as I had

Re: [PATCH 08/12] remote.c: mark messages for translation

2018-10-29 Thread Junio C Hamano
Nguyễn Thái Ngọc Duy writes: > @@ -995,12 +995,12 @@ static int match_explicit_lhs(struct ref *src, >* way to delete 'other' ref at the remote end. >*/ > if (try_explicit_object_name(rs->src, match) < 0) > - return error("src

Re: [PATCH v3 7/8] push: add DWYM support for "git push refs/remotes/...:"

2018-10-29 Thread Junio C Hamano
Ævar Arnfjörð Bjarmason writes: > This is the first use of the %N$ style of printf format in > the *.[ch] files in our codebase. It's supported by POSIX[2] and > there's existing uses for it in po/*.po files,... For now, I'll eject this from 'pu', as I had spent way too much time trying to

Re: [PATCH] worktree: refactor lock_reason_valid and lock_reason to be more sensible

2018-10-29 Thread Junio C Hamano
Nickolai Belakovski writes: > Either way, I do see an issue with the current code that anybody who > wants to know the lock status and/or lock reason of a worktree gets > faced with a confusing, misleading, and opaque piece of code. Sorry, I don't. I do not mind a better documentation for

Re: [PATCH] worktree: refactor lock_reason_valid and lock_reason to be more sensible

2018-10-29 Thread Eric Sunshine
On Mon, Oct 29, 2018 at 1:45 AM Nickolai Belakovski wrote: > On Sun, Oct 28, 2018 at 9:01 PM Eric Sunshine wrote: > > That said, I wouldn't necessarily oppose renaming the function, but I > > also don't think it's particularly important to do so. > > To me, I would just go lookup the signature