Starting with LLVM-GCC on Cygwin

Hi,

I would like to use LLVM-GCC to compare its performance with other compilers.
Something like testsuite "Computing very large Fibonacci numbers" at
http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/37.

My environment:

Alex Vinokur wrote:

Hi,

I would like to use LLVM-GCC to compare its performance with other compilers.
Something like testsuite "Computing very large Fibonacci numbers" at
http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/37.

My environment:
-----------------
Windows 2000
Cygwin
$ uname -srom
CYGWIN_NT-5.0 1.5.11(0.116/4/2) i686 Cygwin
-----------------

What do I have to download from
Low Level Virtual Machine - Browse Files at SourceForge.net
* executables(?) cfrontend-1.3.i386-unknown-freebsd5.2.1.tar.gz ?
* sources cfrontend-1.3.source.tar.gz ?

You will need to download both the LLVM sources (llvm-1.3.tar.gz) and the LLVM-GCC sources (cfrontend-1.3.source.tar.gz).

The LLVM sources always have to be built (we don't distribute binary verisons of these). You will have to build the LLVM GCC frontend on Cygwin since we don't have binaries for these (unless Cygwin supports FreeBSD emulation, the FreeBSD binaries won't work).

I don't know if LLVM 1.3 will work on Cygwin. If not, you can get the latest llvm-gcc and llvm sources from our CVS repository; I know there is at least partial support for Cygwin in the latest sources. Please see http://llvm.cs.uiuc.edu/docs/GettingStarted.html#checkout for more information.

1. Question about executables.
-------------------------------
After gunzip
* cfrontend-1.3.i386-unknown-freebsd5.2.1.tar.gz
  and
* tar -xf cfrontend-1.3.i386-unknown-freebsd5.2.1.tar
I see that cfrontend/x86/llvm-gcc/bin contains the following files:

c++
cpp
g++
gcc
gccbug
gcov
i386-unknown-freebsd5.2.1-c++
i386-unknown-freebsd5.2.1-g++
i386-unknown-freebsd5.2.1-gcc
i386-unknown-freebsd5.2.1-gcc-3.4-llvm

Are they executables?

Which of them should I use on Cygwin?

Well, you shouldn't use any of these, as the FreeBSD binaries probably won't work on Cygwin.

But, once you build the llvm-gcc frontend, you'll get a very similar directory tree. To compile programs, you'll use the c++, g++, and gcc binaries listed above. I believe the programs with the "i386-unknown-freebsd..." prefix are just there in case you've got a cross compiling environment.

2. Question about sources.
--------------------------
http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html#cygwin contains the following instruction:
Configure and build the LLVM libraries and tools using:
% cd llvm
% ./configure [options...]
% gmake tools-only

2.1. Which options should I use with ./configure [options...]?

The only option you will probably need is --with-llvmgccdir, which will tell the LLVM sources where the LLVM GCC files will eventually be located (they won't be there when you start, because you have to build LLVM before LLVM-GCC).

The build process is a little inconvenient, but here's the gist of it:

o) Build LLVM tools (i.e. configure llvm and do "make tools-only").
o) Build the LLVM GCC frontend.
o) Go back into the LLVM sources, build the runtime libraries, and install them.
o) Set the LLVM_LIB_SEARCH_PATH variable so that the LLVM tools can find the libraries.

