5 ms·
Just use LLVM: http://llvm.org/ http://llvm.org/
by parax 12y ago
Just use LLVM:
http://llvm.org/ http://llvm.org/
- kzrdude 12y agoAnd if you find one bug in llvm, switch back?
- LeoNatan25 12y agoMove to MSVC++ :P
- a3_nm 12y agoPeople are working on it http://llvm.linuxfoundation.org http://llvm.linuxfoundation.org but it is not a trivial thing to do.
- keeperofdakeys 12y agoUnfortunately the linux kernel still relies on some gnu C extensions for some low-level control of the output. I don't know if comparable stuff exists in llvm and clang, and if so, if linus has any plans on supporting them. However this is just bugs in a new compiler, and the Linux kernel is probably one of those things that hits cornercases.
- exDM69 12y agoI'm not sure which C extensions do you mean, but Clang supports most of the same GNU extensions that GCC does. Indeed, it's one of the goals of Clang to be compatible with GCC whenever possible. However, there might be some things that are not (yet?) supported. And the kernel can be compiled using LLVM and Clang, but not quite in all configurations. But compiling mainline kernel for x86 using LLVM was achieved some years ago.
- gillianseed 12y agoA lot (if not the majority) of GCC extensions used by Linux exist in GCC because the Linux kernel developers requested them in order to have a great level of control in terms of the generated machine code, so it's not exactly surprising that the Linux kernel relies on a lot of said GCC extensions. Many of these extensions which the Linux kernel relies on have been added to LLVM, but obviously not all, and from the looks of it some never will, which means either Linux needs to refrain from using said extensions, or building Linux using LLVM will continue to require patching.
- _stephan 12y agoAs if LLVM had no bugs.
- userbinator 12y agoThe optimiser in LLVM does some even more "seriously crazy shit" - usually revolving around obscure edge cases involving officially undefined behaviour. Linus would definitely not be happy with that.