[llvm] [DXIL] Define and generate `DXILAttribute` and `DXILProperty` (PR #117072)
Finn Plummer via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 22 10:25:23 PST 2024
================
@@ -396,19 +396,16 @@ static void emitDXILProperties(const RecordKeeper &Records, raw_ostream &OS) {
OS << "#endif\n\n";
}
-static void emitDXILPropertyHelpers(const RecordKeeper &Records,
- raw_ostream &OS) {
- // Generate their helper functions
- for (const Record *Prop : Records.getAllDerivedDefinitions("DXILProperty")) {
- OS << "[[maybe_unused]]\n";
- OS << "static bool has" << Prop->getName() << "(dxil::OpCode Op) {\n";
- OS << " auto *OpCodeProp = getOpCodeProperty(Op);\n";
- OS << " for (auto Prop : OpCodeProp->Properties)\n";
- OS << " if (Prop == dxil::Property::" << Prop->getName() << ")\n";
- OS << " return true;\n";
- OS << " return false;\n";
- OS << "}\n\n";
- }
+static void emitDXILPropertyHelper(raw_ostream &OS) {
----------------
inbelic wrote:
This won't be tested until we use it in https://github.com/llvm/llvm-project/issues/114565. So we could wait until there to implement this
https://github.com/llvm/llvm-project/pull/117072
More information about the llvm-commits
mailing list