[petsc-dev] Hijacked MPI calls...

Jed Brown jed at jedbrown.org
Thu Sep 15 23:06:29 CDT 2016


Satish Balay <balay at mcs.anl.gov> writes:

> On Tue, 13 Sep 2016, Satish Balay wrote:
>
>> On Tue, 13 Sep 2016, Satish Balay wrote:
>> 
>> > And this one is perhaps for Matt..
>> 
>> Ops - perhaps Jed needs to look at this..
>> > 
>> > >>>>>>>>>>>>>>>>>>>
>> >           CC arch-clang-cmplx/obj/src/dm/impls/composite/pack.o
>> > /home/balay/petsc/src/dm/impls/composite/pack.c:657:17: warning: passing an object that undergoes default argument promotion to 'va_start' has undefined behavior [-Wvarargs]
>> >   va_start(Argp,imode);
>> >                 ^
>> > /home/balay/petsc/src/dm/impls/composite/pack.c:641:61: note: parameter of type 'InsertMode' is declared here
>> > PetscErrorCode  DMCompositeGather(DM dm,Vec gvec,InsertMode imode,...)
>> >                                                             ^
>> > 1 warning generated.
>> >  <<<<<<<<<<<<<<<<<
>
> The fix here is:
>
> -PetscErrorCode  DMCompositeGather(DM dm,Vec gvec,InsertMode imode,...)
> +PetscErrorCode  DMCompositeGather(DM dm,InsertMode imode,Vec gvec,...)
>
> [Barry is ok - but Jed,Matt might object?]

It's annoying, but it appears to be needed.  It's screwy because enum
ought to be handled no differently than int for this purpose.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 800 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20160915/07d6ee4c/attachment.sig>


More information about the petsc-dev mailing list