Re: [DebianGIS] grass and 64bit
On Thu, Mar 16, 2006 at 12:43:08PM +0100, Francesco P. Lovergine wrote:
> On Thu, Mar 16, 2006 at 11:54:05AM +0100, Markus Neteler wrote:
> > On Thu, Mar 16, 2006 at 11:41:34AM +0100, Francesco P. Lovergine wrote:
> > > Now that amd64 arch just entered the great main world, I wonder if
> > > it would be useful/needed(?) in grass enabling the '64bit support'
> > > whose use is not so clear to me...
> > >
> > >
> > > (C) COMPILATION NOTES for 64bit platforms
> > >
> > > To successfully compile GRASS on 64bit platforms, the required
> > > FFTW2 library has to be compiled with -fPIC flag:
> > >
> > > #applies to FFTW2, not GRASS:
> > > cd fftw-2.1.5/
> > > CFLAGS="-fPIC" ./configure
> > > make
> > > make install
> > >
> > > To fully enable 64bit library usage for GRASS on 64bit platforms,
> > > the following additional parameters are recommended/required:
> > >
> > > ./configure \
> > > --enable-64bit \
> > > --with-libs=/usr/lib64 \
> > > ...
> > >
> >
> > Francesco,
> >
> > I am using it for some months now (wrote above notes),
> > but right, I don't know if I gain anything :-)
> >
> > Maybe it affects the data storage internally. Since
> > the GRASS 6 data formats are portable across 32bit/64bit,
> > I don't know any effective difference. but I am no
> > expert.
> >
>
> Most details are hidden in the libc. On AMD64 at least /usr/lib64 and
> /usr/lib are the same directory. It has been introduced to differentiate
> /usr/lib32 which contain the 32bit edition for that multi-arch platform.
>
> > Maybe someone could test the performance by creating
> > fractal DEMs with r.surf.fractal and generate
> > vector topology of the GSHHS dataset?
> >
>
> Well, AFAIK it is a non-sense. We already build on pure 64bit platforms
> (alpha, ia64, sparc) without additional flags. The only true difference
> for multi-arch amd64 is obtaining binary-compatibility without rebuilding,
> but that's interesting only for 32bit native programs, not for 64bit
> native ones, like grass and any other software in main for those
> platforms.
>
> If --enable-64 would select specific per-arch compiler flags, that would
> be another question...
I am enforcing this manually (my GRASS development flags):
# XEON 64
XEON="-mcpu=nocona -mtune=nocona -m64 -minline-all-stringops"
# some flags to catch all possible problems:
MYCFLAGS="-g -Wall -Werror-implicit-function-declaration -fno-common $XEON"
MYCXXFLAGS="-g -Wall"
CFLAGS="$MYCFLAGS" CXXFLAGS="$MYCXXFLAGS" ./configure \
--enable-64bit \
--with-libs=/usr/lib64 \
...
# Pentium 64
PENTIUM64="-mtune=nocona -m64 -minline-all-stringops"
# some flags to catch all possible problems:
MYCFLAGS="-g -Werror-implicit-function-declaration -fno-common $PENTIUM64"
MYCXXFLAGS="-g -Wall"
# RHEL 4/64bit:
CFLAGS="$MYCFLAGS" CXXFLAGS="$MYCXXFLAGS" ./configure \
--enable-64bit \
--with-libs=/usr/lib64 \
...
Someone knowledgable may improve the --enable-64bit switch...
Markus
Reply to: