Skip to content

git commit take unexpected long time for Cygwin #3490

Closed

Description

@nhatkhai

It seem to me every time I commit a normal files (text file) with small change took more than 40seconds to be finished.
When I look at the TRACE, it seem to be delay for a while at 11:42:05.182320 trace git-lfs: exec: git 'version'.
Also, run git lfs install is really slow too. Wounder they are relate.
I Also noted that git lfs env took a quite a long time to complete too.
See all the log bellow:

git commit -a -m ".................."
11:42:04.475541 git.c:344               trace: built-in: git commit -a -m '...........'
11:42:04.842330 run-command.c:640       trace: run_command: git gc --auto
11:42:04.920327 git.c:344               trace: built-in: git gc --auto
11:42:04.935927 run-command.c:640       trace: run_command: GIT_EDITOR=: GIT_INDEX_FILE=/cygdrive/c/projects/git/XYZ/.git/modules/XX/YY/index /cygdrive/c/projects/git/XYZ/.git/modules/XX/YY/hooks/post-commit
11:42:05.091922 git.c:576               trace: exec: git-lfs post-commit
11:42:05.091922 run-command.c:640       trace: run_command: git-lfs post-commit
11:42:05.182320 trace git-lfs: exec: git 'version'
11:43:23.773230 trace git-lfs: exec: git 'config' '-l'
11:43:34.398492 trace git-lfs: exec: git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'
11:43:47.358082 trace git-lfs: filepathfilter: rewrite ".git" as "**/.git/**"
11:43:47.358082 trace git-lfs: filepathfilter: rewrite "**/.git" as "**/.git"
11:43:47.358082 trace git-lfs: filepathfilter: rejecting "YY" via []
11:43:47.358082 trace git-lfs: filepathfilter: accepting "YY"
11:43:47.358082 trace git-lfs: filepathfilter: rewrite "~*.*" as "**/~*.*"
....
(519)$ git-lfs version
git-lfs/2.6.1 (GitHub; windows amd64; go 1.11.1; git dc072c3e)
(519)$ git version
11:52:17.642972 git.c:344               trace: built-in: git version
git version 2.17.0
(521)$ git-lfs env
11:55:22.963372 trace git-lfs: exec: git 'version'
git-lfs/2.6.1 (GitHub; windows amd64; go 1.11.1; git dc072c3e)
git version 2.17.0

11:55:35.774772 trace git-lfs: exec: git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'
11:56:54.454613 trace git-lfs: exec: git 'config' '-l'
Endpoint=https://stash.ZZZZ.com/att/YY.git/info/lfs (auth=basic)
  [email protected]:att/YY.git
LocalWorkingDir=C:\projects\git\XYZ\XX\YY
LocalGitDir=C:\projects\git\XYZ\.git\modules\XX\YY
LocalGitStorageDir=C:\projects\git\XYZ\.git\modules\XX\YY
LocalMediaDir=C:\projects\git\XYZ\.git\modules\XX\YY\lfs\objects
LocalReferenceDirs=
TempDir=C:\projects\git\XYZ\.git\modules\XX\YY\lfs\tmp
ConcurrentTransfers=3
TusTransfers=false
BasicTransfersOnly=false
SkipDownloadErrors=false
FetchRecentAlways=false
FetchRecentRefsDays=7
FetchRecentCommitsDays=0
FetchRecentRefsIncludeRemotes=true
PruneOffsetDays=3
PruneVerifyRemoteAlways=false
PruneRemoteName=origin
LfsStorageDir=C:\projects\git\XYZ\.git\modules\XX\YY\lfs
AccessDownload=basic
AccessUpload=basic
DownloadTransfers=basic
UploadTransfers=basic
GIT_CURL_VERBOSE=1
GIT_LFS_PATH=C:\Program Files\Git LFS
GIT_TRACE=1
git config filter.lfs.process = "git-lfs filter-process"
git config filter.lfs.smudge = "git-lfs smudge -- %f"
git config filter.lfs.clean = "git-lfs clean -- %f"
11:56:58.899219 trace git-lfs: filepathfilter: rewrite ".git" as "**/.git/**"
11:56:58.899219 trace git-lfs: filepathfilter: rewrite "**/.git" as "**/.git"
11:56:58.899219 trace git-lfs: filepathfilter: rejecting "tmp" via []
11:56:58.899219 trace git-lfs: filepathfilter: accepting "tmp"
11:56:58.899219 trace git-lfs: filepathfilter: rejecting "objects" via []
11:56:58.899219 trace git-lfs: filepathfilter: accepting "objects"

