Cognibiz

CUDA Toolkit 12.6 and cuDNN 9.x: from a program to GPU computationnvidia.com

AI technologies, organized by technology area.

Nsight Compute: analysis of a CUDA kernel, as published in NVIDIA’s 2024.3 documentation.Inset: Educational schematic, without performance measurements. cuDNN is a separate specialized library: not every CUDA kernel uses it.Credit and source

The sketch explained

CUDA: distributing work across the GPU

The CPU program launches a kernel. CUDA organizes its threads into blocks, which are distributed across GPU compute resources. Arrows show the launch and production of results.

On a small screen, scroll the diagram horizontally to read its labels.

CUDA: distributing work across the GPUCPU program · NVIDIA GPU · Thread blocks · ResultsCPUprogramNVIDIA GPUThread blocksResults
CPU program
The program prepares data and launches work on the GPU.
NVIDIA GPU
The GPU executes kernel threads using available resources.
Thread blocks
Each rectangle groups a few threads represented by dots; their number is illustrative.
Results
Results are produced on the GPU. Returning them to the CPU may require a transfer.
Educational schematic, without performance measurements. cuDNN is a separate specialized library: not every CUDA kernel uses it.Technical documentation
Updated

UNDERSTANDING THE SYSTEM

CUDA Toolkit 12.6 and cuDNN 9.x: from a program to GPU computation

CUDA organizes parallel computation on NVIDIA GPUs; cuDNN supplies specialized implementations for neural networks. Their effectiveness depends on transfers, tensor layouts and plan selection as well as compute units. This dossier fixes its scope at CUDA Toolkit 12.6.0 and cuDNN 9.5.0, explains their contracts and provides a documented measurement protocol without claiming experimental results.

02 / CHAPTER

Pin versions before discussing compatibility

The original listing names CUDA Toolkit v12.6 and cuDNN v9.x. A 9.x family is not a reproducible configuration: this dossier selects cuDNN 9.5.0 for CUDA 12.x and the CUDA Toolkit 12.6.0 archive, preserving that provenance without calling them current releases. The 9.5.0 support matrix explicitly lists CUDA 12.6; NVIDIA recommends this pairing for Volta and later architectures in the context of tuning its heuristics. This recommendation promises no improvement for every network.

The NVIDIA driver provides access to the GPU and loads device code. The CUDA runtime supplies application services such as allocation and kernel launches. The Toolkit adds the nvcc compiler, headers, libraries and tools; cuDNN is a separate library, used directly or through a framework such as PyTorch. A prebuilt executable may carry its dependencies without needing the local development Toolkit; compiling a CUDA extension changes those prerequisites. The version shown by nvidia-smi describes driver capability, not proof that this Toolkit is installed.

Distinguish the driver associated with CUDA 12.6 GA, the CUDA 12.x minor compatibility floor and the minimum listed by cuDNN. The archives give different Windows thresholds, reproduced below rather than merged. Meeting the most demanding component threshold is necessary, but newer features and just-in-time PTX compilation may still require a newer driver. Include operating system, CPU architecture and GPU in the qualification matrix.

Pin versions before discussing compatibility
Documented contractLinux x86_64Windows x86_64
Driver associated with CUDA 12.6 GA≥ 560.28.03≥ 560.76
CUDA 12.x minor compatibility, 12.6.0 notes≥ 525.60.13≥ 528.33
cuDNN 9.5.0 / CUDA 12.x matrix minimum≥ 525.60.13≥ 527.41

References for this chapter[1][2][3][4]

03 / CHAPTER

Connect threads to the GPU and Tensor Cores

A kernel is a function executed on the GPU by many threads. CUDA groups threads into blocks, then blocks into a grid. Blocks are assigned to Streaming Multiprocessors, or SMs; threads within a block can cooperate through shared memory and explicit synchronization. A warp groups 32 threads in this NVIDIA model. A thread, block or stream is not a hardware core reserved for the application.

