Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-2742

MemPool allocation growth behavior

    XMLWordPrintableJSON

    Details

      Description

      Currently, the MemPool would always double the size of the last allocation. This can lead to bad behavior if the MemPool transferred the ownership of all it's data except the last chunk. In the next allocation, the next allocated chunk would double the size of this large chunk which can be undesirable.

      If a MemPool is used without a FreePool there are some alternatives to consider:

      • Cap the chunk size at a reasonable value
      • Allocate only doubles of the requested size
      • Instead of doubling pick a slightly smaller factor that is a root of 2

        Attachments

          Activity

            People

            • Assignee:
              tarmstrong Tim Armstrong
              Reporter:
              mgrund_impala_bb91 Martin Grund
            • Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: