[PATCH v5 07/17] trace2: add region in clear_ce_flags

2019-10-21 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler When Git updates the working directory with the sparse-checkout feature enabled, the unpack_trees() method calls clear_ce_flags() to update the skip-wortree bits on the cache entries. This check can be expensive, depending on the patterns used. Add trace2 regions around the

[PATCH v4 07/17] trace2: add region in clear_ce_flags

2019-10-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler When Git updates the working directory with the sparse-checkout feature enabled, the unpack_trees() method calls clear_ce_flags() to update the skip-wortree bits on the cache entries. This check can be expensive, depending on the patterns used. Add trace2 regions around the

[PATCH v3 07/17] trace2: add region in clear_ce_flags

2019-10-07 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler When Git updates the working directory with the sparse-checkout feature enabled, the unpack_trees() method calls clear_ce_flags() to update the skip-wortree bits on the cache entries. This check can be expensive, depending on the patterns used. Add trace2 regions around the

[PATCH v2 07/11] trace2: add region in clear_ce_flags

2019-09-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler When Git updates the working directory with the sparse-checkout feature enabled, the unpack_trees() method calls clear_ce_flags() to update the skip-wortree bits on the cache entries. This check can be expensive, depending on the patterns used. Add trace2 regions around the

[PATCH 6/9] trace2:experiment: clear_ce_flags_1

2019-08-20 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler The clear_ce_flags_1 method is used by many types of calls to unpack_trees(). Add trace2 regions around the method, including some flag information, so we can get granular performance data during experiments. Signed-off-by: Jeff Hostetler Signed-off-by: Derrick Stolee ---

[PATCH v3 1/7] trace2: cleanup column alignment in perf target format

