[llvm] [DirectX] Infrastructure to collect shader flags for each function (PR #112967)
Chris B via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 18 13:39:23 PST 2024
================
@@ -60,21 +62,54 @@ struct ComputedShaderFlags {
return FeatureFlags;
}
- static ComputedShaderFlags computeFlags(Module &M);
+ uint64_t getModuleFlags() const {
+ uint64_t ModuleFlags = 0;
+#define DXIL_MODULE_FLAG(DxilModuleBit, FlagName, Str) \
+ ModuleFlags |= FlagName ? getMask(DxilModuleBit) : 0ull;
----------------
llvm-beanz wrote:
We have this exact expansion inside the `operator uint64_t` definition above. Should we maybe refactor this so that one uses the other instead of duplicating the expansion?
https://github.com/llvm/llvm-project/pull/112967
More information about the llvm-commits
mailing list