Don't leak CodeGenInfos.

llvm-svn: 135555
This commit is contained in:
Benjamin Kramer 2011-07-20 01:27:58 +00:00
parent 2262d28bab
commit cc38ef6d84
1 changed files with 3 additions and 1 deletions

View File

@ -202,7 +202,8 @@ FunctionSections("ffunction-sections",
TargetMachine::TargetMachine(const Target &T,
StringRef TT, StringRef CPU, StringRef FS)
: TheTarget(T), TargetTriple(TT), TargetCPU(CPU), TargetFS(FS), AsmInfo(0),
: TheTarget(T), TargetTriple(TT), TargetCPU(CPU), TargetFS(FS),
CodeGenInfo(0), AsmInfo(0),
MCRelaxAll(false),
MCNoExecStack(false),
MCSaveTempLabels(false),
@ -215,6 +216,7 @@ TargetMachine::TargetMachine(const Target &T,
}
TargetMachine::~TargetMachine() {
delete CodeGenInfo;
delete AsmInfo;
}