Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-88491

Avoid unnecessary allocations in WiredTigerUtil::exportTableToBSON

    • Type: Icon: Improvement Improvement
    • Resolution: Won't Do
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Storage Execution
    • v8.0
    • Execution Team 2024-04-29, Execution Team 2024-05-13

      In iterating over the cursors in a table we manually create a new BSONObjBuilder for each sub. This will induce a new allocation for each sub. If we can rework the code to concatenate all of the {{sub}}s and their children and then feed into the parent BSONObjBuilder supplied in the function, we can avoid these individual allocations.

      I have a patch POC that clumsily achieves this, but we'd need somebody to make sure the final approach is sound.

            erin.liang@mongodb.com Erin Liang
            blake.oler@mongodb.com Blake Oler
            0 Vote for this issue
            8 Start watching this issue