Activity

  1. bk2204 commented on Jan 23, 2019

    @bk2204
    Member

    Hey, sorry to hear you're having trouble.

    It looks like for some reason one of two things is happening:

    1. Invoking git is for some reason very expensive.
    2. We're spending a lot of time waiting on or handling an internal lock that's used for reading both Git configuration and references.

    I'm not seeing this on my system.

    @nhatkhai, can you try running each of those commands on the command line, prefixed with time, and put the output here? I'd like to see if that's the cause of the issue.

    Also, it looks like you're using Cygwin. Are you using Cygwin's Git, or Git for Windows? And are you using Git LFS from Git for Windows, or specifically built for Cygwin?

    @ttaylorr, do you happen to know why we use a single lock for all of these cases? I'm wondering if it might perform better if we used independent sync.Once values here (stuffing them into a struct for tidiness).

  2. nhatkhai commented on Jan 23, 2019

    @nhatkhai
    Author

    @bk2204, I'm using Cygwin git, and git-lfs for windows. Which command line you want me to run with time? I think the trace have all the time stamp which is very clear to see. I'm not sure time prefix would show any more useful info.

    I try ran in with Git for windows, and git-lfs for windows. It much much better:

    C:\projects\git\XYZ\HW\YY>git commit -a -m "....."
    17:09:21.891198 exec-cmd.c:236          trace: resolved executable dir: C:/Program Files/Git/mingw64/bin
    17:09:21.906798 git.c:415               trace: built-in: git commit -a -m '....'
    The file will have its original line endings in your working directory.
    17:09:22.109599 run-command.c:637       trace: run_command: git gc --auto
    17:09:22.187600 exec-cmd.c:236          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
    17:09:22.187600 git.c:415               trace: built-in: git gc --auto
    17:09:22.203200 run-command.c:637       trace: run_command: GIT_EDITOR=: GIT_INDEX_FILE=C:/projects/git/XYZ/.git/mod
    ules/XX/YY/index C:/projects/git/XYZ/.git/modules/XX/YY/hooks/post-commit
    17:09:22.344601 exec-cmd.c:236          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
    17:09:22.344601 git.c:654               trace: exec: git-lfs post-commit
    17:09:22.344601 run-command.c:637       trace: run_command: git-lfs post-commit
    17:09:22.424405 trace git-lfs: exec: git 'version'
    17:09:22.821444 trace git-lfs: exec: git 'config' '-l'
    17:09:22.887451 trace git-lfs: exec: git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '
    -c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'
    17:09:22.957458 trace git-lfs: filepathfilter: rewrite ".git" as "**/.git/**"
    17:09:22.958458 trace git-lfs: filepathfilter: rewrite "**/.git" as "**/.git"
    17:09:22.960458 trace git-lfs: filepathfilter: rejecting "YY" via []
    17:09:22.961458 trace git-lfs: filepathfilter: accepting "YY"
    17:09:22.963459 trace git-lfs: filepathfilter: rewrite "~*.*" as "**/~*.*"
    17:09:22.964459 trace git-lfs: filepathfilter: rewrite "*.sw[op]" as "**/*.sw[op]"
    17:09:22.966459 trace git-lfs: filepathfilter: rewrite "*.bak" as "**/*.bak"
    17:09:22.968459 trace git-lfs: filepathfilter: rewrite "*.bck" as "**/*.bck"
    17:09:22.969459 trace git-lfs: filepathfilter: rewrite ".idea" as "**/.idea/**"
    17:09:22.970459 trace git-lfs: filepathfilter: rewrite "*.pyc" as "**/*.pyc"
    17:09:22.973460 trace git-lfs: filepathfilter: rejecting ".git" via []
    17:09:22.973460 trace git-lfs: filepathfilter: rejecting ".git" via ".git"
    17:09:22.975460 trace git-lfs: filepathfilter: rejecting ".gitattributes" via []
    17:09:22.976460 trace git-lfs: filepathfilter: accepting ".gitattributes"
    17:09:22.977460 trace git-lfs: filepathfilter: rejecting ".gitignore" via []
    17:09:22.979460 trace git-lfs: filepathfilter: accepting ".gitignore"
    17:09:22.980460 trace git-lfs: filepathfilter: rejecting "YY_PROBLEM.md" via []
    17:09:22.981460 trace git-lfs: filepathfilter: accepting "YY_PROBLEM.md"
    ..... (the rest are extremely fast)
    
  3. ttaylorr commented on Jan 23, 2019

    @ttaylorr
    Contributor

    @ttaylorr, do you happen to know why we use a single lock for all of these cases?

    Could you clarify which locks you're talking about? It looks like the slowdown is happening from some call in git lfs post-commit, but I was only able to spot out the 'git version' call immediately.

    I was able to implement the replacement that you're talking about (I think, see #3492), but if there are other places that you are thinking about, too, I'd be happy to look there too.

  4. nhatkhai commented on Jan 24, 2019

    @nhatkhai
    Author

    Yes it was slow down at 11:42:05.182320 to 11:43:47.358082.
    And 11:55:22.963372 to 11:56:54.454613

    And here it also slow similar way for git-lfs install (from 18:57:51.630246 to 19:00:09.058246):

    (522)$ git lfs install
    18:57:51.491246 git.c:576               trace: exec: git-lfs install
    18:57:51.494246 run-command.c:640       trace: run_command: git-lfs install
    18:57:51.630246 trace git-lfs: exec: git 'version'
    18:58:04.442246 trace git-lfs: exec: git 'config' '--global' 'filter.lfs.clean'
    18:58:18.151246 trace git-lfs: exec: git 'config' '--global' 'filter.lfs.smudge'
    18:58:29.161246 trace git-lfs: exec: git 'config' '--global' 'filter.lfs.process'
    18:58:40.960246 trace git-lfs: exec: git 'config' '--global' 'filter.lfs.required'
    18:58:55.805246 trace git-lfs: exec: git 'config' '--global' '--replace-all' 'filter.lfs.required' 'true'
    19:00:09.058246 trace git-lfs: exec: git 'config' '-l'
    19:00:20.589246 trace git-lfs: Install hook: pre-push, force=false, path=C:\projects\git\XYZ\.git\modules\XX\YY\hooks\pre-push, upgrading...
    19:00:20.591246 trace git-lfs: Install hook: post-checkout, force=false, path=C:\projects\git\XYZ\.git\modules\XX\YY\hooks\post-checkout, upgrading...
    19:00:20.595246 trace git-lfs: Install hook: post-commit, force=false, path=C:\projects\git\XYZ\.git\modules\XX\YY\hooks\post-commit, upgrading...
    19:00:20.609246 trace git-lfs: Install hook: post-merge, force=false, path=C:\projects\git\XYZ\.git\modules\XX\YY\hooks\post-merge, upgrading...
    

    My Global .gitconfig file look like:

    [core]
    	editor = vim
    	eol = CRLF
    	autocrlf = true
    	filemode = false
    
    [pull]
        rebase = true
    
    [difftool]
    	prompt = false
    [difftool.vimdiff]
        #cmd = mintty -w max -e vimdiff \"$LOCAL\" \"$REMOTE\"
    	cmd = vimdiff \"$LOCAL\" \"$REMOTE\"
    [difftool.winmerge]
    	cmd = \"C:/Program Files (x86)/WinMerge/winmergeu.exe\" -e -u \"$LOCAL\" \"$REMOTE\"
    	trustExitCode = true
    [difftool "tmerge"]
    	cmd = \"C:/Program Files/TortoiseGit/bin/TortoiseGitMerge.exe\" \"$LOCAL\" \"$REMOTE\"
    	trustExitCode = true
    [diff]
    	tool = vimdiff
    	guitool = winmerge
    
    [mergetool]
    	prompt = false
    [mergetool.vimdiff]
        #cmd = mintty -w max -e vimdiff \"$LOCAL\" \"$MERGED\" \"$REMOTE\"
    	cmd = vimdiff \"$LOCAL\" \"$MERGED\" \"$REMOTE\"
    [mergetool.winmerge]
    	cmd = \"C:/Program Files (x86)/WinMerge/WinMergeU.exe\" -e -u \"$LOCAL\" \"$REMOTE\" \"$MERGED\"
    	trustExitCode = true
    [mergetool "TortoiseMerge"]
    	cmd = \"C:/Program Files/TortoiseGit/bin/TortoiseGitMerge.exe\" -base:\"$BASE\" -mine:\"$LOCAL\" -theirs:\"$REMOTE\" -merged:\"$MERGED\"
    	trustExitCode = true
    [merge]
    	tool = vimdiff
    	guitool = winmerge
    	conflictstyle = diff3
    
    [alias]
    	d = difftool
    
    [credential]
    	helper = cache --timeout=7200
    
    [lfs]
      contenttype = false
    
    [filter "lfs"]
    	clean = git-lfs clean -- %f
    	smudge = git-lfs smudge -- %f
    	process = git-lfs filter-process
    	required = true
    
    [include]
      path = ~/.gitconfig_local  # <--- This use set my user name and email
    

    My project .git/config file look like:

    [core]
    	repositoryformatversion = 0
    	bare = false
    	logallrefupdates = true
    	ignorecase = true
    [remote "origin"]
    	url = ssh://[email protected]:7999/BB/XYZ.git
    	fetch = +refs/heads/master:refs/remotes/origin/master
    	fetch = +refs/heads/feature/*:refs/remotes/origin/feature/*
    [lfs "https://stash.AAA.com/BB/XYZ.git/info/lfs"]
    	access = basic
    [branch "TTT/SS"]
    [lfs "https://stash.AAA.com/BB/TTT.git/info/lfs"]
    	access = basic
    [gui]
    	wmstate = normal
    	geometry = 848x395+1676+76 191 179
    [remote "TTT"]
    	url = ssh://[email protected]:7999/BB/TTT.git
    	fetch = +refs/heads/feature/XYZ/sw:refs/remotes/TTT/feature/XYZ/sw
    	fetch = +refs/heads/feature/XYZ/XX/ecg/ftdi:refs/remotes/TTT/feature/XYZ/XX/ecg/ftdi
    [branch "TTT/SS"]
    	remote = TTT
    	merge = refs/heads/feature/XYZ/sw
    [submodule "XX/YY"]
    	url = ssh://[email protected]:7999/BB/YY.git
    	active = true
    [branch "feature/www"]
    	remote = origin
    	merge = refs/heads/feature/www
    [branch "feature/SS_prototype/0"]
    	remote = origin
    	merge = refs/heads/feature/SS_prototype
    [branch "feature/SS_prototype/1"]
    	remote = origin
    	merge = refs/heads/feature/SS_prototype
    
  5. nhatkhai commented on Jan 24, 2019

    @nhatkhai
    Author

    Is there a git-lfs image build for cygwin?
    Not all the project I used are slow, most only once that have lfs files. It wasn't this slow before, but may be after I introduce submodule which also have lfs files.

  6. bk2204 commented on Jan 24, 2019

    @bk2204
    Member

    Could you clarify which locks you're talking about? It looks like the slowdown is happening from some call in git lfs post-commit, but I was only able to spot out the 'git version' call immediately.

    Of course. I was thinking about the loading mutex. My conjecture was that we were in some way contending on that mutex, since we see a slowdown between each pair of git version, git rev-parse, and git config.

  7. bk2204 commented on Jan 24, 2019

    @bk2204
    Member

    The reason I asked to run with the time command is because I want to see if this is an issue with Git LFS (i.e., that it has a bad interaction with Cygwin) or if the issue is that Git itself is for some reason slow on Cygwin. If running the Git commands themselves is slow, then that's a separate issue.

    I'd want the time command to be run in the environment in which you're running your code. So if that's Cygwin, then Cygwin is the place to run the commands.

    I'm not aware of any native builds for Cygwin, since Go doesn't have that as a target architecture. There was some discussion of it, but it doesn't seem to have gotten off the ground.

  8. nhatkhai commented on Jan 24, 2019

    @nhatkhai
    Author
    (582)$ time git commit -a -m "Refactoring, and improve documentation"
    14:17:02.902935 git.c:344               trace: built-in: git commit -a -m 'Refactoring, and improve documentation'
    14:17:03.443989 run-command.c:640       trace: run_command: git gc --auto
    14:17:03.568002 git.c:344               trace: built-in: git gc --auto
    14:17:03.585003 run-command.c:640       trace: run_command: GIT_EDITOR=: GIT_INDEX_FILE=/cygdrive/c/projects/git/XYZ/.git/modules/XX/YY/index /cygdrive/c/projects/git/XYZ/.git/modules/XX/YY/hooks/post-commit
    14:17:03.745019 git.c:576               trace: exec: git-lfs post-commit
    14:17:03.749020 run-command.c:640       trace: run_command: git-lfs post-commit
    14:17:03.954040 trace git-lfs: exec: git 'version'
    14:17:53.250969 trace git-lfs: exec: git 'config' '-l'
    14:17:57.431387 trace git-lfs: exec: git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'
    14:18:01.575802 trace git-lfs: filepathfilter: rewrite ".git" as "**/.git/**"
    14:18:01.575802 trace git-lfs: filepathfilter: rewrite "**/.git" as "**/.git"
    14:18:01.575802 trace git-lfs: filepathfilter: rejecting "YY" via []
    ...
    14:18:01.597804 trace git-lfs: filepathfilter: accepting "lib/3dpackage/conns/USB_type_B.wrl"
    [feature/XYZ/SSS 436edd0] Refactoring, and improve documentation
     3 files changed, 286 insertions(+), 192 deletions(-)
     create mode 100644 scripts/libs/utils.py
    
    real    0m58.852s
    user    0m0.138s
    sys     0m0.760s
    
  9. bk2204 commented on Jan 24, 2019

    @bk2204
    Member

    I'm sorry, I think I was unclear. The time output I was looking for was for the git commands that appear in the trace output, namely the following:

    $ time git version
    $ time git config -l
    $ time git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'

    I want to find out if git version and git config -l that are slow or if it's Git LFS's handling of their output.

  10. nhatkhai commented on Jan 24, 2019

    @nhatkhai
    Author
    (587)$ time git version
    15:47:24.353504 git.c:344               trace: built-in: git version
    git version 2.17.0
    
    real    0m0.091s
    user    0m0.000s
    sys     0m0.092s
    
    (587)$ time git config -l
    15:47:31.708504 git.c:344               trace: built-in: git config -l
    15:47:31.728504 run-command.c:640       trace: run_command: unset GIT_PAGER_IN_USE; LESS=FRX LV=-c less
    core.editor=vim
    core.eol=CRLF
    core.autocrlf=true
    core.filemode=false
    pull.rebase=true
    difftool.prompt=false
    difftool.vimdiff.cmd=vimdiff "$LOCAL" "$REMOTE"
    difftool.winmerge.cmd="C:/Program Files (x86)/WinMerge/winmergeu.exe" -e -u "$LOCAL" "$REMOTE"
    difftool.winmerge.trustexitcode=true
    difftool.tmerge.cmd="C:/Program Files/TortoiseGit/bin/TortoiseGitMerge.exe" "$LOCAL" "$REMOTE"
    difftool.tmerge.trustexitcode=true
    diff.tool=vimdiff
    diff.guitool=winmerge
    mergetool.prompt=false
    mergetool.vimdiff.cmd=vimdiff "$LOCAL" "$MERGED" "$REMOTE"
    mergetool.winmerge.cmd="C:/Program Files (x86)/WinMerge/WinMergeU.exe" -e -u "$LOCAL" "$REMOTE" "$MERGED"
    mergetool.winmerge.trustexitcode=true
    mergetool.TortoiseMerge.cmd="C:/Program Files/TortoiseGit/bin/TortoiseGitMerge.exe" -base:"$BASE" -mine:"$LOCAL" -theirs:"$REMOTE" -merged:"$MERGED"
    mergetool.TortoiseMerge.trustexitcode=true
    merge.tool=vimdiff
    merge.guitool=winmerge
    merge.conflictstyle=diff3
    alias.d=difftool
    credential.helper=cache --timeout=7200
    lfs.contenttype=false
    filter.lfs.clean=git-lfs clean -- %f
    filter.lfs.smudge=git-lfs smudge -- %f
    filter.lfs.process=git-lfs filter-process
    include.path=~/.gitconfig_local
    user.name=nnnnnn
    [email protected]
    core.repositoryformatversion=0
    core.bare=false
    core.logallrefupdates=true
    core.ignorecase=true
    core.worktree=../../../../XX/YY
    remote.origin.url=ssh://[email protected]:7999/att/YY.git
    remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
    branch.feature/XYZ/SSS.remote=origin
    branch.feature/XYZ/SSS.merge=refs/heads/feature/XYZ/SSS
    lfs.https://stash.AAA.com/att/YY.git/info/lfs.access=basic
    
    real    0m0.357s
    user    0m0.015s
    sys     0m0.232s
    
    (587)$ time git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'
    15:47:55.591504 git.c:344               trace: built-in: git rev-parse HEAD --symbolic-full-name HEAD
    436edd08e3e8544abb649181989a0fb186a3d0a7
    refs/heads/feature/XYZ/SSS
    
    real    0m0.200s
    user    0m0.015s
    sys     0m0.093s
    
  11. ttaylorr commented on Jan 26, 2019

    @ttaylorr
    Contributor

    Could you clarify which locks you're talking about? It looks like the slowdown is happening from some call in git lfs post-commit, but I was only able to spot out the 'git version' call immediately.

    Of course. I was thinking about the loading mutex.

    Thanks for the clarification. I looked into whether or not this was doable in config/config.go, and I think that our current use of sync.Mutex is (in the general sense) appropriate. We use the loading mutex for one of two things:

    1. Making sure that we have loaded a value (e.g., in the same way that you would otherwise use sync.Once), or,
    2. Making sure that we don't contend loading any of the values in (1) during a clean-up operation, or (2) other mutable change.

    The Git configuration values themselves are handled differently. For these, we use 2 implementations of the config.Environment interface: gitEnvironment and delayedEnvironment. Upon construction, a gitEnvironment reads all of the values in the repository's configuration, and builds a corresponding map[string]string. To avoid doing this until the last possible moment, we use a delayedEnvironment, which delays construction until the first time a query is issued.

    So I don't think that there is a ton of work for us to do that would meaningfully improve the performance issues that we're seeing here. Is it possible that these are coming as a result of some interaction between Git LFS and Cygwin? If so, I don't know that there's much that we can do in general, except pass this bug report over to someone who works on Cygwin.

    @bk2204 @nhatkhai what are your thoughts?

  12. nhatkhai commented on Feb 14, 2019

    @nhatkhai
    Author

    Are there better way to narrow down more to see why parsing .gitconfig files way too slow in Cygwin?
    git-lfs install run way so long under Cygwin (1min 26 seconds!!!). I don't see this trouble with git only when it parsing it own .gitconfig files!

  13. bk2204 commented on Feb 15, 2019

    @bk2204
    Member

    My guess about why the delay is so great is something having to do with an interaction between native Windows programs like Git LFS and Cygwin programs, such as a problem with the pipes or handles being used. Unfortunately, I don't know very much about Cygwin or Windows, so I can't be of much help here. Go doesn't build programs for Cygwin (mostly because the language doesn't use libc), so it isn't possible to build a native version of Git LFS for Cygwin.

    If you're using Windows 10, it may be possible for you to try Windows Subsystem for Linux, which should have better performance in this area.

    I'm sorry I can't be of more help.

  14. changed the title [-]git commit take unexpected long time[/-] [+]git commit take unexpected long time for Cygwin[/+] on Aug 19, 2019
  15. nhatkhai commented on Aug 19, 2019

    @nhatkhai
    Author

    Look like with git lfs 2.7.1 is work faster now:

     time git lfs env
    11:49:00.846501 git.c:576               trace: exec: git-lfs env
    11:49:00.849501 run-command.c:640       trace: run_command: git-lfs env
    11:49:00.966501 trace git-lfs: exec: git 'version'
    git-lfs/2.7.1 (GitHub; windows amd64; go 1.11.5; git 6b7fb6e3)
    git version 2.17.0
    
    11:49:01.066501 trace git-lfs: exec: git '-c' 'filter.lfs.smudge=' '-c' 'filter.lfs.clean=' '-c' 'filter.lfs.process=' '-c' 'filter.lfs.required=false' 'rev-parse' 'HEAD' '--symbolic-full-name' 'HEAD'
    11:49:01.512501 trace git-lfs: exec: git 'config' '-l'
    ....
    
    real    0m0.901s
    user    0m0.015s
    sys     0m0.139s
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions