summaryrefslogtreecommitdiffstats
path: root/Modules/_asynciomodule.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix typo (#5049)Andrew Svetlov2017-12-301-1/+1
|
* bpo-31721: Allow Future._log_traceback to only be set to False (#5009)Yury Selivanov2017-12-251-0/+5
|
* bpo-32363: Disable Task.set_exception() and Task.set_result() (#4923)Yury Selivanov2017-12-251-9/+42
|
* bpo-32415: Fix "error is already set" (#4999)Yury Selivanov2017-12-231-0/+1
|
* bpo-32357: Use PySet_GET_SIZE macro in _is_coroutine() from _asynciomodule.c ↵Andrew Svetlov2017-12-231-1/+1
| | | | (#4990)
* bpo-32415: Add asyncio.Task.get_loop() and Future.get_loop() (#4992)Yury Selivanov2017-12-231-29/+69
|
* Fix GCC warning in _asynciomodule.c (#4928)Zackery Spytz2017-12-191-1/+1
|
* bpo-32357: Optimize asyncio.iscoroutine() for non-native coroutines (#4915)Yury Selivanov2017-12-191-28/+85
|
* bpo-32348: Optimize asyncio.Future schedule/add/remove callback. (#4907)Yury Selivanov2017-12-181-75/+322
|
* bpo-32250: Implement asyncio.current_task() and asyncio.all_tasks() (#4799)Andrew Svetlov2017-12-161-110/+260
|
* bpo-32311: Implement asyncio.create_task() shortcut (#4848)Andrew Svetlov2017-12-151-1/+28
| | | | | * Implement functionality * Add documentation
* bpo-32296: Implement asyncio.get_event_loop and _get_running_loop in C. (#4827)Yury Selivanov2017-12-131-7/+244
| | | | | | | | asyncio.get_event_loop(), and, subsequently asyncio._get_running_loop() are one of the most frequently executed functions in asyncio. They also can't be sped up by third-party event loops like uvloop. When implemented in C they become 4x faster.
* bpo-31185: Fixed miscellaneous errors in asyncio speedup module. (#3076)Serhiy Storchaka2017-09-031-207/+206
|
* bpo-31061: fix crash in asyncio speedup module (GH-2966)Alexander Mohr2017-08-021-0/+4
|
* bpo-30828: Fix out of bounds write in ↵Yury Selivanov2017-07-051-3/+10
| | | | `asyncio.CFuture.remove_done_callback() (#2569)
* bpo-30508: Don't log exceptions if Task/Future "cancel()" method called (#2050)Yury Selivanov2017-06-111-1/+17
|
* bpo-30048: asyncio: fix Task.cancel() was ignored. (GH-1097)INADA Naoki2017-05-111-0/+12
| | | | | | | | | | | | when there are no more `await` or `yield (from)` before return in coroutine, cancel was ignored. example: async def coro(): asyncio.Task.current_task().cancel() return 42 ... res = await coro() # should raise CancelledError
* bpo-28963: Fix out of bound iteration in ↵Yury Selivanov2017-03-031-1/+1
| | | | asyncio.Future.remove_done_callback/C (#408)
* bpo-29271: Fix Task.current_task and Task.all_tasks to accept None. (#406)Yury Selivanov2017-03-031-6/+6
|
* Use _PyObject_CallMethodIdObjArgs() in _asyncioVictor Stinner2016-12-091-17/+19
| | | | | | | | | Issue #28915: Replace _PyObject_CallMethodId() with _PyObject_CallMethodIdObjArgs() when the format string was only made of "O" formats, PyObject* arguments. _PyObject_CallMethodIdObjArgs() avoids the creation of a temporary tuple and doesn't have to parse a format string.
* Use _PyObject_CallNoArg()Victor Stinner2016-12-061-1/+1
| | | | | | | Replace: PyObject_CallFunctionObjArgs(callable, NULL) with: _PyObject_CallNoArg(callable)
* Use _PyObject_CallNoArg()Victor Stinner2016-12-061-6/+6
| | | | | | | Replace: PyObject_CallObject(callable, NULL) with: _PyObject_CallNoArg(callable)
* Issue #28858: Remove _PyObject_CallArg1() macroVictor Stinner2016-12-051-3/+3
| | | | | | | | | | | Replace _PyObject_CallArg1(func, arg) with PyObject_CallFunctionObjArgs(func, arg, NULL) Using the _PyObject_CallArg1() macro increases the usage of the C stack, which was unexpected and unwanted. PyObject_CallFunctionObjArgs() doesn't have this issue.
* Backed out changeset b9c9691c72c5Victor Stinner2016-12-041-5/+7
| | | | | | Issue #28858: The change b9c9691c72c5 introduced a regression. It seems like _PyObject_CallArg1() uses more stack memory than PyObject_CallFunctionObjArgs().
* Merge 3.6 (issue #28843)Yury Selivanov2016-12-011-0/+5
|
* Replace PyObject_CallFunctionObjArgs() with fastcallVictor Stinner2016-12-011-7/+5
| | | | | | | | | | | | | | * PyObject_CallFunctionObjArgs(func, NULL) => _PyObject_CallNoArg(func) * PyObject_CallFunctionObjArgs(func, arg, NULL) => _PyObject_CallArg1(func, arg) PyObject_CallFunctionObjArgs() allocates 40 bytes on the C stack and requires extra work to "parse" C arguments to build a C array of PyObject*. _PyObject_CallNoArg() and _PyObject_CallArg1() are simpler and don't allocate memory on the C stack. This change is part of the fastcall project. The change on listsort() is related to the issue #23507.
* correctly emulate error semantics of gen.throw in FutureIter_throwBenjamin Peterson2016-11-141-19/+34
|
* Issue #26081: Fix refleak in _asyncio.Future.__iter__().throw.Yury Selivanov2016-11-091-1/+3
|
* Issue #23996: Added _PyGen_SetStopIterationValue for safe raisingSerhiy Storchaka2016-11-061-18/+4
| | | | | StopIteration with value. More safely handle non-normalized exceptions in -_PyGen_FetchStopIterationValue.
* Issue #28544: Fix inefficient call to _PyObject_CallMethodId()Victor Stinner2016-10-291-1/+1
| | | | | "()" format string creates an empty list of argument but requires extra work to parse the format string.
* Issue #28544: Pass `PyObject*` to _PyDict_Pop, not `PyDictObject*`Yury Selivanov2016-10-281-5/+5
|
* Issue #28544: Fix _asynciomodule.c on WindowsVictor Stinner2016-10-281-5/+5
| | | | | | PyType_Ready() sets the reference to &PyType_Type. &PyType_Type cannot be resolved at compilation time (not on Windows?).
* Issue #28544: Implement asyncio.Task in C.Yury Selivanov2016-10-281-277/+1699
| | | | | | | | This implementation provides additional 10-20% speed boost for asyncio programs. The patch also fixes _asynciomodule.c to use Arguments Clinic, and makes '_schedule_callbacks' an overridable method (as it was in 3.5).
* Issue #28430: Fix iterator of C implemented asyncio.Future doesn'tINADA Naoki2016-10-251-6/+4
| | | | accept non-None value is passed to it.send(val).
* Issue #28493: Fix typos in _asynciomodule.cYury Selivanov2016-10-201-2/+2
| | | | Thanks to Stéphane Wirtel!
* Issue #28492: Fix how StopIteration is raised in _asyncio.FutureYury Selivanov2016-10-201-2/+19
|
* Issue #28452: Remove _asyncio._init_module functionINADA Naoki2016-10-181-66/+55
|
* Issue #28428: Rename _futures module to _asyncio.INADA Naoki2016-10-151-0/+1034
It will have more speedup functions or classes other than asyncio.Future.