Please see our documentation (http://llvm.cs.uiuc.edu/docs/GettingStarted.html) and (http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html) for all the details. I highly recommend that you follow them as exactly as you can; missing one detail can mean the difference between a successful build and a very confusing build that doesn't work.

2.2. Cygwin doesn't have gmake:
$ which gmake
gmake: Command not found.

Could I use make?

On Cygwin, your make program is most likely GNU Make. Type:

make --version

... and if you get something like this:

GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.

... then your "make" program is actually "GNU Make" and will work just fine.

If you run into any more trouble, please let us know. We'll do what we can to help.

-- John T.

I would like to use LLVM-GCC to compare its performance with other compilers.
Something like testsuite "Computing very large Fibonacci numbers" at
http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/37.

For the performance comparisons that we run, see for example http://llvm.org/testresults/X86/ ; there we compare LLVM's performance to regular GCC on a daily, ongoing basis.

What do I have to download [...] ?
After gunzip
* cfrontend-1.3.i386-unknown-freebsd5.2.1.tar.gz
[...] Which of them should I use on Cygwin?

There is no binary executable C/C++ front-end distributed for Windows/Cygwin yet. You must build your own from sources; you can't use the FreeBSD-compiled C/C++ front end.

2.1. Which options should I use with ./configure [options...]?

For a first build of the LLVM tool chain on x86, you don't need to specify any options. You might want to specify --enable-spec2000 if you have the SPEC CPU2000 benchmark sources.

2.2. Cygwin doesn't have gmake:
$ which gmake
gmake: Command not found.
Could I use make?

Cygwin's make is GNU make; it should work.

-Brian

Out of curiousity, I ran some quick tests on a AMD Athlon(TM) MP 2100+ box
running Redhat linux 7.1.

With the LLVM C backend and GCC 3.3 -O3, I got:

$ time Output/bigfib.cbe th 50000 > /dev/null
0.800u 0.190s 0:00.99 100.0% 0+0k 0+0io 245pf+0w
$ time Output/bigfib.cbe th 50000 > /dev/null
0.800u 0.190s 0:00.99 100.0% 0+0k 0+0io 245pf+0w
$ time Output/bigfib.cbe th 50000 > /dev/null
0.770u 0.230s 0:00.99 101.0% 0+0k 0+0io 245pf+0w

Native GCC 3.3 -O2:

$ time Output/bigfib.native th 50000 > /dev/null
1.010u 0.170s 0:01.18 100.0% 0+0k 0+0io 234pf+0w
$ time Output/bigfib.native th 50000 > /dev/null
1.030u 0.160s 0:01.17 101.7% 0+0k 0+0io 234pf+0w
$ time Output/bigfib.native th 50000 > /dev/null
1.000u 0.170s 0:01.16 100.8% 0+0k 0+0io 234pf+0w

Native GCC 3.3 -O3:

$ time Output/bigfib.native th 50000 > /dev/null
0.940u 0.150s 0:01.08 100.9% 0+0k 0+0io 235pf+0w
$ time Output/bigfib.native th 50000 > /dev/null
0.930u 0.150s 0:01.07 100.9% 0+0k 0+0io 235pf+0w
$ time Output/bigfib.native th 50000 > /dev/null
0.890u 0.200s 0:01.08 100.9% 0+0k 0+0io 235pf+0w

Note that this benchmark allocates a TON of memory, so it's not a
wonderful benchmark of CPU bound tasks (also, the compiler in use will
have less impact than for a CPU bound program). In any case, I've added
this program to the LLVM testsuite as
SingleSource/Benchmarks/Misc-C++/bigfib.cpp, so we should have numbers for
it generated every night on multiple platforms.

-Chris

"Chris Lattner" <sabre@nondot.org> wrote in message news:Pine.LNX.4.44.0410051204480.5863-100000@nondot.org...

> I would like to use LLVM-GCC to compare its performance with other compilers.
> Something like testsuite "Computing very large Fibonacci numbers" at
> http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/37.

Out of curiousity, I ran some quick tests on a AMD Athlon(TM) MP 2100+ box
running Redhat linux 7.1.

[snip]

Note that this benchmark allocates a TON of memory,

The main purpose of the "Computing very large Fibonacci numbers" algorithm was to create fast _recursive_ algorithm.
The algorithm generates very large Fibonacci numbers using the primary recursive formula:
F(n) = F(n-1) + F(n-2) n > 1; F(1) = 1, F(0) = 0.

Latest version of the algorithm is 2.7.9 and can be seen at
http://groups.google.com/groups?selm=2paj5hFim4q1U1%40uni-berlin.de

so it's not a wonderful benchmark of CPU bound tasks (also, the compiler in use will
have less impact than for a CPU bound program). In any case, I've added
this program to the LLVM testsuite as
SingleSource/Benchmarks/Misc-C++/bigfib.cpp, so we should have numbers for
it generated every night on multiple platforms.