2019-08-09 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Truncate/elide very long "filename:linenumber" field. Truncate region and data "category" field if necessary. Adjust overall column widths. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_perf.c | 39 +-- 1 file changed, 29 insertions(+

[PATCH v3 0/7] trace2: clean up formatting in perf target format

2019-08-09 Thread Jeff Hostetler via GitGitGadget
V2 of this patch series cleans up some whitespace and column alignment issues in the trace2 perf and normal formats. It also removes some dead code. Jeff Hostetler (7): trace2: cleanup column alignment in perf target format trace2: trim whitespace in region messages in perf target format tra

[PATCH v3 5/7] quote: add sq_append_quote_argv_pretty()

2019-08-09 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler sq_quote_argv_pretty() builds a "pretty" string from the given argv. It inserts whitespace before each value, rather than just between them, so the resulting string always has a leading space. Lets give callers an option to not have the leading space or have to ltrim() it la

[PATCH v3 4/7] trace2: trim trailing whitespace in normal format error message

2019-08-09 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Avoid creating unnecessary trailing whitespace in normal target format error messages when the message is omitted. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_normal.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/trace2/tr2_tgt_normal.c b

[PATCH v3 2/7] trace2: trim whitespace in region messages in perf target format

2019-08-09 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Avoid unecessary trailing whitespace in "region_enter" and "region_leave" messages in perf target format. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_perf.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/trace2/tr2_tgt_perf.c b/tra

[PATCH v3 3/7] trace2: remove dead code in maybe_add_string_va()

2019-08-09 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Remove an unnecessary "if" block in maybe_add_string_va(). Commit "ad006fe419e trace2: NULL is not allowed for va_list" changed "if (fmt && *fmt && ap)" to just "if (fmt && *fmt)" because it isn't safe to treat 'ap' as a pointer. This made the "if" block following it unnece

[PATCH v3 7/7] trace2: cleanup whitespace in perf format

2019-08-09 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Make use of new sq_append_quote_argv_pretty() to normalize how we handle leading whitespace in perf format messages. Signed-off-by: Jeff Hostetler --- t/t0211-trace2-perf.sh | 4 ++-- trace2/tr2_tgt_perf.c | 31 --- 2 files changed, 22 inserti

[PATCH v3 6/7] trace2: cleanup whitespace in normal format

2019-08-09 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Make use of new sq_append_quote_argv_pretty() to normalize how we handle leading whitespace in normal format messages. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_normal.c | 23 +-- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/tr

[PATCH v2 6/7] trace2: cleanup whitespace in normal format

2019-08-08 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Make use of new sq_quote_argv_pretty_ltrim() to normalize how we handle leading whitespace in normal format messages. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_normal.c | 21 - 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/trace2

[PATCH v2 2/7] trace2: trim whitespace in region messages in perf target format

2019-08-08 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Avoid unecessary trailing whitespace in "region_enter" and "region_leave" messages in perf target format. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_perf.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/trace2/tr2_tgt_perf.c b/tra

[PATCH v2 3/7] trace2: remove dead code in maybe_add_string_va()

2019-08-08 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Remove an unnecessary "if" block in maybe_add_string_va(). Commit "ad006fe419e trace2: NULL is not allowed for va_list" changed "if (fmt && *fmt && ap)" to just "if (fmt && *fmt)" because it isn't safe to treat 'ap' as a pointer. This made the "if" block following it unnece

[PATCH v2 7/7] trace2: cleanup whitespace in perf format

2019-08-08 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Make use of new sq_quote_argv_pretty_ltrim() to normalize how we handle leading whitespace in perf format messages. Signed-off-by: Jeff Hostetler --- t/t0211-trace2-perf.sh | 4 ++-- trace2/tr2_tgt_perf.c | 31 --- 2 files changed, 22 insertio

[PATCH v2 5/7] quote: add sq_quote_argv_pretty_ltrim

2019-08-08 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Create version of sq_quote_argv_pretty() that does not insert a leading space before argv[0]. Signed-off-by: Jeff Hostetler --- quote.c | 11 +++ quote.h | 1 + 2 files changed, 12 insertions(+) diff --git a/quote.c b/quote.c index 7f2aa6faa4..7cad8798ac 100644 -

[PATCH v2 4/7] trace2: trim trailing whitespace in normal format error message

2019-08-08 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Avoid creating unnecessary trailing whitespace in normal target format error messages when the message is omitted. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_normal.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/trace2/tr2_tgt_normal.c b

[PATCH v2 1/7] trace2: cleanup column alignment in perf target format

2019-08-08 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Truncate/elide very long "filename:linenumber" field. Truncate region and data "category" field if necessary. Adjust overall column widths. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_perf.c | 39 +-- 1 file changed, 29 insertions(+

[PATCH v2 0/7] trace2: clean up formatting in perf target format

2019-08-08 Thread Jeff Hostetler via GitGitGadget
V2 of this patch series cleans up some whitespace and column alignment issues in the trace2 perf and normal formats. It also removes some dead code. Jeff Hostetler (7): trace2: cleanup column alignment in perf target format trace2: trim whitespace in region messages in perf target format tra

[PATCH 0/3] trace2: clean up formatting in perf target format

2019-07-31 Thread Jeff Hostetler via GitGitGadget
This patch series contains a few column alignment and whitespace fixes for perf target format. This should make it a little easier to read. Jeff Hostetler (3): trace2: cleanup column alignment in perf target format trace2: trim whitespace in start message in perf target format trace2: trim w

[PATCH 3/3] trace2: trim whitespace in region messages in perf target format

2019-07-31 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Trim trailing whitespace in "region_enter" and "region_leave" messages in perf target format. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_perf.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/trace2/tr2_tgt_perf.c b/trace2/tr2_tgt_perf.c index ed4e708f28..3c7ff

[PATCH 1/3] trace2: cleanup column alignment in perf target format

2019-07-31 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Truncate/elide very long "filename:linenumber" field. Truncate region and data "category" field if necessary. Adjust overall column widths. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_perf.c | 39 +-- 1 file changed, 29 insertions(+

[PATCH 2/3] trace2: trim whitespace in start message in perf target format

2019-07-31 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Trim leading/trailing whitespace from the command line printed in the "start" message in the perf target format. We use `sq_quote_argv_pretty()` to format the message and it adds a leading space to the output. Trim that. Signed-off-by: Jeff Hostetler --- trace2/tr2_tgt_p

[PATCH v3 15/20] msvc: support building Git using MS Visual C++

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler With this patch, Git can be built using the Microsoft toolchain, via: make MSVC=1 [DEBUG=1] Third party libraries are built from source using the open source "vcpkg" tool set. See https://github.com/Microsoft/vcpkg On a first build, the vcpkg tools and the third pa

[PATCH v3 12/20] msvc: define ftello()

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler It is just called differently in MSVC's headers. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/msvc.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/compat/msvc.h b/compat/msvc.h index d336d80670..d7525cf61d 100644 --- a/compat/msvc.h

[PATCH v3 18/20] msvc: do not pretend to support all signals

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler This special-cases various signals that are not supported on Windows, such as SIGPIPE. These cause the UCRT to throw asserts (at least in debug mode). Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.c | 25 + 1 fil

[PATCH v3 11/20] msvc: do not re-declare the timespec struct

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler VS2015's headers already declare that struct. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/compat/mingw.h b/compat/mingw.h index 210f1b01a8..a03e40e6e2 100644 --- a/compat/mingw.h

[PATCH v3 13/20] msvc: fix detect_msys_tty()

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler The ntstatus.h header is only available in MINGW. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/winansi.c | 13 + 1 file changed, 13 insertions(+) diff --git a/compat/winansi.c b/compat/winansi.c index f4f08237f9..11cd9b82cc 1006

[PATCH v3 04/20] cache-tree/blame: avoid reusing the DEBUG constant

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler In MS Visual C, the `DEBUG` constant is set automatically whenever compiling with debug information. This is clearly not what was intended in `cache-tree.c` nor in `builtin/blame.c`, so let's use a less ambiguous name there. Signed-off-by: Jeff Hostetler Signed-off-by: Joh

[PATCH v3 20/20] msvc: ignore .dll and incremental compile output

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Ignore .dll files copied into the top-level directory. Ignore MSVC incremental compiler output files. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- .gitignore | 5 + 1 file changed, 5 insertions(+) diff --git a/.gitignore b/.gitignore index 237

[PATCH v3 10/20] msvc: mark a variable as non-const

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler VS2015 complains when using a const pointer in memcpy()/free(). Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/compat/mingw.c b/compat/mingw.c index 0d8713e515..d1

[PATCH v3 14/20] msvc: update Makefile to allow for spaces in the compiler path

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler It is quite common that MS Visual C++ is installed into a location whose path contains spaces, therefore we need to quote it. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/

[PATCH v3 16/20] msvc: add a compile-time flag to allow detailed heap debugging

2019-06-25 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler MS Visual C comes with a few neat features we can use to analyze the heap consumption (i.e. leaks, max memory, etc). With this patch, we introduce support via the build-time flag `USE_MSVC_CRTDBG`. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- comp

[PATCH v2 13/20] msvc: fix detect_msys_tty()

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler The ntstatus.h header is only available in MINGW. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/winansi.c | 13 + 1 file changed, 13 insertions(+) diff --git a/compat/winansi.c b/compat/winansi.c index f4f08237f9..11cd9b82cc 1006

[PATCH v2 15/20] msvc: support building Git using MS Visual C++

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler With this patch, Git can be built using the Microsoft toolchain, via: make MSVC=1 [DEBUG=1] Third party libraries are built from source using the open source "vcpkg" tool set. See https://github.com/Microsoft/vcpkg On a first build, the vcpkg tools and the third pa

[PATCH v2 12/20] msvc: define ftello()

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler It is just called differently in MSVC's headers. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/msvc.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/compat/msvc.h b/compat/msvc.h index d336d80670..d7525cf61d 100644 --- a/compat/msvc.h

[PATCH v2 04/20] cache-tree/blame: avoid reusing the DEBUG constant

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler In MS Visual C, the `DEBUG` constant is set automatically whenever compiling with debug information. This is clearly not what was intended in `cache-tree.c` nor in `builtin/blame.c`, so let's use a less ambiguous name there. Signed-off-by: Jeff Hostetler Signed-off-by: Joh

[PATCH v2 20/20] msvc: ignore .dll and incremental compile output

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Ignore .dll files copied into the top-level directory. Ignore MSVC incremental compiler output files. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- .gitignore | 5 + 1 file changed, 5 insertions(+) diff --git a/.gitignore b/.gitignore index 237

[PATCH v2 16/20] msvc: add a compile-time flag to allow detailed heap debugging

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler MS Visual C comes with a few neat features we can use to analyze the heap consumption (i.e. leaks, max memory, etc). With this patch, we introduce support via the build-time flag `USE_MSVC_CRTDBG`. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- comp

[PATCH v2 11/20] msvc: do not re-declare the timespec struct

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler VS2015's headers already declare that struct. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/compat/mingw.h b/compat/mingw.h index 210f1b01a8..a03e40e6e2 100644 --- a/compat/mingw.h

[PATCH v2 18/20] msvc: do not pretend to support all signals

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler This special-cases various signals that are not supported on Windows, such as SIGPIPE. These cause the UCRT to throw asserts (at least in debug mode). Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.c | 25 + 1 fil

[PATCH v2 10/20] msvc: mark a variable as non-const

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler VS2015 complains when using a const pointer in memcpy()/free(). Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/compat/mingw.c b/compat/mingw.c index 0d8713e515..d1

[PATCH v2 14/20] msvc: update Makefile to allow for spaces in the compiler path

2019-06-19 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler It is quite common that MS Visual C++ is installed into a location whose path contains spaces, therefore we need to quote it. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/

[PATCH 3/3] status: ignore status.aheadbehind in porcelain formats

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach porcelain V[12] formats to ignore the status.aheadbehind config setting. They only respect the --[no-]ahead-behind command line argument. This is for backwards compatibility with existing scripts. Signed-off-by: Jeff Hostetler Signed-off-by: Derrick Stolee --- buil

[PATCH 2/3] status: warn when a/b calculation takes too long

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler The ahead/behind calculation in 'git status' can be slow in some cases. Users may not realize that there are ways to avoid this computation, especially if they are not using the information. Add a warning that appears if this calculation takes more than two seconds. The warn

[PATCH 1/3] status: add status.aheadbehind setting

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler The --[no-]ahead-behind option was introduced in fd9b544a (status: add --[no-]ahead-behind to status and commit for V2 format, 2018-01-09). This is a necessary change of behavior in repos where the remote tracking branches can move very quickly ahead of the local branches. Ho

[PATCH 11/17] msvc: define ftello()

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler It is just called differently in MSVC's headers. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/msvc.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/compat/msvc.h b/compat/msvc.h index d336d80670..d7525cf61d 100644 --- a/compat/msvc.h

[PATCH 03/17] cache-tree.c: avoid reusing the DEBUG constant

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler In MSVC, the DEBUG constant is set automatically whenever compiling with debug information. This is clearly not what was intended in cache-tree.c, so let's use a less ambiguous constant there. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- cache-tre

[PATCH 09/17] msvc: mark a variable as non-const

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler VS2015 complains when using a const pointer in memcpy()/free(). Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/compat/mingw.c b/compat/mingw.c index 0d8713e515..d1

[PATCH 10/17] msvc: do not re-declare the timespec struct

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler VS2015's headers already declare that struct. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/compat/mingw.h b/compat/mingw.h index 210f1b01a8..a03e40e6e2 100644 --- a/compat/mingw.h

[PATCH 15/17] msvc: do not pretend to support all signals

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler This special-cases various signals that are not supported on Windows, such as SIGPIPE. These cause the UCRT to throw asserts (at least in debug mode). Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/mingw.c | 26 ++ 1 fi

[PATCH 13/17] msvc: support building Git using MS Visual C++

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler With this patch, Git can be built using the Microsoft toolchain, via: make MSVC=1 [DEBUG=1] Third party libraries are built from source using the open source "vcpkg" tool set. See https://github.com/Microsoft/vcpkg On a first build, the vcpkg tools and the third pa

[PATCH 17/17] msvc: ignore .dll and incremental compile output

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Ignore .dll files copied into the top-level directory. Ignore MSVC incremental compiler output files. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- .gitignore | 5 + 1 file changed, 5 insertions(+) diff --git a/.gitignore b/.gitignore index 237

[PATCH 12/17] msvc: fix detect_msys_tty()

2019-06-18 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler The ntstatus.h header is only available in MINGW. Signed-off-by: Jeff Hostetler Signed-off-by: Johannes Schindelin --- compat/winansi.c | 13 + 1 file changed, 13 insertions(+) diff --git a/compat/winansi.c b/compat/winansi.c index f4f08237f9..11cd9b82cc 1006

[PATCH 1/1] diffcore-rename: speed up register_rename_src

2019-06-08 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach register_rename_src() to see if new file pair can simply be appended to the rename_src[] array before performing the binary search to find the proper insertion point. This is a performance optimization. This routine is called during run_diff_files in status and the ca

[PATCH 05/11] status: add warning when a/b calculation takes too long for long/normal format

2019-06-03 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Signed-off-by: Jeff Hostetler Signed-off-by: Derrick Stolee --- advice.c| 2 ++ advice.h| 1 + wt-status.c | 17 + 3 files changed, 20 insertions(+) diff --git a/advice.c b/advice.c index ce5f374ecd..54f8dea30c 100644 --- a/advice.c +++ b/advice.

[PATCH 06/11] status: ignore status.aheadbehind in porcelain formats

2019-06-03 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach porcelain V[12] formats to ignore the status.aheadbehind config setting. They only respect the --[no-]ahead-behind command line argument. This is for backwards compatibility with existing scripts. Signed-off-by: Jeff Hostetler Signed-off-by: Derrick Stolee --- buil

[PATCH 04/11] status: add status.aheadbehind setting

2019-06-03 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add "status.aheadbehind" config setting to change the default behavior of ALL git status formats. Signed-off-by: Jeff Hostetler Signed-off-by: Derrick Stolee --- Documentation/config/status.txt | 5 + builtin/commit.c| 17 - t/t6040-tr

[PATCH 0/1] trace2: fix tracing when NO_PTHREADS is defined

2019-05-21 Thread Jeff Hostetler via GitGitGadget
This commit addresses the problem reported in: https://public-inbox.org/git/92cfdf43-8841-9c5a-7838-dda995038...@jeffhostetler.com/T/#mbaf8069f6d1bc18d5a02d3682a1f9282f5547ea9 As Duy suggested, pthread_getspecific() just returns NULL when NO_PTHREADS is defined. And pthread_setspecific() silently

[PATCH 1/1] trace2: fix tracing when NO_PTHREADS is defined

2019-05-21 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach trace2 TLS code to not rely on pthread_getspecific() when NO_PTHREADS is defined. Instead, always assume the context data of the main thread. Signed-off-by: Jeff Hostetler --- trace2/tr2_tls.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) diff

[PATCH v5 08/11] trace2: clarify UTC datetime formatting

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Update tr2_tbuf_utc_datetime to generate extended UTC format. Update tr2_tgt_event target to use extended format in 'time' columns. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 12 ++-- trace2/tr2_tbuf.c | 4 ++--

[PATCH v5 01/11] config: initialize opts structure in repo_read_config()

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Initialize opts structure in repo_read_config(). This change fixes a crash in later commit after a new field is added to the structure. In commit 3b256228a66f8587661481ef3e08259864f3ba2a, repo_read_config() was added. It only initializes 3 fields in the opts structure. It

[PATCH v5 02/11] trace2: refactor setting process starting time

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Create trace2_initialize_clock() and call from main() to capture process start time in isolation and before other sub-systems are ready. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 12 ++-- common-main.c | 2 ++

[PATCH v5 00/11] trace2: load trace2 settings from system config

2019-04-29 Thread Jeff Hostetler via GitGitGadget
Version 4 fixes a few clang-format warnings and simplifies the PID field in the SID. Jeff Hostetler (11): config: initialize opts structure in repo_read_config() trace2: refactor setting process starting time trace2: add absolute elapsed time to start event trace2: find exec-dir before tra

[PATCH v5 06/11] trace2: use system/global config for default trace2 settings

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach git to read the system and global config files for default Trace2 settings. This allows system-wide Trace2 settings to be installed and inherited to make it easier to manage a collection of systems. The original GIT_TR2* environment variables are loaded afterwards and

[PATCH v5 11/11] trace2: fixup access problem on /etc/gitconfig in read_very_early_config

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach do_git_config_sequence() to optionally gently check for access to the system config. Use this option in read_very_early_config() when initializing trace2. In [1] SZEDER Gábor reported that my changes in [2] introduced a regression when the user does not have permissio

[PATCH v5 03/11] trace2: add absolute elapsed time to start event

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add elapsed process time to "start" event to measure the performance of early process startup. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 11 ++- t/t0211-trace2-perf.sh | 12 ++-- trace2.c

[PATCH v5 04/11] trace2: find exec-dir before trace2 initialization

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach Git to resolve the executable directory before initializing Trace2. This allows the system configuration directory to be discovered earlier (because it is sometimes relative to the prefix or runtime-prefix). This will be used by the next commit to allow trace2 setting

[PATCH v5 05/11] config: add read_very_early_config()

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Created an even lighter version of read_early_config() that only looks at system and global config settings. It omits repo-local, worktree-local, and command-line settings. Signed-off-by: Jeff Hostetler --- config.c | 23 --- config.h | 4 2 file

[PATCH v5 07/11] trace2: report peak memory usage of the process

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach Windows version of git to report peak memory usage during exit() processing. Signed-off-by: Jeff Hostetler --- common-main.c| 2 +- compat/win32/trace2_win32_process_info.c | 50 ++-- trace2.c

[PATCH v5 09/11] trace2: make SIDs more unique

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Update SID component construction to use the current UTC datetime and a portion of the SHA1 of the hostname. Use an simplified date/time format to make it easier to use the SID component as a logfile filename. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-

[PATCH v5 10/11] trace2: update docs to describe system/global config settings

2019-04-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Signed-off-by: Jeff Hostetler --- Documentation/config.txt | 2 + Documentation/config/trace2.txt| 56 + Documentation/technical/api-trace2.txt | 151 ++--- Documentation/trace2-target-values.txt | 10 ++ 4 files changed

[PATCH v4 08/10] trace2: clarify UTC datetime formatting

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Update tr2_tbuf_utc_datetime to generate extended UTC format. Update tr2_tgt_event target to use extended format in 'time' columns. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 12 ++-- trace2/tr2_tbuf.c | 4 ++--

[PATCH v4 07/10] trace2: report peak memory usage of the process

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach Windows version of git to report peak memory usage during exit() processing. Signed-off-by: Jeff Hostetler --- common-main.c| 2 +- compat/win32/trace2_win32_process_info.c | 50 ++-- trace2.c

[PATCH v4 09/10] trace2: make SIDs more unique

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Update SID component construction to use the current UTC datetime and a portion of the SHA1 of the hostname. Use an simplified date/time format to make it easier to use the SID component as a logfile filename. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-

[PATCH v4 02/10] trace2: refactor setting process starting time

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Create trace2_initialize_clock() and call from main() to capture process start time in isolation and before other sub-systems are ready. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 12 ++-- common-main.c | 2 ++

[PATCH v4 03/10] trace2: add absolute elapsed time to start event

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add elapsed process time to "start" event to measure the performance of early process startup. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 11 ++- t/t0211-trace2-perf.sh | 12 ++-- trace2.c

[PATCH v4 10/10] trace2: update docs to describe system/global config settings

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Signed-off-by: Jeff Hostetler --- Documentation/config.txt | 2 + Documentation/config/trace2.txt| 56 + Documentation/technical/api-trace2.txt | 151 ++--- Documentation/trace2-target-values.txt | 10 ++ 4 files changed

[PATCH v4 05/10] config: add read_very_early_config()

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Created an even lighter version of read_early_config() that only looks at system and global config settings. It omits repo-local, worktree-local, and command-line settings. Signed-off-by: Jeff Hostetler --- config.c | 23 --- config.h | 4 2 file

[PATCH v4 01/10] config: initialize opts structure in repo_read_config()

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Initialize opts structure in repo_read_config(). This change fixes a crash in later commit after a new field is added to the structure. In commit 3b256228a66f8587661481ef3e08259864f3ba2a, repo_read_config() was added. It only initializes 3 fields in the opts structure. It

[PATCH v4 06/10] trace2: use system/global config for default trace2 settings

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach git to read the system and global config files for default Trace2 settings. This allows system-wide Trace2 settings to be installed and inherited to make it easier to manage a collection of systems. The original GIT_TR2* environment variables are loaded afterwards and

[PATCH v4 04/10] trace2: find exec-dir before trace2 initialization

2019-04-15 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach Git to resolve the executable directory before initializing Trace2. This allows the system configuration directory to be discovered earlier (because it is sometimes relative to the prefix or runtime-prefix). This will be used by the next commit to allow trace2 setting

[PATCH v4 00/10] trace2: load trace2 settings from system config

2019-04-15 Thread Jeff Hostetler via GitGitGadget
Version 4 fixes a few clang-format warnings and simplifies the PID field in the SID. Jeff Hostetler (10): config: initialize opts structure in repo_read_config() trace2: refactor setting process starting time trace2: add absolute elapsed time to start event trace2: find exec-dir before tra

[PATCH v3 06/10] trace2: use system/global config for default trace2 settings

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach git to read the system and global config files for default Trace2 settings. This allows system-wide Trace2 settings to be installed and inherited to make it easier to manage a collection of systems. The original GIT_TR2* environment variables are loaded afterwards and

[PATCH v3 02/10] trace2: refactor setting process starting time

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Create trace2_initialize_clock() and call from main() to capture process start time in isolation and before other sub-systems are ready. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 12 ++-- common-main.c | 2 ++

[PATCH v3 04/10] trace2: find exec-dir before trace2 initialization

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach Git to resolve the executable directory before initializing Trace2. This allows the system configuration directory to be discovered earlier (because it is sometimes relative to the prefix or runtime-prefix). This will be used by the next commit to allow trace2 setting

[PATCH v3 05/10] config: add read_very_early_config()

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Created an even lighter version of read_early_config() that only looks at system and global config settings. It omits repo-local, worktree-local, and command-line settings. Signed-off-by: Jeff Hostetler --- config.c | 25 ++--- config.h | 4 2 fi

[PATCH v3 03/10] trace2: add absolute elapsed time to start event

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Add elapsed process time to "start" event to measure the performance of early process startup. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 11 ++- t/t0211-trace2-perf.sh | 12 ++-- trace2.c

[PATCH v3 10/10] trace2: update docs to describe system/global config settings

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Signed-off-by: Jeff Hostetler --- Documentation/config.txt | 2 + Documentation/config/trace2.txt| 56 ++ Documentation/technical/api-trace2.txt | 141 ++--- Documentation/trace2-target-values.txt | 10 ++ 4 files change

[PATCH v3 09/10] trace2: make SIDs more unique

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Update SID component construction to use the current UTC datetime and a portion of the SHA1 of the hostname. Use an simplified date/time format to make it easier to use the SID component as a logfile filename. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-

[PATCH v3 08/10] trace2: clarify UTC datetime formatting

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Update tr2_tbuf_utc_datetime to generate extended UTC format. Update tr2_tgt_event target to use extended format in 'time' columns. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 12 ++-- trace2/tr2_tbuf.c | 4 ++--

[PATCH v3 07/10] trace2: report peak memory usage of the process

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach Windows version of git to report peak memory usage during exit() processing. Signed-off-by: Jeff Hostetler --- common-main.c| 2 +- compat/win32/trace2_win32_process_info.c | 50 ++-- trace2.c

[PATCH v3 00/10] trace2: load trace2 settings from system config

2019-04-11 Thread Jeff Hostetler via GitGitGadget
Here is version 3. [] It incorporates Ævar's suggestions WRT the format and uniqueness of the SID. [] It now reads both system and global config for trace2 settings and handles includes as Jonathan suggested. I added a read_very_early_config() function that is similar to read_early_config()but om

[PATCH v3 01/10] config: initialize opts structure in repo_read_config()

2019-04-11 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Initialize opts structure in repo_read_config(). This change fixes a crash in later commit after a new field is added to the structure. In commit 3b256228a66f8587661481ef3e08259864f3ba2a, repo_read_config() was added. It only initializes 3 fields in the opts structure. It

[PATCH v2 7/7] trace2: make SIDs more unique

2019-03-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Update SID component construction to use the current UTC datetime and a portion of the SHA1 of the hostname. Use an simplified date/time format to make it easier to use the SID component as a logfile filename. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-

[PATCH v2 5/7] trace2: report peak memory usage of the process

2019-03-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach Windows version of git to report peak memory usage during exit() processing. Signed-off-by: Jeff Hostetler --- common-main.c| 2 +- compat/win32/trace2_win32_process_info.c | 50 ++-- trace2.c

[PATCH v2 6/7] trace2: clarify UTC datetime formatting

2019-03-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Update tr2_tbuf_utc_datetime to generate extended UTC format. Update tr2_tgt_event target to use extended format in 'time' columns. Signed-off-by: Jeff Hostetler --- Documentation/technical/api-trace2.txt | 12 ++-- trace2/tr2_tbuf.c | 4 ++--

[PATCH v2 3/7] trace2: find exec-dir before trace2 initialization

2019-03-29 Thread Jeff Hostetler via GitGitGadget
From: Jeff Hostetler Teach Git to resolve the executable directory before initializing Trace2. This allows the system configuration directory to be discovered earlier (because it is sometimes relative to the prefix or runtime-prefix). This will be used by the next commit to allow trace2 setting

  1   2   3   >