Monday, 31 March 2014

LinBox Code Sample

As part of my project application, the Lmonade developers asked for a
small code sample. I've posted it below. The code is very simple and
not suitable for production use but will compile and run, and helps to
illustrate the LinBox interface and some basic OpenMP use.

The program multiplies two matrices together in parallel using a
single round of Strassens algorithm to split up the work.

Known Bugs:

  - To keep things simple there are no recursive calls, so only a
    maximum of 7 cores will be used.

  - strassen() doesn't check to ensure that the input matrices are
    square and 2n*2n.

  - The locking mechanism could be made significantly more efficient
    with some finer grained locks.

No comments:

Post a Comment