[snip]

Newsgroup http://news.gmane.org/gmane.comp.lang.c%2B%2B.perfometer contains another testsuites.
For instance:

1. Simple C++ Perfometer
Methods of copying files
http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/47.

2. C/C++ Program Perfometer

Latest version is 2.8.0-1.18.
Its description can be ssen at http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/39

List of all testsuites

I downloaded this and took a quick look at it. It looks like an
interesting suite of benchmarks, similar in design to oopack.
Unfortunately, it does not compile with LLVM (or GCC 3.4), as the source
is not compliant with two phase name lookup. I get errors such as:

$ llvmg++ -O3 -I. -DOPT_LEVEL=-1 -W -Wall -c pfmeter.cpp
In file included from pfmeter2.h:50,
                 from pfmeter.cpp:44:
pfmeter.h: In destructor `ClassPerfoMeter<T1, T2,
T3>::~ClassPerfoMeter()':
pfmeter.h:620: error: there are no arguments to
`check_state_resource_values' that depend on a template parameter, so a
declaration of `check_state_resource_values' must be available
pfmeter.h:620: error: (if you use `-fpermissive', G++ will accept your
code, but allowing the use of an undeclared name is deprecated)
pfmeter.h:621: error: there are no arguments to `check_state_clock' that
depend on a template parameter, so a declaration of `check_state_clock'
must be available

and (with -fpermissive):
pfmeter2.h: In member function `void ClassPerfoMeter<T1, T2,
T3>::dtor_action() const':
pfmeter2.h:832: error: `end_resource_value_' undeclared (first use this
function)
...

In any case, our test suite works best with individual programs that do
one thing, then exit (like the fib program), so perfmeter isn't directly
useful. It's a neat suite though, thanks for the pointer!

-Chris

"Chris Lattner" <sabre@nondot.org> wrote in message news:Pine.LNX.4.44.0410061044190.367-100000@nondot.org...

> > have less impact than for a CPU bound program). In any case, I've added
> > this program to the LLVM testsuite as
> > SingleSource/Benchmarks/Misc-C++/bigfib.cpp, so we should have numbers for
> > it generated every night on multiple platforms.
> >
> [snip]
>
> Newsgroup http://news.gmane.org/gmane.comp.lang.c%2B%2B.perfometer contains another testsuites.
> For instance:

> 2. C/C++ Program Perfometer
> C/C++ Program Perfometer download | SourceForge.net
> C/C++ Program Perfometer
>
> Latest version is 2.8.0-1.18. Its description can be ssen at
> http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/39

I downloaded this and took a quick look at it. It looks like an
interesting suite of benchmarks, similar in design to oopack.
Unfortunately, it does not compile with LLVM (or GCC 3.4), as the source
is not compliant with two phase name lookup. I get errors such as:

$ llvmg++ -O3 -I. -DOPT_LEVEL=-1 -W -Wall -c pfmeter.cpp
In file included from pfmeter2.h:50,
                 from pfmeter.cpp:44:
pfmeter.h: In destructor `ClassPerfoMeter<T1, T2,
T3>::~ClassPerfoMeter()':
pfmeter.h:620: error: there are no arguments to
`check_state_resource_values' that depend on a template parameter, so a
declaration of `check_state_resource_values' must be available
pfmeter.h:620: error: (if you use `-fpermissive', G++ will accept your
code, but allowing the use of an undeclared name is deprecated)
pfmeter.h:621: error: there are no arguments to `check_state_clock' that
depend on a template parameter, so a declaration of `check_state_clock'
must be available

and (with -fpermissive):
pfmeter2.h: In member function `void ClassPerfoMeter<T1, T2,
T3>::dtor_action() const':
pfmeter2.h:832: error: `end_resource_value_' undeclared (first use this
function)
...

In any case, our test suite works best with individual programs that do
one thing, then exit (like the fib program), so perfmeter isn't directly
useful. It's a neat suite though, thanks for the pointer!

