agentsclimarketplace

Rust optimise

Skill ComeOnOliver/skillshub/skills/pproenca/dot-skills/rust-optimise

🧠 The right skill, one API call. AI agent skills registry with token-efficient skill resolution. 5,000+ skills from 500+ top repos.

Install
npx -y skills add ComeOnOliver/skillshub --skill rust-optimise

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

SKILL.md

7.3 KB, ~1.9k tokens by cl100k_base, as published. Nobody here has run it

Rust Optimise Best Practices

Performance optimization guide for Rust applications. Contains 42 rules across 8 categories, prioritized by impact from critical (memory allocation, ownership) to incremental (micro-optimizations).

When to Apply

  • Optimizing Rust code for performance or reducing allocations
  • Choosing data structures for optimal algorithmic complexity
  • Working with iterators to avoid unnecessary intermediate allocations
  • Writing async code with Tokio or other runtimes
  • Profiling hot paths and eliminating performance bottlenecks
  • Reviewing code for performance anti-patterns

Rule Categories by Priority

PriorityCategoryImpactPrefix
1Memory AllocationCRITICALmem-
2Ownership & BorrowingCRITICALown-
3Data Structure SelectionHIGHds-
4Iterator & Collection PatternsHIGHiter-
5Async & ConcurrencyMEDIUM-HIGHasync-
6Algorithm ComplexityMEDIUMalgo-
7Compile-Time OptimizationMEDIUMcomp-
8Micro-optimizationsLOWmicro-

Quick Reference

1. Memory Allocation (CRITICAL)

2. Ownership & Borrowing (CRITICAL)

3. Data Structure Selection (HIGH)

4. Iterator & Collection Patterns (HIGH)

5. Async & Concurrency (MEDIUM-HIGH)

6. Algorithm Complexity (MEDIUM)

7. Compile-Time Optimization (MEDIUM)

8. Micro-optimizations (LOW)

References

  1. https://nnethercote.github.io/perf-book/
  2. https://rust-lang.github.io/api-guidelines/
  3. https://doc.rust-lang.org/nomicon/
  4. https://tokio.rs/tokio/tutorial

Related Skills

  • For idiomatic patterns, architecture, and code organization, see rust-refactor skill

Keep looking

Skills are one crate of 328,083. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.