{"thread":{"id":"41276","subject":"[PATCH 0/2] Make stash a builtin","startedAt":"2016-01-28T19:38:47Z","lastAt":"2016-01-28T19:38:47Z","messageCount":1,"participants":["Matthias Aßhauer"],"isPatch":true,"patchVersion":1,"patchTotal":2},"messages":[{"id":"276998","messageId":"BLU436-SMTP27D65F59A444FA678FFD8AA5DA0@phx.gbl","threadId":"41276","inReplyTo":null,"subject":"[PATCH 0/2] Make stash a builtin","fromName":"Matthias Aßhauer","fromEmail":"mha1993@live.de","sentAt":"2016-01-28T19:38:47Z","receivedAt":"2016-01-28T19:38:47Z","isPatch":true,"sender":{"key":"mha1993@live.de","avatar":"https://avatars.githubusercontent.com/u/6178234?v=4"},"body":"These are the first two Patches in an upcomming series of Patches to\nconvert git stash into a builtin command. This is mainly based on the\ngeneral performance of scripts running inside an interpreter (bash in\nthis case) running inside a POSIX emulation layer on Windows. Shell,\nperl and python scripts are generaly a lot faster on Unix-like systems\ncompared to Windows systems. That does not mean that Unix-like systems\nwon't benefit from more native Git commands, but the effect is bigger\non Git for Windows.\n\nThese two patches port over the core non-patch part of git-stash into\nnative code using a separate helper command. This helper command is\nintended as a temporary meassure and as such it's subject to change.\nFor this reason, I did not implement new regression tests, documentation\nor localizations for this command.\n\nI meassured the changes in excecution time for the stash related\nregression tests on the same hardware running Windows 8.1 and\nKubuntu 15.10. Each result is the difference between the average of five\nmeassurements (six on Linux, because I lost count on the first run of\nmeassurements) each before and after these changes. I meassured the\nfollowing changes:\n\nWindows:\n\nt3903\nreal -5,10%\nuser -0,94%\nsys +0,16% (10ms)\n\nt3904\nreal -0,30%\nuser -2,98% (20ms)\nsys +5,03%\n\nt3905\nreal -4,03%\nuser -8,13%\nsys +17,42%\n\nt3906\nreal -2,57%\nuser +1,94%\nsys +1,59%\n\nLinux:\n\nt3903\nreal +0,63%\nuser +10,87% (3ms)\nsys +4,29% (4ms)\n\nt3904\nreal -7,29%\nuser -30,61%\nsys +5,77% (4ms)\n\nt3905\nreal -7,29%\nuser -33,33% (2ms)\nsys +20% (2ms)\n\nt3906\nreal -0,88%\nuser -1,08% (1ms)\nsys -2,22%\n\nI added the asolute times where I think the difference is below the\nmeassurement precission (4ms on Linux) and on the two lowest absolute\ndifferences on windows. A full log of all meassurement runs is available\nat https://gist.github.com/rimrul/82adf3b368ed633263d2. Please note that\naccording to Johannes Schindelin, maintainer of Git for Windows, the\nmeassuring of sys time on Windows is unreliable. With that in mind,\nin summary this is a slight increase in performance on Linux, and a more\nnoticeable increase on Windows.\n"}]}