[snip]

Thanks.

I compiled that with g++ 3.3 some time ago.

I checked that again.
* It is compiled fine with g++ 3.3.
* It isn't compiled with g++ 3.4.

I have such a problem with my other projects.

I should update C/C++ Perfometer to suit it to g++ 3.4.

Thanks again.

"Alex Vinokur" <alexvn@go.to> wrote in message news:ck187g$5au$1@sea.gmane.org...

"Chris Lattner" <sabre@nondot.org> wrote in message news:Pine.LNX.4.44.0410061044190.367-100000@nondot.org...
> > > have less impact than for a CPU bound program). In any case, I've added
> > > this program to the LLVM testsuite as
> > > SingleSource/Benchmarks/Misc-C++/bigfib.cpp, so we should have numbers for
> > > it generated every night on multiple platforms.
> > >
> > [snip]
> >
> > Newsgroup http://news.gmane.org/gmane.comp.lang.c%2B%2B.perfometer contains another testsuites.
> > For instance:
>
> > 2. C/C++ Program Perfometer
> > C/C++ Program Perfometer download | SourceForge.net
> > C/C++ Program Perfometer
> >
> > Latest version is 2.8.0-1.18. Its description can be ssen at
> > http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/39
>
> I downloaded this and took a quick look at it. It looks like an
> interesting suite of benchmarks, similar in design to oopack.
> Unfortunately, it does not compile with LLVM (or GCC 3.4), as the source
> is not compliant with two phase name lookup. I get errors such as:
>
> $ llvmg++ -O3 -I. -DOPT_LEVEL=-1 -W -Wall -c pfmeter.cpp
> In file included from pfmeter2.h:50,
> from pfmeter.cpp:44:
> pfmeter.h: In destructor `ClassPerfoMeter<T1, T2,
> T3>::~ClassPerfoMeter()':
> pfmeter.h:620: error: there are no arguments to
> `check_state_resource_values' that depend on a template parameter, so a
> declaration of `check_state_resource_values' must be available
> pfmeter.h:620: error: (if you use `-fpermissive', G++ will accept your
> code, but allowing the use of an undeclared name is deprecated)
> pfmeter.h:621: error: there are no arguments to `check_state_clock' that
> depend on a template parameter, so a declaration of `check_state_clock'
> must be available
>
> and (with -fpermissive):
> pfmeter2.h: In member function `void ClassPerfoMeter<T1, T2,
> T3>::dtor_action() const':
> pfmeter2.h:832: error: `end_resource_value_' undeclared (first use this
> function)
> ...
>
> In any case, our test suite works best with individual programs that do
> one thing, then exit (like the fib program), so perfmeter isn't directly
> useful. It's a neat suite though, thanks for the pointer!
>
[snip]

Thanks.

I compiled that with g++ 3.3 some time ago.

I checked that again.
* It is compiled fine with g++ 3.3.
* It isn't compiled with g++ 3.4.

I have such a problem with my other projects.

I should update C/C++ Perfometer to suit it to g++ 3.4.

[snip]

C/C++ Perfometer has been updated and compiled with GNU gcc/gpp 3.4.1 (Djgpp).
Latest version is 2.9.0-1.19. It can be downloaded at

"John Criswell" <criswell@cs.uiuc.edu> wrote in message news:4162A940.8090307@cs.uiuc.edu...

Alex Vinokur wrote:
> Hi,
>
> I would like to use LLVM-GCC to compare its performance with other compilers.
> Something like testsuite "Computing very large Fibonacci numbers" at
> http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/37.
>
>
> My environment:
> -----------------
> Windows 2000
> Cygwin
> $ uname -srom
> CYGWIN_NT-5.0 1.5.11(0.116/4/2) i686 Cygwin
> -----------------
>
> What do I have to download from
> Low Level Virtual Machine - Browse Files at SourceForge.net
> * executables(?) cfrontend-1.3.i386-unknown-freebsd5.2.1.tar.gz ?
> * sources cfrontend-1.3.source.tar.gz ?

