This revision was automatically updated to reflect the committed changes.
Closed by commit rGfc470013d13f: [Docs] Add HLSL ResourceType documentation 
(authored by beanz).

Changed prior to commit:
  https://reviews.llvm.org/D130794?vs=448699&id=450795#toc

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D130794/new/

https://reviews.llvm.org/D130794

Files:
  clang/docs/HLSL/HLSLDocs.rst
  clang/docs/HLSL/HLSLSupport.rst
  clang/docs/HLSL/ResourceTypes.rst
  clang/docs/HLSLSupport.rst
  clang/docs/index.rst


Index: clang/docs/index.rst
===================================================================
--- clang/docs/index.rst
+++ clang/docs/index.rst
@@ -46,7 +46,7 @@
    OpenCLSupport
    OpenMPSupport
    SYCLSupport
-   HLSLSupport
+   HLSL/HLSLDocs
    ThinLTO
    APINotes
    DebuggingCoroutines
Index: clang/docs/HLSL/ResourceTypes.rst
===================================================================
--- /dev/null
+++ clang/docs/HLSL/ResourceTypes.rst
@@ -0,0 +1,34 @@
+============
+HLSL Support
+============
+
+.. contents::
+   :local:
+
+Introduction
+============
+
+HLSL Resources are runtime-bound data that is provided as input, output or both
+to shader programs written in HLSL. Resource Types in HLSL provide key user
+abstractions for reading and writing resource data.
+
+Implementation Details
+======================
+
+In Clang resource types are forward declared by the ``HLSLExternalSemaSource``
+on initialization. They are then lazily completed when ``requiresCompleteType``
+is called later in Sema.
+
+Resource types are templated class declarations. The template parameter
+specifies the expected return type of resource loads, and the expected 
parameter
+type for stores.
+
+In Clang's AST and code generation, resource types are classes that store a
+pointer of the template parameter type. The pointer is populated from a call to
+``__builtin_hlsl_create_handle``, and treated as a pointer to an array of typed
+data through until lowering in the backend.
+
+Resource types are annotated with the ``HLSLResource`` attribute, which drives
+code generation for resource binding metadata. The ``hlsl`` metadata nodes are
+transformed in the backend to the binding information expected by the target
+runtime.
Index: clang/docs/HLSL/HLSLDocs.rst
===================================================================
--- /dev/null
+++ clang/docs/HLSL/HLSLDocs.rst
@@ -0,0 +1,14 @@
+.. title:: Clang HLSL Documentation
+
+.. toctree::
+   :maxdepth: 1
+
+   HLSLSupport
+
+HLSL Design and Implementation
+==============================
+
+.. toctree::
+   :maxdepth: 1
+
+   ResourceTypes


Index: clang/docs/index.rst
===================================================================
--- clang/docs/index.rst
+++ clang/docs/index.rst
@@ -46,7 +46,7 @@
    OpenCLSupport
    OpenMPSupport
    SYCLSupport
-   HLSLSupport
+   HLSL/HLSLDocs
    ThinLTO
    APINotes
    DebuggingCoroutines
Index: clang/docs/HLSL/ResourceTypes.rst
===================================================================
--- /dev/null
+++ clang/docs/HLSL/ResourceTypes.rst
@@ -0,0 +1,34 @@
+============
+HLSL Support
+============
+
+.. contents::
+   :local:
+
+Introduction
+============
+
+HLSL Resources are runtime-bound data that is provided as input, output or both
+to shader programs written in HLSL. Resource Types in HLSL provide key user
+abstractions for reading and writing resource data.
+
+Implementation Details
+======================
+
+In Clang resource types are forward declared by the ``HLSLExternalSemaSource``
+on initialization. They are then lazily completed when ``requiresCompleteType``
+is called later in Sema.
+
+Resource types are templated class declarations. The template parameter
+specifies the expected return type of resource loads, and the expected parameter
+type for stores.
+
+In Clang's AST and code generation, resource types are classes that store a
+pointer of the template parameter type. The pointer is populated from a call to
+``__builtin_hlsl_create_handle``, and treated as a pointer to an array of typed
+data through until lowering in the backend.
+
+Resource types are annotated with the ``HLSLResource`` attribute, which drives
+code generation for resource binding metadata. The ``hlsl`` metadata nodes are
+transformed in the backend to the binding information expected by the target
+runtime.
Index: clang/docs/HLSL/HLSLDocs.rst
===================================================================
--- /dev/null
+++ clang/docs/HLSL/HLSLDocs.rst
@@ -0,0 +1,14 @@
+.. title:: Clang HLSL Documentation
+
+.. toctree::
+   :maxdepth: 1
+
+   HLSLSupport
+
+HLSL Design and Implementation
+==============================
+
+.. toctree::
+   :maxdepth: 1
+
+   ResourceTypes
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to