Tensor Cores are hardware units specializing in certain matrix operations; they are not another Toolkit version. Their use depends on GPU generation, numerical type, dimensions, memory layout and the selected implementation. A cuDNN convolution may use such an implementation, whereas an elementwise transformation kernel may use other units. Installing cuDNN therefore does not turn every instruction into a Tensor Cores operation.

Compute capability identifies hardware features and compilation targets; the CUDA version identifies a software stack. Check both. A program may expose too little parallelism, wait on memory or spend too much time between small launches even on a powerful GPU. SM occupancy can help diagnose some cases, but maximizing it is not an independent objective: register pressure and shared memory per block change the tradeoffs.

References for this chapter[5][11]

04 / CHAPTER

Order copies and kernels without equating asynchrony with concurrency

A stream is an ordered sequence of operations. Within one stream, an input copy precedes the kernel that consumes it, followed by an output copy. A launch returning to the CPU usually means work was submitted, not completed. Wait for an event or appropriate synchronization before reading a result on the host or reusing a buffer still involved in processing.

Two streams may allow one batch to compute while another is transferred, provided the data is independent and the GPU has the resources. The application expresses cross-stream dependencies with events and waits; it must also preserve allocation lifetimes. A device-wide wait after every operation removes the intended overlap. The default stream has specific rules, including legacy and per-thread modes: do not assume one universal behavior.

An Async suffix alone does not guarantee a nonblocking call in every situation. The 12.6 reference distinguishes pageable host memory from page-locked, or pinned, memory; staging or resource shortages may block execution. Confirm copy/compute overlap in a trace rather than infer it from the number of streams. The drawings below represent possible dependencies, without a time scale or measured throughput.

Submit, compute, make available

Two independent batches A and B. Blocks and arrows represent ordering and possible overlap; their dimensions encode no measured time.

  1. Copy the inputs

    The transfer of A must finish before its computation. A pinned host buffer supports asynchronous transfers and remains valid until its copy completes.

  2. Overlap conditionally

    Computing A may coexist with copying B in another stream. The arrows preserve each batch’s dependency; simultaneous execution is not guaranteed.

  3. Wait for the right result

    An event marks completion of the tracked work. The CPU consumes output after the required copy and wait, then safely reuses the buffer.

References for this chapter[6][7][8][9]

05 / CHAPTER

Budget memory and describe tensor layouts

GPU memory holds weights, inputs, outputs, activations and temporary storage. Training adds gradients and optimizer state; its budget differs from inference. An allocator cache may retain reserved memory after a tensor disappears. When investigating an out-of-memory error, distinguish live allocations, allocator reservation, other processes and the workspace requested by the selected plan.

GPU global memory, block shared memory and pinned host memory have different roles. Unified Memory manages accessible storage according to system capabilities, but does not eliminate migration, page faults or contention. A common virtual address does not establish common bandwidth. Start by keeping useful intermediates on the GPU, batching small copies and measuring access patterns before multiplying buffers.

A tensor descriptor specifies dimensions, type and strides: the steps between elements. NCHW and NHWC describe layouts, not two different mathematical models. A conversion may help one operation yet cost more across the network if repeatedly introduced. The table calculates only the raw size of the same hypothetical dense tensor: it includes no outputs, workspace, alignment overhead or allocator costs.

Budget memory and describe tensor layouts
Hypothetical dense tensorByte calculationRaw size
32 × 64 × 56 × 56 in FP3232 × 64 × 56 × 56 × 425 690 112 B = 24.5 MiB
32 × 64 × 56 × 56 in FP1632 × 64 × 56 × 56 × 212 845 056 B = 12.25 MiB
32 × 64 × 56 × 56 in INT832 × 64 × 56 × 56 × 16 422 528 B = 6.125 MiB

References for this chapter[10][11][9]

06 / CHAPTER

Turn a cuDNN graph into an eligible execution plan

The cuDNN graph API describes operations and their tensors; that graph may represent part of a network. The library then seeks an engine and configuration to execute it. A convolution followed by bias and activation may be fused when the pattern and hardware are supported. Fusion can avoid intermediate writes and launches; it is not guaranteed for every graph or layout.