You will need to download both the LLVM sources (llvm-1.3.tar.gz) and
the LLVM-GCC sources (cfrontend-1.3.source.tar.gz).

The LLVM sources always have to be built (we don't distribute binary
verisons of these). You will have to build the LLVM GCC frontend on
Cygwin since we don't have binaries for these (unless Cygwin supports
FreeBSD emulation, the FreeBSD binaries won't work).

I don't know if LLVM 1.3 will work on Cygwin. If not, you can get the
latest llvm-gcc and llvm sources from our CVS repository; I know there
is at least partial support for Cygwin in the latest sources. Please
see http://llvm.cs.uiuc.edu/docs/GettingStarted.html#checkout for more
information.

>
> 1. Question about executables.
> -------------------------------
> After gunzip
> * cfrontend-1.3.i386-unknown-freebsd5.2.1.tar.gz
> and
> * tar -xf cfrontend-1.3.i386-unknown-freebsd5.2.1.tar
> I see that cfrontend/x86/llvm-gcc/bin contains the following files:
>
> c++
> cpp
> g++
> gcc
> gccbug
> gcov
> i386-unknown-freebsd5.2.1-c++
> i386-unknown-freebsd5.2.1-g++
> i386-unknown-freebsd5.2.1-gcc
> i386-unknown-freebsd5.2.1-gcc-3.4-llvm
>
> Are they executables?
>
> Which of them should I use on Cygwin?

Well, you shouldn't use any of these, as the FreeBSD binaries probably
won't work on Cygwin.

But, once you build the llvm-gcc frontend, you'll get a very similar
directory tree. To compile programs, you'll use the c++, g++, and gcc
binaries listed above. I believe the programs with the
"i386-unknown-freebsd..." prefix are just there in case you've got a
cross compiling environment.

>
>
> 2. Question about sources.
> --------------------------
> http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html#cygwin contains the following instruction:
> Configure and build the LLVM libraries and tools using:
> % cd llvm
> % ./configure [options...]
> % gmake tools-only
>
> 2.1. Which options should I use with ./configure [options...]?

The only option you will probably need is --with-llvmgccdir, which will
tell the LLVM sources where the LLVM GCC files will eventually be
located (they won't be there when you start, because you have to build
LLVM before LLVM-GCC).

The build process is a little inconvenient, but here's the gist of it:

o) Build LLVM tools (i.e. configure llvm and do "make tools-only").
o) Build the LLVM GCC frontend.
o) Go back into the LLVM sources, build the runtime libraries, and
install them.
o) Set the LLVM_LIB_SEARCH_PATH variable so that the LLVM tools can find
the libraries.

