On Wed, Apr 26, 2017 at 12:10 PM, D D <[email protected]> wrote:

> Why does MatAlloc_AIJ_CSR make two preallocation calls?
>
>         CHKERR( MatSeqAIJSetPreallocationCSR(A, i, j, v) )
>         CHKERR( MatMPIAIJSetPreallocationCSR(A, i, j, v) )
>
> I am assuming memory if preallocated twice, once for sequential and
> another for MPI. So each matrix created with createAIJ will have a
> sequential and MPI structure.
>
> Is this for convenience when switching from sequential to MPI?
>

Only one function will actually take affect, depending on the type of
matrix A is. This is like Objective-C rather than C++.

  Thanks,

     Matt


> Thanks,
> Dale
>



-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

Reply via email to