[petsc-dev] PetscFinalize broken with -options_table ?

William Perkins william.perkins at pnnl.gov
Tue Mar 18 18:20:33 CDT 2014


All,

I also ran into this today.

Attached is a minimal program that exhibited the problem for me. 
Initially, I thought it was because I was using non-default formats 
(e.g. MATLAB) for VecView and MatView, but I think any Viewer use causes 
the problem.

Thanks.

Bill

P.S. I'm using 3.4.3 configured as follows:

python ./config/configure.py \
     PETSC_ARCH=arch-macosx-complex-opt \
     --with-prefix="$prefix" \
     --with-mpi=1 \
     --with-cc=mpicc \
     --with-fc=mpif90 \
     --with-cxx=mpicxx \
     --with-c++-support=1 \
     --with-c-support=0 \
     --with-fortran=0 \
     --with-scalar-type=complex \
     --with-fortran-kernels=generic \
     --with-valgrind=0 \
     --download-superlu_dist \
     --download-parmetis \
     --download-metis \
     --download-f2cblaslapack=1 \
     --with-clanguage=c++ \
     --with-shared-libraries=0 \
     --with-dynamic-loading=0 \
     --with-x=0 \
     --with-mpirun=mpiexec \
     --with-mpiexec=mpiexec \
     --with-debugging=0


On 03/12/2014 04:30 AM, Matthew Knepley wrote:
> On Wed, Mar 12, 2014 at 4:52 AM, Václav Hapla <vaclav.hapla at vsb.cz
> <mailto:vaclav.hapla at vsb.cz>> wrote:
>
>     You're right this is not happening with the petsc example. Thus it's
>     probably problem in my code. I'll come back when I know what's the
>     true reason.
>
>
> It could still be our bug. If you can strip down your code and send it,
> I will look at it.
>
>    Thanks,
>
>       Matt
>
>     Matt, sorry for replying to your personal address only.
>
>     Thank you,
>     Vaclav
>
>
>     Dne 11.3.2014 16:04, Matthew Knepley napsal(a):
>>     On Tue, Mar 11, 2014 at 9:27 AM, Václav Hapla <vaclav.hapla at vsb.cz
>>     <mailto:vaclav.hapla at vsb.cz>> wrote:
>>
>>         FWICS PetscFinalize in petsc-current contains the following bug.
>>         It calls
>>            PetscObjectRegisterDestroyAll()
>>         and after that, if -options_table is present, it calls
>>         PetscViewerASCIIGetStdout(PETSC_COMM_WORLD,&viewer);
>>            PetscOptionsView(viewer);
>>         causing
>>            [0]PETSC ERROR: No support for this operation for this
>>         object type!
>>            [0]PETSC ERROR: Only supports ASCII viewer!
>>         because the viewer is destroyed already by
>>         PetscObjectRegisterDestroyAll.
>>
>>         I haven't tested petsc-dev but I can see in it's the same
>>         situation in the pinit.c source.
>>
>>
>>     I cannot reproduce this on 'next':
>>
>>     next $:/PETSc3/petsc/petsc-dev/src/snes/examples/tutorials$ ./ex19
>>     -options_table -snes_monitor
>>     PETSC_OPTIONS="-cublas 0" ./ex19 -options_table -snes_monitor
>>     lid velocity = 0.0625, prandtl # = 1, grashof # = 1
>>       0 SNES Function norm 2.391552133017e-01
>>       1 SNES Function norm 6.839858507066e-05
>>       2 SNES Function norm 8.558777232425e-11
>>     Number of SNES iterations = 2
>>     #PETSc Option Table entries:
>>     -options_table
>>     -snes_monitor
>>     #End of PETSc Option Table entries
>>
>>     Can you reproduce this with a PETSc example?
>>
>>       Thanks,
>>
>>          Matt
>>
>>         Best regards,
>>         Vaclav
>>
>>
>>         --
>>
>>         Vaclav Hapla
>>         Junior researcher / PhD student
>>         IT4Innovations <http://www.it4i.eu/> / Dept. of Applied
>>         Mathematics <http://am.vsb.cz/>
>>
>>         _office PI 328_
>>         tel.: (+420) 597 329 078 <tel:%28%2B420%29%20597%20329%20078>
>>         Podnikatelsky inkubator VSB-TUO
>>         Studentska 6202/17
>>         708 00 Ostrava-Poruba
>>         Czech Republic
>>
>>         _contact address_
>>         IT4Innovations
>>         VSB - Technical University of Ostrava
>>         17. listopadu 15/2172
>>         708 33 Ostrava-Poruba
>>         Czech Republic
>>
>>
>>
>>
>>     --
>>     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
>
>     --
>
>     Vaclav Hapla
>     Junior researcher / PhD student
>     IT4Innovations <http://www.it4i.eu/> / Dept. of Applied Mathematics
>     <http://am.vsb.cz/>
>
>     _office PI 328_
>     tel.: (+420) 597 329 078 <tel:%28%2B420%29%20597%20329%20078>
>     Podnikatelsky inkubator VSB-TUO
>     Studentska 6202/17
>     708 00 Ostrava-Poruba
>     Czech Republic
>
>     _contact address_
>     IT4Innovations
>     VSB - Technical University of Ostrava
>     17. listopadu 15/2172
>     708 33 Ostrava-Poruba
>     Czech Republic
>
>
>
>
> --
> 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

-- 
Bill Perkins
Research Engineer
Hydrology Group

