Skip to content

Optimization: Don't store descendants of BasicObject and friends #553

@amomchilov

Description

@amomchilov

Every single class in the system is a descendant of BasicObject. We don't need to spend memory to remember them all, we can just look at the list of all constants.

Similarly, almost every BasicObject is also an Object (which includes Kernel). Module/Class would also have particularly large descendants lists. We should investigate optimizing these.

For what it's worth, "What is every descendant of Class in my system?" is not a particularly common/useful question, so it's okay if it's slower than queries.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions