[petsc-dev] Possible error running C/C++ src/snes/examples/tutorials/ex19 with 1 MPI process

Satish Balay balay at mcs.anl.gov
Wed Oct 12 19:31:24 CDT 2016


On Wed, 12 Oct 2016, Satish Balay wrote:

> On Wed, 12 Oct 2016, Antonio Trande wrote:
> 
> > Latest builds:
> > http://copr-fe.cloud.fedoraproject.org/coprs/sagitter/petsc/build/464373/

> I'll try and see if I can reproduce this.. [in a 32bit VM]..

To start off - I looked at all the 5 32bit build logs in 464373 - and
they don't have any C or OpeMPI tests crashing anymore.  I remember
seeing these crashes in some of the previous logs. Any idea what fixed
this?

And wrt the fortran example [with non-mpi build] crashing - somehow
the following appears to make a difference:

FFLAGS=-specs=/usr/lib/rpm/redhat/redhat-hardened-cc1

balay at localhost petsc]$ cat /usr/lib/rpm/redhat/redhat-hardened-cc1
*cc1_options:
+ %{!r:%{!fpie:%{!fPIE:%{!fpic:%{!fPIC:%{!fno-pic:-fPIE}}}}}}
[balay at localhost petsc]$ 

For one - this doesn't look like something gfortran would use or
invoke - and yet - its affected by it. Its changing the behavior of
fortran common blocks - and adds a couple of entries in the object
file created (somefort.o) - I don't know what they do..

<          U _GLOBAL_OFFSET_TABLE_
< 00000000 T __x86.get_pc_thunk.ax


Is it possible to remove this option from FFLAGS? [with 'FOPTFLAGS=']

[BTW: PETSc configure ignores FCFLAGS - so you should remove that.]

Satish

