<div class="gmail_quote">On Mon, Jun 6, 2011 at 23:49, Boyce Griffith <span dir="ltr"><<a href="mailto:griffith@cims.nyu.edu">griffith@cims.nyu.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
But if the model is that the Vec implementation is responsible for updating the state, then would it be better if PETSc did NOT increase the state, e.g., in calls to VecAXPY, or MatVecMult?  It seems like it might be better if it did not, so that if one has a non-"compliant" implementation, one finds out more quickly that their code is broken.</blockquote>
</div><br><div>Good point. We could replace the increments with debug-mode checks that the state actually did get incremented, with errors if it didn't. There are perhaps 50 call sites to update. It would not be a big deal.</div>
<div><br></div><div>This would be great for SNESComputeFunction() too because a common mistake is to forget to put anything in the output vector. This would check that they at least got access to the vector (though we still couldn't confirm that they put anything into it).</div>