<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Apr 5, 2018 at 7:50 AM, Klaij, Christiaan <span dir="ltr"><<a href="mailto:C.Klaij@marin.nl" target="_blank">C.Klaij@marin.nl</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">




<div dir="ltr" style="font-size:12pt;color:#000000;background-color:#ffffff;font-family:Calibri,Arial,Helvetica,sans-serif">
<p>??? In my original email I mention that page and state that the<br>
command line option is working.<br>
</p>
<p><br>
</p>
<p>Were you expecting me to understand from your reply that the<br>
option :ascii_xml somehow translates to<br>
PetscViewerPushFormat(viewer,"<wbr>PETSC_VIEWER_ASCII_XML")?</p></div></blockquote><div>Yes. The format for viewer input is</div><div><br></div><div>  -foo_view type:filename:format:mode</div><div><br></div><div>where any argument can be omitted so that it takes the default. The defaults are</div><div><br></div><div>  type        - ascii</div><div>  filename - stdout <br></div><div>  format    - FORMAT_DEFAULT</div><div>  mode     - read</div><div><br></div><div>  Thanks,</div><div><br></div><div>      Matt</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr" style="font-size:12pt;color:#000000;background-color:#ffffff;font-family:Calibri,Arial,Helvetica,sans-serif">
<p>Chris<br>
</p>
<div style="color:rgb(33,33,33)">
<hr style="display:inline-block;width:98%">
<div id="m_494809818832931531divRplyFwdMsg" dir="ltr"><font style="font-size:11pt" face="Calibri, sans-serif" color="#000000"><b>From:</b> Matthew Knepley <<a href="mailto:knepley@gmail.com" target="_blank">knepley@gmail.com</a>><br>
<b>Sent:</b> Thursday, April 05, 2018 1:35 PM<br>
<b>To:</b> Klaij, Christiaan<br>
<b>Cc:</b> Smith, Barry F.; <a href="mailto:petsc-dev@mcs.anl.gov" target="_blank">petsc-dev@mcs.anl.gov</a>; Koos Huijssen<br>
<b>Subject:</b> Re: [petsc-dev] getting on with the nested timers</font>
<div> </div>
</div>
<div>
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote">On Thu, Apr 5, 2018 at 7:31 AM, Klaij, Christiaan <span dir="ltr">
<<a href="mailto:C.Klaij@marin.nl" target="_blank">C.Klaij@marin.nl</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr" style="font-size:12pt;color:#000000;background-color:#ffffff;font-family:Calibri,Arial,Helvetica,sans-serif">
<p></p>
<p>Matt,<br>
<br>
I guess you meant to send this link:<br>
<br>
<a href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Viewer/PetscViewerPushFormat.html" target="_blank">http://www.mcs.anl.gov/petsc/p<wbr>etsc-current/docs/manualpages/<wbr>Viewer/PetscViewerPushFormat.<wbr>html</a></p>
</div>
</blockquote>
<div>No, I meant to send the link I sent. In the section Options Database Keys, it gives you the format.<br>
</div>
<div><br>
</div>
<div>  Matt</div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr" style="font-size:12pt;color:#000000;background-color:#ffffff;font-family:Calibri,Arial,Helvetica,sans-serif">
<p><br>
If so, it doesn't say anything on XML either. But after some<br>
trial and error I found the format to<br>
be "PETSC_VIEWER_ASCII_XML", so problem solved.<br>
<br>
Summarizing the problem from a user perspective:<br>
<br>
1) The manual page of PetscLogView mentions PetscViewerASCIIOpen,<br>
which mentions PetscViewerPushFormat, I should have figured that<br>
out by myself, sorry.<br>
<br>
2) The manual page of PetscLogView mentions PetscLogNestedBegin,<br>
which doesn't have a manual entry.<br>
<br>
3) The manual page of PetscViewerPushFormat doesn't mention the<br>
format PETSC_VIEWER_ASCII_XML, although it is available.<br>
<br>
Chris<br>
</p>
<div style="color:rgb(33,33,33)"></div>
<br>
<font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold">dr. ir.</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold">
</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold">Christiaan</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold">
</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold">Klaij</font><font size="3" face="Segoe UI"></font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold"> |
</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold">Senior Researcher</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold"> |
</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d;font-weight:bold">Research & Development</font><br>
<font style="font-family:Verdana;font-size:9pt;color:#7d7d7d;font-weight:bold">MARIN</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d"> | T
</font><font style="font-family:Verdana;font-size:8pt;color:#7d7d7d">+31 317 49 33 44</font><font size="2" face="Segoe UI" color="#7d7d7d"></font><font style="font-family:Verdana;font-size:8pt"> |
</font><span style="font-family:Verdana;font-size:8pt"><a href="mailto:C.Klaij@marin.nl" title="" style="font-family:Verdana;font-size:8pt" target="_blank"><span style="font-family:Verdana;font-size:8pt">C.Klaij@marin.nl</span></a></span><font size="2" face="Segoe UI" color="#7d7d7d"></font><font style="font-family:Verdana;font-size:8pt"> |
</font><span style="font-family:Verdana;font-size:8pt"><a href="http://www.marin.nl" title="" style="font-family:Verdana;font-size:8pt" target="_blank"><span style="font-family:Verdana;font-size:8pt">www.marin.nl</span></a></span><br>
<br>
<a href="https://www.linkedin.com/company/marin" target="_blank"><img alt="LinkedIn" style="border:0px Solid" width="16" height="16" src="cid:image8057bb.PNG@dec356c2.4aa84464"></a> <a href="http://www.youtube.com/marinmultimedia" target="_blank"><img alt="YouTube" style="border:0px Solid" width="16" height="16" src="cid:image528f07.PNG@ea884aa9.43a35394"></a> <a href="https://twitter.com/MARIN_nieuws" target="_blank"><img alt="Twitter" style="border:0px Solid" width="16" height="16" src="cid:image003692.PNG@efa8349a.4a86e5a4"></a> <a href="https://www.facebook.com/marin.wageningen" target="_blank"><img alt="Facebook" style="border:0px Solid" width="16" height="16" src="cid:image209c91.PNG@334fe4fc.4d90b49c"></a><br>
<font style="font-family:Verdana;font-size:8pt" size="2" face="Verdana" color="#7d7d7d">MARIN news:
<font style="font-family:Verdana;font-size:8pt"><span style="font-family:Verdana;font-size:8pt"><a href="http://www.marin.nl/web/News/News-items/Comfort-draft-for-semisubmersible-yachts.htm" title="" style="font-family:Verdana;font-size:8pt" target="_blank"><span style="font-family:Verdana;font-size:8pt">Comfort
 draft for semi-submersible yachts</span></a></span></font></font>
