Skip to content

bpo-44821: Eagerly assign __dict__ for new objects.#27589

Merged
markshannon merged 3 commits intopython:mainfrom
faster-cpython:eager-dicts
Aug 4, 2021
Merged

bpo-44821: Eagerly assign __dict__ for new objects.#27589
markshannon merged 3 commits intopython:mainfrom
faster-cpython:eager-dicts

Conversation

@markshannon
Copy link
Member

@markshannon markshannon commented Aug 4, 2021

This is part of our drive to make layout of objects more regular and efficient.
This has little or no overall impact on performance

The main reason for this PR is make specialization of STORE_ATTR work well.

https://bugs.python.org/issue44821

Copy link
Member

@gvanrossum gvanrossum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aren’t there code paths that no longer can be taken now the dict is always initialized?

@markshannon markshannon merged commit cee67fa into python:main Aug 4, 2021
@markshannon markshannon deleted the eager-dicts branch August 23, 2021 13:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants