[petsc-dev] [petsc-maint #49008] Problems with VecDotNorm2
Barry Smith
bsmith at mcs.anl.gov
Tue Jul 6 22:36:03 CDT 2010
On Jul 6, 2010, at 9:49 AM, Jose E. Roman wrote:
> Dear all,
>
> We at SLEPc have included a custom implementation of vectors that emulates block vectors in the spirit of PetscExt: v=[v1' v2']' where v1 and v2 are PETSc vectors. This is required for some new SLEPc solvers. With this new type of vectors, we avoid the VecGetArray/VecRestoreArray operations, which would imply array copies, and overload any other required operation. The only place outside SLEPc where these vectors are used is as arguments to KSPSolve.
>
> The problem is VecDotNorm2, which is used in KSPSolve_BCGS and KSPSolve_GCR_cycle and invokes VecGetArray. VecDotNorm2 cannot be overloaded as the other functions, since it is not included in the _VecOps table. Therefore we cannot use KSP=bcgsl with our new solvers. A fix for us would be to promote VecDotNorm2 to be a true Vec operation
I have no objection to upgrading VecDotNorm2() to be a virtual function.
> . If possible, it would be nice that the fix would be included in petsc-3.1.
We really don't like to make such a big change in a patch but if you make the change the change to 3.1 and test it then I have no objection.
Barry
>
> Thanks,
> Jose
>
> PS. We plan to release slepc-3.1 in a few weeks.
>
>
More information about the petsc-dev
mailing list