bpo-26110: Add `CALL_METHOD_KW` opcode to speedup method calls with keywords (GH-26014)

* Add CALL_METHOD_KW

* Make CALL_METHOD branchless too since it shares the same code

* Place parentheses in STACK_SHRINK
This commit is contained in:
Ken Jin 2021-05-15 23:15:23 +08:00 committed by GitHub
parent e4e931a67e
commit f24afda591
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 247 additions and 180 deletions

View file

@ -282,13 +282,13 @@ const unsigned char _Py_M__zipimport[] = {
254,16,3,114,11,0,0,0,122,23,122,105,112,105,109,112,
111,114,116,101,114,46,102,105,110,100,95,109,111,100,117,108,
101,99,3,0,0,0,0,0,0,0,0,0,0,0,7,0,
0,0,5,0,0,0,67,0,0,0,115,108,0,0,0,116,
0,0,6,0,0,0,67,0,0,0,115,108,0,0,0,116,
0,124,0,124,1,131,2,125,3,124,3,100,1,117,1,114,
17,116,1,106,2,124,1,124,0,124,3,100,2,141,3,83,
17,116,1,160,2,124,1,124,0,124,3,100,2,166,3,83,
0,116,3,124,0,124,1,131,2,125,4,116,4,124,0,124,
4,131,2,114,52,124,0,106,5,155,0,116,6,155,0,124,
4,155,0,157,3,125,5,116,1,106,7,124,1,100,1,100,
3,100,4,141,3,125,6,124,6,106,8,160,9,124,5,161,
4,155,0,157,3,125,5,116,1,160,7,124,1,100,1,100,
3,100,4,166,3,125,6,124,6,106,8,160,9,124,5,161,
1,1,0,124,6,83,0,100,1,83,0,41,5,122,107,67,
114,101,97,116,101,32,97,32,77,111,100,117,108,101,83,112,
101,99,32,102,111,114,32,116,104,101,32,115,112,101,99,105,
@ -1047,8 +1047,8 @@ const unsigned char _Py_M__zipimport[] = {
0,0,0,67,0,0,0,115,14,1,0,0,116,0,124,0,
124,1,131,2,125,2,100,0,125,3,116,1,68,0,93,100,
92,3,125,4,125,5,125,6,124,2,124,4,23,0,125,7,
116,2,106,3,100,1,124,0,106,4,116,5,124,7,100,2,
100,3,141,5,1,0,9,0,124,0,106,6,124,7,25,0,
116,2,160,3,100,1,124,0,106,4,116,5,124,7,100,2,
100,3,166,5,1,0,9,0,124,0,106,6,124,7,25,0,
125,8,110,10,35,0,4,0,116,7,121,134,1,0,1,0,
1,0,89,0,113,9,37,0,124,8,100,4,25,0,125,9,
116,8,124,0,106,4,124,8,131,2,125,10,100,0,125,11,