[Gsll-devel] practical differences between native CL array and the GSLL marray type?

Liam Healy lhealy at common-lisp.net
Thu Apr 16 04:00:01 UTC 2009


I have added a method for lisp-unit:numerical-equal on marrays.  I
changed only the vector-add test to take advantage of the ability to
now compare marrays directly, to make sure it works.  It actually is a
fair amount of work to rewrite the tests, so I'll probably do this
gradually.  Thank you Malcolm and Tom for your contributions.

P.S. Further thoughts on the efficiency of fobbing the comparison off
to CL behind the method:  If element values were extracted using the
GSL interface (like gsl_vector_get) then copying could be avoided.
However, with native arrays (for SBCL), it seemed simplest to always
access elements on the CL side, and just make sure they were
synchronized if on a non-native implementation.  It's possible that it
would be faster to use the C values but since you have to read all the
elements anyway to do a comparison, I don't think it would gain that
much.
In any case, it would be handy to have an iterate over marray
elements, another thing on my to-do list.

Liam




More information about the gsll-devel mailing list