[petsc-users] Question about setting block size for arbitrary Mat formats

Samuel Estes samuelestes91 at gmail.com
Wed Oct 27 11:25:01 CDT 2021


Hi,

I am solving a linear system in which the matrix has some block structure.
We will ultimately use the BAIJ format but for now we are just using the
default CSR and would like to play with different formats to compare
performance for our problem. Currently, I call MatSetBlockSize so that I
can then use MatSetValuesBlocked and MatSetValuesBlockedLocal.

My question is: in the absence of specifying one of the blocked formats,
does setting the block size with MatSetBlockSize have any real effect on
performance? My understanding is that it is really just useful from a
programming perspective in that it allows you to set/access Mat values in
blocks which is often a natural way to do things. Obviously changing the
actual format to have a blocked structure could make a difference but I
just want to check if there's anything else going on under the hood with
the block size when the matrix is in AIJ format.

Thanks!

Sam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20211027/ba9d633c/attachment.html>


More information about the petsc-users mailing list