Lines Matching refs:tstate

928 handle_legacy_finalizers(PyThreadState *tstate,
932 assert(!_PyErr_Occurred(tstate));
941 _PyErr_Clear(tstate);
955 finalize_garbage(PyThreadState *tstate, PyGC_Head *collectable)
979 assert(!_PyErr_Occurred(tstate));
991 delete_garbage(PyThreadState *tstate, GCState *gcstate,
994 assert(!_PyErr_Occurred(tstate));
1006 _PyErr_Clear(tstate);
1014 if (_PyErr_Occurred(tstate)) {
1178 gc_collect_main(PyThreadState *tstate, int generation,
1191 GCState *gcstate = &tstate->interp->gc;
1196 assert(!_PyErr_Occurred(tstate));
1274 finalize_garbage(tstate, &unreachable);
1287 delete_garbage(tstate, gcstate, &final_unreachable, old);
1307 handle_legacy_finalizers(tstate, gcstate, &finalizers, old);
1313 clear_freelists(tstate->interp);
1316 if (_PyErr_Occurred(tstate)) {
1318 _PyErr_Clear(tstate);
1342 assert(!_PyErr_Occurred(tstate));
1350 invoke_gc_callback(PyThreadState *tstate, const char *phase,
1354 assert(!_PyErr_Occurred(tstate));
1357 GCState *gcstate = &tstate->interp->gc;
1388 assert(!_PyErr_Occurred(tstate));
1395 gc_collect_with_callback(PyThreadState *tstate, int generation)
1397 assert(!_PyErr_Occurred(tstate));
1399 invoke_gc_callback(tstate, "start", generation, 0, 0);
1400 result = gc_collect_main(tstate, generation, &collected, &uncollectable, 0);
1401 invoke_gc_callback(tstate, "stop", generation, collected, uncollectable);
1402 assert(!_PyErr_Occurred(tstate));
1407 gc_collect_generations(PyThreadState *tstate)
1409 GCState *gcstate = &tstate->interp->gc;
1455 n = gc_collect_with_callback(tstate, i);
1523 PyThreadState *tstate = _PyThreadState_GET();
1526 _PyErr_SetString(tstate, PyExc_ValueError, "invalid generation");
1530 GCState *gcstate = &tstate->interp->gc;
1538 n = gc_collect_with_callback(tstate, generation);
1751 PyThreadState *tstate = _PyThreadState_GET();
1754 GCState *gcstate = &tstate->interp->gc;
1768 _PyErr_Format(tstate, PyExc_ValueError,
1776 _PyErr_SetString(tstate, PyExc_ValueError,
2070 PyThreadState *tstate = _PyThreadState_GET();
2071 GCState *gcstate = &tstate->interp->gc;
2085 _PyErr_Fetch(tstate, &exc, &value, &tb);
2086 n = gc_collect_with_callback(tstate, NUM_GENERATIONS - 1);
2087 _PyErr_Restore(tstate, exc, value, tb);
2095 _PyGC_CollectNoFail(PyThreadState *tstate)
2103 GCState *gcstate = &tstate->interp->gc;
2110 n = gc_collect_main(tstate, NUM_GENERATIONS - 1, NULL, NULL, 1);
2258 PyThreadState *tstate = _PyThreadState_GET();
2259 GCState *gcstate = &tstate->interp->gc;
2267 !_PyErr_Occurred(tstate))
2270 gc_collect_generations(tstate);
2278 PyThreadState *tstate = _PyThreadState_GET();
2280 return _PyErr_NoMemory(tstate);
2285 return _PyErr_NoMemory(tstate);