[weak vtables] Remove a bunch of weak vtables

This patch removes most of the trivial cases of weak vtables by pinning them to
a single object file. The memory leaks in this version have been fixed. Thanks
Alexey for pointing them out.

Differential Revision: http://llvm-reviews.chandlerc.com/D2068

Reviewed by Andy

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@195064 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Juergen Ributzka
2013-11-19 00:57:56 +00:00
parent 26efdc5621
commit 354362524a
113 changed files with 506 additions and 152 deletions

View File

@@ -105,10 +105,13 @@ static int gettok() {
/// ExprAST - Base class for all expression nodes.
class ExprAST {
public:
virtual ~ExprAST() {}
virtual ~ExprAST();
virtual Value *Codegen() = 0;
};
// Provide out-of-line definition to prevent weak vtable.
ExprAST::~ExprAST() {}
/// NumberExprAST - Expression class for numeric literals like "1.0".
class NumberExprAST : public ExprAST {
double Val;