summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Misc/NEWS.d/next/Core and Builtins/2019-09-28-22-54-25.bpo-38310.YDTbEo.rst1
-rw-r--r--Python/ceval.c2
2 files changed, 3 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Core and Builtins/2019-09-28-22-54-25.bpo-38310.YDTbEo.rst b/Misc/NEWS.d/next/Core and Builtins/2019-09-28-22-54-25.bpo-38310.YDTbEo.rst
new file mode 100644
index 0000000000..5c3086b607
--- /dev/null
+++ b/Misc/NEWS.d/next/Core and Builtins/2019-09-28-22-54-25.bpo-38310.YDTbEo.rst
@@ -0,0 +1 @@
+Predict ``BUILD_MAP_UNPACK_WITH_CALL`` -> ``CALL_FUNCTION_EX`` opcode pairs in the main interpreter loop. Patch by Brandt Bucher. \ No newline at end of file
diff --git a/Python/ceval.c b/Python/ceval.c
index 964ce13336..a7d2ea8006 100644
--- a/Python/ceval.c
+++ b/Python/ceval.c
@@ -2943,6 +2943,7 @@ main_loop:
while (oparg--)
Py_DECREF(POP());
PUSH(sum);
+ PREDICT(CALL_FUNCTION_EX);
DISPATCH();
}
@@ -3522,6 +3523,7 @@ main_loop:
}
case TARGET(CALL_FUNCTION_EX): {
+ PREDICTED(CALL_FUNCTION_EX);
PyObject *func, *callargs, *kwargs = NULL, *result;
if (oparg & 0x01) {
kwargs = POP();