<div dir="ltr"><div class="markdown-here-wrapper" style=""><p style="margin:0px 0px 1.2em!important">Hi PETSc-developers, </p>
<p style="margin:0px 0px 1.2em!important">I have a few questions regarding changes to PETSc between version 3.13.5 and current master. I’m trying to run an application that worked with no issues with version 3.13.5 but isn’t working with the current master. </p>
<p style="margin:0px 0px 1.2em!important">[1] To assemble a matrix in this application I loop over all rows and have multiple calls to MatSetValuesStencil with INSERT_VALUES as the addv argument for all except one call which has ADD_VALUES. Final assembly is called after this loop. With PETSc-3.13.5 this ran with no errors but with PETSc-master I get : </p>
<pre style="font-size:0.85em;font-family:Consolas,Inconsolata,Courier,monospace;font-size:1em;line-height:1.2em;margin:1.2em 0px"><code style="font-size:0.85em;font-family:Consolas,Inconsolata,Courier,monospace;margin:0px 0.15em;padding:0px 0.3em;white-space:pre-wrap;border:1px solid rgb(234,234,234);background-color:rgb(248,248,248);border-radius:3px;display:inline;white-space:pre;overflow:auto;border-radius:3px;border:1px solid rgb(204,204,204);padding:0.5em 0.7em;display:block!important">Object is in wrong state
[0]PETSC ERROR: Cannot mix add values and insert values
</code></pre><p style="margin:0px 0px 1.2em!important">This is fixed by having a flush assembly in between two stages where the first stage has two loops with INSERT_VALUES and the second stage has a loop with ADD_VALUES.</p>
<p style="margin:0px 0px 1.2em!important">Did this change result from a bugfix or are users now expected to no longer mix add and insert values within the same loop ? </p>
<p style="margin:0px 0px 1.2em!important">[2] To prevent re-building the preconditioner at all TSSteps, I had the command line argument <code style="font-size:0.85em;font-family:Consolas,Inconsolata,Courier,monospace;margin:0px 0.15em;padding:0px 0.3em;white-space:pre-wrap;border:1px solid rgb(234,234,234);background-color:rgb(248,248,248);border-radius:3px;display:inline">-snes_lag_preconditioner -1</code>. This did the job in 3.13.5 but with the current master I get the following error : </p>
<pre style="font-size:0.85em;font-family:Consolas,Inconsolata,Courier,monospace;font-size:1em;line-height:1.2em;margin:1.2em 0px"><code style="font-size:0.85em;font-family:Consolas,Inconsolata,Courier,monospace;margin:0px 0.15em;padding:0px 0.3em;white-space:pre-wrap;border:1px solid rgb(234,234,234);background-color:rgb(248,248,248);border-radius:3px;display:inline;white-space:pre;overflow:auto;border-radius:3px;border:1px solid rgb(204,204,204);padding:0.5em 0.7em;display:block!important">Cannot set the lag to -1 from the command line since the preconditioner must be built as least once, perhaps you mean -2
</code></pre><p style="margin:0px 0px 1.2em!important">I can however run the application without this option. If this is a breaking change, what is the new option to prevent re-building the preconditioner ?</p>
<p style="margin:0px 0px 1.2em!important">[3] Finally, I’m used the latest development version of MPICH for building both 3.13.5 and petsc-master and I get these warnings at exit : </p>
<pre style="font-size:0.85em;font-family:Consolas,Inconsolata,Courier,monospace;font-size:1em;line-height:1.2em;margin:1.2em 0px"><code style="font-size:0.85em;font-family:Consolas,Inconsolata,Courier,monospace;margin:0px 0.15em;padding:0px 0.3em;white-space:pre-wrap;border:1px solid rgb(234,234,234);background-color:rgb(248,248,248);border-radius:3px;display:inline;white-space:pre;overflow:auto;border-radius:3px;border:1px solid rgb(204,204,204);padding:0.5em 0.7em;display:block!important">[WARNING] yaksa: 2 leaked handles
.... (repeated N number of times where N is number of mpi ranks)
</code></pre><p style="margin:0px 0px 1.2em!important">Can this be safely neglected ?<br></p><p style="margin:0px 0px 1.2em!important">Let me know if sharing either the application code and/or logs would be helpful and I can share either.<br></p>
<p style="margin:0px 0px 1.2em!important">Thank You,<br>Sajid Ali | PhD Candidate<br>Applied Physics<br>Northwestern University<br><a href="http://s-sajid-ali.github.io">s-sajid-ali.github.io</a></p>
<div title="MDH:PGRpdj5IaSBQRVRTYy1kZXZlbG9wZXJzLCA8YnI+PGJyPkkgaGF2ZSBhIGZldyBxdWVzdGlvbnMg
cmVnYXJkaW5nIGNoYW5nZXMgdG8gUEVUU2MgYmV0d2VlbiB2ZXJzaW9uIDMuMTMuNSBhbmQgY3Vy
cmVudCBtYXN0ZXIuIEknbSB0cnlpbmcgdG8gcnVuIGFuIGFwcGxpY2F0aW9uIHRoYXQgd29ya2Vk
IHdpdGggbm8g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