Open cmarcusreid opened 7 years ago
@Tasteful could you grab the executable from https://github.com/cmarcusreid/git-status-cache/releases/tag/v1.1.5-alpha and grab the timing information from the logs?
Here we have the new log with a lot of more timings
There are two slow requests in the log:
2017-02-20 10:43:23.179259 GitStatusCache.exe (0x00004ba0) 0x000014b8 Spam NamedPipeInstance.OnClientRequest.19 Call completed. Reporting timing. { "milliseconds": 22689.1, "call": "m_onClientRequestCallback(readResult.second)" }
2017-02-20 10:47:42.035621 GitStatusCache.exe (0x00004ba0) 0x000014b8 Spam NamedPipeInstance.OnClientRequest.19 Call completed. Reporting timing. { "milliseconds": 10730.8, "call": "m_onClientRequestCallback(readResult.second)" }
In both cases the vast majority of the cost is in git_status_list_new:
2017-02-20 10:43:23.170311 GitStatusCache.exe (0x00004ba0) 0x000014b8 Spam Git.GetFileStatus.377 Call completed. Reporting timing. { "milliseconds": 22669, "call": "git_status_list_new(&statusList.get(), repository.get(), &statusOptions)" }
2017-02-20 10:47:42.025614 GitStatusCache.exe (0x00004ba0) 0x000014b8 Spam Git.GetFileStatus.377 Call completed. Reporting timing. { "milliseconds": 10713.4, "call": "git_status_list_new(&statusList.get(), repository.get(), &statusOptions)" }
This is a libgit2 function, and unfortunately I don't see a way to retrieve the status more efficiently from within GitStatusCache. I think the next step is to follow-up with libgit2 experts about the function's cost on these repositories.
Creating issue here to continue investigation of https://github.com/dahlbyk/posh-git/issues/423.