Roadmap › Modern .NET — Hosting, Configuration, DI & Deployment › Module: Deployment and Performance
Lessons in this course (9)

8. Performance features of modern .NET

AdvancedMediumLesson 8 of 9
  • Span<T>/Memory<T>, ArrayPool<T>, stackalloc — fewer allocations.
  • System.Text.Json (fast, source-generated) instead of Newtonsoft for new code.
  • Tiered compilation + Dynamic PGO, ReadyToRun, Native AOT.
  • ValueTask, IAsyncEnumerable, System.IO.Pipelines, Channel<T>.
  • FrozenDictionary/FrozenSet (.NET 8) for read-heavy lookups; SearchValues<T> for fast searches.
  • Output caching, response compression, HybridCache (.NET 9).
  • Measure with BenchmarkDotNet; profile with dotnet-trace / PerfView before optimising.