-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Extreme boot time difference when concurrency specified #1318
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I'm surprised by the difference in CPU usage. Something seems to be doing significantly more work, though I doubt it's I assume you can't share your test suite? |
Results appear to be very similar as long as concurrency is >= the number of logical cores on the machine. And unfortunately no I cannot share the test suite; if it helps any, they're all unit tests running as
My thought regarding Bluebird wasn't so much that Bluebird#map was broken or directly responsible, but rather perhaps when concurrency limiting is enabled, event-loop scheduling might be different such that spawning child processes doesn't result in a lockup. Just a guess though, didn't really dig very far down into the depths. |
If I had to guess, it would be how we handle If we can prove that to be true, I propose we abandon the current We can almost certainly catch 99% of |
@jamestalmage the surprising behavior in this issue is that specifying concurrency slows the tests down more than not specifying it does. |
Right. When you specify concurrency, we run tests as soon as possible. When you don't, we pause, waiting for all tests to load and report back about |
Description
There appears to be a significant "boot time" (presumably transpiling and spawning child processes?) difference for ava when specifying concurrency, even with ridiculously high numbers.
With my suite of 103 tests across 36 files, running ava without specifying any concurrency, the spinning indicator would be the only output for upwards of 30 seconds, after which the test output would speed by and the suite would complete with total time nearing a minute.
After seeing #966 I experimented with the concurrency option, and noticed a drastic difference in execution speed, even when the number provided was a radically high number (higher than my system's logical cores, higher than the number of test files...).
Perhaps there is an unexpected performance difference in how Bluebird.map works when concurrency is left to default to 0?
Config
Environment
Node.js v6.9.4
darwin 16.4.0
ava 0.18.2
npm 3.10.10
The text was updated successfully, but these errors were encountered: