Skip to content

Use Arc::new_cyclic for cyclic Rust references #989

Open
@qinsoon

Description

@qinsoon

For example, we have cyclic reference between GCTrigger and Plan. Currently we use MayUninit to create the cyclic reference. The idiomatic way is to use Weak, and upgrade the weak reference when accessing the field. upgrade has a performance cost. We should measure and see if this is appropriate for us.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-generalArea: all code base (issues with this label may be divided into more concrete issues)C-cleanupCategory: CleanupP-normalPriority: Normal.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions