<div dir="ltr"><div><div><div><div><div><div>Hi All,<br><br></div>I've finally gotten around to putting together a matrix class (called AIJMKL for now) that inherits from AIJ but uses some methods provided by Intel MKL.  One thing I'd like to support is the "SpMV 2" sparse inspector-executor routines, detailed in the MKL reference manual starting at<br><br>  <a href="https://software.intel.com/en-us/node/590105">https://software.intel.com/en-us/node/590105</a><br><br></div>The basic usage model is this: You set some hints (see the functions at <a href="https://software.intel.com/en-us/node/590120">https://software.intel.com/en-us/node/590120</a>) about how a matrix you have is going to be used, e.g., you call 'mkl_sparse_mv_hint' to set a guess about the number of upcoming matrix-vector multiplications that will be performed with this matrix.  When you've set various hints, then you call 'mkl_sparse_optimize' to start an analysis operation in which MKL examines the sparsity structure and maybe does some internal things for optimizations.  Then you can then apply mkl_sparse_d_mv to perform mat-vec operations.<br><br></div>I am wondering what a proper way to provide a PETSc interface to these is.  I can think of a few ways to do this.  The most straightforward way is probably.<br><br>* Add MatAIJMKLSetMVHint(), MatAIJMKLSetMMHint(), etc.<br></div>* Add MatAIJMKLOptimize() call.<br><br></div>I also will be adding a BAIJMKL class for BAIJ matrices, so I'd duplicate these.  Does this option sound OK?  Or do others think I should do something more general?<br><br></div><div>--Richard<br></div></div>