<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
{font-family:Verdana;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman","serif";}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p.MsoNoSpacing, li.MsoNoSpacing, div.MsoNoSpacing
{mso-style-priority:1;
margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri","sans-serif";}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Verdana","sans-serif";
color:windowtext;}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Verdana","sans-serif"'>Thanks, -help works now.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Verdana","sans-serif"'><o:p> </o:p></span></p><div style='border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt'><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> petsc-dev-bounces@mcs.anl.gov [mailto:petsc-dev-bounces@mcs.anl.gov] <b>On Behalf Of </b>Jed Brown<br><b>Sent:</b> Tuesday, July 10, 2012 8:27 AM<br><b>To:</b> For users of the development version of PETSc<br><b>Subject:</b> Re: [petsc-dev] crash inside PetscVFPrintfDefault on using -help<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p> </o:p></p><div><p class=MsoNormal>On Mon, Jul 9, 2012 at 12:02 AM, Jed Brown <<a href="mailto:jedbrown@mcs.anl.gov" target="_blank">jedbrown@mcs.anl.gov</a>> wrote:<o:p></o:p></p><p class=MsoNormal>Looks like there are a couple of these uninitialized or improperly initialized cases in valgrind ./exX -help. I'll look at them and patch petsc-3.3. Thanks.<o:p></o:p></p><div><p class=MsoNormal><o:p> </o:p></p></div><div><p class=MsoNormal><a href="http://petsc.cs.iit.edu/petsc/releases/petsc-3.3/rev/2189e73a0652">http://petsc.cs.iit.edu/petsc/releases/petsc-3.3/rev/2189e73a0652</a><o:p></o:p></p></div><div><p class=MsoNormal> <o:p></o:p></p></div><blockquote style='border:none;border-left:solid #CCCCCC 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in'><div><div><p class=MsoNormal style='margin-bottom:12.0pt'><o:p> </o:p></p><div><p class=MsoNormal>On Sun, Jul 8, 2012 at 4:23 PM, Chetan Jhurani <<a href="mailto:chetan.jhurani@gmail.com" target="_blank">chetan.jhurani@gmail.com</a>> wrote:<o:p></o:p></p><p class=MsoNormal style='margin-bottom:12.0pt'>Hi,<br><br>PetscVFPrintfDefault crashes on using -help on command line<br>due to bad function arguments.<br><br>Tried this using src/snes/examples/tutorials/ex19, and<br>petsc-dev nightly and petsc-3.3-p1. The stack is given below<br>and the code is not valgrind clean. The debugger told<br>me that in src/ksp/ksp/interface/itcl.c and on this line<br>ksp->pc_side is -1.<br><br> ierr = PetscOptionsEList("-ksp_pc_side","KSP preconditioner side",<br> "KSPSetPCSide",PCSides,3,PCSides[ksp->pc_side],&indx,&flg);CHKERRQ(ierr);<br><br>Stack:<br><br>..... [help skipped]<br><br> -ksp_monitor_draw_true_residual: <FALSE> Monitor graphically true residual norm (KSPMonitorSet)<br> -ksp_monitor_range_draw: <FALSE> Monitor graphically range of preconditioned residual norm (KSPMonitorSet)<br> -ksp_monitor_ams: <FALSE> Publish KSP progress using AMS (KSPMonitorSet)<br>[0]PETSC ERROR: ------------------------------------------------------------------------<br>[0]PETSC ERROR: Caught signal number 11 SEGV: Segmentation Violation, probably memory access out of range<br>[0]PETSC ERROR: Try option -start_in_debugger or -on_error_attach_debugger<br>[0]PETSC ERROR: or see <a href="http://www.mcs.anl.gov/petsc/documentation/faq.html#valgrind[0]PETSC" target="_blank">http://www.mcs.anl.gov/petsc/documentation/faq.html#valgrind[0]PETSC</a> ERROR: or try <a href="http://valgrind.org" target="_blank">http://valgrind.org</a> on<br>GNU/linux and Apple Mac OS X to find memory corruption errors<br>[0]PETSC ERROR: likely location of problem given in stack below<br>[0]PETSC ERROR: --------------------- Stack Frames ------------------------------------<br>[0]PETSC ERROR: Note: The EXACT line numbers in the stack are not available,<br>[0]PETSC ERROR: INSTEAD the line number of the start of the function<br>[0]PETSC ERROR: is given.<br>[0]PETSC ERROR: [0] PetscVFPrintfDefault line 197 src/sys/fileio/mprint.c<br>[0]PETSC ERROR: [0] PetscHelpPrintfDefault line 607 src/sys/fileio/mprint.c<br>[0]PETSC ERROR: [0] PetscOptionsEList line 967 src/sys/objects/aoptions.c<br>[0]PETSC ERROR: [0] KSPSetFromOptions line 382 src/ksp/ksp/interface/itcl.c<br>[0]PETSC ERROR: [0] SNESSetFromOptions line 540 src/snes/interface/snes.c<br>[0]PETSC ERROR: --------------------- Error Message ------------------------------------<br>[0]PETSC ERROR: Signal received!<br>[0]PETSC ERROR: ------------------------------------------------------------------------<br>[0]PETSC ERROR: Petsc Development HG revision: 13f423daabbd83291cd7dca6481f7cffb49b7019 HG Date: Sat Jul 07 21:50:45 2012 -0500<br>[0]PETSC ERROR: See docs/changes/index.html for recent updates.<br>[0]PETSC ERROR: See docs/faq.html for hints about trouble shooting.<br>[0]PETSC ERROR: See docs/index.html for manual pages.<br>[0]PETSC ERROR: ------------------------------------------------------------------------<br>[0]PETSC ERROR: ./ex19 on a test_cras named <a href="http://mg1.txcorp.com" target="_blank">mg1.txcorp.com</a> by jhurani Sun Jul 8 18:15:50 2012<br>[0]PETSC ERROR: Libraries linked from /scr_0/jhurani/builds/crash/petsc-dev/test_crash/lib<br>[0]PETSC ERROR: Configure run at Sun Jul 8 18:12:46 2012<br>[0]PETSC ERROR: Configure options --with-clanguage=C++ --with-c-support=1 --with-fortran=0 --with-debugging=yes<br>[0]PETSC ERROR: ------------------------------------------------------------------------<br>[0]PETSC ERROR: User provided function() line 0 in unknown directory unknown file<br>--------------------------------------------------------------------------<br><br>Chetan<br><br><o:p></o:p></p></div><p class=MsoNormal><o:p> </o:p></p></div></div></blockquote></div><p class=MsoNormal><o:p> </o:p></p></div></div></body></html>