]> granicus.if.org Git - clang/commitdiff
Unbreak CGFunctionInfo::Profile method and reenable caching of ABI
authorDaniel Dunbar <daniel@zuster.org>
Thu, 5 Feb 2009 00:00:23 +0000 (00:00 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Thu, 5 Feb 2009 00:00:23 +0000 (00:00 +0000)
information.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63799 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/CGCall.cpp
lib/CodeGen/CGCall.h

index a3dd877ce58b59058a04a2c42523596bcd267569..61c6653236df20aba4289794be507c8d06cf7e01 100644 (file)
@@ -101,9 +101,7 @@ const CGFunctionInfo &CodeGenTypes::getFunctionInfo(QualType ResTy,
 
   // Construct the function info.
   FI = new CGFunctionInfo(ResTy, ArgTys);
-
-  // FIXME: This is leaking like a sieve; please fix me.
-  //  FunctionInfos.InsertNode(FI, InsertPos);
+  FunctionInfos.InsertNode(FI, InsertPos);
 
   // Compute ABI information.
   getABIInfo().computeInfo(*FI, getContext());
index 562dfa911329d61c82c1605e6868748452b64e3e..daf6f00045012e149cf6508fb2d208383b453b5c 100644 (file)
@@ -84,6 +84,7 @@ namespace CodeGen {
     const ABIArgInfo &getReturnInfo() const { return Args[0].info; }
 
     void Profile(llvm::FoldingSetNodeID &ID) {
+      getReturnType().Profile(ID);
       for (arg_iterator it = arg_begin(), ie = arg_end(); it != ie; ++it)
         it->type.Profile(ID);
     }