[LLVMdev] gcc4 or gcc3?

Tanya M. Lattner tonic at nondot.org
Mon Aug 7 11:26:53 PDT 2006


> (1) To install llvm, do I really need the llvm version of the gcc front
> end? I have no special interest in yet another c/c++ conmpiler.

You need it if you plan to compile C/C++ program to llvm bytecode. You 
don't if you plan to write llvm bytecode directly.

> (2) If I need llvm gcc, will the binary version suffice, or do I need
> to compile the CVS version?

You can use the binary (either llvm-gcc4 or llvm-gcc3).

> (3) If I need its source code, does it properly fit within the
> llvm/projects directory, just like the test suite?  And it that where I
> should execute the cvs co, like like the test suite?  Or is it so
> independent that I should put it totally elsewhere in the file
> system?

No. Its separate. I put it in its own directory.

> (4) The page http://llvm.org/docs/GettingStarted.html#checkout says to get
> the gcc 3.4 source code.
> The instructions to compile it in http://llvm.org/docs/CFEBuildInstrs.html
> seem to deal in gcc 3 and gcc 4 instead.  Is this an error in the
> documentation, or does it indicate that I should compile the llvm-gcc 3.4
> source code with GNU's gcc versions 3 or 4 depending on what;'s already
> installed on my system.

I would use llvm-gcc4 if possible. The CFEBuildInstrs has instructions for 
obtaining llvm-gcc4 source and building.

http://llvm.org/docs/CFEBuildInstrs.html#instructions

-Tanya



More information about the llvm-dev mailing list