A heuristic query proposes configurations ranked by expected performance. Before selecting one, check graph support, workspace, numerical properties, required determinism and any compilation prerequisites. Autotuning times eligible candidates for the specific problem and GPU. Its initial cost can be worthwhile for recurring shapes and disproportionate for shapes that continually change.

An execution plan binds the graph to a concrete configuration. Execution then receives the required data pointers and workspace. Selection must account for memory already occupied and concurrent requests, rather than only an isolated run. A cuDNN graph should not be confused with a CUDA Graph, which organizes submission of CUDA work. The new native CUDA Graph API in cuDNN 9.5.0 covers only selected engines: it makes neither fusion nor capture universal.

A plan is a constrained choice

Conceptual plan-selection diagram. The three candidate drawings are symbolic: they imply no actual engine identifiers, numerical ranking or benchmark result.

  1. Describe the problem

    The graph specifies operations; tensors fix shapes, strides and types. Changing these parameters may change the eligible implementations.

  2. Filter the candidates

    Check support, workspace and numerical rules before comparing. A candidate excluded by the memory budget does not become acceptable because it might be fast.

  3. Build, then measure

    The selected plan runs with the correct pointers and temporary storage. Measure preparation and real shapes too; retain a fallback.

References for this chapter[12][11][14]

07 / CHAPTER

Define numerical quality and reproducibility

The stored type does not fully describe computation. An engine may use another accumulation precision or internal conversions; cuDNN numerical notes identify these properties. TensorFloat-32, or TF32, allows matrix computation with FP32 inputs rounded under its rules and FP32 accumulation on compatible GPUs. Do not equate that path with FP32 multiplication retaining the full input mantissa.

FP16, BF16 and FP8 have different ranges and precision. Reducing bit width requires checking errors, extreme values and, during training, gradient stability. Numerical tolerance follows the problem; model quality needs evaluation on representative data. Halving the raw size in the memory table promises neither half the latency nor unchanged quality.

Determinism concerns repeatability for a given configuration. A variable order of floating-point additions may alter the last bits; setting a random seed does not fix that. cuDNN documents exceptions and does not guarantee bitwise identity between different architectures. Filtering nondeterministic engines and disabling autotuning are distinct decisions. Record versions, GPU, settings and tolerances alongside the result.

Computation contract
Document input, storage and accumulation types, together with permitted conversions.
Quality contract
Compare reference outputs, then an application metric on representative data.
Repeatability contract
Specify whether a tolerance is sufficient or bitwise repeatability is required in a fixed environment.

References for this chapter[13][12][16]

08 / CHAPTER

Measure an explicit scope rather than a Python call

A CPU clock around an asynchronous launch mainly measures submission. For GPU time, place events in the relevant stream and wait for the final event before reading the interval. Separate warm-up, plan construction and steady-state measurements. Concurrent work may interleave and extend that interval; an event does not isolate the GPU. For service latency, separately measure the complete pipeline, including queues and transfers.

The documentary example below uses APIs described in PyTorch 2.6 and guards requiring a CUDA 12.6 build and cuDNN 9.5.0 already available. It offers neither installation instructions nor a promised prebuilt package for this combination. Inputs are constant; every expected output is 1 because 16 × 3 × 3 contributions are weighted by their reciprocal. This simple check validates output and shape before timing without demonstrating the quality of a real model.

The code measures nine series of one hundred convolutions after thirty warm-ups, with data already on the GPU, no gradients, no TF32 and a deterministic cuDNN choice. The median summarizes series averages, not individual request latencies. Output allocation and the framework’s submission pace can contribute to the interval. Host copies, loading and preparation are outside scope. No output numbers were produced for this dossier; a trace is still needed to confirm the implementation actually used.

import statistics
import torch

assert torch.cuda.is_available()
assert torch.version.cuda == "12.6"
assert torch.backends.cudnn.is_available()
assert torch.backends.cudnn.version() == 90500
torch.backends.cudnn.enabled = True
torch.backends.cudnn.benchmark = False
torch.backends.cudnn.deterministic = True
torch.backends.cudnn.allow_tf32 = False
torch.backends.cuda.matmul.allow_tf32 = False

