From 377e12cf75b33e41a8b59d2d620f6653dec16528 Mon Sep 17 00:00:00 2001 From: David Greene Date: Fri, 29 Jul 2011 19:07:09 +0000 Subject: [AVX] Unique UnsetInit Keep only one UnsetInit around. llvm-svn: 136487 --- llvm/utils/TableGen/Record.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'llvm') diff --git a/llvm/utils/TableGen/Record.cpp b/llvm/utils/TableGen/Record.cpp index 17fe2fad6e7..0f50df69d7d 100644 --- a/llvm/utils/TableGen/Record.cpp +++ b/llvm/utils/TableGen/Record.cpp @@ -443,7 +443,8 @@ RecTy *llvm::resolveTypes(RecTy *T1, RecTy *T2) { void Init::dump() const { return print(errs()); } const UnsetInit *UnsetInit::get() { - return new UnsetInit; + static const UnsetInit TheInit; + return &TheInit; } const BitInit *BitInit::get(bool V) { -- cgit v1.2.3