This book is required reading for anyone working with accelerator-based computing systems. " From the Foreword by Jack Dongarra, University of Tennessee and Oak Ridge National Laboratory CUDA is a computing architecture designed to facilitate the development of parallel programs. In conjunction with a comprehensive software platform, the CUDA Architecture enables programmers to draw on the immense power of graphics processing units (GPUs) when building high-performance applications. GPUs, of course, have long been available for demanding graphics and game applications. CUDA now brings this valuable resource to programmers working on applications in other domains, including science, engineering, and finance. No knowledge of graphics programming is required just the ability to program in a modestly extended version of C. " CUDA by Example, " written by two senior members of the CUDA software platform team, shows programmers how to employ this new technology. The authors introduce each area of CUDA development through working examples. After a concise introduction to the CUDA platform and architecture, as well as a quick-start guide to CUDA C, the book details the techniques and trade-offs associated with each key CUDA feature. You ll discover when to use each CUDA C extension and how to write CUDA software that delivers truly outstanding performance. Major topics covered include Parallel programming Thread cooperation Constant memory and events Texture memory Graphics interoperability Atomics Streams CUDA C on multiple GPUs Advanced atomics Additional CUDA resources All the CUDA software tools you ll need are freely available for download from NVIDIA.http: //developer.nvidia.com/object/cuda-by-e...
This book fits the mold of what most programmers are always looking for more of: trendy topics that seize the dialog. However, it's more than just trendy as my journey through this book was a mind expanding experience and I had a lot of fun working through the examples.
Shared memory, weaves/warps/texture memory, atomics, multiple GPUs, streams, reductions, just to name of few of the indispensable tools covered in this book. If you're going to develop software for massively parallel architectures I'd recommend this book.
The main reason I chose to read this book is because at the time I started reading it, there were no OpenCL books and from what I have read both languages are very similar apart from some naming conventions and other minor trivialities. Personally I prefer OpenCL seeing how it's not owned by a single vendor and it works on several brands of hardware. I’d still recommend this book even if you're going to be developing software for OpenCL.
In regards to reductions, the dot product sample blew my mind. Using a separate shared memory buffer so that each block has it's own buffer to write to to avoid millions of threads competing for write access to a single buffer (not to mention a ten-fold performance improvement). I can't help but remember Dijkstra: "Simplicity is a great virtue but it requires hard work to achieve it and education to appreciate it. And to make matters worse: complexity sells better."
Great introduction to CUDA. You could probably find all this information somewhere on the web, but save yourself the time and read the book. It reads quick with well explained examples focusing on the CUDA and not side issues. There is only the occasional problem with it assuming to know what libraries to link against such as GL or glut, but that I figured out pretty quick. The books really gets you going on CUDA fast.
If the reader is familiar with C and concurrency, then this book is a fast read as it walks through the examples that are simple yet convey the programming concepts and it does not ask the reader to fill the gaps in explanation. It covers all of the basic concepts of cuda programming along with the associated common and simple gotchas.
On the downside, the book is light on explaining the details of Cuda architecture and is it affects the programming. For such details, look elsewhere. If you are looking for parallel algorithm patterns, then look elsewhere. Also, since the book is a decade old, it does not cover recent changes to cuda architecture and programming model.
All said, this is a great first book to learn cuda programming.
I had great fun reading this book. The book is over a decade old (written in 2011) at the time of CUDA 3.0 while CUDA 13.0 was released while I was reading through this book. But fortunately this book is quite solid and most of the knowledge in the book is still relevant today.
A perfect introduction for CUDA programming. Well organized and sectioned. I suggest it strongly for each one to start using CUDA to get benefit from GPU parallel development. It is the first book I have read to get ready for my master thesis.
The main issue I have noticed is the lack of instructions to install CUDA and configure its environment on different operating systems. Another issue is the repeating of many ideas and parts all over the book.