Describes support in D3D12 for multi-engine adapter systems, covering scenarios where applications explicitly target multiple GPU adapters, and scenarios where drivers implicitly use multiple GPU adapters on behalf of an application.

Multi-adapter Overview

A GPU adapter can be any graphics adapter (including an on-board adapter), from any manufacturer, that supports D3D12.

Multiple adapters are referenced as nodes. in the API. These nodes are indexed from zero, but in the bit masks used to refer to the nodes, zero translates to bit 1, 1 to bit 2, and so on. A number of elements, such as the queues, apply to each node, so if there are two nodes, there will be two default 3D queues. Other elements, such as the pipeline state and root and command signatures, can refer to one or more or all of the nodes, as shown in the following diagram.

queues apply to each graphics adapter

Sharing heaps across adapters

Refer to the Shared Heaps section.

Multi-adapter APIs

Similar to previous D3D APIs, each set of linked adapters is enumerated as a single IDXGIAdapter3 object. All outputs attached to any adapter in the link are enumerated as attached to the single IDXGIAdapter3 object.

Single nodes

Applications can determine the number of physical adapters associated with a given device with a call to ID3D12Device::GetNodeCount. Many APIs in D3D12 accept a NodeMask, which indicates the set of nodes which the API call refers to.

When calling the following (single node) APIs, applications specify a single node that the API call will be associated with. Most of the time this is specified by a NodeMask. Each bit in the mask corresponds to a single node. For all of the APIs described in this section, exactly 1 bit must be set in the NodeMask.

Multiple nodes

When calling the following APIs, applications specify a set of nodes that the API call will be associated with. Node affinity is specified as a bit mask. If the application passes 0 for the bit mask, then the D3D12 driver converts this to the bit mask 1 (indicating that the object is associated with node 0).

Resource creation APIs

The following APIs reference node masks:

When creating reserved resource no node index or mask is specified. The reserved resource can be mapped onto a heap on any node (following the cross-node sharing rules).

The method MakeResident works internally with adapter queues, there is no need for the application to specify anything for this.

When calling the following ID3D12Device APIs, applications do not need to specify a set of nodes that the API call will be associated with because the API call applies to all nodes:

Multi-engine and multi-adapter synchronization