[petsc-users] MatSetValues() for MATMPICUSP

Jed Brown jedbrown at mcs.anl.gov
Fri Feb 10 14:26:44 CST 2012


On Fri, Feb 10, 2012 at 14:24, recrusader <recrusader at gmail.com> wrote:

> I use Libmesh with PETSc for my FEM simulation.
> The program works when using MATSEQCUSP.  However, When I test
> MATMPICUSP with 2 GPU cards, I met the following errors:
> "
> [1]PETSC ERROR: --------------------- Error Message
> ------------------------------------
> [1]PETSC ERROR: Argument out of range!
> [1]PETSC ERROR: New nonzero at (1,5) caused a malloc!
>

Can you try with plain MATMPIAIJ? I suspect you are not preallocating
correctly.

*Preallocation routines now automatically set
MAT_NEW_NONZERO_ALLOCATION_ERR, if you intentionally preallocate less than
necessary then use
MatSetOption(mat,MAT_NEW_NONZERO_ALLOCATION_ERR,PETSC_FALSE) to disable the
error generation.*

http://www.mcs.anl.gov/petsc/documentation/changes/dev.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20120210/a6917ce0/attachment.htm>


More information about the petsc-users mailing list