Files
clang-p2996/clang/docs/HLSL/HLSLIRReference.rst
Chris Bieneman d20f9f8d21 [Docs] [HLSL] Add IR reference for HLSL
HLSL uses a variety of named IR metadata and attributes to convey
additional information from the frontend to the backend. This document
tries to capture and document the named annotations to provide a
reference for future contributors.

Reviewed By: python3kgae

Differential Revision: https://reviews.llvm.org/D134304
2022-09-23 10:29:54 -05:00

32 lines
672 B
ReStructuredText

=================
HLSL IR Reference
=================
.. contents::
:local:
Introduction
============
The goal of this document is to provide a reference for all the special purpose
IR metadata and attributes used by the HLSL code generation path.
IR Metadata
===========
``hlsl.uavs``
-------------
The ``hlsl.uavs`` metadata is a list of all the external global variables that
represent UAV resources.
Function Attributes
===================
``hlsl.shader``
---------------
The ``hlsl.shader`` function attribute is a string attribute applied to entry
functions. The value is the string representation of the shader stage (i.e.
``compute``, ``pixel``, etc).