[llvm] [VPlan] Introduce VPSingleDefRecipe. (PR #77023)
via llvm-commits
llvm-commits at lists.llvm.org
Sun Jan 7 10:58:29 PST 2024
================
@@ -819,10 +810,77 @@ class VPRecipeBase : public ilist_node_with_parent<VPRecipeBase, VPBasicBlock>,
} \
static inline bool classof(const VPRecipeBase *R) { \
return R->getVPDefID() == VPDefID; \
+ } \
+ static inline bool classof(const VPSingleDefRecipe *R) { \
+ return R->getVPDefID() == VPDefID; \
}
+/// A common base class for recipes defining a single result value.
----------------
ayalz wrote:
The comment documenting VPRecipeBase above should probably move here, and possibly rephrased:
```
/// Single-value
/// VPRecipeBases that also inherit from VPValue must make sure to inherit from
/// VPRecipeBase before VPValue.
```
https://github.com/llvm/llvm-project/pull/77023
More information about the llvm-commits
mailing list