mrgit icon indicating copy to clipboard operation
mrgit copied to clipboard

Rise concurrency level

Open Reinmar opened this issue 7 years ago • 4 comments

Right now we use 2-4 processes to work with multiple repos. I raised the number to 4-8 and reduced e.g. mgit update time from about 30-40% (although, more tests would need to be done). It should not make that much difference in case of normal (local) commands, where network is not involved, but those usually take considerably less time anyway.

Reinmar avatar Dec 04 '18 16:12 Reinmar

I also tried 30+ threads but that did make any difference. And it actually slowed down mgit st. 4-8 seems to be safest on a typical machine.

Reinmar avatar Dec 04 '18 16:12 Reinmar

@pomek Could you do ~5+ tests of the current setting and with 4-8 threads (see utils/createforkpool.js)? GH seems to give quite random numbers so we need more tests to draw conclusions.

Reinmar avatar Dec 04 '18 17:12 Reinmar

Why can't we introduce a property that allows controlling how many threads you would like to use?

GH seems to give quite random numbers so we need more tests to draw conclusions.

That's a reason why my tests won't be good. We need to involve a people that can reproduce an error https://github.com/cksource/mgit2/issues/92.

pomek avatar Dec 05 '18 07:12 pomek

Why can't we introduce a property that allows controlling how many threads you would like to use?

We can. But we need sensible defaults. If you'll confirm my observations, we can assume this is a common trend. If not, we can check with more people.

Reinmar avatar Dec 05 '18 08:12 Reinmar