TaskMemoryManager. cleanUpAllAllocatedMemory -> Memory leaks ???

2015-10-12 Thread Lei Wu
Dear all, I'm reading source code of TaskMemoryManager.java and I got stuck in the last function, that is cleanUpAllAllocatedMemory. What confuses me is the comments for this function : "A non-zero return value can be used to detect memory leaks". And from Executor.scala where this function is

Re: TaskMemoryManager. cleanUpAllAllocatedMemory -> Memory leaks ???

2015-10-12 Thread Ted Yu
Please note the block where cleanUpAllAllocatedMemory() is called: } finally { val freedMemory = taskMemoryManager.cleanUpAllAllocatedMemory() if (freedMemory > 0) { I think the intention is that allocated memory should have been freed by the time we reach the finally

Re: TaskMemoryManager. cleanUpAllAllocatedMemory -> Memory leaks ???

2015-10-12 Thread Ted Yu
Please take a look at the design doc attached to SPARK-1 The answer is on page 2 of that doc. On Mon, Oct 12, 2015 at 8:55 AM, Ted Yu wrote: > Please note the block where cleanUpAllAllocatedMemory() is called: > } finally { > val freedMemory =