[llvm] [VPlan] Separate out logic to manage IR flags to VPIRFlags (NFC). (PR #140621)
via llvm-commits
llvm-commits at lists.llvm.org
Sun May 25 07:20:37 PDT 2025
================
@@ -851,11 +802,60 @@ class VPRecipeWithIRFlags : public VPSingleDefRecipe {
return DisjointFlags.IsDisjoint;
}
+#if !defined(NDEBUG)
+ /// Returns true if the set flags are valid for \p Opcode.
+ bool flagsValidForOpcode(unsigned Opcode) const;
+#endif
+
#if !defined(NDEBUG) || defined(LLVM_ENABLE_DUMP)
void printFlags(raw_ostream &O) const;
#endif
};
+/// A pure-virtual common base class for recipes defining a single VPValue and
+/// using IR flags.
+struct VPRecipeWithIRFlags : public VPSingleDefRecipe, public VPIRFlags {
----------------
ayalz wrote:
This retains existing name, but perhaps `VPSingleDefWithIRFlags` would be more accurate, following its documentation above. Or `VPSingleDefWithFlags`, considering IR Flags are wrapped in VPIRFlags (along with condition predicates and potentially other constants).
https://github.com/llvm/llvm-project/pull/140621
More information about the llvm-commits
mailing list