[petsc-users] ERROR: Cannot pass default in for both input and output indices

Dominik Szczerba dominik at itis.ethz.ch
Sun Oct 23 04:33:56 CDT 2011


>    The reason it is there is because, except for input vectors x and y with very specific layout having VecScatterCreate() create default index sets leads to errors (because how is it suppose to know what parts of the vector you want0 and this is confusing for users.

To me "scatters all values" and "fills entire vector yin", as per the
documentation, is unambiguous.

>     The best solution is for you to pass in an index set for either one or both of the IS arguments.

This is changing very many lines in a few codes, so I am looking for a
minimalistic approach. Am I rigorously correct, or just lucky till the
next release, to replace the first PETSC_NULL with IS created with
ISCreateStride? I am only doing SCATTER_FORWARD.

Many thanks,
Dominik

>
>     Barry
>
> On Oct 22, 2011, at 4:56 PM, Dominik Szczerba wrote:
>
>> After upgrade to 3.2 I face the following error:
>>
>> ERROR: VecScatterCreate() line 841 in
>> /home/dsz/pack/petsc-3.2-p3/src/vec/vec/utils/vscat.c Cannot pass
>> default in for both input and output indices
>>
>> My code is:
>>
>> VecScatterCreate(bv0, PETSC_NULL, bv0Seq, PETSC_NULL, &ctx);
>>
>> According to the docu, there is nothing wrong passing PETSC_NULL for
>> both, it was also fine in 3.1. I find no mention of any changes here
>> in the 3.2 Changes documentation. What have I missed here?
>>
>> Regards,
>> Dominik
>
>


More information about the petsc-users mailing list