[gmx-users] compiling gromacs on powerpc64

Martin Siegert siegert at sfu.ca
Thu Aug 4 00:48:10 CEST 2005


Hi Nathan,

On Wed, Aug 03, 2005 at 06:30:47AM -0500, Nathan Moore wrote:
> Martin,
> 
> I've been able to compile Gromacs on PowerPC64 systems in the past with
> normal functionality, but I'm wary of the -O5 flag you included.  Have you
> tried installing a vanilla version?  Here's the configure script I used a
> few months ago which worked,
> 
> ./configure \
>         --prefix="/bglhome/usr2/ntmoore/GROMACS/bin/bglfen3.double" \
>         --disable-float \
>         F77='f77' \
>         CC='xlc' \
>         CXX='xlC' \
>         CFLAGS="-g -O2
> -I/bglhome/usr2/ntmoore/lib/fftw-double-bglfen3/include/" \
>         CPPFALGS="-I/bglhome/usr2/ntmoore/lib/fftw-double-bglfen3/include/"\
>         LIBS="-L/bglhome/usr2/ntmoore/lib/fftw-double-bglfen3/lib/"\
>         LDFLAGS="-lfftw -lrfftw"\
>         --disable-fftw \
>         --without-xml \
>         --without-x
> 
Thanks, this is good to know. I do require the -q64 flag though.
But I'll test the -g -O2 flags first and if that works I go from
there.

By now I know that this is no problem with byte swapping: I can compile
gromacs in 64 bit mode on AIX 5.3 on Power4 and the generated topol.tpr
file works with mdrun on PowerPC64. I also looked at the topol.tpr
files with a binary editor (bvi). Here are the first "lines":

correct:

00000000  00 00 00 0E 00 00 00 0D 56 45 52 53 49 4F 4E 20 ........VERSION
00000010  33 2E 32 2E 31 00 00 00 00 00 00 04 00 00 00 1F 3.2.1...........
00000020  00 00 00 04 00 01 DC 00 00 00 00 02 00 00 00 00 ................

powerpc64:

00000000  00 00 00 00 00 00 00 00 56 45 52 53 49 4F 4E 20 ........VERSION
00000010  33 2E 32 2E 31 00 00 00 00 00 00 00 00 00 00 00 3.2.1...........
00000020  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................

Thus the files differ already in the bytes before the "VERSION 3.2.1"
string. Can somebody tell me what is supposed to be stored in those
bytes (00 00 00 0E 00 00 00 0D)? Or which routine writes these data?

Thanks again,
Martin

> > On Sun, Jul 31, 2005 at 09:29:21PM +0200, David wrote:
> >> On Sun, 2005-07-31 at 11:59 -0700, Martin Siegert wrote:
> >> > Hi,
> >> >
> >> > On Sat, Jul 30, 2005 at 03:55:20PM -0700, Martin Siegert wrote:
> >> >
> >> > > I then try to run the d.dppc test case:
> >> > > grompp -c conf.gro -f grompp.mdp -p topol.top
> >> > > mdrun -s topol.tpr -nice 0
> >> > >
> >> > > The grompp command completes fine, but the mdrun command fails with
> >> > >
> >> > > Fatal error: Can not read file topol.tpr,
> >> > >              this file is from a Gromacs version which is older than
> >> 2.0
> >> > >              Make a new one with grompp or use a gro or pdb file, if
> >> possible
> >> > >
> >> > > Thus, mdrun cannot read the topol.tpr file although both are
> >> definitely
> >> > > compiled from the same gromacs-3.2.1 source tree.
> >> > >
> >> > > It gets really strange when I ran the grompp command on a different
> >> platform,
> >> > > Linux 64-bit Opteron, copied the so-generated topol.tpr file over to
> >> the
> >> > > PPC machine and ran mdrun using that topol.tpr file. That works!
> >> > >
> >> > > But that really shouldn't work, should it? X86_64 is little endian
> >> and
> >> > > PowerPC is big endian. Thus, is there an endian issue that configure
> >> > > is not resolving correctly on the PPC platform or what is going
> >> wrong here?
> >> >
> >> > By now I succeeded compiling gromacs-3.2.1 using the --disable-shared
> >> > configure option. This avoids all the libtool problems and compiles
> >> > cleanly. It nevertheless generates a grompp that produces topol.tpr
> >> > files that cannot be read by mdrun which lets me conclude that this
> >> > problem has nothing to do with the libtool problems reported in my
> >> > previous email. Thus:
> >> >
> >> > How do I compile grompp on powerpc64?
> >> Maybe there is a problem with the xdr libraries, used for the platform-
> >> independent file formats that gromacs uses (edr, tpr, trr). Check which
> >> libraries gromacs uses for these.
> >>
> >> Have you tried moving a powerpw64 tpr file to another machine and
> >> reading it there (using e.g. gmxdump)?
> >
> > I tried that on the X86_64 platform and it give the same error message.
> > I spent the day getting gromacs to compile with libxml2 (libtool screws
> > that up as well) but even with libxml2 support the result remains the
> > same.
> >
> > You are probably right when suggesting that something goes wrong
> > with the compilation of those gromacs libraries. But if those file
> > formats are supposed to be platform indenpendent then there ought to
> > be some code that makes a decision to compile these libraries
> > differently on big endian and little endian machines. Does anybody
> > know where that code is and where the code is that detects whether
> > a platform is little endian or big endian?
> >
> > Cheers,
> > Martin
> > _______________________________________________
> > gmx-users mailing list
> > gmx-users at gromacs.org
> > http://www.gromacs.org/mailman/listinfo/gmx-users
> > Please don't post (un)subscribe requests to the list. Use the
> > www interface or send it to gmx-users-request at gromacs.org.



More information about the gromacs.org_gmx-users mailing list