<p></p>
<p></p>
<div style="color:rgb(33,33,33)">
<hr style="display:inline-block;width:98%">
<div id="m_494809818832931531m_4094180488162798360divRplyFwdMsg" dir="ltr"><font style="font-size:11pt" face="Calibri, sans-serif" color="#000000"><b>From:</b> Matthew Knepley <<a href="mailto:knepley@gmail.com" target="_blank">knepley@gmail.com</a>><br>
<b>Sent:</b> Thursday, April 05, 2018 12:50 PM<br>
<b>To:</b> Klaij, Christiaan<br>
<b>Cc:</b> Smith, Barry F.; <a href="mailto:petsc-dev@mcs.anl.gov" target="_blank">
petsc-dev@mcs.anl.gov</a>; Koos Huijssen<br>
<b>Subject:</b> Re: [petsc-dev] getting on with the nested timers</font>
<div> </div>
</div>
<div>
<div dir="ltr">
<div class="gmail_extra">
<div class="gmail_quote">On Thu, Apr 5, 2018 at 6:15 AM, Klaij, Christiaan <span dir="ltr">
<<a href="mailto:C.Klaij@marin.nl" target="_blank">C.Klaij@marin.nl</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Barry,<br>
<br>
I'm still trying to use petsc's nested logging with our code. I<br>
have it working for 3.8.3 with the command line option, for<br>
example:<br>
<br>
mpirun -n 3 ./refresco -log_view :performance.xml:ascii_xml<br>
<br>
This gives the expected performance.xml file. How to get the same<br>
without command line options? So far I have:<br>
<br>
CALL PetscLogDefaultBegin(ierr)<br>
...<br>
CALL PetscViewerASCIIOpen(MPI_COMM_<wbr>WORLD,'performance.xml',viewer<wbr>,ierr)<br>
CALL PetscLogView(viewer,ierr)<br>
<br>
which gives the regular log in the performance.xml file.<br>
<br>
I guess I should replace PetscLogDefaultBegin by<br>
PetscLogNestedBegin as stated in the manual page of PetscLogView.<br>
<br>
But there's no manual page for PetscLogNestedBegin and I didn't<br>
find anything like PetscViewerASCIIOpenXML either.<br>
</blockquote>
<div><br>
</div>
<div><a href="http://www.mcs.anl.gov/petsc/petsc-master/docs/manualpages/Profiling/PetscLogView.html" target="_blank">http://www.mcs.anl.gov/petsc/p<wbr>etsc-master/docs/manualpages/P<wbr>rofiling/PetscLogView.html</a><br>
</div>
<div><br>
</div>
<div>You need to push the ASCII_XML format before viewing.</div>
<div><br>
</div>
<div>  Thanks,</div>
<div><br>
</div>
<div>     Matt</div>
<div> </div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Chris<br>
<br>
<br>
dr. ir. Christiaan Klaij  | Senior Researcher | Research & Development<br>
MARIN | T +31 317 49 33 44 | mailto:<a href="mailto:C.Klaij@marin.nl" target="_blank">C.Klaij@marin.nl</a> |
<a href="http://www.marin.nl" rel="noreferrer" target="_blank">http://www.marin.nl</a><br>
<br>
MARIN news: <a href="http://www.marin.nl/web/News/News-items/Kom-zaterdag-10-november-naar-de-open-dag-in-Wageningen.htm" rel="noreferrer" target="_blank">
http://www.marin.nl/web/News/N<wbr>ews-items/Kom-zaterdag-10-nove<wbr>mber-naar-de-open-dag-in-Wagen<wbr>ingen.htm</a><br>
<br>
<span class="m_494809818832931531HOEnZb"><font color="#888888"></font></span></blockquote>
<span class="m_494809818832931531HOEnZb"><font color="#888888"></font></span></div>
<span class="m_494809818832931531HOEnZb"><font color="#888888"><br>
<br clear="all"><span class="HOEnZb"><font color="#888888">
<div><br>
</div>
-- <br>
<div class="m_494809818832931531m_4094180488162798360gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
-- Norbert Wiener</div>
<div><br>
</div>
<div><a href="http://www.caam.rice.edu/~mk51/" target="_blank">https://www.cse.buffalo.edu/~k<wbr>nepley/</a><br>
</div>
</div>
</div>
</div>
</div>
</font></span></font></span></div><span class="HOEnZb"><font color="#888888">
</font></span></div><span class="HOEnZb"><font color="#888888">
</font></span></div><span class="HOEnZb"><font color="#888888">
</font></span></div><span class="HOEnZb"><font color="#888888">
<u></u>
<p></p>
<u></u><u></u><u></u></font></span></div><span class="HOEnZb"><font color="#888888">
</font></span></blockquote><span class="HOEnZb"><font color="#888888">
</font></span></div><span class="HOEnZb"><font color="#888888">
<br>
<br clear="all">
<div><br>
</div>
-- <br>
<div class="m_494809818832931531gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
-- Norbert Wiener</div>
<div><br>
</div>
<div><a href="http://www.caam.rice.edu/~mk51/" target="_blank">https://www.cse.buffalo.edu/~<wbr>knepley/</a><br>
</div>
</div>
</div>
</div>
</div>
</font></span></div>
</div>
</div>
</div>
</div>

</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div><div><br></div><div><a href="http://www.caam.rice.edu/~mk51/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div>
</div></div>