psblas: util: made METIS optional, chosen via a preprocessor directive.

psblas3-type-indexed
Salvatore Filippone 17 years ago
parent 2922fcba6e
commit c21252c51b

@ -45,15 +45,17 @@ BLACS=-lmpiblacsg95 -L$(HOME)/LIB
# Other useful tools&defines # # Other useful tools&defines #
########################################################## ##########################################################
# #
# We are using the public domain tool METIS from U. Minnesota. To get it # The examples can make use of METIS from U. Minnesota.
# check URL http://www.cs.umn.edu:~karypis # http://www.cs.umn.edu:~karypis
# but it's optional
# #
METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis #METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis
PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB) PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB)
# Add -DLargeFptr for 64-bit addresses # Add -DLargeFptr for 64-bit addresses
PSBCDEFINES=-DAdd_ PSBCDEFINES=-DAdd_
PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) -DHAVE_MOVE_ALLOC PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) -DHAVE_MOVE_ALLOC
# -DHAVE_METIS
AR=ar -cur AR=ar -cur
RANLIB=ranlib RANLIB=ranlib

@ -49,16 +49,17 @@ BLACS=-lmpiblacs-gcc42 -L$(HOME)/LIB
# Other useful tools&defines # # Other useful tools&defines #
########################################################## ##########################################################
# #
# We are using the public domain tool METIS from U. Minnesota. To get it # The examples can make use of METIS from U. Minnesota.
# check URL http://www.cs.umn.edu:~karypis # http://www.cs.umn.edu:~karypis
# but it's optional
# #
METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis #METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis
PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB) PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB)
# Add -DLargeFptr for 64-bit addresses # Add -DLargeFptr for 64-bit addresses
PSBCDEFINES=-DAdd_ PSBCDEFINES=-DAdd_
PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) -DHAVE_MOVE_ALLOC PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) -DHAVE_MOVE_ALLOC
# -DHAVE_METIS
AR=ar -cur AR=ar -cur
RANLIB=ranlib RANLIB=ranlib

@ -48,15 +48,17 @@ EXTRA_COBJS=fakempi.o
# Other useful tools&defines # # Other useful tools&defines #
########################################################## ##########################################################
# #
# We are using the public domain tool METIS from U. Minnesota. To get it # The examples can make use of METIS from U. Minnesota.
# check URL http://www.cs.umn.edu:~karypis # http://www.cs.umn.edu:~karypis
# but it's optional
# #
METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis #METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis
PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB) PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB)
# Add -DLargeFptr for 64-bit addresses # Add -DLargeFptr for 64-bit addresses
PSBCDEFINES=-DAdd_ PSBCDEFINES=-DAdd_
PSBFDEFINES=-DHAVE_MOVE_ALLOC -DSERIAL_MPI $(MPI_FINC) PSBFDEFINES=-DHAVE_MOVE_ALLOC -DSERIAL_MPI $(MPI_FINC)
# -DHAVE_METIS
AR=ar -cur AR=ar -cur
RANLIB=ranlib RANLIB=ranlib

@ -49,15 +49,17 @@ BLACS=-lmpiblacs-gcc42 -L$(HOME)/LIB
# Other useful tools&defines # # Other useful tools&defines #
########################################################## ##########################################################
# #
# We are using the public domain tool METIS from U. Minnesota. To get it # The examples can make use of METIS from U. Minnesota.
# check URL http://www.cs.umn.edu:~karypis # http://www.cs.umn.edu:~karypis
# but it's optional
# #
METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis #METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis
PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB) PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB)
# Add -DLargeFptr for 64-bit addresses # Add -DLargeFptr for 64-bit addresses
PSBCDEFINES=-DAdd_ PSBCDEFINES=-DAdd_
PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) -DHAVE_MOVE_ALLOC PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) -DHAVE_MOVE_ALLOC
# -DHAVE_METIS
AR=ar -cur AR=ar -cur
RANLIB=ranlib RANLIB=ranlib

@ -50,17 +50,18 @@ BLACS=-lmpiblacs-ifort91 -L$(HOME)/LIB
# Other useful tools&defines # # Other useful tools&defines #
########################################################## ##########################################################
# #
# We are using the public domain tool METIS from U. Minnesota. To get it # The examples can make use of METIS from U. Minnesota.
# check URL http://www.cs.umn.edu:~karypis # http://www.cs.umn.edu:~karypis
# but it's optional
# #
METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis #METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis
PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB) PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB)
# Add -DLargeFptr for 64-bit addresses # Add -DLargeFptr for 64-bit addresses
# Note: MOVE_ALLOC is only on Intel Fortran 9.1, NOT on 9.0 # Note: MOVE_ALLOC is only on Intel Fortran 9.1, NOT on 9.0
PSBCDEFINES=-DAdd_ PSBCDEFINES=-DAdd_
PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) -DHAVE_MOVE_ALLOC PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) -DHAVE_MOVE_ALLOC
# -DHAVE_METIS
AR=ar -cur AR=ar -cur
RANLIB=ranlib RANLIB=ranlib

