That fixed it- thanks! On Tue, Aug 28, 2012 at 4:01 PM, Matthew Knepley <knepley at gmail.com> wrote: > On Tue, Aug 28, 2012 at 4:49 PM, Chris Eldred <chris.eldred at gmail.com> > wrote: >> >> I am getting a segmentation fault when calling PetscSectionCreate. The >> error is: >> [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] PetscTrMallocDefault line 183 >> /home/user/Desktop/LIBRARIES/petsc-dev/src/sys/memory/mtr.c >> [0]PETSC ERROR: [0] PetscSectionCreate line 37 >> /home/user/Desktop/LIBRARIES/petsc-dev/src/vec/vec/impls/seq/vsection.c >> [0]PETSC ERROR: --------------------- Error Message >> ------------------------------------ >> [0]PETSC ERROR: Signal received! >> [0]PETSC ERROR: >> ------------------------------------------------------------------------ >> [0]PETSC ERROR: Petsc Development HG revision: >> b6fe82991deee4a0d3f9a20654bc7750a6b1fe0f HG Date: Mon Aug 27 13:17:10 >> 2012 -0500 >> [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: ./test on a arch-linu named Puget-101334 by user Tue >> Aug 28 15:47:36 2012 >> [0]PETSC ERROR: Libraries linked from >> /home/user/Desktop/LIBRARIES/petsc-dev/arch-linux2-cxx-debug/lib >> [0]PETSC ERROR: Configure run at Mon Aug 27 12:55:14 2012 >> [0]PETSC ERROR: Configure options --download-boost --download-chaco >> --download-ctetgen --download-f-blas-lapack --download-fiat >> --download-generator --download-metis --download-ml --download-mpich >> --download-parmetis --download-scientificpython --download-triangle >> --with-clanguage=cxx --with-dynamic-loading --with-shared-libraries >> --with-sieve PETSC_ARCH=arch-linux2-cxx-debug >> [0]PETSC ERROR: >> ------------------------------------------------------------------------ >> [0]PETSC ERROR: User provided function() line 0 in unknown directory >> unknown file >> application called MPI_Abort(MPI_COMM_WORLD, 59) - process 0 >> [unset]: aborting job: >> application called MPI_Abort(MPI_COMM_WORLD, 59) - process 0 >> >> The relevant code section is: > > > From a recent petsc-users reply: > > Okay, there was a bug in the Fortran stub generation for this type. I have > pushed a fix for this. In order to > get these to rebuild, you need to > > rm $PETSC_DIR/$PETSC_ARCH/bin/bfort > rm -rf $PETSC_DIR/externalpackages/sowing* > cd $PETSC_DIR > cd externalpackages > hg clone http://petsc.cs.iit.edu/petsc/externalpackages/sowing-1.1.16/ > ./$PETSC_ARCH/conf/reconfigure-$PETSC_ARCH.py > > Then you can run src/vec/vec/examples/tests/ex40f90.F > > Thanks > > Matt > >> >> call PetscSectionCreate(PETSC_COMM_WORLD, section, ierr) >> CHKERRQ(ierr) >> >> call PetscSectionSetChart(section, 0, 11, ierr) >> CHKERRQ(ierr) >> do p=0,10 >> call PetscSectionSetDof(section, p, 3, ierr) >> CHKERRQ(ierr) >> end do >> call PetscSectionSetUp(section, ierr) >> CHKERRQ(ierr) >> >> call PetscSectionView(section, PETSC_VIEWER_STDOUT_WORLD, ierr) >> CHKERRQ(ierr) >> >> call PetscSectionDestroy(section, ierr) >> CHKERRQ(ierr) >> >> Ideas? >> >> -- >> Chris Eldred >> DOE Computational Science Graduate Fellow >> Graduate Student, Atmospheric Science, Colorado State University >> B.S. Applied Computational Physics, Carnegie Mellon University, 2009 >> chris.eldred at gmail.com > > > > > -- > 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
-- Chris Eldred DOE Computational Science Graduate Fellow Graduate Student, Atmospheric Science, Colorado State University B.S. Applied Computational Physics, Carnegie Mellon University, 2009 chris.eldred at gmail.com
