From 64f1d845b3823b0a9e0b0344416f9032d38bde9c Mon Sep 17 00:00:00 2001 From: Florian Hahn Date: Mon, 2 Jan 2023 17:32:31 +0000 Subject: [PATCH] [VPlan] Use VP_CLASSOF_IMPL for VPWidenMemoryInstructionRecipe (NFC). Replace VPWidenMemoryInstructionRecipe ::classof implementation with general VP_CLASSOF_IMPL. --- llvm/lib/Transforms/Vectorize/VPlan.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/llvm/lib/Transforms/Vectorize/VPlan.h b/llvm/lib/Transforms/Vectorize/VPlan.h index a535ed6..9d38b4d 100644 --- a/llvm/lib/Transforms/Vectorize/VPlan.h +++ b/llvm/lib/Transforms/Vectorize/VPlan.h @@ -1701,10 +1701,8 @@ public: setMask(Mask); } - /// Method to support type inquiry through isa, cast, and dyn_cast. - static inline bool classof(const VPDef *D) { - return D->getVPDefID() == VPRecipeBase::VPWidenMemoryInstructionSC; - } + VP_CLASSOF_IMPL(VPRecipeBase::VPWidenMemoryInstructionSC, + VPValue::VPVMemoryInstructionSC) /// Return the address accessed by this recipe. VPValue *getAddr() const { -- 2.7.4