[petsc-dev] use of hash table vs array in various places in PETSc

Dmitry Karpeev karpeev at mcs.anl.gov
Tue Sep 20 08:56:21 CDT 2011


On Tue, Sep 20, 2011 at 8:43 AM, Jed Brown <jedbrown at mcs.anl.gov> wrote:

> On Tue, Sep 20, 2011 at 01:05, Barry Smith <bsmith at mcs.anl.gov> wrote:
>
>> It may very well be limiting with MatGetSubMatrix() for VI solvers.
>
>
> As I recall, the gather is used to identify which global columns out of the
> off-diagonal block are needed. Well, the process owning that part of the
> index set knows, so why not use the scatter for the off-diagonal block to
> mark the needed columns?
>
> This seems quite straightforward when the submatrix is taking a local
> subset (not moving rows to different processes). This also takes care of the
> most common use case in fieldsplit.
>

Extracting matrices with an overlap (e.g., in ASM) may very well move rows,
though.


>
>
> This would be even nicer if we could move indices over the same channels as
> scalars. This comes up so frequently that I think we should build a
> type-independent scatter, something like
>
> PetscScatterCreate(PetscLayout from,IS isfrom,PetscLayout to,IS
> isto,PetscScatter*);
>
> PetscScatterBegin(PetscScatter,void *from,MPI_Datatype,void
> *to,MPI_Datatype,MPI_Op,ScatterMode);
>
>
> The VecScatter API could be preserved, but the implementation would become
> a thin wrapper over this thing.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20110920/af599999/attachment.html>


More information about the petsc-dev mailing list