[llvm-branch-commits] [llvm] [DirectX] Updating DXContainer logic to read version 1.2 of static samplers (PR #160184)

Finn Plummer via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Tue Sep 23 11:59:59 PDT 2025


================
@@ -209,6 +209,12 @@ DXContainerYAML::RootSignatureYamlDesc::create(
     NewS.RegisterSpace = S.RegisterSpace;
     NewS.ShaderVisibility = dxbc::ShaderVisibility(S.ShaderVisibility);
 
+    if (Version > 2) {
+#define STATIC_SAMPLER_FLAG(Num, Enum, Flag)                                   \
+  NewS.Enum =                                                                  \
+      (S.Flags & llvm::to_underlying(dxbc::StaticSamplerFlags::Enum)) > 0;
----------------
inbelic wrote:

nit: I think the `> 0` comparison is redundant

https://github.com/llvm/llvm-project/pull/160184


More information about the llvm-branch-commits mailing list