[R-sig-hpc] Rmpi on NetBSD with OpenMPI

Kevin.Buckley at ecs.vuw.ac.nz Kevin.Buckley at ecs.vuw.ac.nz
Tue May 18 23:56:12 CEST 2010


Aleksej writes

> Ideally, R should allow installation of software into place outside
> its PREFIX, this is good anyway, since user may have no permissions
> to access anything within PREFIX.

R does.

I am not an R user but I have been involved in the development and
deployment of packages for users of R and I am aware you can put
the libraries where you want at package install time by using
--library and then adding a "lib.loc=" when you load the package.

For example I've been using:

R CMD INSTALL --library=/vol/grid/pkg/R/Rlibs Rmpi \
  --configure-args=--with-Rmpi-type=OPENMPI \
  --configure-args=--with-Rmpi-libpath=/usr/pkg/lib/openmpi \
  --configure-args=--with-Rmpi-include=/usr/pkg/include

to get the Rmpi installed library where I want it, within the confines
of the SGE grid, I am working with and then I add a

lib.loc="/vol/grid/pkg/R/Rlibs"

clause to the library(Rmpi) loading in the Rprofile that gets sourced
to actually load it and set it up.

But I am not sure that's the issue here.

What we are talking about here is overcoming the vaguries of
cross-platform shared-library symbol visibility, when shared
libraries are chain-loaded, by explicitly pre-loading a library
(libmpi.so) that you will need anayway, whether the platform
needs it loaded explicitly or not.

My contention, for maintainer of Rmpi, is that if you did explicitly
load it so as to facilitate platforms that have a "local scope"
for symbol visibility, you would not break anything for the platforms
with global scope BUT you would give platforms that might need to play
around with the code a place at which to do so.

As things stand, because Rmpi assumes that there a global scoping
in operation, and that libmpi.so will be loaded with any issues,
there is no obvious patch for systems, like NetBD, where that is
not true.

If Rmpi's installtion process explicitly looked for libmpi.so
and provided the R code to explicitly load it, then any platform
which needed to could provide a patch.

Because the loading of libmpi.so is currently implicit, as in, left
to the chaining by anothe OpenMPI library,there is no clear way to
proceed, for folks working in NetBSD-land.

As with many of these cross platform issues, it comes down to "making
things explicit".

That's my understanding of it anyway: you'll appreciate this has
pretty much crept up on me over the last month or so,
Kevin

-- 
Kevin M. Buckley                                  Room:  CO327
School of Engineering and                         Phone: +64 4 463 5971
 Computer Science
Victoria University of Wellington
New Zealand



More information about the R-sig-hpc mailing list