From beda0f192362fc907358ee367fc8c04460e7e1f1 Mon Sep 17 00:00:00 2001 From: Alexander Kornienko Date: Fri, 10 Feb 2017 17:00:27 +0000 Subject: [PATCH] Add a virtual destructor for LegalizerInfo. lib/Target/X86/X86TargetMachine.cpp has a code that deletes an instance of a LegalizerInfo descendant via a pointer to base. llvm-svn: 294757 --- llvm/include/llvm/CodeGen/GlobalISel/LegalizerInfo.h | 1 + 1 file changed, 1 insertion(+) diff --git a/llvm/include/llvm/CodeGen/GlobalISel/LegalizerInfo.h b/llvm/include/llvm/CodeGen/GlobalISel/LegalizerInfo.h index 4a9e535090ce..079b77252723 100644 --- a/llvm/include/llvm/CodeGen/GlobalISel/LegalizerInfo.h +++ b/llvm/include/llvm/CodeGen/GlobalISel/LegalizerInfo.h @@ -96,6 +96,7 @@ public: }; LegalizerInfo(); + virtual ~LegalizerInfo() = default; /// Compute any ancillary tables needed to quickly decide how an operation /// should be handled. This must be called after all "set*Action"methods but