dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #04229
Re: New assembly benchmark results
On Fri, Jan 19, 2007 at 03:46:33PM -0600, Garth N. Wells wrote:
>
>
> Anders Logg wrote:
> > I have updated the assembly benchmark in src/bench/fem/assembly and
> > added a simple straight-forward assembly that just uses a
> >
> > std::vector<std::map<int, double> >
> >
> > to store the sparse matrix.
> >
> > Here are the results:
> >
> > Current assembly: 1.37 (with DofMap)
> > Old assembly: 0.814 (without DofMap)
> > Simple assembly: 0.425 (without DofMap and with STL)
> >
> > Simple assembly is 3 times faster than our current assembly.
> >
>
> The picture changes with PETSc matrices, with old assembly and simple
> assembly being almost the same (5% difference). The problem is slow
> insertion into uBLAS matrices and the overhead in converting a
> vector-of-compressed-vectors into a CSR matrix. The current
> implementation using uBLAS matrices is a compromise between ease,
> assembly time and conversion to a CSR matrix.
>
> If you take a look at the benchmarks on
>
> http://www.bauv.unibw-muenchen.de/~winkler/ublas/sparse_comparison.html
>
> DOLFIN currently assembles a "GVOV & CRS" corresponding to "fill 3"
> (random) and then converts it to a CSR matrix. If DofMap would be used
> to initialise the layout of a CSR matrix, this would correspond to
> assembling a "compressed matrix" corresponding to "fill 2". This gives a
> speed up of at least 2, plus it will avoid the overhead (and memory use)
> of converting from one matrix format to another.
>
> Garth
ok. It seems we have quite a number of parameters to play with.
Perhaps we should have a more or less permanent benchmark that
implements a series of different approaches (as simple as
possible)? We will then learn which is fastest and we will be able to
monitor the speed of the default DOLFIN assembly with the series of
benchmarks as we add more functionality to it.
/Anders
References