----------
[balay at localhost petsc]$ (./configure --with-mpi=0 --with-blas-lapack-lib=-lopenblas PETSC_ARCH=arch-test1 'FFLAGS=' && make ) > /dev/null && make testRunning test examples to verify correct installation
Using PETSC_DIR=/home/balay/petsc and PETSC_ARCH=arch-test1
C/C++ example src/snes/examples/tutorials/ex19 run successfully with 1 MPI process
Fortran example src/snes/examples/tutorials/ex5f run successfully with 1 MPI process
Completed test examples
=========================================
Now to evaluate the computer systems you plan use - do:
make PETSC_DIR=/home/balay/petsc PETSC_ARCH=arch-test1 streams
[balay at localhost petsc]$ (./configure --with-mpi=0 --with-blas-lapack-lib=-lopenblas PETSC_ARCH=arch-test1 'FFLAGS=-specs=/usr/lib/rpm/redhat/redhat-hardened-cc1' && make ) > /dev/null && make test
Running test examples to verify correct installation
Using PETSC_DIR=/home/balay/petsc and PETSC_ARCH=arch-test1
C/C++ example src/snes/examples/tutorials/ex19 run successfully with 1 MPI process
/usr/bin/sh: line 13: 24506 Aborted                 (core dumped) /home/balay/petsc/bin/petsc-mpiexec.uni -n 1 ./ex5f > ex5f_1.tmp 2>&1
Possible error running Fortran example src/snes/examples/tutorials/ex5f with 1 MPI process
See http://www.mcs.anl.gov/petsc/documentation/faq.html
[0]PETSC ERROR: #1 PetscCommDuplicate() line 138 in /home/balay/petsc/src/sys/objects/tagm.c
[0]PETSC ERROR: #2 PetscHeaderCreate_Private() line 60 in /home/balay/petsc/src/sys/objects/inherit.c
[0]PETSC ERROR: #3 SNESCreate() line 1476 in /home/balay/petsc/src/snes/interface/snes.c
[0]PETSC ERROR: #4 PetscCommDuplicate() line 138 in /home/balay/petsc/src/sys/objects/tagm.c
[0]PETSC ERROR: #5 PetscHeaderCreate_Private() line 60 in /home/balay/petsc/src/sys/objects/inherit.c
[0]PETSC ERROR: #6 DMCreate() line 44 in /home/balay/petsc/src/dm/interface/dm.c
[0]PETSC ERROR: #7 DMDACreate() line 462 in /home/balay/petsc/src/dm/impls/da/dacreate.c
[0]PETSC ERROR: #8 DMDACreate2d() line 855 in /home/balay/petsc/src/dm/impls/da/da2.c
[0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------
[0]PETSC ERROR: Null argument, when expecting valid pointer
[0]PETSC ERROR: Null Object: Parameter # 1
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.7.4, unknown 
[0]PETSC ERROR: ./ex5f on a arch-test1 named localhost.localdomain by balay Wed Oct 12 18:57:42 2016
[0]PETSC ERROR: Configure options --with-mpi=0 --with-blas-lapack-lib=-lopenblas PETSC_ARCH=arch-test1 FFLAGS=-specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
[0]PETSC ERROR: #9 DMCreateGlobalVector() line 870 in /home/balay/petsc/src/dm/interface/dm.c
[0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------
[0]PETSC ERROR: Invalid argument
[0]PETSC ERROR: Wrong type of object: Parameter # 1
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.7.4, unknown 
[0]PETSC ERROR: ./ex5f on a arch-test1 named localhost.localdomain by balay Wed Oct 12 18:57:42 2016
[0]PETSC ERROR: Configure options --with-mpi=0 --with-blas-lapack-lib=-lopenblas PETSC_ARCH=arch-test1 FFLAGS=-specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
[0]PETSC ERROR: #10 VecDuplicate() line 398 in /home/balay/petsc/src/vec/vec/interface/vector.c
[0]PETSC ERROR: ------------------------------------------------------------------------
[0]PETSC ERROR: Caught signal number 11 SEGV: Segmentation Violation, probably memory access out of range
[0]PETSC ERROR: Try option -start_in_debugger or -on_error_attach_debugger
[0]PETSC ERROR: or see http://www.mcs.anl.gov/petsc/documentation/faq.html#valgrind
[0]PETSC ERROR: or try http://valgrind.org on GNU/linux and Apple Mac OS X to find memory corruption errors
[0]PETSC ERROR: likely location of problem given in stack below
[0]PETSC ERROR: ---------------------  Stack Frames ------------------------------------
[0]PETSC ERROR: Note: The EXACT line numbers in the stack are not available,
[0]PETSC ERROR:       INSTEAD the line number of the start of the function
[0]PETSC ERROR:       is given.
[0]PETSC ERROR: [0] VecDuplicate line 397 /home/balay/petsc/src/vec/vec/interface/vector.c
[0]PETSC ERROR: [0] DMCreateGlobalVector line 869 /home/balay/petsc/src/dm/interface/dm.c
[0]PETSC ERROR: [0] PetscCommDuplicate line 136 /home/balay/petsc/src/sys/objects/tagm.c
[0]PETSC ERROR: [0] PetscHeaderCreate_Private line 36 /home/balay/petsc/src/sys/objects/inherit.c
[0]PETSC ERROR: [0] DMCreate line 36 /home/balay/petsc/src/dm/interface/dm.c
[0]PETSC ERROR: [0] DMDACreate line 460 /home/balay/petsc/src/dm/impls/da/dacreate.c
[0]PETSC ERROR: [0] DMDACreate2d line 854 /home/balay/petsc/src/dm/impls/da/da2.c
[0]PETSC ERROR: [0] PetscCommDuplicate line 136 /home/balay/petsc/src/sys/objects/tagm.c
[0]PETSC ERROR: [0] PetscHeaderCreate_Private line 36 /home/balay/petsc/src/sys/objects/inherit.c
[0]PETSC ERROR: [0] SNESCreate line 1471 /home/balay/petsc/src/snes/interface/snes.c
[0]PETSC ERROR: --------------------- Error Message --------------------------------------------------------------
[0]PETSC ERROR: Signal received
[0]PETSC ERROR: See http://www.mcs.anl.gov/petsc/documentation/faq.html for trouble shooting.
[0]PETSC ERROR: Petsc Release Version 3.7.4, unknown 
[0]PETSC ERROR: ./ex5f on a arch-test1 named localhost.localdomain by balay Wed Oct 12 18:57:42 2016
[0]PETSC ERROR: Configure options --with-mpi=0 --with-blas-lapack-lib=-lopenblas PETSC_ARCH=arch-test1 FFLAGS=-specs=/usr/lib/rpm/redhat/redhat-hardened-cc1
[0]PETSC ERROR: #11 User provided function() line 0 in  unknown file

Program received signal SIGABRT: Process abort signal.

Backtrace for this error:
#0  0xb47c31ce in ???
#1  0xb47c1f93 in ???
#2  0xb76dcd43 in ???
#3  0xb76dcd61 in ???
#4  0xb437e5c8 in ???
#5  0xb437fca6 in ???
#6  0xb65b2117 in Petsc_MPI_Abort
	at /home/balay/petsc/src/sys/mpiuni/mpi.c:191
#7  0xb64f04a4 in PetscSignalHandlerDefault
	at /home/balay/petsc/src/sys/error/signal.c:161
#8  0xb64efef8 in PetscSignalHandler_Private
	at /home/balay/petsc/src/sys/error/signal.c:49
#9  0xb76dcd43 in ???
#10  0xb6bd0856 in DMDAGetInfo
	at /home/balay/petsc/src/dm/impls/da/daview.c:150
#11  0xb6c24e1b in dmdagetinfo_
	at /home/balay/petsc/src/dm/impls/da/ftn-custom/zdaviewf.c:27
#12  0x804967d in MAIN__
	at /home/balay/petsc/src/snes/examples/tutorials/ex5f.F:122
#13  0x80499e2 in main
	at /home/balay/petsc/src/snes/examples/tutorials/ex5f.F:184
Completed test examples
=========================================
Now to evaluate the computer systems you plan use - do:
make PETSC_DIR=/home/balay/petsc PETSC_ARCH=arch-test1 streams

[balay at localhost petsc]$ gfortran -c -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1  -g    -I/home/balay/petsc/include -I/home/balay/petsc/arch-test1/include -I/home/balay/petsc/include/petsc/mpiuni    -MMD -MP /home/balay/petsc/src/sys/fsrc/somefort.F -o arch-test1/obj/src/sys/fsrc/somefort.o -Jarch-test1/include
[balay at localhost petsc]$ nm  ./arch-test1/obj/src/sys/fsrc/somefort.o
         U _gfortran_get_command_argument_i4
         U _gfortran_iargc
         U _GLOBAL_OFFSET_TABLE_
00000004 C mpiunipriv_
00000107 T petsccommandargumentcount_
00000000 B petsccomminit_
00000050 C petscfortran1_
00000010 B petscfortran10_
00000008 C petscfortran14_
00000008 C petscfortran15_
00000008 C petscfortran16_
00000008 C petscfortran17_
00000008 C petscfortran18_
00000008 C petscfortran19_
00000004 C petscfortran2_
00000008 C petscfortran20_
00000008 C petscfortran21_
00000008 C petscfortran4_
00000008 C petscfortran5_
00000008 C petscfortran6_
00000004 C petscfortran7_
00000004 C petscfortran8_
00000020 B petscfortran9_
0000012b T petscgetcommandargument_
00000074 T petscgetcommoncomm_
         U petsc_null_function_
00000000 T petscsetcommonblock_
0000008f T petscsetcommonblocknumeric_
         U petscsetfortranbasepointers_
00000000 T __x86.get_pc_thunk.ax
[balay at localhost petsc]$ gfortran -c -g    -I/home/balay/petsc/include -I/home/balay/petsc/arch-test1/include -I/home/balay/petsc/include/petsc/mpiuni    -MMD -MP /home/balay/petsc/src/sys/fsrc/somefort.F -o arch-test1/obj/src/sys/fsrc/somefort.o -Jarch-test1/include
[balay at localhost petsc]$ nm  ./arch-test1/obj/src/sys/fsrc/somefort.o
         U _gfortran_get_command_argument_i4
         U _gfortran_iargc
00000004 C mpiunipriv_
000000c1 T petsccommandargumentcount_
00000000 B petsccomminit_
00000050 C petscfortran1_
00000010 B petscfortran10_
00000008 C petscfortran14_
00000008 C petscfortran15_
00000008 C petscfortran16_
00000008 C petscfortran17_
00000008 C petscfortran18_
00000008 C petscfortran19_
00000004 C petscfortran2_
00000008 C petscfortran20_
00000008 C petscfortran21_
00000008 C petscfortran4_
00000008 C petscfortran5_
00000008 C petscfortran6_
00000004 C petscfortran7_
00000004 C petscfortran8_
00000020 B petscfortran9_
000000d4 T petscgetcommandargument_
00000052 T petscgetcommoncomm_
         U petsc_null_function_
00000000 T petscsetcommonblock_
00000063 T petscsetcommonblocknumeric_
         U petscsetfortranbasepointers_
[balay at localhost petsc]$ 




More information about the petsc-dev mailing list