[clang] [HLSL] Change default linkage of HLSL functions and groupshared variables (v2) (PR #95331)
Helena Kotas via cfe-commits
cfe-commits at lists.llvm.org
Thu Aug 1 15:20:30 PDT 2024
================
@@ -119,3 +119,16 @@ behavior between Clang and DXC. Some examples include:
diagnostic notifying the user of the conversion rather than silently altering
precision relative to the other overloads (as FXC does) or generating code
that will fail validation (as DXC does).
+
+Correctness improvements (bug fixes)
+====================================
+
+Entry point functions & ``static`` keyword
+------------------------------------------
+Marking a shader entry point function ``static`` will result in an error.
+
+This is identical to DXC behavior when an entry point is specified as compiler
+argument. However, DXC does not report an error when compiling a shader library
+that has an entry point function with ``[shader("stage")]`` attribute that is
+also marked ``static``. Additionally, this function definition is not included
+in the final DXIL.
----------------
hekota wrote:
Right, we are currently producing just warnings. I have filed an issue to make sure we always report an error when a shader entry point is not found of it is marked static: llvm/llvm-project#101571.
https://github.com/llvm/llvm-project/pull/95331
More information about the cfe-commits
mailing list