aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/ADT/Statistic.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-06-21 16:53:47 +0000
committerChris Lattner <sabre@nondot.org>2006-06-21 16:53:47 +0000
commit70aa33ee37fede7fb84de02daa38557ffd366458 (patch)
tree9f7faee50e86f0107e468ece963a7d71e8c3cbeb /include/llvm/ADT/Statistic.h
parent0ad19703aef030ff92c7ccd28b741dc2da086e10 (diff)
downloadexternal_llvm-70aa33ee37fede7fb84de02daa38557ffd366458.zip
external_llvm-70aa33ee37fede7fb84de02daa38557ffd366458.tar.gz
external_llvm-70aa33ee37fede7fb84de02daa38557ffd366458.tar.bz2
Add some out-of-line virtual dtors so that the class has a "home", preventing
vtables for (e.g.) Instruction from being emitted into every .o file. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28898 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/ADT/Statistic.h')
-rw-r--r--include/llvm/ADT/Statistic.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/llvm/ADT/Statistic.h b/include/llvm/ADT/Statistic.h
index 69406ac..dabacf4 100644
--- a/include/llvm/ADT/Statistic.h
+++ b/include/llvm/ADT/Statistic.h
@@ -37,7 +37,8 @@ protected:
StatisticBase(const char *name, const char *desc) : Name(name), Desc(desc) {
++NumStats; // Keep track of how many stats are created...
}
- virtual ~StatisticBase() {}
+ // Out of line virtual dtor, to give the vtable etc a home.
+ virtual ~StatisticBase();
// destroy - Called by subclass dtor so that we can still invoke virtual
// functions on the subclass.