You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: llvm/docs/DirectX/DXContainer.rst
+15-15Lines changed: 15 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -496,17 +496,24 @@ signature and passed to the shader without requiring a constant buffer resource:
496
496
#. **RegisterSpace**: The register space used for the binding.
497
497
#. **Num32BitValues**: The number of 32-bit values included in this constant buffer.
498
498
499
-
Root constants provide a fast way to pass small amounts of data directly to the shader without the overhead of creating and binding a constant buffer resource.
499
+
Root constants provide a fast way to pass small amounts of data directly to the shader without the
500
+
overhead of creating and binding a constant buffer resource.
500
501
501
502
Root Descriptor
502
503
~~~~~~~~~~~~~~~
503
504
504
-
Root descriptors provide a direct mechanism for binding individual resources to shader stages in the Direct3D 12
505
-
rendering pipeline. They represent a critical interface for efficient resource management, allowing applications
506
-
to specify how shader stages access specific GPU resources.
505
+
Root descriptors provide a mechanism for binding individual resources to shader stages in the Direct3D 12
506
+
rendering pipeline. They allow applications to specify how shader stages access specific GPU resources.
507
507
508
508
.. code-block:: cpp
509
509
510
+
enum RootDescriptorFlags {
511
+
None = 0,
512
+
DataVolatile = 0x2,
513
+
DataStaticWhileSetAtExecute = 0x4,
514
+
DataStatic = 0x8,
515
+
}
516
+
510
517
// Version 1.0 Root Descriptor
511
518
struct RootDescriptor_V1_0 {
512
519
uint32_t ShaderRegister;
@@ -516,21 +523,14 @@ to specify how shader stages access specific GPU resources.
516
523
// Version 1.1 Root Descriptor
517
524
struct RootDescriptor_V1_1 {
518
525
uint32_t ShaderRegister;
519
-
uint32_t RegisterSpace;
520
-
// New flags for Version 1.1
521
-
enum Flags {
522
-
None = 0x0,
523
-
DATA_STATIC = 0x1,
524
-
DATA_STATIC_WHILE_SET_AT_EXECUTE = 0x2,
525
-
DATA_VOLATILE = 0x4
526
-
};
527
-
526
+
uint32_t RegisterSpace;
528
527
// Bitfield of flags from the Flags enum
529
528
uint32_t Flags;
530
529
};
531
530
532
-
The Root Descriptor structure has evolved to support two versions, providing enhanced flexibility and
533
-
performance optimization capabilities.
531
+
Version 1.1 of Root Descriptors has introduced some flags that can hint the drivers into
532
+
performing further code optimizations. For details, check
533
+
`Direct X documentation <https://learn.microsoft.com/en-us/windows/win32/direct3d12/root-signature-version-1-1#static-and-volatile-flags>`_.
0 commit comments