<div dir="ltr"><div class="gmail_default" style="color:#000000"><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Feb 26, 2015 at 4:10 PM, Sturla Molden <span dir="ltr"><<a href="mailto:sturla.molden@gmail.com" target="_blank">sturla.molden@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 26/02/15 18:48, Jason Swails wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Thu, 2015-02-26 at 16:53 +0000, Sturla Molden wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
GPU computing is great if you have the following:<br>
<br>
1. Your data structures are arrays floating point numbers.<br>
</blockquote>
<br>
It actually works equally great, if not better, for integers.<br>
</blockquote>
<br></span>
Right, but not complicated data structures with a lot of references or pointers. It requires data are laid out in regular arrays, and then it acts on these arrays in a data-parallel manner. It is designed to process vertices in parallel for computer graphics, and that is a limitation which is always there. It is not a CPU with 1024 cores. It is a "floating point monster" which can process 1024 vectors in parallel. You write a tiny kernel in a C-like language (CUDA, OpenCL) to process one vector, and then it will apply the kernel to all the vectors in an array of vectors. It is very comparable to how GLSL and Direct3D vertex and fragment shaders work. (The reason for which should be obvious.) The GPU is actually great for a lot of things in science, but it is not a CPU. The biggest mistake in the GPGPU hype is the idea that the GPU will behave like a CPU with many cores.</blockquote><div><br></div><div><div class="gmail_default" style="color:rgb(0,0,0);display:inline">Very well summarized.  At least in my field, though, it is well-known that GPUs are not 'uber-fast CPUs'.  Algorithms have been redesigned, programs rewritten to take advantage of their architecture.  It has been a *massive* investment of time and resources, but (unlike the Xeon Phi coprocessor [1]) has reaped most of its promised rewards.</div></div><div><div class="gmail_default" style="color:rgb(0,0,0);display:inline"><br></div></div><div><div class="gmail_default" style="color:rgb(0,0,0)">​--Jason</div></div><div class="gmail_default" style="color:rgb(0,0,0)"><br></div><div class="gmail_default" style="color:rgb(0,0,0)">[1] I couldn't resist the jab.  At several times the cost of the top of the line NVidia gaming card, the GPU is about 15-20x faster...</div></div>
</div></div>