Github user tejasapatil commented on a diff in the pull request:

    https://github.com/apache/spark/pull/17180#discussion_r114036088
  
    --- Diff: 
core/src/main/java/org/apache/spark/unsafe/map/BytesToBytesMap.java ---
    @@ -358,10 +358,20 @@ public long spill(long numBytes) throws IOException {
               return 0L;
             }
     
    +        long released = 0L;
    +        // longArray will not be used anymore, but may take significant 
amount of memory
    +        // but never released until the task is complete.
    +        if (longArray != null) {
    +          released += longArray.memoryBlock().size();
    --- End diff --
    
    nit: i would do this *after* the memory is cleaned up


---
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 infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to