Re: [PATCH] git-svn: shorten glob error message

2016-01-22 Thread Victor Leschuk
Hello all, On 01/14/2016 09:15 PM, Junio C Hamano wrote: > Eric Wong writes: > >> Error messages should attempt to fit within the confines of >> an 80-column terminal to avoid compatibility and accessibility >> problems. Furthermore the word "directories" can be misleading >> when used in the co

[PATCH v4] git-svn: add support for prefixed globs in config

2015-12-30 Thread Victor Leschuk
Introduce prefixed globs for branches and tags in git-svn. Globs like 'release_*' allow users to avoid long lines in config like: branches = branches/{release_20,release_21,release_22,...} Signed-off-by: Victor Leschuk --- Changes from v3: * Wrapped all test preparations i

[PATCH v3] git-svn: add support for prefixed globs in config

2015-12-17 Thread Victor Leschuk
Introduce prefixed globs for branches and tags in git-svn. Globs like 'release_*' allow users to avoid long lines in config like: branches = branches/{release_20,release_21,release_22,...} Signed-off-by: Victor Leschuk --- Changes from v1 (in v2 I forgot to switch

[PATCH v2] git-svn: add support for prefixed globs in config

2015-12-17 Thread Victor Leschuk
Introduce prefixed globs for branches and tags in git-svn. Globs like 'release_*' allow users to avoid long lines in config like: branches = branches/{release_20,release_21,release_22,...} Signed-off-by: Victor Leschuk --- Changes from v1: * Joined implementation and test in

Re: [PATCH 2/2] git-svn: test for git-svn prefixed globs

2015-12-16 Thread Victor Leschuk
ost things look fine with 1/2, comments on 2/2 below... Victor Leschuk wrote: Add test for git-svn prefixed globs. Why a separate patch? Unless there's some documentation purpose for a regression, usually tests and a feature should be added atomically in the same commit. --- /dev/null ++

[PATCH 2/2] git-svn: test for git-svn prefixed globs

2015-12-16 Thread Victor Leschuk
Add test for git-svn prefixed globs. Signed-off-by: Victor Leschuk --- t/t9168-git-svn-prefixed-glob.sh | 136 +++ 1 file changed, 136 insertions(+) create mode 100755 t/t9168-git-svn-prefixed-glob.sh diff --git a/t/t9168-git-svn-prefixed-glob.sh b/t/t9168

[PATCH 1/2] git-svn: support for prefixed globs in config

2015-12-16 Thread Victor Leschuk
Introduce prefixed globs for branches and tags in git-svn. Signed-off-by: Victor Leschuk --- Documentation/git-svn.txt | 5 + perl/Git/SVN/GlobSpec.pm | 9 - 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/Documentation/git-svn.txt b/Documentation/git-svn.txt index

[PATCH 0/2] git-svn: add support for prefixed globs in config

2015-12-16 Thread Victor Leschuk
* instead of this. Thus I suggest to add support for such 'prefixed' globs into git-svn. Victor Leschuk (2): Introduce prefixed globs for branches and tags in git-svn. Add test for git-svn prefixed globs. Documentation/git-svn.txt| 5 ++ perl/Git/SVN/GlobSpec.pm

Re: [PATCH 1/2] Introduce grep threads param

2015-12-15 Thread Victor Leschuk
Hello Junio, On 12/15/2015 11:06 PM, Junio C Hamano wrote: Victor Leschuk writes: Subject: Re: [PATCH 1/2] Introduce grep threads param I'll retitle this to something like grep: add --threads= option and grep.threads configuration while queuing (which I did for v7 earlier)

[PATCH 1/2] Introduce grep threads param

2015-12-15 Thread Victor Leschuk
"git grep" can now be configured (or told from the command line) how many threads to use when searching in the working tree files. Signed-off-by: Victor Leschuk --- Documentation/config.txt | 4 +++ Documentation/git-grep.txt | 12 + buil

[PATCH v8 0/2] Add git-grep threads param

2015-12-15 Thread Victor Leschuk
single place (grep.threads description in git-grep.txt) and is referenced from other places. Also made few language improvements in documentation. * Style improvements: splitted too long lines Victor Leschuk (2): "git grep" can now be configured (or told from the command line) how m

[PATCH 2/2] Get rid of online_cpus() when determining grep threads num

2015-12-15 Thread Victor Leschuk
tiple threads can significantly boost grep performance when working on slow filesystems (or repo isn't cached) or through network (for example repo is located on NFS). Signed-off-by: Victor Leschuk --- builtin/grep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builti

Re: [PATCH v7] Add git-grep threads param

2015-12-13 Thread Victor Leschuk
Hello Eric: Hmm, v7 doesn't seem to address any of the v6 review comments here[1]. Was that review merely overlooked or did you disagree with the reviewer? [1]: http://article.gmane.org/gmane.comp.version-control.git/281817 Sorry, it looks like I missed that letter. My bad. History of change

[PATCH v7] Add git-grep threads param

2015-12-13 Thread Victor Leschuk
through network (for example repo is located on NFS). Signed-off-by: Victor Leschuk --- History of changes from the first version ($gmane/280053/: * Param renamed from threads-num to threads * Short version of '--threads' cmd key was removed * Made num_thread

RE: [PATCH v6] Add git-grep threads param

2015-11-30 Thread Victor Leschuk
Hello all, does anybody have time to review this patch? PS Sorry for bothering =) -- Best Regards, Victor From: Victor Leschuk [vlesc...@gmail.com] Sent: Wednesday, November 11, 2015 03:52 To: git@vger.kernel.org Cc: Victor Leschuk Subject: [PATCH v6

Re: What's cooking in git.git (Nov 2015, #03; Fri, 20)

2015-11-23 Thread Victor Leschuk
On 11/20/2015 05:09 PM, Jeff King wrote: * vl/grep-configurable-threads (2015-11-01) 1 commit - grep: add --threads= option and grep.threads configuration "git grep" can now be configured (or told from the command line) how many threads to use when searching in the working tree files.

RE: [PATCH v6] Add git-grep threads param

2015-11-16 Thread Victor Leschuk
d patch to pu? Thanks. -- Best Regards, Victor ____ From: Victor Leschuk [vlesc...@gmail.com] Sent: Wednesday, November 11, 2015 03:52 To: git@vger.kernel.org Cc: Victor Leschuk Subject: [PATCH v6] Add git-grep threads param "git grep" can now be conf

[PATCH v6] Add git-grep threads param

2015-11-11 Thread Victor Leschuk
ULT (8) threads will be used even on 1-core CPU. Signed-off-by: Victor Leschuk --- History of changes from the first version ($gmane/280053/: * Param renamed from threads-num to threads * Short version of '--threads' cmd key was removed * Made num_threads &#x

[PATCH v5] Add git-grep threads param

2015-11-10 Thread Victor Leschuk
"git grep" can now be configured (or told from the command line) how many threads to use when searching in the working tree files. Signed-off-by: Victor Leschuk --- Documentation/config.txt | 7 + Documentation/git-grep.txt | 15 ++ buil

RE: [PATCH v4] Add git-grep threads param

2015-11-09 Thread Victor Leschuk
Correct. I think adding the option (both to command line and to config file) is good, as long as the IO issues are documented. And default to just the fixed number of threads for now - and with the option, maybe people can then more easily try out different scenarios and maybe improve on the p

RE: [PATCH v4] Add git-grep threads param

2015-11-09 Thread Victor Leschuk
. > In the meantime I'd argue for just getting rid of the online_cpu's > check, because > (a) I think it's actively misleading > (b) the threaded grep probably doesn't hurt much even on a single > CPU, and the _potential_ upside from IO could easily dwarf the cost. > (c) do developers actual

RE: [PATCH v4] Add git-grep threads param

2015-11-09 Thread Victor Leschuk
On Mon, Nov 9, 2015 at 9:28 AM, Victor Leschuk wrote: > > Maybe use the simplest version (and keep num_numbers == 0 also as flag for > all other checks in code like if(num_flags) ): > > if (list.nr || cached ) > num_threads = 0; // do not use threads > else

RE: [PATCH v4] Add git-grep threads param

2015-11-09 Thread Victor Leschuk
> if (list.nr || cached) >num_threads = 1; > if (!num_threads) > num_threads = GREP_NUM_THREADS_DEFAULT; > and then later, instead of use_threads, do: > if (num_threads <= 1) { ... do single-threaded version ... > } else { ... do multi-threaded version ...

RE: [PATCH v4] Add git-grep threads param

2015-11-09 Thread Victor Leschuk
> Why don't we leave it at 8, then? That's the conservative choice, and > once we have --threads, people can easily experiment with different > values and we can follow-up with a change to the default if need be. I'd propose the following: if (list.nr || cached) {

RE: [PATCH v4] Add git-grep threads param

2015-11-09 Thread Victor Leschuk
From: Jeff King [p...@peff.net] Sent: Tuesday, November 03, 2015 22:40 To: Junio C Hamano Cc: Victor Leschuk; git@vger.kernel.org; Victor Leschuk; torva...@linux-foundation.org; j...@keeping.me.uk Subject: Re: [PATCH v4] Add git-grep threads param On Tue

RE: [PATCH v4] Add git-grep threads param

2015-11-03 Thread Victor Leschuk
>> do we have any objections on this patch? > The question you should be asking is "do we have any support". Hello all, CCing participated reviewers. As Junio has correctly mentioned: "Do we have any support for including this functionality?" I think this kind of customization can be useful in

RE: [PATCH v4] Add git-grep threads param

2015-11-01 Thread Victor Leschuk
Hello all, do we have any objections on this patch? -- Best Regards, Victor From: Victor Leschuk [vlesc...@gmail.com] Sent: Tuesday, October 27, 2015 14:22 To: git@vger.kernel.org Cc: Victor Leschuk Subject: [PATCH v4] Add git-grep threads param Make

RE: [PATCH 3/6] Facilitate debugging Git executables in tests with gdb

2015-10-31 Thread Victor Leschuk
> > +if test -n "$TEST_GDB_GIT" > > +then > > + exec gdb -args "${GIT_EXEC_PATH}/@@PROG@@" "$@" > Maybe we could make $TEST_GDB_GIT not just a boolean flag? It would be useful > to contain "gdb" executable name. It would allow to set path to GDB when it > is not in $PATH, set different debugg

Re: [PATCH 3/6] Facilitate debugging Git executables in tests with gdb

2015-10-28 Thread Victor Leschuk
+if test -n "$TEST_GDB_GIT" +then + exec gdb -args "${GIT_EXEC_PATH}/@@PROG@@" "$@" Maybe we could make $TEST_GDB_GIT not just a boolean flag? It would be useful to contain "gdb" executable name. It would allow to set path to GDB when it is not in $PATH, set different debuggers (for e

Re: Bug: Segfault when doing "git diff"

2015-10-28 Thread Victor Leschuk
On 10/28/2015 04:35 PM, Mathias L. Baumann wrote: I was using the latest git version 2.6.2 already. I suspect it is due to a .gitconfig. This is what is probably required: ➜ ~ cat .gitconfig [diff] submodule = log Yep, that did the trick. The segfault is from sha1_file.c: /* add the

Re: Bug: Segfault when doing "git diff"

2015-10-28 Thread Victor Leschuk
On 10/28/2015 02:58 PM, Mathias L. Baumann wrote: Hello dear git devs, I just stumbled upon a segfault when doing just "git diff" in my repo. I managed to create a minimal repo setup where the bug is reproducable. The problem seems to be a mix of having an untracked submodule and having set

[PATCH v4] Add git-grep threads param

2015-10-27 Thread Victor Leschuk
Make number of git-grep worker threads a configuration parameter. According to several tests on systems with different number of CPU cores the hard-coded number of 8 threads is not optimal for all systems: tuning this parameter can significantly speed up grep performance. Signed-off-by: Victor

RE: [PATCH v3] Add git-grep threads param

2015-10-27 Thread Victor Leschuk
Hello John, >> This thought also crossed my mind, however we already pass grep_opt to >> start_threads() function, so I think passing it to wait_all() is not >> that ugly, and kind of symmetric. And I do not like the idea of >> duplicating same information in different places. What do you think?

RE: [PATCH v3] Add git-grep threads param

2015-10-27 Thread Victor Leschuk
Hello Linus, >> According to several tests on systems with different number of CPU cores >> the hard-coded number of 8 threads is not optimal for all systems: > Did you also compare cold-cache filesystem performance? > One of the reasons for doing threaded grep is for CPU scaling. But another

RE: [PATCH v3] Add git-grep threads param

2015-10-26 Thread Victor Leschuk
Hello John, see comments inline. >> @@ -22,6 +22,7 @@ SYNOPSIS >> [--color[=] | --no-color] >> [--break] [--heading] [-p | --show-function] >> [-A ] [-B ] [-C ] >> +[--threads ] > Is this the best place for this option? I know the current list isn't > sorted i

[PATCH v3] Add git-grep threads param

2015-10-26 Thread Victor Leschuk
Make number of git-grep worker threads a configuration parameter. According to several tests on systems with different number of CPU cores the hard-coded number of 8 threads is not optimal for all systems: tuning this parameter can significantly speed up grep performance. Signed-off-by: Victor

Re: git --literal-pathspecs add -u says "fatal: pathspec ':/' did not match any files"

2015-10-24 Thread Victor Leschuk
Hello Noam, The problem is that in the absence of explicit argument we set the list of files to special path ":/" which means repo root: if ((0 < addremove_explicit || take_worktree_changes) && !argc) { static const char *whole[2] = { ":/", NULL }; argc = 1; argv =

[PATCH v2] Add git-grep threads-num param

2015-10-23 Thread Victor Leschuk
s: on my 4-core and 8-core systems the thread number of 4 worked about 20% faster than default 8. So I think it is better to allow users tune this parameter. Signed-off-by: Victor Leschuk --- Documentation/config.txt | 4 Documentation/git-grep.txt | 4

RE: [PATCH] Add git-grep threads-num param

2015-10-22 Thread Victor Leschuk
rsday, October 22, 2015 7:23 AM To: Victor Leschuk Cc: git@vger.kernel.org; Victor Leschuk Subject: Re: [PATCH] Add git-grep threads-num param On Thu, Oct 22, 2015 at 04:23:56PM +0300, Victor Leschuk wrote: > Hello all, I suggest we make number of git-grep worker threads a configuration > parame

[PATCH] Add git-grep threads-num param

2015-10-22 Thread Victor Leschuk
of 4 worked about 20% faster than default 8. So I think it is better to allow users tune this parameter. Signed-off-by: Victor Leschuk --- Documentation/config.txt | 4 Documentation/git-grep.txt | 5 + builtin/grep.c | 20

RE: thread-utils: build with NO_PTHREADS fails

2015-10-14 Thread Victor Leschuk
Hamano [gits...@pobox.com] Sent: Monday, October 12, 2015 10:55 AM To: Victor Leschuk Cc: git@vger.kernel.org; vlesc...@gmail.com Subject: Re: thread-utils: build with NO_PTHREADS fails Junio C Hamano writes: > Victor Leschuk writes: > >> I think that no one tried it for a long time

thread-utils: build with NO_PTHREADS fails

2015-10-11 Thread Victor Leschuk
Hello all, I think that no one tried it for a long time but I needed a single-threaded git version for debug purpose. I tried to build with -DNO_PTHREADS and thread-utils.c failed to compile. In brief the situation is the following: in header file we have something like that: #ifndef NO_PTHR

RE: [PATCH] git-svn: make batch mode optional for git-cat-file

2015-10-11 Thread Victor Leschuk
ds, Victor From: Eric Wong [normalper...@yhbt.net] Sent: Wednesday, September 23, 2015 12:22 PM To: Victor Leschuk Cc: Junio C Hamano; git@vger.kernel.org Subject: Re: [PATCH] git-svn: make batch mode optional for git-cat-file Victor Leschuk wrote: > Hello Eric, thank

RE: [PATCH] git-svn: make batch mode optional for git-cat-file

2015-09-23 Thread Victor Leschuk
ide git-cat-file, I think we could give it a try, I can prepare a patch and run some tests. -- Best Regards, Victor ________ From: Eric Wong [normalper...@yhbt.net] Sent: Tuesday, September 22, 2015 5:35 PM To: Victor Leschuk Cc: Junio C Hamano; git@vger.kernel.org Subject: Re: [PATCH] git-svn: ma

RE: [PATCH] git-svn: make batch mode optional for git-cat-file

2015-09-22 Thread Victor Leschuk
x27;. So I was just following the existing convention. Do you think we need to change it and stick with --catch-file-batch=1/--cat-file-batch=0 ? -- Best Regards, Victor ________ From: Victor Leschuk Sent: Monday, September 21, 2015 3:03 PM To: Junio C Hamano Cc

git-svn: Why not use git-fast-import?

2015-09-22 Thread Victor Leschuk
Hello all, I've been playing with git-svn for some time already and as it seems to me there are two most important problems which make it hard to use in production for large repositories. Very low speed and large memory footprint of synchronization with SVN repos (I am talking about clone and

RE: [PATCH] git-svn: make batch mode optional for git-cat-file

2015-09-21 Thread Victor Leschuk
__ From: Junio C Hamano [jch2...@gmail.com] On Behalf Of Junio C Hamano [gits...@pobox.com] Sent: Monday, September 21, 2015 11:25 AM To: Victor Leschuk Cc: git@vger.kernel.org; Victor Leschuk Subject: Re: [PATCH] git-svn: make batch mode optional for git-cat-file Victor Leschu

[PATCH] git-svn: make batch mode optional for git-cat-file

2015-09-21 Thread Victor Leschuk
Signed-off-by: Victor Leschuk --- git-svn.perl | 1 + perl/Git.pm | 41 - 2 files changed, 41 insertions(+), 1 deletion(-) diff --git a/git-svn.perl b/git-svn.perl index 36f7240..b793c26 100755 --- a/git-svn.perl +++ b/git-svn.perl @@ -139,6 +139,7

RE: git-svn: cat-file memory usage

2015-09-16 Thread Victor Leschuk
-- Best Regards, Victor From: Jeff King [p...@peff.net] Sent: Wednesday, September 16, 2015 4:56 AM To: Victor Leschuk Cc: git@vger.kernel.org Subject: Re: git-svn: cat-file memory usage On Wed, Sep 16, 2015 at 04:00:48AM -0700, Victor Leschuk wrote: &

git-svn: cat-file memory usage

2015-09-16 Thread Victor Leschuk
or somehow tune allocation policy in C code? Please let me know your thoughts. -- Best Regards, Victor Leschuk