Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-1470

[C++] Add BufferAllocator abstract interface

    XMLWordPrintableJSON

Details

    • New Feature
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.17.0
    • C++
    • None

    Description

      There are some situations (arrow::ipc::SerializeRecordBatch where we pass a MemoryPool* solely to call AllocateBuffer using it. This is not as flexible as it could be, since there are situation where we may wish to allocate from shared memory instead.

      So instead:

      Func(..., BufferAllocator* allocator, ...) {
        ...
        std::shared_ptr<Buffer> buffer;
        RETURN_NOT_OK(allocator->Allocate(nbytes, &buffer));
        ...
      }
      

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              wesm Wes McKinney
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: