================
@@ -0,0 +1,139 @@
+=============================
+HLSL Availability Diagnostics
+=============================
+
+.. contents::
+   :local:
+
+Introduction
+============
+
+HLSL availability diagnostics emits errors or warning when unavailable shader 
APIs are used. Unavailable shader APIs are APIs that are exposed in HLSL code 
but are not available in the target shader stage or shader model version.
+
+There are three modes of HLSL availability diagnostic:
+
+#. **Default mode** - compiler emits an error when an unavailable API is found 
in a code that is reachable from the shader entry point function or from an 
exported library function (when compiling a shader library)
+
+#. **Relaxed mode** - same as default mode except the compiler emits a 
warning. This mode is enabled by ``-Wno-error=hlsl-availability``.
+
+#. **Strict mode** - compiler emits an error when an unavailable API is found 
in parsed code regardless of whether it can be reached from the shader entry 
point or exported functions, or not. This mode is enabled by 
``-fhlsl-strict-diagnostics``.
----------------
llvm-beanz wrote:

nit: maybe we should name this flag `-fhlsl-strict-availability`, which more 
clearly associates it with availability rather than more general diagnostics.

https://github.com/llvm/llvm-project/pull/92207
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to