The Leanpub 60 Day 100% Happiness Guarantee
Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.
See full terms...
An Advanced Engineering Reference for GPU Architecture, Low-Level Optimization, and High-Performance Computing
Modern GPU programming requires more than exposing parallel work to thousands of threads. It demands an understanding of the relationship between hardware architecture, instruction execution, memory movement, synchronization, and the software systems that coordinate computation across multiple GPUs. Mastering NVIDIA CUDA: Expert GPU Programming is a 100-chapter technical reference for experienced developers, high-performance computing engineers, researchers, and AI systems architects.
Minimum price
$31.00
$31.00
Buying multiple copies for your team? See below for a discount!
About the Book
An Advanced Engineering Reference for GPU Architecture, Low-Level Optimization, and High-Performance Computing
Modern GPU programming requires more than exposing parallel work to thousands of threads. It demands an understanding of the relationship between hardware architecture, instruction execution, memory movement, synchronization, and the software systems that coordinate computation across multiple GPUs. Mastering NVIDIA CUDA: Expert GPU Programming is a 100-chapter technical reference for experienced developers, high-performance computing engineers, researchers, and AI systems architects. It explores GPU performance engineering from microarchitecture and low-level machine code to distributed computing, production deployment, and specialized computational workloads, with particular attention to NVIDIA Hopper and Blackwell systems. The book moves beyond introductory CUDA programming to examine how hardware constraints influence software design. Topics include instruction-level parallelism, register pressure, warp scheduling, memory hierarchy, asynchronous execution, mixed-precision arithmetic, and multi-GPU communication. The goal is to help readers reason about performance at the level where implementation choices meet the capabilities and limitations of the hardware.
Understanding GPU performance begins with understanding what the hardware actually executes. The book examines Streaming Multiprocessor organization, register allocation, warp-level synchronization, control-flow divergence, predication, and shared-memory bank conflicts.
Dedicated chapters explore PTX as CUDA's virtual instruction set and SASS as NVIDIA's machine-level instruction representation. Profiling, instruction analysis, occupancy, and performance modeling are treated as complementary tools for identifying bottlenecks rather than relying on assumptions about what should be fast.
The discussion spans architectural developments from Fermi through Hopper and Blackwell, providing historical context for changes in execution models, memory systems, and specialized compute capabilities.
GPU performance often depends as much on moving data efficiently as on performing arithmetic. This reference examines shared-memory pipelines, cache behavior, memory allocation, Unified Memory, stream-ordered operations, and asynchronous data movement.
Hopper and Blackwell topics include the Tensor Memory Accelerator (TMA), thread block clusters, Distributed Shared Memory, and synchronization mechanisms for coordinating work across Streaming Multiprocessors. Double-buffering, data-layout design, and memory-access optimization are considered in the context of practical kernel engineering.
The book also explores CUDA Graphs, cooperative execution, and other techniques for reducing host-side launch overhead and coordinating complex GPU workloads.
Modern AI workloads depend on specialized arithmetic units, carefully designed data layouts, and efficient movement of model parameters and intermediate results. The book covers Tensor Core programming, mixed-precision computation, FP8 and FP4 formats, custom matrix multiplication kernels, quantization, and kernel fusion.
Additional chapters address TensorRT inference, custom AI plugins, data-loading pipelines, and GPU acceleration for large language models. The emphasis is on understanding the trade-offs among throughput, numerical behavior, memory consumption, and latency.
Scaling beyond a single GPU introduces communication costs and coordination challenges that cannot be solved through kernel optimization alone.
The book examines NVLink and NVSwitch interconnects, GPUDirect RDMA, GPUDirect Storage, NCCL communication patterns, collective operations, and multi-GPU workload distribution. It also explores all-reduce and all-to-all operations, CUDA streams and events, and the architectural considerations involved in building larger GPU compute systems.
These topics connect individual GPU programming techniques to the broader requirements of distributed AI training, scientific computing, and high-performance cluster workloads.
Performance engineering requires measurable evidence. Chapters on NVIDIA Nsight Systems, Nsight Compute, Roofline analysis, debugging, sanitizers, and race-condition detection provide a framework for investigating execution behavior and validating optimization decisions.
Application-oriented material explores sparse matrix computations, FFTs, graph analytics, Monte Carlo simulation, computational fluid dynamics, molecular dynamics, computer vision, video processing, signal processing, cryptographic workloads, and scientific visualization.
Further topics include Python integration through CuPy and Numba, CUDA interoperability with Rust and modern C++, C++ standard parallelism, OpenMP offloading, and performance-portable approaches using Kokkos and RAJA.
Advanced GPU software must remain reliable outside controlled benchmarks. The final sections examine formal verification, static analysis, memory validation, security vulnerabilities, energy efficiency, thermal throttling, custom memory allocators, and the CUDA Driver API and Runtime API. Production engineering topics include CI/CD pipelines, Kubernetes and Slurm deployment, long-running GPU services, and sustained performance under operational constraints. The book also considers the Grace Hopper platform, heterogeneous memory systems, and emerging directions in GPU computing.
This reference is intended for experienced CUDA developers optimizing existing applications, HPC engineers working with large-scale simulations, researchers developing computational kernels, and machine learning systems engineers seeking better performance from modern GPU hardware.
It is particularly suited to readers who already understand programming fundamentals and want to deepen their knowledge of GPU architecture, low-level execution, profiling, memory behavior, and distributed compute systems. The material is technical in scope and is best approached as an advanced reference rather than a first introduction to CUDA.
The bundle combines the core textbook with supplementary reference materials intended to support implementation, review, and further study.
Core Textbook — PDF and TXT contains the 100-chapter reference covering GPU architecture, low-level optimization, parallel algorithms, and production systems. A sample chapter provides a preview of the book's technical approach.
The Blackwell CUDA Blueprint presents architectural diagrams and a technical overview of Blackwell-related design concepts and GPU interconnects. NVIDIA CUDA Architecture Features & Optimization Techniques provides a comparative reference across GPU generations, while CUDA & Blackwell Architecture Executive Briefing summarizes performance models and scaling considerations.
Advanced GPU Compute Fabric Architectures supplies a high-resolution architectural schematic covering GPU components such as Graphics Processing Clusters, Texture Processing Clusters, and Streaming Multiprocessors.
The bundle also includes TMA: Zero-Overhead Data Movement, a technical video exploring asynchronous transfers and synchronization, together with an Interactive Study Engine containing 79 structured flashcards for reviewing PTX, SASS, memory layouts, and consistency concepts.
High-performance GPU programming is not a matter of applying a single optimization technique. It is the process of understanding the workload, identifying the limiting resource, selecting an appropriate execution strategy, and validating the result against real hardware behavior. Mastering NVIDIA CUDA: Expert GPU Programming brings these concerns together in a broad, systems-oriented reference for developers working at the intersection of GPU architecture, scientific computing, and modern AI infrastructure.
Team Discounts
Get a team discount on this book!
Up to 3 members
Up to 5 members
Up to 10 members
Up to 15 members
Up to 25 members
About the Author
I am an independent technology developer and systems engineer who built my technical path largely through self-directed engineering, experimentation, and continuous learning outside a traditional academic or corporate technology career.
My professional background began far from the technology industry. I spent years working in manufacturing, while independently developing my knowledge of software engineering, computer systems, and advanced computing. Over time, that self-directed work evolved into a broad technical practice spanning autonomous AI, cybersecurity, systems programming, GPU computing, automation, and advanced computational architectures.
Today, I design, build, and publish projects involving agentic AI, autonomous defense systems, SIEM/EDR integration, secure software architecture, C/C++, Go, Python, CUDA, quantum computing, cryptography, and privacy-oriented local AI infrastructure.
I approach technology from a systems perspective — from low-level software, memory architecture, and GPU performance to distributed systems, intelligent agents, and high-assurance security architectures.
I also explore aerospace and high-assurance software concepts, including safety-critical architectures, multi-level security, cross-domain solutions, and advanced computational systems.
Alongside active development, I publish long-form engineering projects covering AI, cybersecurity, cloud engineering, quantum computing, GPU programming, cryptography, automation, blockchain, and aerospace engineering.
My current focus is on autonomous software agents, privacy-first local infrastructure, advanced computing, and reliable systems designed to operate with a high degree of independence.
I am open to opportunities involving AI engineering, cybersecurity, software engineering, autonomous systems, HPC/GPU computing, and advanced technology development.
https://businessofmachines.blogspot.com/
https://learn.microsoft.com/en-us/users/machinadeusex/
Click the buttons to get the free sample in PDF or EPUB, or read the sample online here
Also by the Author
Engineering Sovereign LLMs: From Data to Deployment
Agentic Cybersecurity: Engineering Autonomous AI Defense
Mastering LLM Quantization: Architecture and Code
CUDA C++: High-Performance GPU Programming
Linux GPU Drivers from Scratch
Blockchain Security: Attack and Defense
The Local AI Stack: Building a Sovereign Machine Learning Workstation with Hyper-V, WSL2, and GPU Virtualization
The Solana MEV Playbook: Building High-Frequency Arbitrage and MEV Bots in Rust
Mastering ELF: From Bytes to Execution
Building a Native LLM Inference Engine
Modern Browser Fingerprinting: Techniques and Code
Mastering AI Agents: Hands-On Production Code
Coding CERN: A Technical Developer's Guide
High-Performance Real-Time Systems in .NET
Building Advanced Algorithmic Crypto Trading Systems
Smart Contract Security: Finding DeFi Vulnerabilities
Advanced Aerospace Engineering: Lockheed & Partners
Mastering AWS: Advanced Python Engineering
Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.
See full terms...
We pay 80% royalties on purchases of $7.99 or more, and 80% royalties minus a 50 cent flat fee on purchases between $0.99 and $7.98. You earn $8 on a $10 sale, and $16 on a $20 sale. So, if we sell 5000 non-refunded copies of your book for $20, you'll earn $80,000.
(Yes, some authors have already earned much more than that on Leanpub.)
Learn more about writing on Leanpub
If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).
Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.
Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.
Learn more about Leanpub's ebook formats and where to read them
You can use Leanpub to easily write, publish and sell in-progress and completed ebooks and online courses!
Leanpub is a powerful platform for serious authors, combining a simple, elegant writing and publishing workflow with a store focused on selling in-progress ebooks.
Leanpub is a magical typewriter for authors: just write in plain text, and to publish your ebook, just click a button. (Or, if you are producing your ebook your own way, you can even upload your own PDF and/or EPUB files and then publish with one click!) It really is that easy.