Pacific Northwest National Laboratory
902 Battelle Boulevard
P.O. Box 999, MSIN K9-36
Richland, WA  99352 USA
Tel:  509-372-6131
Fax: 509-372-6089
william.perkins at pnnl.gov
www.pnnl.gov
-------------- next part --------------
A non-text attachment was scrubbed...
Name: viewer.cpp
Type: text/x-c++src
Size: 1419 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20140318/70027009/attachment.bin>
-------------- next part --------------
Script started on Tue Mar 18 16:15:45 2014
d3g096 at pe10900> mpiexec -np 2 viewer
d3g096 at pe10900> mpiexec -np 2 viewer -options_table
#PETSc Option Table entries:
-options_table
#End of PETSc Option Table entries
d3g096 at pe10900> mpiexec -np 2 viewer -options_table -breakme
Vector Object: 2 MPI processes
  type: mpi
Process [0]
1
1
1
1
1
Process [1]
1
1
1
1
1
[1]PETSC ERROR: --------------------- Error Message ------------------------------------
[1]PETSC ERROR: No support for this operation for this object type!
[1]PETSC ERROR: Only supports ASCII viewer!
[1]PETSC ERROR: ------------------------------------------------------------------------
[1]PETSC ERROR: Petsc Release Version 3.4.3, Oct, 15, 2013 
[1]PETSC ERROR: See docs/changes/index.html for recent updates.
[1]PETSC ERROR: See docs/faq.html for hints about trouble shooting.
[1]PETSC ERROR: See docs/index.html for manual pages.
[1]PETSC ERROR: ------------------------------------------------------------------------
[1]PETSC ERROR: viewer on a arch-macosx-complex-opt named pe10900 by d3g096 Tue Mar 18 16:16:25 2014
[1]PETSC ERROR: Libraries linked from /net/flophouse/files0/perksoft/petsc-3.4.3/arch-macosx-complex-opt/lib
[1]PETSC ERROR: Configure run at Tue Jan 28 12:41:14 2014
[1]PETSC ERROR: Configure options PETSC_ARCH=arch-macosx-complex-opt --with-prefix=/net/flophouse/files0/perksoft/macosx --with-mpi=1 --with-cc=mpicc --with-fc=mpif90 --with-cxx=mpicxx --with-c++-support=1 --with-c-support=0 --with-fortran=0 --with-scalar-type=complex --with-fortran-kernels=generic --with-valgrind=0 --download-superlu_dist --download-parmetis --download-metis --download-f2cblaslapack=1 --with-clanguage=c++ --with-shared-libraries=0 --with-dynamic-loading=0 --with-x=0 --with-mpirun=mpiexec --with-mpiexec=mpiexec --with-debugging=0
[1]PETSC ERROR: ------------------------------------------------------------------------
[1]PETSC ERROR: PetscOptionsView() line 692 in /net/flophouse/files0/perksoft/petsc-3.4.3/src/sys/objects/options.c
[1]PETSC ERROR: PetscFinalize() line 1036 in /net/flophouse/files0/perksoft/petsc-3.4.3/src/sys/objects/pinit.c
[1]PETSC ERROR: main() line 44 in /home/d3g096/Projects/PerformanceLDRD/src/sandbox/petsc/viewer.cpp
[0]PETSC ERROR: --------------------- Error Message ------------------------------------
[0]PETSC ERROR: No support for this operation for this object type!
[0]PETSC ERROR: Only supports ASCII viewer!
[0]PETSC ERROR: ------------------------------------------------------------------------
[0]PETSC ERROR: Petsc Release Version 3.4.3, Oct, 15, 2013 
[0]PETSC ERROR: See docs/changes/index.html for recent updates.
[0]PETSC ERROR: See docs/faq.html for hints about trouble shooting.
[0]PETSC ERROR: See docs/index.html for manual pages.
[0]PETSC ERROR: ------------------------------------------------------------------------
[0]PETSC ERROR: viewer on a arch-macosx-complex-opt named pe10900 by d3g096 Tue Mar 18 16:16:25 2014
[0]PETSC ERROR: Libraries linked from /net/flophouse/files0/perksoft/petsc-3.4.3/arch-macosx-complex-opt/lib
[0]PETSC ERROR: Configure run at Tue Jan 28 12:41:14 2014
[0]PETSC ERROR: Configure options PETSC_ARCH=arch-macosx-complex-opt --with-prefix=/net/flophouse/files0/perksoft/macosx --with-mpi=1 --with-cc=mpicc --with-fc=mpif90 --with-cxx=mpicxx --with-c++-support=1 --with-c-support=0 --with-fortran=0 --with-scalar-type=complex --with-fortran-kernels=generic --with-valgrind=0 --download-superlu_dist --download-parmetis --download-metis --download-f2cblaslapack=1 --with-clanguage=c++ --with-shared-libraries=0 --with-dynamic-loading=0 --with-x=0 --with-mpirun=mpiexec --with-mpiexec=mpiexec --with-debugging=0
[0]PETSC ERROR: ------------------------------------------------------------------------
[0]PETSC ERROR: PetscOptionsView() line 692 in /net/flophouse/files0/perksoft/petsc-3.4.3/src/sys/objects/options.c
[0]PETSC ERROR: PetscFinalize() line 1036 in /net/flophouse/files0/perksoft/petsc-3.4.3/src/sys/objects/pinit.c
[0]PETSC ERROR: main() line 44 in /home/d3g096/Projects/PerformanceLDRD/src/sandbox/petsc/viewer.cpp
--------------------------------------------------------------------------
MPI_ABORT was invoked on rank 1 in communicator MPI_COMM_WORLD 
with errorcode 56.

NOTE: invoking MPI_ABORT causes Open MPI to kill all MPI processes.
You may or may not see output from other processes, depending on
exactly when Open MPI kills them.
--------------------------------------------------------------------------
d3g096 at pe10900> exit
exit

Script done on Tue Mar 18 16:16:29 2014


More information about the petsc-dev mailing list