In this episode, Stephen Toub chats with Rich about ValueTask<T> and how it might help reduce allocations and memory usage for your asynchronous .NET code.
- [00:34] - What is ValueTask and why do we need it?
- [05:22] - What is a good scenario for ValueTask?
- [10:00] - What is IValueTask<T>?
- [12:14] - Why was the non-generic ValueTask introduced?
- [13:54] - Does ValueTask offer cancellation?
- [14:42] - What can you do with Task vs ValueTask?
- [16:28] - What's the uptake with ValueTask usage?
- [18:28] - How does IAsyncEnumerable task advantage of ValueTask?
- [21:11] - What other performance work is happening around allocations?
- Understanding the Whys, what's, and when's of ValueTask
- ValueTask reference docs
- NuGet package for ValueTask