[issue45527] Reduce overhead for cache hits in specialized opcodes.

2021-10-20 Thread Łukasz Langa
Łukasz Langa added the comment: Thanks, Mark! ✨ 🍰 ✨ -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ _

[issue45527] Reduce overhead for cache hits in specialized opcodes.

2021-10-20 Thread Łukasz Langa
Łukasz Langa added the comment: New changeset bc85eb7a4f16e9e2b6fb713be2466ebb132fd7f2 by Mark Shannon in branch 'main': bpo-45527: Don't count cache hits, just misses. (GH-29092) https://github.com/python/cpython/commit/bc85eb7a4f16e9e2b6fb713be2466ebb132fd7f2 -- nosy: +lukasz.langa

[issue45527] Reduce overhead for cache hits in specialized opcodes.

2021-10-20 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +27361 stage: -> patch review pull_request: https://github.com/python/cpython/pull/29092 ___ Python tracker ___ ___

[issue45527] Reduce overhead for cache hits in specialized opcodes.

2021-10-20 Thread Ken Jin
Ken Jin added the comment: Strong +1 from me. Not to mention some instructions don't even need to read the _PyAdaptiveEntry apart from recording cache hits, so that's one more dependent load and store too. Extremely cheap instructions off the top of my head: - BINARY_SUBSCR - LOAD_METHOD -

[issue45527] Reduce overhead for cache hits in specialized opcodes.

2021-10-19 Thread Mark Shannon
Change by Mark Shannon : -- nosy: +kj ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org

[issue45527] Reduce overhead for cache hits in specialized opcodes.

2021-10-19 Thread Mark Shannon
New submission from Mark Shannon : Every time we get a cache hit in, e.g. LOAD_ATTR_CACHED, we increment the saturating counting. Takes a dependent load and a store, as well as the shift. For fast instructions like BINARY_ADD_FLOAT, this represents a significant portion of work done in the in