Github user andrewor14 commented on a diff in the pull request:
https://github.com/apache/spark/pull/9127#discussion_r42902440
--- Diff: core/src/main/java/org/apache/spark/memory/TaskMemoryManager.java
---
@@ -277,10 +311,20 @@ public long cleanUpAllAllocatedMemory() {
freedBytes += memory.size();
// We don't call free() here because that calls Set.remove, which
would lead to a
// ConcurrentModificationException here.
- executorMemoryManager.free(memory);
+ memoryManager.tungstenMemoryAllocator().free(memory);
--- End diff --
can these just be `memoryManager.free(memory)`? i.e. We still keep the
actual allocation code in a separate class, but just provide a helper method to
call the internal memory allocator. Then you don't need to say
`tungstenMemoryAllocator` everywhere.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]