[Beowulf] Java vs C++ for interfacing to parallel library

Joe Landman landman at scalableinformatics.com
Mon Aug 21 17:46:29 PDT 2006



Robert G. Brown wrote:

>> Obviously this is a trivial example, but if you create a reasonable set
>> of API's that you can express as we have indicated, even pass function
>> prototypes in using a header file, and a little config stuff at the
>> front end to give paths to libraries, this is not generally very hard.
> 
> I'm a bit skeptical about this for heavy lifting.  As in, could you
> encapsulate the GSL in this way?  I doubt it.

As do I now.

After spending a little time playing with it, I discovered that it is
very good at wrapping trivial things trivially.

I took a simple GSL program I used to introduce students to GSL, that
was a modified example from one of the GSL example files.  Basically a
little Hooke's law bit to use as input to an LU solver.  Really short
GSL program.

What I discovered is that it doesn't take much to make this not work.
:(  Specifically passing arrays and vectors back and forth between
C/Perl is hard (IMO).

Since I don't do this on a regular basis, this isn't so bad.  Also there
is this PDL thing
(http://search.cpan.org/~csoe/PDL-2.4.3/Basic/Pod/Impatient.pod) which
doesn't look so bad, but it still doesn't solve the issues I want solved.

>> Only when you have some ... odd ... structures or objects passing back
>> and forth which require a bit more work.
> 
> What's an odd structure? 

As I have discovered ... odd structures are arrays ... and anything more
complex :(

[...]

>> Python has similar facilities.  Generally speaking the dynamic
>> languanges (Perl, Python, Ruby) are pretty easy to wrap around things
>> and link with other stuff, as long as the API/data structures are pretty
>> clean.
> 
> Ay, that's the rub...;-) That and what you consider "pretty easy"...:-)

Less time than I spent on this so far !



-- 
Joseph Landman, Ph.D
Founder and CEO
Scalable Informatics LLC,
email: landman at scalableinformatics.com
web  : http://www.scalableinformatics.com
phone: +1 734 786 8423
fax  : +1 734 786 8452 or +1 866 888 3112
cell : +1 734 612 4615



More information about the Beowulf mailing list