UPDATED 18:13 EDT / FEBRUARY 10 2014

GCC and LLVM developers collaboration is good for open source ecology

gcc-logoThere is something GNU Compiler Collection (GCC) has been lacking for quite some time and a possible collaberation with LLVM/Clang (ow Level Virtual Machine) might help add it. However, some criticisms of this alliance may yet apply.

GCC–the GNU Compiler Collection–is a compiler compilation for a wide variety of programming languages. It is free software distributed by the Free Software Foundation under the GNU General Public License and the GNU Lesser General Public License and is a key component among GNU tool chain.

But, GCC’s developers have actively resisted allowing it to be modularized in a way that would allow GCC’s internal code representations to be read and used by proprietary compilation tools or optimizers. The software first appeared in 1987 and now that it has reached a certain age and it needs a lot of changes before it can enable this sort of state serialization.

Now, in a latest development, GCC and Low Level Virtual Machine (LLVM/Clang) developers may be seeing a light at the end of the tunnel in a decision to better collaborate under some sort of open-source compiler initiative. LLVM continues to be widely used by different users but comes under a BSD-style license rather than the GPL.

Renato Golin of Linaro said that the collaboration would help developers to port to other compliers, compiler extensions and other non-standard or undocumented features when they need it. It will create a better open source ecology for developers. Developers from both sides can now cooperate and create new open source standards even though they may have their fundamental differences.

“LLVM and GCC developers begin collaborating due to an unnecessary fence between the competing compilers and decisions that need to be shared.” he said. “Developers begin relying upon one compiler but then hit roadblocks when trying to compile against the competing compiler for extensions and other changes that are developed in the open. There’s decisions that need to be shared when it comes to compiler extensions and other non-standard or undocumented features.”

In contrast, Founder of GNU Project and Free Software Foundation, Richard Stallman has called LLVM a terrible setback in a new mailing list exchange over GCC vs. Clang. He has claimed the existence of LLVM is a terrible setback for GCC community precisely because it is not copylefted and can be used as the basis for nonfree compilers–so that all contribution to LLVM directly helps proprietary software.

“In the free software movement, we campaign for the freedom of the users of computing. The values of free software are fundamentally different from the values of open source, which make “better code” the ultimate goal. If GCC were to change from a free compiler into a platform for nonfree compilers, it would no longer serve the goal of freedom very well. Therefore, we had to take care to prevent that,” he said.

“The Clang and LLVM developers reach different conclusions from ours because they do not share our values and goals. They object to the measures we have taken to defend freedom because they see the inconvenience of them and do not recognize (or don’t care about) the need for them. I would guess they describe their work as “open source” and do not talk about freedom. They have been supported by Apple, the company which hates our freedom so much that its app store for the ithings _requires_ all apps to be nonfree,” Stallman continued.

LLVM is a low-level object representation mostly used for Linux development uses simple RISC-like code instructions, but provides rich, language-independent, type and dataflow information. This combination enables sophisticated transformations on object code, while remaining light-weight enough to be attached to the executable. This combination is also key to allowing link-time, run-time, and offline transformations.

LLVM is also a collection of source code that implements the strategy language and compilation. The primary components of the LLVM infrastructure are a GCC-based C&C++ front-end, a link-time optimization framework with a growing set of global and interprocedural analyzes and transformations, static back-ends for many popular (and some obscure) architectures, a back-end which emits portable C code, and a Just-In-Time compilers for several architectures.

LLVM does not imply things that you would expect from a high-level virtual machine. It does not require garbage collection or run-time code generation. Note that LLVM optional components can be used to build virtual machines and other high-level systems that need these services. LLVM is a robust system, particularly suited well for developing new mid-level language-independent analyzes and optimizations of all sorts, including those that require interprocedural analysis.


A message from John Furrier, co-founder of SiliconANGLE:

Your vote of support is important to us and it helps us keep the content FREE.

One click below supports our mission to provide free, deep, and relevant content.  

Join our community on YouTube

Join the community that includes more than 15,000 #CubeAlumni experts, including Amazon.com CEO Andy Jassy, Dell Technologies founder and CEO Michael Dell, Intel CEO Pat Gelsinger, and many more luminaries and experts.

“TheCUBE is an important partner to the industry. You guys really are a part of our events and we really appreciate you coming and I know people appreciate the content you create as well” – Andy Jassy

THANK YOU