<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Sat, Feb 22, 2014 at 3:05 PM, Mani Chandra <span dir="ltr"><<a href="mailto:mc0710@gmail.com" target="_blank">mc0710@gmail.com</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">Hi Everyone,<div><br></div><div>I tested the updated implementation of the viennacl bindings in petsc-dev/next and I get rather poor performance when using viennacl on either cpu or gpu. I am using the TS module (type:theta) with a simple advection equation in 2D with resolution 256x256 and 8 variables. I tested with the following cases:</div>
<div><br></div><div>1) Single cpu with petsc's old aij mat and vec implementation</div><div>2) Viennacl mat and vec and using VecViennaCLGetArrayRead/Write in the residual evaluation function on an intel cpu with intel's opencl.</div>
<div>3) Viennacl mat and vec and using VecViennaCLGetArrayRead/Write in the residual evaluation function on an nvidia gpu.</div><div><br></div><div>The first case is the fastest and the other cases are 2-3 times slower. Attached are the log summaries for each cases and the code I used to test with. I am running using the following command:</div>
</div></blockquote><div><br></div><div>At least one problem here is the excessive copying of Vecs to the card in the GPU timings. After this, the MatMult() is getting</div><div>abysmal performance.</div><div><br></div><div>
Karl, something is certainly wrong with the matvec in this example, and it seems to be copying the matrix to the card.</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr"><div>time ./petsc_opencl -ts_monitor -snes_monitor -ts_dt 0.01 -ts_max_steps 10 -ts_type theta -log_summary<br></div><div><br></div><div>Cheers,</div><div>Mani</div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>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>