-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
I-slowIssue: Problems and improvements with respect to performance of generated code.Issue: Problems and improvements with respect to performance of generated code.
Description
Rust currently imposes overhead on all compiled code to accommodate managed pointers and will need to continue doing so to some extent for a real garbage collector. Trait objects and closures are opaque, and may contain garbage collected boxes. Support for correctly rooting references may involve overhead even for unique pointers without managed data inside.
- closures currently have a 4-word header which is unnecessary
- procs currently have a 4-word header
including aTyDesc
, which should just be a destructor pointer &Trait
has aTyDesc
, which is unnecessary~Trait
has aTyDesc
, which should just be a destructor pointerfree glue is unnecessary, and should just be drop gluetake glue is unnecessary- any future support for tracing (shadow stack, references inside unique pointers, etc.) should be entirely disabled
Metadata
Metadata
Assignees
Labels
I-slowIssue: Problems and improvements with respect to performance of generated code.Issue: Problems and improvements with respect to performance of generated code.