~/talk

Fast File IO with .NET 6

Talkat DotNext 2021 Moscow · 2021-10-21..10-22· [dotnet]
links:none on file
slides:none on file

.NET 6 rewrites file I/O and shows concrete wins: benchmarks (BenchmarkDotNet + profilers) report reduced syscalls, much lower allocations and large latency drops — seeking forward and async reads/writes measure up to 50x faster in microbenchmarks, async writes up to ~5x faster and reads ~2x faster, with allocation-free steady-state after the first call. New APIs include File.OpenHandle and RandomAccess plus scatter/gather writes; disabling buffering and using 64 KB buffers or the scatter API cuts syscall overhead.

AI-written summary · about

  1. 0:00Introduction
  2. 2:33File stream basics
  3. 11:57Buffering and performance tips
  4. 18:03Async file IO necessity
  5. 26:08Position tracking improvements
  6. 33:44Async write optimizations
  7. 41:40Read async optimizations
  8. 46:51Performance gains summary
  9. 47:13New APIs in .NET 6
  10. 58:21Performance recap and tips
  11. 1:02:38Q&A and closing
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.