GH-118093: Specialize CALL_KW (GH-123006)

This commit is contained in:
Mark Shannon 2024-08-16 17:11:24 +01:00 committed by GitHub
parent e2f2dc708e
commit c13e7d98fb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
17 changed files with 1083 additions and 273 deletions

View file

@ -807,7 +807,7 @@ translate_bytecode_to_trace(
ADD_TO_TRACE(_DYNAMIC_EXIT, 0, 0, 0);
goto done;
}
assert(_PyOpcode_Deopt[opcode] == CALL);
assert(_PyOpcode_Deopt[opcode] == CALL || _PyOpcode_Deopt[opcode] == CALL_KW);
int func_version_offset =
offsetof(_PyCallCache, func_version)/sizeof(_Py_CODEUNIT)
// Add one to account for the actual opcode/oparg pair: