Commit a6c4e38a authored by arnaud.charnoz@gmail.com's avatar arnaud.charnoz@gmail.com
Browse files

Fixed free memory estimation on 32bits os x processes

--HG--
branch : fw4spl_0.7.9
extra : source : be522826431334864c00161ebba9c301dec22f0f
parent 6f5a2458
......@@ -54,6 +54,13 @@ DarwinMemoryMonitorTools::~DarwinMemoryMonitorTools()
freeMemory = getFreeSystemMemory();
#ifndef __LP64__
// Hard coded 3Gb limit for 32bit process
const ::boost::uint64_t maxMemory = 3221225472LL; // 3 Go
const ::boost::uint64_t usedProcessMemory = getUsedProcessMemory();
freeMemory = std::min( maxMemory - usedProcessMemory, freeMemory);
#endif
return freeMemory;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment