GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||
GeezerVison is showing github.com — gh-146041: Avoid lock in sys.intern() for already interned strings by colesbury · Pull Request #146072 · python/cpython Conversation
|
|
@encukou, please let me know if you'd like me to do this differently. I've removed the assertion about unicode state in |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Looks correct to me
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| PyObject *r; | ||
| int res = PyDict_GetItemRef(interned, s, &r); | ||
| if (res < 0) { | ||
| PyErr_Clear(); |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Clearing the error here feels a little weird to me, but it's consistent with the rest of the function.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
🤖 New build scheduled with the buildbot fleet by @colesbury for commit 6e59598 🤖 Results will be shown at: https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F146072%2Fmerge If you want to schedule another build, you need to add the 🔨 test-with-refleak-buildbots label again. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
Thanks @colesbury for the PR 🌮🎉.. I'm working now to backport this PR to: 3.14. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Sorry, @colesbury, I could not cleanly backport this to |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…ed strings (pythongh-146072) Fix free-threading scaling bottleneck in sys.intern and `PyObject_SetAttr` by avoiding the interpreter-wide lock when the string is already interned and immortalized. (cherry picked from commit 6009309) Co-authored-by: Sam Gross <[email protected]>
|
GH-146390 is a backport of this pull request to the 3.14 branch. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…ngs (pythongh-146072) Fix free-threading scaling bottleneck in sys.intern and `PyObject_SetAttr` by avoiding the interpreter-wide lock when the string is already interned and immortalized.
…ngs (pythongh-146072) Fix free-threading scaling bottleneck in sys.intern and `PyObject_SetAttr` by avoiding the interpreter-wide lock when the string is already interned and immortalized.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.