@ -47,17 +47,18 @@ BLACS=-lblacssmp
# Other useful tools&defines # # Other useful tools&defines #
########################################################## ##########################################################
# #
# We are using the public domain tool METIS from U. Minnesota. To get it # The examples can make use of METIS from U. Minnesota.
# check URL http://www.cs.umn.edu:~karypis # http://www.cs.umn.edu:~karypis
# but it's optional
# #
METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis #METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis
PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB) PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB)
# Add -DLargeFptr for 64-bit addresses # Add -DLargeFptr for 64-bit addresses
PSBCDEFINES=-DNoChange -DLargeFptr PSBCDEFINES=-DNoChange -DLargeFptr
PSBFDEFINES=-WF,-DESSL_BLACS $(MPI_FINC) PSBFDEFINES=-WF,-DESSL_BLACS $(MPI_FINC)
# There's no MOVE_ALLOC yet in XLF 10.1. # There's no MOVE_ALLOC yet in XLF 10.1.
#-WF,-DHAVE_MOVE_ALLOC #-WF,-DHAVE_MOVE_ALLOC -WF,-DHAVE_METIS
AR=ar -cur AR=ar -cur

@ -47,10 +47,11 @@ BLACS=$(HOME)/LIB/libblacs_MPI-SUN4SOL2-0.a $(HOME)/LIB/libblacsCinit_MPI-SUN4SO
# Other useful tools&defines # # Other useful tools&defines #
########################################################## ##########################################################
# #
# We are using the public domain tool METIS from U. Minnesota. To get it # The examples can make use of METIS from U. Minnesota.
# check URL http://www.cs.umn.edu:~karypis # http://www.cs.umn.edu:~karypis
# but it's optional
# #
METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis #METIS_LIB = -L$(HOME)/NUMERICAL/metis-4.0 -lmetis
PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB) PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB)
# Add -DLargeFptr for 64-bit addresses # Add -DLargeFptr for 64-bit addresses
@ -58,6 +59,7 @@ PSBLDLIBS=$(BLACS) $(BLAS) $(METIS_LIB)
# -DHAVE_MOVE_ALLOC # -DHAVE_MOVE_ALLOC
PSBCDEFINES=-DAdd_ PSBCDEFINES=-DAdd_
PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC) PSBFDEFINES=-DNETLIB_BLACS $(MPI_FINC)
# -DHAVE_METIS
AR=ar -cur AR=ar -cur
RANLIB=ranlib RANLIB=ranlib

@ -1,4 +1,4 @@
This directory contains the PSBLAS library, version 2.1.1 This directory contains the PSBLAS library, version 2.2
Version 1.0 of the library was described in: Version 1.0 of the library was described in:
@ -78,8 +78,8 @@ prerequisites (see also SERIAL below):
4. We have had good results with the METIS library, from 4. We have had good results with the METIS library, from
http://www-users.cs.umn.edu/~karypis/metis/metis/main.html http://www-users.cs.umn.edu/~karypis/metis/metis/main.html
This is not necessary to compile our library, but the test program This is optional: it is used in the util and test/fileread
in test/Fileread assumes you have it installed. directories if you define the HAVE_METIS directive.
To install, choose a Make.inc.XXX file in directory Make that fits To install, choose a Make.inc.XXX file in directory Make that fits
your compilers, modify the paths to libraries to match your your compilers, modify the paths to libraries to match your

@ -139,6 +139,8 @@ contains
integer, parameter :: nb=512 integer, parameter :: nb=512
real(kind(1.d0)), parameter :: seed=12345.d0 real(kind(1.d0)), parameter :: seed=12345.d0
integer :: iopt(10),idummy(2),jdummy(2) integer :: iopt(10),idummy(2),jdummy(2)
#if defined(HAVE_METIS)
interface interface
subroutine METIS_PartGraphRecursive(n,ixadj,iadj,ivwg,iajw,& subroutine METIS_PartGraphRecursive(n,ixadj,iadj,ivwg,iajw,&
& wgflag,numflag,nparts,iopt,nedc,part) & wgflag,numflag,nparts,iopt,nedc,part)
@ -176,6 +178,9 @@ contains
graph_vect(i) = 0 graph_vect(i) = 0
enddo enddo
endif endif
#else
write(0,*) 'Warning: METIS was not configured at PSBLAS compile time !'
#endif
return return
Loading…
Cancel
Save