Linux 6.1: Rust to hit mainline kernel

The first big change for the forthcoming Linux kernel 6.1 is in... and it's a big one.

Kees Cook made the pull request and Linus Torvalds accepted it earlier this week, meaning that Linux 6.1 will soon have direct support for Rust code. The initial support is in the region of 12-and-a-half thousand lines of code.

No, this doesn't mean that the kernel will start to be rewritten in Rust. There are already other Rust operating system kernels in development, such as Redox OS, and Linux is not going to become one of them.

Linux is a traditional monolithic Unix kernel, following closely in the footsteps of the original AT&T kernel of the 1970s, and if it were rewritten in a different programming language, then it would cause serious difficulties in interoperating with existing code.

What's interesting is that it's Rust that has made it. There are multiple languages vying to be successors to C, with C-like syntax but which extend C with new features. C++ was one of the first, which adds object oriented programming to C.

Many Unix and Linux traditionalists frown upon C++, but it's enjoyed wide success despite its great size and complexity. KDE, the Plasma desktop, and the many apps in the KDE Gear collection are predominantly built in C++, which has aided their adaptation to the safety-enhanced CHERI processor architecture. The Blink engine behind the Chrome browser is based on Apple's WebKit engine, which in turn is based on KDE's KHTML, making it by far the most widely used code from KDE.

C++ has also been used in multiple successful OS projects: Psion's EPOC32, which evolved into the Symbian smartphone OS, as well as BeOS and Haiku.

C++, however, is famed for its size and complexity, which has inspired multiple successors which try to retain some of its power, such as OOPS support, while being simpler. Apple's Objective-C replaces C++'s OOPS style, inherited from Simula, with Smalltalk-style OOPS. Google's Go is related to Alef, from the Plan 9 OS, and Limbo, the systems programming language of Inferno, the last descendant of the original UNIX project. The D Language was created by Walter Bright, who wrote Zortech C++ (later sold as Symantec C++), the first ever compiler to turn C++ source into native object code.

All improved upon C in various ways, but none has won the approval of the kernel team. Indeed, writing about Rust always quickly summons fervent supporters in a way that none of the others do - and doubtless this story will, too. It did when we previously wrote about the expected support that was mentioned in Torvalds' Open Source Summit keynote. Anything less than passionate support for Rust, or any kind of criticism, is typically met with savage criticism.

Previously, Rust advocates have told us that its interoperability with C code is one of its core strengths. However, the latest version of Rust still can't be compiled with GCC, and the Clang compiler that does support Rust only has first-class support for x86-64 and AArch64.

So, for now, this could be a limiting factor: if a driver is implemented in Rust, that could spell limited support the relevant hardware (or filesystem or whatever) for other processor architectures. Saying that, though, a likely consequence will be rapid improvement in Rust's compiler support - both in other compilers, and quite likely in Clang and LLVM's target support too. ®

About Us
Website HardCracked provides softwares, patches, cracks and keygens. If you have software or keygens to share, feel free to submit it to us here. Also you may contact us if you have software that needs to be removed from our website. Thanks for use our service!
IT News
Dec 3
OpenAI tweaks ChatGPT to avoid dangerous AI information

In brief Plus: DeepMind beats humans at Stratego

Dec 3
Google says Android runs better when covered in Rust

Banishing memory safety bugs cuts critical vulnerabilities

Dec 2
Google frees nifty ML image-compression model... but it's for JPEG-XL

Yep. The very same JPEG-XL that's just been axed from Chromium

Dec 2
Blockchain needs a reason to exist, Boris Johnson tells roomful of blockchain pros

As for Twitter, politicians need to grow thick skins and stop mistaking it for advertisement

Dec 2
DoJ worries messaging apps could hide evidence of crime, corruption

Record keeping rules might need a tweak to ensure content is preserved

Dec 1
Microsoft adds silicon muscle into latest Azure SQL database configs

Intel's 'Ice Lake' and AMD's 'Milan' chips bump up speeds and feeds

Dec 1
.NET open source is 'heavily under-funded' says AWS

RE:INVENT Amazon web arm investing in Microsoft's platform to help customers escape Windows