Replace C++: Microsoft is switching to Rust to rewrite the Windows 11 kernel
1 min readReplace C++: Microsoft is switching to Rust to rewrite the Windows 11 kernel
Replace C++: Microsoft is switching to Rust to rewrite the Windows 11 kernel.
Microsoft has decided to end the feature update of Win10, and more of its energy will be transferred to Win11 and “Win12”.
At the BlueHat IL 2023 conference held recently, David Weston, Microsoft’s vice president of enterprise and operating system security, introduced the kernel-level transformation they are doing to Win11.
Simply put, Microsoft is rewriting the kernel in Rust instead of C++, and has added 36,000 lines of code so far.
Weston pointed out that the Rust language has extremely high memory safety, and a large number of unsafe subroutines in the original kernel disappeared after rewriting. At the same time, the Rust language is more concise and efficient.
In terms of performance, after porting the Rust code, the Office application has no performance loss, and most benchmark tests are almost the same. In some cases, Rust has better performance than the C++ kernel.
In addition, Win32k’s GDI (Graphics Driver Interface) ported to Rust passed all Windows boot tests.
According to Microsoft, after a few weeks or months, everyone’s Win11 is likely to start with the Rust kernel.