Please see our documentation
(http://llvm.cs.uiuc.edu/docs/GettingStarted.html) and
(http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html) for all the details.
  I highly recommend that you follow them as exactly as you can; missing
one detail can mean the difference between a successful build and a very
confusing build that doesn't work.

>
> 2.2. Cygwin doesn't have gmake:
> $ which gmake
> gmake: Command not found.
>
> Could I use make?

On Cygwin, your make program is most likely GNU Make. Type:

make --version

... and if you get something like this:

GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.

... then your "make" program is actually "GNU Make" and will work just fine.

If you run into any more trouble, please let us know. We'll do what we
can to help.

-- John T.

--
*********************************************************************
* John T. Criswell Email: criswell@uiuc.edu *
* Research Programmer *
* University of Illinois at Urbana-Champaign *
* *
* "It's today!" said Piglet. "My favorite day," said Pooh. *
*********************************************************************

I would like to download LLVM 1.4 for Cygwin on Windows 2000.

Here are a fragment from http://llvm.cs.uiuc.edu/releases/register.cgi
  a.. LLVM source code (3.5M)
  b.. LLVM Test Suite (8.0M)
  c.. GCC Front End Binaries for Linux/x86 (6.2M)
  d.. GCC Front End Binaries for Solaris/Sparc (6.6M)
  e.. GCC Front End Binaries for MacOS X/PowerPC (7.0M)
  f.. GCC Front End Source Code (30.0M)
What do I have to dowonload for for Cygwin?

You should download and install in the first shot:

  a.. LLVM source code (3.5M)
  f.. GCC Front End Source Code (30.0M)

Then follow the items listed in http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html for Cygwin.

Henrik.

Alex Vinokur wrote:

"John Criswell" <criswell@cs.uiuc.edu> wrote in message news:4162A940.8090307@cs.uiuc.edu...

Alex Vinokur wrote:
   

Hi,

I would like to use LLVM-GCC to compare its performance with other compilers.
Something like testsuite "Computing very large Fibonacci numbers" at
http://article.gmane.org/gmane.comp.lang.c%2B%2B.perfometer/37.

My environment:
-----------------
Windows 2000
Cygwin
$ uname -srom
CYGWIN_NT-5.0 1.5.11(0.116/4/2) i686 Cygwin
-----------------

What do I have to download from
Low Level Virtual Machine - Browse Files at SourceForge.net
* executables(?) cfrontend-1.3.i386-unknown-freebsd5.2.1.tar.gz ?
* sources cfrontend-1.3.source.tar.gz ?
     

You will need to download both the LLVM sources (llvm-1.3.tar.gz) and
the LLVM-GCC sources (cfrontend-1.3.source.tar.gz).

The LLVM sources always have to be built (we don't distribute binary
verisons of these). You will have to build the LLVM GCC frontend on
Cygwin since we don't have binaries for these (unless Cygwin supports
FreeBSD emulation, the FreeBSD binaries won't work).

I don't know if LLVM 1.3 will work on Cygwin. If not, you can get the
latest llvm-gcc and llvm sources from our CVS repository; I know there
is at least partial support for Cygwin in the latest sources. Please
see http://llvm.cs.uiuc.edu/docs/GettingStarted.html#checkout for more
information.

1. Question about executables.
-------------------------------
After gunzip
* cfrontend-1.3.i386-unknown-freebsd5.2.1.tar.gz
and
* tar -xf cfrontend-1.3.i386-unknown-freebsd5.2.1.tar
I see that cfrontend/x86/llvm-gcc/bin contains the following files:

c++
cpp
g++
gcc
gccbug
gcov
i386-unknown-freebsd5.2.1-c++
i386-unknown-freebsd5.2.1-g++
i386-unknown-freebsd5.2.1-gcc
i386-unknown-freebsd5.2.1-gcc-3.4-llvm

Are they executables?

Which of them should I use on Cygwin?
     

Well, you shouldn't use any of these, as the FreeBSD binaries probably
won't work on Cygwin.

But, once you build the llvm-gcc frontend, you'll get a very similar
directory tree. To compile programs, you'll use the c++, g++, and gcc
binaries listed above. I believe the programs with the
"i386-unknown-freebsd..." prefix are just there in case you've got a
cross compiling environment.

2. Question about sources.
--------------------------
http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html#cygwin contains the following instruction:
Configure and build the LLVM libraries and tools using:
% cd llvm
% ./configure [options...]
% gmake tools-only

2.1. Which options should I use with ./configure [options...]?
     

The only option you will probably need is --with-llvmgccdir, which will
tell the LLVM sources where the LLVM GCC files will eventually be
located (they won't be there when you start, because you have to build
LLVM before LLVM-GCC).

The build process is a little inconvenient, but here's the gist of it:

o) Build LLVM tools (i.e. configure llvm and do "make tools-only").
o) Build the LLVM GCC frontend.
o) Go back into the LLVM sources, build the runtime libraries, and
install them.
o) Set the LLVM_LIB_SEARCH_PATH variable so that the LLVM tools can find
the libraries.

