summaryrefslogtreecommitdiffstats
path: root/Python/clinic
diff options
context:
space:
mode:
authorMark Shannon <mark@hotpy.org>2021-06-07 17:38:06 (GMT)
committerGitHub <noreply@github.com>2021-06-07 17:38:06 (GMT)
commit001eb520b5757294dc455c900d94b7b153de6cdd (patch)
treec9d3a3d36e860a9a0591ce6d7d758201e72c2230 /Python/clinic
parent89e50ab36fac6a0e7f1998501f36fcd2872a6604 (diff)
downloadcpython-001eb520b5757294dc455c900d94b7b153de6cdd.zip
cpython-001eb520b5757294dc455c900d94b7b153de6cdd.tar.gz
cpython-001eb520b5757294dc455c900d94b7b153de6cdd.tar.bz2
bpo-44187: Quickening infrastructure (GH-26264)
* Add co_firstinstr field to code object. * Implement barebones quickening. * Use non-quickened bytecode when tracing. * Add NEWS item * Add new file to Windows build. * Don't specialize instructions with EXTENDED_ARG.
Diffstat (limited to 'Python/clinic')
-rw-r--r--Python/clinic/sysmodule.c.h29
1 files changed, 28 insertions, 1 deletions
diff --git a/Python/clinic/sysmodule.c.h b/Python/clinic/sysmodule.c.h
index 04c8481..763fe7a 100644
--- a/Python/clinic/sysmodule.c.h
+++ b/Python/clinic/sysmodule.c.h
@@ -710,6 +710,33 @@ exit:
#endif /* defined(Py_REF_DEBUG) */
+PyDoc_STRVAR(sys__getquickenedcount__doc__,
+"_getquickenedcount($module, /)\n"
+"--\n"
+"\n");
+
+#define SYS__GETQUICKENEDCOUNT_METHODDEF \
+ {"_getquickenedcount", (PyCFunction)sys__getquickenedcount, METH_NOARGS, sys__getquickenedcount__doc__},
+
+static Py_ssize_t
+sys__getquickenedcount_impl(PyObject *module);
+
+static PyObject *
+sys__getquickenedcount(PyObject *module, PyObject *Py_UNUSED(ignored))
+{
+ PyObject *return_value = NULL;
+ Py_ssize_t _return_value;
+
+ _return_value = sys__getquickenedcount_impl(module);
+ if ((_return_value == -1) && PyErr_Occurred()) {
+ goto exit;
+ }
+ return_value = PyLong_FromSsize_t(_return_value);
+
+exit:
+ return return_value;
+}
+
PyDoc_STRVAR(sys_getallocatedblocks__doc__,
"getallocatedblocks($module, /)\n"
"--\n"
@@ -983,4 +1010,4 @@ sys__deactivate_opcache(PyObject *module, PyObject *Py_UNUSED(ignored))
#ifndef SYS_GETANDROIDAPILEVEL_METHODDEF
#define SYS_GETANDROIDAPILEVEL_METHODDEF
#endif /* !defined(SYS_GETANDROIDAPILEVEL_METHODDEF) */
-/*[clinic end generated code: output=68c62b9ca317a0c8 input=a9049054013a1b77]*/
+/*[clinic end generated code: output=e77bf636a177c5c3 input=a9049054013a1b77]*/