-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Open
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation
Description
Introduce a dedicated performance section documenting escape hatches and optimization patterns available to developers who need to go beyond the default Anchor abstractions.
Content to include:
- Custom entrypoint with discriminator-based dispatch (as shown in the design doc) that falls back to the Anchor
entryfunction. - When and how to use raw
AccountViewaccess instead of typedAccount<T>for hot paths. - Zero-copy layout best practices: alignment, padding,
repr(C)rules. - Benchmarking methodology (CU usage, LiteSVM-based benchmarks).
- Trade-offs: what safety guarantees you give up with each escape hatch.
Acceptance criteria:
The Anchor documentation has a "Performance" section with runnable code examples and CU comparisons.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
documentationImprovements or additions to documentationImprovements or additions to documentation
Type
Projects
Status
Todo