Add possibility to set memory limit for binaries run via libSystem. This
is especially needed for bugpoint. This partly implements PR688
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34349 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/tools/bugpoint/ExecutionDriver.cpp b/tools/bugpoint/ExecutionDriver.cpp
index 92e7737..f4a072b 100644
--- a/tools/bugpoint/ExecutionDriver.cpp
+++ b/tools/bugpoint/ExecutionDriver.cpp
@@ -263,11 +263,11 @@
InterpreterSel == CBE_bug)
RetVal = AI->ExecuteProgram(BytecodeFile, InputArgv, InputFile,
OutputFile, AdditionalLinkerArgs, SharedObjs,
- Timeout);
+ Timeout, MemoryLimit);
else
RetVal = AI->ExecuteProgram(BytecodeFile, InputArgv, InputFile,
OutputFile, std::vector<std::string>(),
- SharedObjs, Timeout);
+ SharedObjs, Timeout, MemoryLimit);
if (RetVal == -1) {
std::cerr << "<timeout>";