[llvm] [DirectX] Infrastructure to collect shader flags for each function (PR #112967)
S. Bharadwaj Yadavalli via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 22 08:25:50 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;
----------------
bharadwajy 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?
Refactored.
https://github.com/llvm/llvm-project/pull/112967
More information about the llvm-commits
mailing list