GBE: clear deadprintfs when current function is done.
authorRuiling Song <ruiling.song@intel.com>
Tue, 26 Aug 2014 07:39:11 +0000 (15:39 +0800)
committerZhigang Gong <zhigang.gong@intel.com>
Wed, 27 Aug 2014 07:21:49 +0000 (15:21 +0800)
It should be cleared, to prevent invalid pointers staying there
when processing next Function.

Signed-off-by: Ruiling Song <ruiling.song@intel.com>
Reviewed-by: He Junyan <junyan.he@inbox.com>
backend/src/llvm/llvm_printf_parser.cpp

index e02f5aa..00e1ef8 100644 (file)
@@ -616,6 +616,7 @@ error:
         prf.first->eraseFromParent();
     }
 
+    deadprintfs.clear();
     delete builder;
 
     return changed;