- 22 Feb, 2018 7 commits
-
-
Jason Madden authored
Add spawn_tree_locals, spawning_greenlet and spawning_stack to gevent.greenlet.Greenlet
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
Small improvements to creating the objects, somewhat larger improvements to joining. From bench_spawn on 3.6.4 before any work: //gevent36/bin/python ./bench_spawn.py geventpool --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 8.71 microseconds per greenlet sleep(0): 16.99 microseconds per greenlet joining: 7.34 microseconds per greenlet //gevent36/bin/python ./bench_spawn.py --with-kwargs geventpool --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 10.25 microseconds per greenlet sleep(0): 18.89 microseconds per greenlet joining: 7.14 microseconds per greenlet And now: //gevent36/bin/python ./bench_spawn.py geventpool --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 11.56 microseconds per greenlet sleep(0): 16.76 microseconds per greenlet joining: 5.74 microseconds per greenlet //gevent36/bin/python ./bench_spawn.py --with-kwargs geventpool --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 11.49 microseconds per greenlet sleep(0): 17.16 microseconds per greenlet joining: 5.31 microseconds per greenlet
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
We're now only ~2x slower, instead of 10x.
-
- 21 Feb, 2018 2 commits
-
-
Jason Madden authored
Based on #755. A comment in the code goes into detail about the timing. Here it is again: Timings taken Feb 21 2018 prior to integration of #755 python -m perf timeit -s 'import gevent' 'gevent.Greenlet()' 3.6.4 : Mean +- std dev: 1.08 us +- 0.05 us 2.7.14 : Mean +- std dev: 1.44 us +- 0.06 us PyPy2 5.10.0: Mean +- std dev: 2.14 ns +- 0.08 ns After the integration of spawning_stack, spawning_greenlet, and spawn_tree_locals on that same date: 3.6.4 : Mean +- std dev: 8.92 us +- 0.36 us -> 8.2x 2.7.14 : Mean +- std dev: 14.8 us +- 0.5 us -> 10.2x PyPy2 5.10.0: Mean +- std dev: 3.24 us +- 0.17 us -> 1.5x Selected bench_spawn output on 3.6.4 before: //gevent36/bin/python src/greentest/bench_spawn.py eventlet --ignore-import-errors using eventlet from //gevent36/lib/python3.6/site-packages/eventlet/__init__.py spawning: 11.93 microseconds per greenlet sleep(0): 23.49 microseconds per greenlet //gevent36/bin/python src/greentest/bench_spawn.py gevent --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 3.39 microseconds per greenlet sleep(0): 17.59 microseconds per greenlet //gevent36/bin/python src/greentest/bench_spawn.py geventpool --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 8.71 microseconds per greenlet //gevent36/bin/python src/greentest/bench_spawn.py geventraw --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 2.09 microseconds per greenlet //gevent36/bin/python src/greentest/bench_spawn.py none --ignore-import-errors noop: 0.33 microseconds per greenlet And after: //gevent36/bin/python bench_spawn.py gevent --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 12.99 microseconds per greenlet -> 3.8x //gevent36/bin/python bench_spawn.py geventpool --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 19.49 microseconds per greenlet -> 2.2x //gevent36/bin/python bench_spawn.py geventraw --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 4.57 microseconds per greenlet -> 2.2x We're approximately the speed of eventlet now. Refs #755
-
Jason Madden authored
Current numbers on my workstation: CPython 3.6.4 //gevent36/bin/python bench_spawn.py eventlet --ignore-import-errors using eventlet from //python3.6/site-packages/eventlet/__init__.py spawning: 11.93 microseconds per greenlet sleep(0): 23.49 microseconds per greenlet //gevent36/bin/python bench_spawn.py gevent --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 3.39 microseconds per greenlet sleep(0): 17.59 microseconds per greenlet //gevent36/bin/python bench_spawn.py geventpool --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 8.71 microseconds per greenlet sleep(0): 16.99 microseconds per greenlet joining: 7.34 microseconds per greenlet //gevent36/bin/python bench_spawn.py geventraw --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 2.09 microseconds per greenlet sleep(0): 13.57 microseconds per greenlet //gevent36/bin/python bench_spawn.py none --ignore-import-errors noop: 0.33 microseconds per greenlet //gevent36/bin/python bench_spawn.py --with-kwargs eventlet --ignore-import-errors using eventlet from //python3.6/site-packages/eventlet/__init__.py spawning: 12.06 microseconds per greenlet sleep(0): 24.25 microseconds per greenlet //gevent36/bin/python bench_spawn.py --with-kwargs gevent --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 4.62 microseconds per greenlet sleep(0): 22.18 microseconds per greenlet //gevent36/bin/python bench_spawn.py --with-kwargs geventpool --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 10.25 microseconds per greenlet sleep(0): 18.89 microseconds per greenlet joining: 7.14 microseconds per greenlet //gevent36/bin/python bench_spawn.py --with-kwargs geventraw --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 3.27 microseconds per greenlet sleep(0): 15.03 microseconds per greenlet //gevent36/bin/python bench_spawn.py --with-kwargs none --ignore-import-errors noop: 0.50 microseconds per greenlet CPython 2.7.14 //gevent27/bin/python bench_spawn.py eventlet --ignore-import-errors using eventlet from //python2.7/site-packages/eventlet/__init__.pyc spawning: 17.84 microseconds per greenlet sleep(0): 31.42 microseconds per greenlet //gevent27/bin/python bench_spawn.py gevent --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 4.95 microseconds per greenlet sleep(0): 21.40 microseconds per greenlet //gevent27/bin/python bench_spawn.py geventpool --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 12.44 microseconds per greenlet sleep(0): 22.90 microseconds per greenlet joining: 10.68 microseconds per greenlet //gevent27/bin/python bench_spawn.py geventraw --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 2.33 microseconds per greenlet sleep(0): 15.11 microseconds per greenlet //gevent27/bin/python bench_spawn.py none --ignore-import-errors noop: 0.58 microseconds per greenlet //gevent27/bin/python bench_spawn.py --with-kwargs eventlet --ignore-import-errors using eventlet from //python2.7/site-packages/eventlet/__init__.pyc spawning: 19.38 microseconds per greenlet sleep(0): 31.62 microseconds per greenlet //gevent27/bin/python bench_spawn.py --with-kwargs gevent --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 6.59 microseconds per greenlet sleep(0): 23.12 microseconds per greenlet //gevent27/bin/python bench_spawn.py --with-kwargs geventpool --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 13.78 microseconds per greenlet sleep(0): 21.65 microseconds per greenlet joining: 10.86 microseconds per greenlet //gevent27/bin/python bench_spawn.py --with-kwargs geventraw --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 3.59 microseconds per greenlet sleep(0): 16.14 microseconds per greenlet //gevent27/bin/python bench_spawn.py --with-kwargs none --ignore-import-errors noop: 0.65 microseconds per greenlet PyPy2 5.10.0 //geventpypy/bin/python bench_spawn.py eventlet --ignore-import-errors using eventlet from //geventpypy/site-packages/eventlet/__init__.pyc spawning: 29.91 microseconds per greenlet sleep(0): 84.24 microseconds per greenlet //geventpypy/bin/python bench_spawn.py gevent --ignore-import-errors using gevent from //src/gevent/__init__.py spawning: 0.73 microseconds per greenlet sleep(0): 33.02 microseconds per greenlet //geventpypy/bin/python bench_spawn.py geventpool --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 2.49 microseconds per greenlet sleep(0): 38.56 microseconds per greenlet joining: 13.08 microseconds per greenlet //geventpypy/bin/python bench_spawn.py geventraw --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 0.52 microseconds per greenlet sleep(0): 29.63 microseconds per greenlet //geventpypy/bin/python bench_spawn.py none --ignore-import-errors noop: 0.02 microseconds per greenlet //geventpypy/bin/python bench_spawn.py --with-kwargs eventlet --ignore-import-errors using eventlet from //geventpypy/site-packages/eventlet/__init__.pyc spawning: 30.36 microseconds per greenlet sleep(0): 83.00 microseconds per greenlet //geventpypy/bin/python bench_spawn.py --with-kwargs gevent --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 1.56 microseconds per greenlet sleep(0): 34.80 microseconds per greenlet //geventpypy/bin/python bench_spawn.py --with-kwargs geventpool --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 3.48 microseconds per greenlet sleep(0): 39.43 microseconds per greenlet joining: 16.21 microseconds per greenlet //geventpypy/bin/python bench_spawn.py --with-kwargs geventraw --ignore-import-errors using gevent from //src/gevent/__init__.pyc spawning: 1.51 microseconds per greenlet sleep(0): 52.19 microseconds per greenlet //geventpypy/bin/python bench_spawn.py --with-kwargs none --ignore-import-errors noop: 0.13 microseconds per greenlet [skip ci]
-
- 20 Feb, 2018 7 commits
-
-
Jason Madden authored
Make the check_callback do stuff under PyPy to trigger signal deliver…
-
Jason Madden authored
-
Jason Madden authored
Cleanup the libev destroyed data like the libuv destroyed data.
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
Fix race conditions in libuv child watchers.
-
Jason Madden authored
-
- 19 Feb, 2018 6 commits
-
-
Jason Madden authored
(hopefully) fix a crash destroying loops in test__core.py; only seen on Windows, but with some tweaks I could reproduce it locally.
-
Jason Madden authored
Fixes #1104
-
Jason Madden authored
Be more careful about issuing the SSL warning on Py2.
-
Jason Madden authored
Also some other doc updates. [skip ci]
-
Jason Madden authored
Fixes #1108.
-
Jason Madden authored
-
- 17 Feb, 2018 3 commits
-
-
Jason Madden authored
-
Jason Madden authored
Update c-ares to 1.14. Fixes #1105.
-
Jason Madden authored
Support GEVENT_RESOLVER_SERVERS for configuring dnspython nameservers.
-
- 16 Feb, 2018 6 commits
-
-
Jason Madden authored
-
Jason Madden authored
Also allow this for ares, and deprecate the GEVENTARES_SERVERS environment variable. Fixes #1103.
-
Jason Madden authored
-
Jason Madden authored
ccache saves us time on compiling, but not linking. The difference is unlikely to be significant for test purposes.
-
Jason Madden authored
Make socket.sendall() fast on PyPy3: 60MB/s -> 600MB/s
-
Jason Madden authored
-
- 15 Feb, 2018 9 commits
-
-
Jason Madden authored
I see in on OS X even without gevent involved. I see it with gevent involved both on the sendall branch and the master branch. I see it on Travis (now) with the sendall patch. I don't know if it's been seen before the sendall patch on Travis---flaky builds tend to get rerun. None of the other SSL tests are failing, though, and the pypy version of test_ssl.py notes that test_handshake has been removed from CPython altogether. It looks like it's very dependent on buffering and things like that.
-
Jason Madden authored
TestEtcHosts round-robin failures also seen on appveyor with the system resolver---because we're not using the local system hosts file.
-
Jason Madden authored
-
Jason Madden authored
Share the chunking code between Python 2 and 3. Also get the tests passing (read: skip a bunch) with 5.10.1 on OS X, which is apparently less well tested than Linux. We don't test pypy3 on appveyor, so: [skip appveyor]
-
Jason Madden authored
-
Jason Madden authored
Simplify libev default loop handling and let it regenerate itself.
-
Jason Madden authored
-
Jason Madden authored
-
Jason Madden authored
-