Preferring to use GCC instead of LLVM

me22.ca wrote:

You said that if I have to install GCC, you might as well just use it for everything. That statement very clearly doesn't apply anymore, since it's binutils that's the dependency. Or if you still stand by it, it means that you consider GCC to also be "incomplete".

How do I get the necessary binutils on Windoze? Install MinGW or Cygwin. But if I do that, then I may as well use MinGW for everything and not bother with LLVM.

Our frontend compiler can generate C code as input to a C compiler (such as GCC in MinGW) and use the C compiler as a backend solution. Alternatively our frontend compiler could be made to generate LLVM instructions as input to LLVM. The problem is that LLVM is an incomplete backend solution -- LLVM practically requires that MinGW or Cygwin be installed.

But if MinGW or Cygwin is installed, then I have no need for LLVM !!

So the point is, Windoze developers will tend to reject LLVM while it requires that MinGW or Cygwin be installed, because MinGW/Cygwin eliminate the need for LLVM.

The Solution:
Make LLVM usable as a DLL or SLL in Windoze, capable of generating a finished ready-to-execute .EXE or .DLL file, without requiring that MinGW or Cygwin be installed first.

me22.ca wrote:

You said that if I have to install GCC, you might as well

just use it for everything. That statement very clearly

doesn’t apply anymore, since it’s binutils that’s the

dependency. Or if you still stand by it, it means that

you consider GCC to also be “incomplete”.

How do I get the necessary binutils on Windoze? Install
MinGW or Cygwin. But if I do that, then I may as well use
MinGW for everything and not bother with LLVM.

You, as the developer, install/build binutils in MinGW. Then you pull the executables out and stick them in the package that you give your clients. Thus the clients don’t need MinGW.

Our frontend compiler can generate C code as input to a C
compiler (such as GCC in MinGW) and use the C compiler as a
backend solution. Alternatively our frontend compiler could
be made to generate LLVM instructions as input to LLVM. The
problem is that LLVM is an incomplete backend solution –
LLVM practically requires that MinGW or Cygwin be installed.

But if MinGW or Cygwin is installed, then I have no need for
LLVM !!

This is not the case. Having MinGW/Cygwin installed != having GCC installed.

The Solution:
Make LLVM usable as a DLL or SLL in Windoze, capable of
generating a finished ready-to-execute .EXE or .DLL file,
without requiring that MinGW or Cygwin be installed first.

The first part is already true: LLVM is built as a set of libraries. The latter is unlikely to change unless you’re volunteering to write it.

–Owen

How do I get the necessary binutils on Windoze? Install
MinGW or Cygwin. But if I do that, then I may as well use
MinGW for everything and not bother with LLVM.

Our frontend compiler can generate C code as input to a C
compiler (such as GCC in MinGW) and use the C compiler as a
backend solution. Alternatively our frontend compiler could
be made to generate LLVM instructions as input to LLVM. The
problem is that LLVM is an incomplete backend solution –
LLVM practically requires that MinGW or Cygwin be installed.

But if MinGW or Cygwin is installed, then I have no need for
LLVM !!

So the point is, Windoze developers will tend to reject LLVM
while it requires that MinGW or Cygwin be installed, because
MinGW/Cygwin eliminate the need for LLVM.

I think the fundamental point of contention here is “need”. You claim to have no need of LLVM if MinGW or Cygwin are present. However, the existing developers of LLVM have a need which superscedes the presence of MinGW, Cygwin, GAS, Binutils, GCC, Gold, MASM, Visual Studio, or any other toolchain element you wish to mention. What they need is not to replace every element of the toolchain, or have a single toolchain package, but rather to fix specific deficits in a single aspect of the toolchain: GCC’s backend. They have done so, with considerable assistance and funding, serving numerous customers.

Sadly, these are not your customers, and their needs seem to not be the same as your needs. However, simply because LLVM is currently targeted at a different group of customers does not mean that it is failing to serve the needs of its customers, it is infact serving them quite well. You will have to take the steps to serve your customers however because they (according to you) have different needs.

Keep in mind that as Owen points out, all other major compilers have the same challenges you enumerate, they simply have had some interested party (such as yourself) with customers who need a solution package and include their dependencies in a nice system such as MinGW or Cygwin. Should you have sufficient demand for LLVM in this context, rather than any C compiler, you might well find it worth your time to contribute such a packaging.

-Chandler

kr512 wrote:

So the point is, Windoze developers will tend to reject LLVM while it requires that MinGW or Cygwin be installed, because MinGW/Cygwin eliminate the need for LLVM.

The Solution:
Make LLVM usable as a DLL or SLL in Windoze, capable of generating a finished ready-to-execute .EXE or .DLL file, without requiring that MinGW or Cygwin be installed first.

Yes, that sounds like a very useful contribution to the project.
I'm sure you could come up with something if you got together
with other Windows developers in this list to hash out what
needs to be done.

You should. The GCC guys are much nicer than we are. They love to answer questions such as yours.

-bw

The Solution:
Make LLVM usable as a DLL or SLL in Windoze, capable of 
generating a finished ready-to-execute .EXE or .DLL file, 
without requiring that MinGW or Cygwin be installed first.

You will be welcomed with open arms by the LLVM community when you write this. I look forward to your announcement with bated breath.