device = torch.device("cuda:0")
torch.cuda.set_device(device)
x = torch.ones((8, 16, 64, 64), device=device)
conv = torch.nn.Conv2d(16, 32, 3, bias=False).to(device).eval()
with torch.no_grad():
    conv.weight.fill_(1.0 / (16 * 3 * 3))

samples_ms = []
with torch.inference_mode():
    for _ in range(30):
        y = conv(x)
    torch.cuda.synchronize(device)
    assert y.shape == (8, 32, 62, 62)
    torch.testing.assert_close(y, torch.ones_like(y), rtol=1e-4, atol=1e-5)
    torch.cuda.synchronize(device)
    start = torch.cuda.Event(enable_timing=True)
    end = torch.cuda.Event(enable_timing=True)
    for _ in range(9):
        start.record()
        for _ in range(100):
            y = conv(x)
        end.record()
        end.synchronize()
        samples_ms.append(start.elapsed_time(end) / 100)

print({"PyTorch": torch.__version__, "CUDA_build": torch.version.cuda,
       "cuDNN": torch.backends.cudnn.version(),
       "GPU": torch.cuda.get_device_name(device),
       "median_ms": statistics.median(samples_ms),
       "min_ms": min(samples_ms), "samples_ms": samples_ms})
Protocol example to review in an already qualified environment; not run here. Printed values would be local observations in milliseconds, not advertised CUDA or cuDNN performance.

References for this chapter[15][16][8]

09 / CHAPTER

Diagnose the system before optimizing a kernel

Start with a timeline: CPU preparation, copies, launches, GPU time, synchronization and idle gaps. Nsight Systems helps inspect this orchestration; Nsight Compute examines a kernel and its memory or compute constraints. An expensive multiplication may deserve attention, but a long CPU queue or repeated copy may explain more of the experienced latency. Instrumentation itself adds overhead: keep baseline measurements separate.

An asynchronous error may surface at a later call, such as synchronization; the reporting line is not necessarily the cause. Reduce the case and check sizes, pointers, lifetimes and graph support before arbitrarily changing versions. A debugging mode that forces synchronization can help localize a fault, but its timings should not become the production benchmark.

The 9.5.0 release notes describe concrete restrictions: some normalization engines are unsupported in GRAPH_JIT_ONLY configuration, and the new native CUDA Graph API is limited to selected engines. An unsupported status therefore does not necessarily mean GPU failure. Keeping the error message, loaded-library versions and a small reproducible graph helps distinguish a missing dependency, a functional limitation and an application defect.

Waiting for data
Look for undersized copies, storage reads and CPU preprocessing on the critical path.
Memory pressure
Inspect workspace, shapes, concurrent allocations and layout conversions before randomly reducing batch size.
Launch overhead
Group operations or evaluate a CUDA Graph when the pattern allows it; check the benefit for the whole service.

References for this chapter[9][14][6]

10 / CHAPTER

Choose an integration level and qualify deployment

For a standard model, starting with the framework and its qualified libraries often provides cuDNN benefits without directly managing descriptors. The cuDNN graph API becomes relevant when a subgraph, its memory constraints or its fusions require precise control. A custom CUDA kernel suits an unsupported operation or a demonstrated bottleneck; it also incurs compilation, numerical validation and maintenance work for each architecture.

CUDA targets NVIDIA GPUs; a framework API does not automatically make application code portable. Evaluating another hardware stack requires checking operators, extensions, types and protocol on that target. For deployment, pin the image or environment, actual loaded libraries, host driver, target GPUs and test data. A container does not replace the host driver or make inconsistent versions compatible.

Useful qualification compares cold start, sustained throughput, loaded latency, peak memory and output quality on the shapes actually expected. Also test falling back to a compatible plan when the fastest one no longer fits the budget. This dossier explains a precisely documented historical configuration; it does not recommend deploying a 2024 stack into a 2026 service without reassessment. The decision concerns a verified software and hardware combination, not the CUDA name alone.

