pyperformance
pyperformance copied to clipboard
Need benchmark using `__getattribute__`
It would be nice if there was a benchmark that exercised __getattribute__ somewhat realistically. Defining that method is the only way to exercise the specialized instruction LOAD_ATTR_GETATTRIBUTE_OVERRIDDEN. Then again, maybe that method is not important enough to have its own specialized opcode?
See also https://github.com/python/cpython/pull/93988#issuecomment-1745806916