What Is a Thread? Kernel Threads, Stacks, Thread-Local Storage and the OS View of a .NET Thread
A thread is the unit the scheduler puts on a CPU: it shares its process's address space but has its own stack, registers and thread-local storage, and in .NET every managed thread is one OS thread. We identify the twelve threads of a console app with ps -T, measure that 1000 threads take 12.7 GB of virtual but 20 MB of resident memory while 100,000 waiting tasks run on seven threads, and show how ThreadStatic and AsyncLocal differ after await.
14 Nov 2026
·
11 min
·
2