-
-
Notifications
You must be signed in to change notification settings - Fork 32.2k
bpo-45340: Don't create object dictionaries unless actually needed #28802
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
markshannon
merged 25 commits into
python:main
from
faster-cpython:inline-attributes-with-opt
Oct 13, 2021
Merged
Changes from 20 commits
Commits
Show all changes
25 commits
Select commit
Hold shift + click to select a range
8214006
Add insertion order bit-vector to dict values to allow dicts to share…
markshannon 45c9814
Add NEWS
markshannon c3de09e
Never change types' cached keys. It could invalidate inline attribute…
markshannon 58dd2a0
Lazily create object dictionaries. Work in progress.
markshannon 769183a
Restore specialization for inline attributes.
markshannon 1e6cd1f
Turn on stats
markshannon a8fbb34
Fix specialization of LOAD/STORE_ATTR.
markshannon 37d8cc6
Turn off stats.
markshannon 0e022f9
Don't update shared keys version for deletion of value.
markshannon ddd2e2c
Merge main into inline-attributes-with-opt
markshannon e979575
Fix refrence leak.
markshannon 42361ad
Change 'InlineAttribute' to 'InstanceAttribute' as they are not inlin…
markshannon e9b09d5
Merge branch 'main' into inline-attributes-with-opt
markshannon 70dc34f
Update gdb support to handle instance values.
markshannon 022f2c5
Rename SPLIT_KEYS opcodes to INSTANCE_VALUE.
markshannon 4ec5f11
Tidy test_gc
markshannon 1818a5a
Don't lose errors.
markshannon bfc7be0
Make sure order is updated when deleting from values array.
markshannon 62a3a59
Update test_dict.
markshannon 7978220
Add NEWS
markshannon b25b1d9
Merge branch 'main' into inline-attributes-with-opt
markshannon 7b2efa4
Merge branch 'main' into inline-attributes-with-opt
markshannon 459e29e
Make sure that instance dicts are GC tracked when necessary.
markshannon 83b90c5
Support older versions of Python in gdb.
markshannon 8c894f3
Rename function and move to internal header.
markshannon File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
Misc/NEWS.d/next/Core and Builtins/2021-10-08-09-47-38.bpo-45340.ukHgDb.rst
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Object attributes are held in an array instead of a dictionary. An object's | ||
dictionary are created lazily, only when needed. Reduces the memory | ||
consumption of a typical Python object by about 30%. Patch by Mark Shannon. |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.