[Trilinos-Users] Compilation of Trilinos 10 on BlueGene/P
Radu Popescu
i.radu.popescu at gmail.com
Fri Oct 29 06:06:12 MDT 2010
Hello,
I have successfully compiled Trilinos-10.6 on a BlueGene/P machine
using the IBM XL compilers. The following are the necessary steps, in
case anyone else also needs to do it:
1. Have the following set of simlinks, at the front of your PATH variable:
f77 -> /bgsys/drivers/ppcfloor/comm/bin/mpixlf77_r
mpicc -> /bgsys/drivers/ppcfloor/comm/bin/mpixlc_r
mpicxx -> /bgsys/drivers/ppcfloor/comm/bin/mpixlcxx_r
mpif77 -> /bgsys/drivers/ppcfloor/comm/bin/mpixlf77_r
This ensures that cmake automatically picks up the correct XL
compilers for the compute nodes.
2. Apply patches (attached to e-mail) to the files:
packages/epetra/src/Epetra_ConfigDefs.h
packages/tpetra/inout/Tpetra_MatrixIO.cpp
These patches were supplied by John Cary.
3. The rest should go without hitch. I've also attached my cmake
configure script. I haven't enabled all packages in Trilinos, so if
you are trying to compile any other packages, your mileage may vary.
Regards,
Radu Popescu
-------------- next part --------------
--- a/packages/epetra/src/Epetra_ConfigDefs.h 2010-09-30 00:37:34.000000000 +0200
+++ b/packages/epetra/src/Epetra_ConfigDefs.h 2010-10-27 16:46:18.638792356 +0200
@@ -138,7 +138,7 @@
using std::fabs;
using std::atoi;
using std::atof;
-using std::abs;
+/*using std::abs;*/
using std::pow;
using std::sqrt;
using std::asin;
-------------- next part --------------
--- a/packages/tpetra/inout/Tpetra_MatrixIO.cpp 2010-09-30 00:38:32.000000000 +0200
+++ b/packages/tpetra/inout/Tpetra_MatrixIO.cpp 2010-10-27 16:51:11.199553627 +0200
@@ -210,15 +210,15 @@
char *linePtr = lineBuf;
for (int ind=0; ind < indsPerLine; ++ind) {
if (indicesRead == numNZ) break;
- int ind;
+ int iind;
// terminate the string at the end of the current ind block, saving the character in that location
std::swap(NullSub,linePtr[indWidth]);
// read the ind
- std::sscanf(linePtr, "%d", &ind);
+ std::sscanf(linePtr, "%d", &iind);
// put the saved character back, and put the '\0' back into NullSub for use again
std::swap(NullSub,linePtr[indWidth]);
linePtr += indWidth;
- rowInds[indicesRead++] = ind;
+ rowInds[indicesRead++] = iind;
}
}
TEST_FOR_EXCEPT(indicesRead != numNZ);
@@ -245,15 +245,15 @@
char *linePtr = lineBuf;
for (int val=0; val < valsPerLine; ++val) {
if (valsRead == totalNumVals) break;
- double val;
+ double dval;
// terminate the string at the end of the current val block, saving the character in that location
std::swap(NullSub,linePtr[valWidth]);
// read the val
- std::sscanf(linePtr, "%le", &val);
+ std::sscanf(linePtr, "%le", &dval);
// put the saved character back, and put the '\0' back into NullSub for use again
std::swap(NullSub,linePtr[valWidth]);
linePtr += valWidth;
- vals[valsRead++] = val;
+ vals[valsRead++] = dval;
}
}
TEST_FOR_EXCEPT(valsRead != totalNumVals);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: configure-t10-opt
Type: application/octet-stream
Size: 3375 bytes
Desc: not available
Url : https://software.sandia.gov/pipermail/trilinos-users/attachments/20101029/5a884241/attachment-0001.obj
More information about the Trilinos-Users
mailing list