Difference between windows threads and fibers

You would have seen this from SQL Server preferences. This could have come with the .NET framework at some point in time, but they kept it separate.

http://stackoverflow.com/questions/796217/what-is-the-difference-between-a-thread-and-a-fiber

This link is mostly correct. But not fully correct though. Windows NT will interrupt threads so that multiple threads can execute at the same time - true. But this will not cause any problems in normal course because if that was the case, half the programs in the world would not work properly.

In reality, it is able to easily manage swapping one thread from kernel to user mode and vice versa along with loading all the data to and from the registers without losing information. In the C++ world, you have a lot of control and can change lots of stuff all over the place which can cause problems and data corruption.

Comments

Popular posts from this blog

Tutorial: Using Google Cloud Storage from C# and .NET

Late 2008 Macbook only giving 1.5 gb/s speed with 6 gb/s Intel SSD?

Enable Visual Studio to use more than 2GB of memory