Please see our documentation
(http://llvm.cs.uiuc.edu/docs/GettingStarted.html) and
(http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html) for all the details.
I highly recommend that you follow them as exactly as you can; missing
one detail can mean the difference between a successful build and a very
confusing build that doesn't work.

2.2. Cygwin doesn't have gmake:
$ which gmake
gmake: Command not found.

Could I use make?
     

On Cygwin, your make program is most likely GNU Make. Type:

make --version

... and if you get something like this:

GNU Make version 3.79.1, by Richard Stallman and Roland McGrath.

... then your "make" program is actually "GNU Make" and will work just fine.

If you run into any more trouble, please let us know. We'll do what we
can to help.

-- John T.

--
*********************************************************************
* John T. Criswell Email: criswell@uiuc.edu *
* Research Programmer *
* University of Illinois at Urbana-Champaign *
* *
* "It's today!" said Piglet. "My favorite day," said Pooh. *
*********************************************************************
   
I would like to download LLVM 1.4 for Cygwin on Windows 2000.

Here are a fragment from http://llvm.cs.uiuc.edu/releases/register.cgi
a.. LLVM source code (3.5M)
b.. LLVM Test Suite (8.0M)
c.. GCC Front End Binaries for Linux/x86 (6.2M)
d.. GCC Front End Binaries for Solaris/Sparc (6.6M)
e.. GCC Front End Binaries for MacOS X/PowerPC (7.0M)
f.. GCC Front End Source Code (30.0M)
What do I have to dowonload for for Cygwin?

You will need to download the LLVM source code (letter a) and the GCC Front End Source Code (letter f). You will need to build both of them.

If you have any problems compiling these, please let us know. I didn't test Cygwin support with the 1.4 release as I don't have a Cygwin installation at UIUC at present.

-- John T.

Henrik Bach wrote:

You should download and install in the first shot:

  a.. LLVM source code (3.5M)
  f.. GCC Front End Source Code (30.0M)

Then follow the items listed in
http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html for Cygwin.

[snip]

<QUOTE from http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html#cygwin&gt;
It has been found that the GCC 3.3.3 compiler provided with recent
Cygwin versions is incapable of compiling the LLVM CFE correctly. If
your Cygwin installation includes GCC 3.3.3 we strongly recommend that
you download GCC 3.4.3, build it separately, and use it for compiling
LLVM CFE. This has been shown to work correctly.
</QUOTE>

However currently latest gcc version in Cygwin is 3.3.3.

So, it seems that currently it is impossible to build LLVM and the GCC
front-end under Cygwin (?).

  Alex Vinokur
     email: alex DOT vinokur AT gmail DOT com
     http://mathforum.org/library/view/10978.html
     alexvn / Profile

Alex Vinokur wrote:

Henrik Bach wrote:

You should download and install in the first shot:

a.. LLVM source code (3.5M)
f.. GCC Front End Source Code (30.0M)

Then follow the items listed in
http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html for Cygwin.

[snip]

<QUOTE from http://llvm.cs.uiuc.edu/docs/CFEBuildInstrs.html#cygwin&gt;
It has been found that the GCC 3.3.3 compiler provided with recent
Cygwin versions is incapable of compiling the LLVM CFE correctly. If
your Cygwin installation includes GCC 3.3.3 we strongly recommend that
you download GCC 3.4.3, build it separately, and use it for compiling
LLVM CFE. This has been shown to work correctly.
</QUOTE>

However currently latest gcc version in Cygwin is 3.3.3.

So, it seems that currently it is impossible to build LLVM and the GCC
front-end under Cygwin (?).

According to what you've quoted above, you *can* build LLVM and the LLVM GCC frontend under Cygwin. The only difficulty is that you will have to build GCC 3.4.3 on Cygwin first.

So, what you'll do is download the source code for GCC 3.4.3 from the GCC website (http://gcc.gnu.org), compile it with GCC 3.3.3 that came with Cygwin, and then use your newly built GCC 3.4.3 compiler to build LLVM and the LLVM GCC frontend.

-- John T.

I have recently completed a build on Cygwin and am now hosting the
Cygwin nightly tester. Here's some things you should know:

1. LLVM 1.4 release won't build on Cygwin so you'll have to use the
    latest CVS sources.
2. Even if you build it on Cygwin, it probably won't work unless you
    use the C Backend. See the test results here:
    http://llvm.x10sys.com/testresults/Cygwin
3. Building on Cygwin will require you to build and install GNU
    binutils 2.15 as the version that comes with Cygwin these days will
    assert fail on building the CFE.
4. As previously noted, you will also need GCC 3.4.3 to be built and
    installed.

My recommendation would be to either wait a week or two until we get
Cygwin issues figured out or use another platform (Linux, FreeBSD,
SPARC/Solaris, Darwin/PPC). Cygwin is not exactly the most performant
system for doing benchmarks as the Cygwin "layer" over Win32 is fairly
involved.

Reid.

Reid Spencer wrote:

I have recently completed a build on Cygwin and am now hosting the
Cygwin nightly tester. Here's some things you should know:

1. LLVM 1.4 release won't build on Cygwin so you'll have to use the
    latest CVS sources.
2. Even if you build it on Cygwin, it probably won't work unless you
    use the C Backend. See the test results here:
    http://llvm.x10sys.com/testresults/Cygwin
3. Building on Cygwin will require you to build and install GNU
    binutils 2.15 as the version that comes with Cygwin these days will
    assert fail on building the CFE.
4. As previously noted, you will also need GCC 3.4.3 to be built and
    installed.

My recommendation would be to either wait a week or two until we get
Cygwin issues figured out or use another platform (Linux, FreeBSD,
SPARC/Solaris, Darwin/PPC). Cygwin is not exactly the most performant
system for doing benchmarks as the Cygwin "layer" over Win32 is fairly
involved.

[snip]

Thank you for that information. I will wait until you get Cygwin issues
figured out.
How can I know of that?

  Alex Vinokur
     email: alex DOT vinokur AT gmail DOT com
     http://mathforum.org/library/view/10978.html
     alexvn / Profile

Check out the link to the Cygwin nightly tester results here:

  http://llvm.cs.uiuc.edu/testresults/

Wait until most of the asterisks in the test results go away. :slight_smile:
The tester runs nightly, so checking every few days shouldn't hurt.

Misha Brukman wrote:

> Thank you for that information. I will wait until you get Cygwin
> issues figured out. How can I know of that?

Check out the link to the Cygwin nightly tester results here:

  http://llvm.cs.uiuc.edu/testresults/

Wait until most of the asterisks in the test results go away. :slight_smile:
The tester runs nightly, so checking every few days shouldn't hurt.

[snip]

Thanks.

But it seems that there are no asterisks at
* http://llvm.cs.uiuc.edu/testresults/
* http://llvm.x10sys.com/testresults/Cygwin/

By the way, is it possible to send a relevant announce to
* gmane.comp.compilers.llvm.announce
* gmane.comp.compilers.llvm.devel

   Alex Vinokur
     email: alex DOT vinokur AT gmail DOT com
     http://mathforum.org/library/view/10978.html
     alexvn / Profile

But it seems that there are no asterisks at
* http://llvm.cs.uiuc.edu/testresults/
* http://llvm.x10sys.com/testresults/Cygwin/

That's because there was a build error (see the big red notice).
Check out http://llvm.x10sys.com/testresults/Cygwin/2004-12-27.html

By the way, is it possible to send a relevant announce to
* gmane.comp.compilers.llvm.announce

That's the announcement list for higher-level things like releases and
status reports, so it's not the right forum.

* gmane.comp.compilers.llvm.devel

This would be the right one, so maybe if we ask Reid nicely, he'll do it
(as he maintains the Cygwin nightly tester).

BTW, gmane.* are just copies of LLVM mailing list archives, so if you're
signed up for llvm-dev, you don't need gmane.comp.compilers.llvm.devel .

I haven't used Net News since its signal-to-noise ratio dropped below my
tolerance level (circa 1995). However, if you'd like to tell me how to
make the post, I'd be happy to.

Reid, you are already posting to gmane! :wink:

Seriously, someone signed up the gmane newsbot on llvmdev, so now gmane
mirrors LLVM mailing lists, see for example:

http://news.gmane.org/gmane.comp.compilers.llvm.devel

All along I thought it was you who signed up gmane to llvm-dev, but now
I'm wondering as to who it was, not that I mind, really.