Skip to content
Snippets Groups Projects
  • Nadav Har'El's avatar
    5e426786
    Improve "osv leak show" · 5e426786
    Nadav Har'El authored
    Various improvements to "osv leak show":
    
    1. Somewhat faster performance (but still slow).
    
    2. Better report of progress (percent done). Previously, much of the`
       work of fetching the backtraces from the guest was actually delayed
       until sort time, so was wrongly attributed to the sort phase. Now
       the fetching phase takes most of the time, and percent of its
       progress is shown.
    
    3. Due to popular request: sort leak records by size:
    
       Instead of outputting immediately each leak record (summary of all
       living allocations from a particular call chain), we now save them
       in memory, making it very easy to sort these records by any interesting
       criterion.
       In this patch, I sort them in decreasing order of total bytes - i.e.,
       the first record one sees is the one responsible for most allocated
       bytes.
    
       The additional sort takes only a fraction of a second, and makes the output
       of "osv leak show" much more useful.
    5e426786
    History
    Improve "osv leak show"
    Nadav Har'El authored
    Various improvements to "osv leak show":
    
    1. Somewhat faster performance (but still slow).
    
    2. Better report of progress (percent done). Previously, much of the`
       work of fetching the backtraces from the guest was actually delayed
       until sort time, so was wrongly attributed to the sort phase. Now
       the fetching phase takes most of the time, and percent of its
       progress is shown.
    
    3. Due to popular request: sort leak records by size:
    
       Instead of outputting immediately each leak record (summary of all
       living allocations from a particular call chain), we now save them
       in memory, making it very easy to sort these records by any interesting
       criterion.
       In this patch, I sort them in decreasing order of total bytes - i.e.,
       the first record one sees is the one responsible for most allocated
       bytes.
    
       The additional sort takes only a fraction of a second, and makes the output
       of "osv leak show" much more useful.