[petsc-users] Segfault in DMPlexCreateSectionF90

Dharmendar Reddy dharmareddy84 at gmail.com
Tue Apr 16 02:52:08 CDT 2013


Hello,
         I am getting a segfault in DMPlexcreateSectionF90 ...I am not sure
if the problem is in parameters i pass or it is coming from petsc...can you
help me fix this ?
Here is the output from debugger:
I print the variables passed to function before call and they seem
consistent with the format required by the DMPlexCreateSectionF90 call...

Breakpoint 1.1, FEMLIB_M::setupdefualtsection_dofmap (this=0x2781e28) at
/home1/00924/R
eddy135/projects/utgds/src/fem/VariationalProblemBoundProcedures.F90:197
197       call DMPlexCreateSectionF90(this%mdata%Meshdm,this%tdim,
this%numField, &
(idb) s
198            this%numComp,this%cellDofMap, this%numBC, this%bcFieldId,  &
(idb) s
199            this%bcPointIS,section,ierr)
(idb) print this%tdim
$25 = 1
(idb) print this%numField
$26 = 1
(idb) print this%numcomp
$27 = 1
(idb) print this%cellDofMap
$28 = {1, 0}
(idb) print this%numBC
$29 = 2
(idb) c
Continuing.

Breakpoint 1.2, FEMLIB_M::setupdefualtsection_dofmap (this=0x2781e28) at
/home1/00924/R
eddy135/projects/utgds/src/fem/VariationalProblemBoundProcedures.F90:197
197       call DMPlexCreateSectionF90(this%mdata%Meshdm,this%tdim,
this%numField, &
(idb) c
Continuing.

Breakpoint 1.3, FEMLIB_M::setupdefualtsection_dofmap (this=0x2781e28) at
/home1/00924/R
eddy135/projects/utgds/src/fem/VariationalProblemBoundProcedures.F90:197
197       call DMPlexCreateSectionF90(this%mdata%Meshdm,this%tdim,
this%numField, &
(idb) c
Continuing.

Now i see a segfault in inside the petsc call

Program received signal SIGSEGV
DMPlexCreateSectionInitial (dm=0x281cfa0, dim=1, numFields=1,
numComp=0x43ce7cf20000000
1, numDof=0x1, section=0x7fffa07c8d28) at
/home1/00924/Reddy135/LocalApps/petsc/src/dm/
impls/plex/plex.c:5892
5892        for (f = 0; f < numFields; ++f) numDofTot[d] +=
numDof[f*(dim+1)+d];

why is the adress of numDof 0x1 ? some thing wrong in the FortranAddress
conversion code in zplexf90 ?

here is the backtrace

#0  0x00002b79e6cec09a in DMPlexCreateSectionInitial (dm=0x281cfa0, dim=1,
numFields=1,
 numComp=0x43ce7cf200000001, numDof=0x1, section=0x7fffa07c8d28) at
/home1/00924/Reddy1
35/LocalApps/petsc/src/dm/impls/plex/plex.c:5892
#1  0x00002b79e6cf1038 in DMPlexCreateSection (dm=0x281cfa0, dim=1,
numFields=1, numCom
p=0x43ce7cf200000001, numDof=0x1, numBC=2, bcField=0xc420000000000000,
bcPoints=0xc4200
00002a66e21, section=0x7fffa07c8d28) at
/home1/00924/Reddy135/LocalApps/petsc/src/dm/im
pls/plex/plex.c:6148
#2  0x00002b79e6d9e571 in dmplexcreatesectionf90_ (dm=0x259bda8,
dim=0x2781e8c, numFiel
ds=0x2781e90, ptrC=0x25ed9e0, ptrD=0x28adf00, numBC=0x27820a0,
ptrF=0x25eda00, ptrP=0x2
878900, section=0x7fffa07c8d28, __ierr=0x7fffa07c8c98) at
/home1/00924/Reddy135/LocalAp
ps/petsc/src/dm/impls/plex/f90-custom/zplexf90.c:221

-- 
-----------------------------------------------------
Dharmendar Reddy Palle
Graduate Student
Microelectronics Research center,
University of Texas at Austin,
10100 Burnet Road, Bldg. 160
MER 2.608F, TX 78758-4445
e-mail: dharmareddy84 at gmail.com
Phone: +1-512-350-9082
United States of America.
Homepage: https://webspace.utexas.edu/~dpr342
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20130416/e0374aaf/attachment.html>


More information about the petsc-users mailing list