8000 bpo-38310: Predict BUILD_MAP_UNPACK_WITH_CALL -> CALL_FUNCTION_EX. (G… · python/cpython@f185a73 · GitHub
[go: up one dir, main page]

Skip to content

Commit f185a73

Browse files
brandtbucherrhettinger
authored andcommitted
bpo-38310: Predict BUILD_MAP_UNPACK_WITH_CALL -> CALL_FUNCTION_EX. (GH-16467)
1 parent c5a7e0c commit f185a73

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Predict ``BUILD_MAP_UNPACK_WITH_CALL`` -> ``CALL_FUNCTION_EX`` opcode pairs in the main interpreter loop. Patch by Brandt Bucher.

Python/ceval.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2943,6 +2943,7 @@ _PyEval_EvalFrameDefault(PyFrameObject *f, int throwflag)
29432943
while (oparg--)
29442944
Py_DECREF(POP());
29452945
PUSH(sum);
2946+
PREDICT(CALL_FUNCTION_EX);
29462947
DISPATCH();
29472948
}
29482949

@@ -3522,6 +3523,7 @@ _PyEval_EvalFrameDefault(PyFrameObject *f, int throwflag)
35223523
}
35233524

35243525
case TARGET(CALL_FUNCTION_EX): {
3526+
PREDICTED(CALL_FUNCTION_EX);
35253527
PyObject *func, *callargs, *kwargs = NULL, *result;
35263528
if (oparg & 0x01) {
35273529
kwargs = POP();

0 commit comments

Comments
 (0)
0