Passes return true if they change something, not if they fail
authorChris Lattner <sabre@nondot.org>
Thu, 18 Oct 2001 01:31:22 +0000 (01:31 +0000)
committerChris Lattner <sabre@nondot.org>
Thu, 18 Oct 2001 01:31:22 +0000 (01:31 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@869 91177308-0d34-0410-b5e6-96231b3b80d8

tools/llc/llc.cpp

index 04ae4686867dcb0ff31abf97ac195f6b905593ab..a072de309e9af01ddf9248eefc271227755fa0df 100644 (file)
@@ -190,8 +190,11 @@ int main(int argc, char **argv) {
     Passes.push_back(new EmitAssembly(Target, Out, Out != &cout));
   }
   
-  // Run our queue of passes all at once now, efficiently.
-  return Pass::runAllPassesAndFree(M.get(), Passes);
+  // Run our queue of passes all at once now, efficiently.  This form of
+  // runAllPasses frees the Pass objects after runAllPasses completes.
+  Pass::runAllPassesAndFree(M.get(), Passes);
+
+  return 0;
 }