[llvm-commits] CVS: llvm/include/Support/SystemUtils.h

Chris Lattner lattner at cs.uiuc.edu
Sat Jul 24 00:41:41 PDT 2004



Changes in directory llvm/include/Support:

SystemUtils.h updated: 1.11 -> 1.12

---
Log message:

Add support for killing the program if it executes for too long.



---
Diffs of the changes:  (+3 -2)

Index: llvm/include/Support/SystemUtils.h
diff -u llvm/include/Support/SystemUtils.h:1.11 llvm/include/Support/SystemUtils.h:1.12
--- llvm/include/Support/SystemUtils.h:1.11	Thu May 27 19:58:48 2004
+++ llvm/include/Support/SystemUtils.h	Sat Jul 24 02:41:31 2004
@@ -38,14 +38,15 @@
 
 /// RunProgramWithTimeout - This function executes the specified program, with
 /// the specified null-terminated argument array, with the stdin/out/err fd's
-/// redirected, with a timeout specified on the commandline.  This terminates
+/// redirected, with a timeout specified by the last argument.  This terminates
 /// the calling program if there is an error executing the specified program.
 /// It returns the return value of the program, or -1 if a timeout is detected.
 ///
 int RunProgramWithTimeout(const std::string &ProgramPath, const char **Args,
                           const std::string &StdInFile = "",
                           const std::string &StdOutFile = "",
-                          const std::string &StdErrFile = "");
+                          const std::string &StdErrFile = "",
+                          unsigned NumSeconds = 0);
 
 /// ExecWait - Execute a program with the given arguments and environment and 
 /// wait for it to terminate.





More information about the llvm-commits mailing list