References for this chapter[1][2][12][4]

ORIGINAL DOCUMENT

Catalog record

2. Low-level software, compilers and training frameworks

Nvidia nvidia.com CUDA Toolkit v12.6 & cuDNN v9.x — Innovation: 9, Adoption: 10

9/10Innovation
10/10Adoption

Editorial source: Taxonomie des Technologies d'Intelligence Artificielle · § 5700. Addresses restored with dots; innovation and adoption scores remain those of the document.

VERIFY AND EXPLORE

References

NVIDIA 12.6.0 and 9.5.0 archives accessed on November 4, 2026. PyTorch 2.6 documentation is used solely to explain the example APIs. No GPU, package, container or cloud service was installed, reserved or run for this dossier.

  1. 01
    CUDA Toolkit 12.6.0 — release notes

    Individual component versions; separate tables for the associated driver and minor compatibility thresholds.

    docs.nvidia.com ·
  2. 02
    cuDNN 9.5.0 — support matrix

    Explicit CUDA 12.6 pairing, Volta+ recommendation and system requirements; Windows floor differs from CUDA notes.

    docs.nvidia.com ·
  3. 03
    CUDA 12.6 — driver and runtime APIs

    Responsibilities and context management; distinguishes development environment from execution services.

    docs.nvidia.com ·
  4. 04
    CUDA — minor version compatibility

    Conditions for new features, PTX and compiled targets. Current general page; historical numbers come from archives.

    docs.nvidia.com ·
  5. 05
    CUDA 12.6 — programming guide

    Threads, blocks, grids, SMs, warps, memory and concurrency rules; capabilities depend on hardware.

    docs.nvidia.com ·
  6. 06
    CUDA 12.6 — synchronization behavior

    Details exceptions to the Async suffix, pageable memory and asynchronous launches.

    docs.nvidia.com ·
  7. 07
    CUDA 12.6 — stream management

    Reference for streams, waits and synchronization; logical order differs from simultaneous execution.

    docs.nvidia.com ·
  8. 08
    CUDA 12.6 — events

    Recording, waiting and interval calculation; concurrent work can affect timing.

    docs.nvidia.com ·
  9. 09
    CUDA 12.6 — best practices

    Transfers, pinned memory, conditional overlap and profiling approach; no old hardware performance figures are reused.

    docs.nvidia.com ·
  10. 10
    CUDA 12.6 — memory management

    Allocations, copies and managed memory; behavior depends on capabilities and system.

    docs.nvidia.com ·
  11. 11
    cuDNN 9.5.0 — core concepts

    Handles, descriptors, dimensions and strides; distinguishes tensor contents from memory layout.

    docs.nvidia.com ·
  12. 12
    cuDNN 9.5.0 — graph API

    Operations, engines, heuristics, numerical filtering, fusion and plans; distinguishes cuDNN graphs from CUDA Graph.

    docs.nvidia.com ·
  13. 13
    cuDNN 9.5.0 — configuration and reproducibility

    Sub-libraries and repeatability limits, especially across architectures.

    docs.nvidia.com ·
  14. 14
    cuDNN 9.5.0 — release notes

    Features and known issues specific to 9.5.0; later capabilities do not apply to every 9.x release.

    docs.nvidia.com ·
  15. 15
    PyTorch 2.6 — CUDA semantics

    Documentary example APIs, asynchronous operations, events and TF32 control; no installation performed.

    docs.pytorch.org ·
  16. 16
    PyTorch 2.6 — backends

    cuDNN controls, availability, autotuning and determinism; allowing a library does not prove that it is used.

    docs.pytorch.org ·

Catalog provenance

Taxonomie des Technologies d'Intelligence Artificielle · Google Docs

Source document consulted on . § 5700.

Websites cited in the record

A website’s inclusion in the catalog does not verify the versions, projections or results mentioned in the document.

FROM KNOWLEDGE TO PROJECT

Apply this knowledge to your context.

Scope, architecture, roadmap and notes: keep your decisions in the dedicated space.

Open dedicated space