- 24 Mar, 2018 5 commits
-
-
Jason Madden authored
Here's the improvement for the greenlet pools: | Benchmark | 36_pool_master | 36_pool_opts | +--------------------+----------------+-----------------------------+ | imap_unordered_seq | 803 us | 686 us: 1.17x faster (-15%) | | imap_unordered_par | 445 us | 389 us: 1.14x faster (-13%) | | imap_seq | 793 us | 729 us: 1.09x faster (-8%) | | imap_par | 407 us | 398 us: 1.02x faster (-2%) | | map_seq | 715 us | 293 us: 2.44x faster (-59%) | | map_par | 388 us | 199 us: 1.96x faster (-49%) | Not significant (2): apply; spawn
-
Jason Madden authored
-
Jason Madden authored
Compared to the previous commit: | Benchmark | 36_threadpool_opt_PR | 36_threadpool_opt_cond10 | +--------------------+----------------------+-----------------------------+ | imap_unordered_seq | 1.06 ms | 1.02 ms: 1.04x faster (-4%) | | imap_unordered_par | 965 us | 928 us: 1.04x faster (-4%) | | imap_seq | 1.08 ms | 1.03 ms: 1.04x faster (-4%) | | map_seq | 785 us | 870 us: 1.11x slower (+11%) | | map_par | 656 us | 675 us: 1.03x slower (+3%) | | apply | 1.14 ms | 1.12 ms: 1.02x faster (-2%) |
-
Jason Madden authored
-
Jason Madden authored
Especially for map. None of the pools really need map to go through imap since they have to wait for everything anyway and they return results ordererd. | Benchmark | 36_threadpool_master | 36_threadpool_opt_cond5 | |--------------------|----------------------|-----------------------------| | imap_unordered_seq | 1.15 ms | 1.07 ms: 1.08x faster (-7%) | | imap_unordered_par | 1.02 ms | 950 us: 1.08x faster (-7%) | | imap_seq | 1.17 ms | 1.10 ms: 1.06x faster (-6%) | | imap_par | 1.07 ms | 1000 us: 1.07x faster (-7%) | | map_seq | 1.16 ms | 724 us: 1.60x faster (-37%) | | map_par | 1.07 ms | 646 us: 1.66x faster (-40%) | | apply | 1.22 ms | 1.14 ms: 1.07x faster (-7%) | | spawn | 1.21 ms | 1.13 ms: 1.07x faster (-7%) |
-
- 23 Mar, 2018 3 commits
-
-
Jason Madden authored
Add monitoring for memory usage, emitting events as it moves around the threshold.
-
Jason Madden authored
-
Jason Madden authored
-
- 22 Mar, 2018 5 commits
-
-
Jason Madden authored
Needs specific tests.
-
Jason Madden authored
Start having the monitor thread emit events for monitored conditions.
-
Jason Madden authored
This is the only reasonable path I could think of to enable memory monitoring, with gevent just being responsible for monitoring the memory and detecting overage conditions, while users plug in their own policies.
-
Jason Madden authored
I wasn't even using them to debug anymore, they were too verbose to be blanket enabled. Fixes #1146. Also tweak the leakcheck tests for threadpools.
-
Jason Madden authored
-
- 21 Mar, 2018 4 commits
-
-
Jason Madden authored
Fix libuv multiplex io watchers from polling too much when one event …
-
Jason Madden authored
Fix libuv multiplex io watchers from polling too much when one event has been completely turned off. Fixes #1144.
-
Jason Madden authored
Add support for a background monitoring thread to be associated with each hub.
-
Jason Madden authored
And give it unittest coverage. (Using it as an actual thread didn't produce coverage metrics because we use 'greenlet' concurrency.) Add a rudimentary scheduler so that functions that don't want to run as often as the minimum stay (very roughly) on their period.
-
- 20 Mar, 2018 2 commits
-
-
Jason Madden authored
-
Jason Madden authored
The threadpolo worker greenlet itself is meant to spend much of its time blocking, so don't report on it if it does. Only if we switch greenlets while running the user's code should we start looking for blocking.
-
- 19 Mar, 2018 3 commits
-
-
Jason Madden authored
-
Jason Madden authored
Right now, it is used to detect blocked event loops, and it is extensible by users. In the future there will be some more default monitoring options (e.g., memory). Refs #1021.
-
Jason Madden authored
Make more performance-sensitive places use _get_hub_noargs, since under Python 3 it is twice as fast to call as get_hub.
-
- 17 Mar, 2018 2 commits
-
-
Jason Madden authored
Introduce GEVENT_TRACK_GREENLET_TREE to disable greenlet tree features
-
Jason Madden authored
As a performance optimization for applications where spawning greenlets is critical. Plus some other optimizations to speed up spawning in the general case. CPython 3.6 with 1.2.2 vs these changes with tracking disabled: | Benchmark | 36_122_bench_spawn | 36config_bench_spawn_tree_off | +------------------------+--------------------+-------------------------------+ | eventlet spawn | 12.6 us | 12.2 us: 1.04x faster (-4%) | | eventlet sleep | 5.22 us | 4.97 us: 1.05x faster (-5%) | | gevent spawn | 4.27 us | 5.06 us: 1.19x slower (+19%) | | gevent sleep | 2.63 us | 1.25 us: 2.11x faster (-53%) | | geventpool spawn | 9.00 us | 8.31 us: 1.08x faster (-8%) | | geventpool sleep | 4.82 us | 2.83 us: 1.70x faster (-41%) | | geventraw spawn | 2.51 us | 2.81 us: 1.12x slower (+12%) | | geventraw sleep | 649 ns | 679 ns: 1.05x slower (+5%) | | geventpool join | 3.47 us | 1.42 us: 2.44x faster (-59%) | | geventpool spawn kwarg | 11.0 us | 8.95 us: 1.23x faster (-19%) | | geventraw spawn kwarg | 3.87 us | 4.20 us: 1.08x slower (+8%) | The differences compared to master are hard to quantify because the standard deviation ends up being more than 10% of the mean in many cases---and about a 10% improvement is what we typically see, so it goes back and forth.
-
- 14 Mar, 2018 1 commit
-
-
Jason Madden authored
-
- 09 Mar, 2018 2 commits
-
-
Jason Madden authored
Also monkey-patch threading._Event on Python 2. Fixes #1136
-
Jason Madden authored
-
- 08 Mar, 2018 4 commits
-
-
Jason Madden authored
Use strongly typed watcher callback functions in libuv, preventing compiler warnings
-
Jason Madden authored
-
Jason Madden authored
Turns out we weren't passing the macros we thought we were at all. Whoops.
-
Jason Madden authored
And also ensuring that in the Python code we know the type of pointer we're dealing with. This might catch some errors.
-
- 07 Mar, 2018 3 commits
-
-
Jason Madden authored
Fix documentation for Pool.full()
-
Jay Oster authored
The original docs had the purpose of the boolean return value reversed. I fixed that distinction, and also tried to clarify how the method can be used.
-
Jason Madden authored
-
- 06 Mar, 2018 6 commits
-
-
Jason Madden authored
-
Jason Madden authored
Exclude 3.3, account for cython being a develop wheel right now. [skip ci]
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
-