[
https://issues.apache.org/jira/browse/DRILL-6126?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16384736#comment-16384736
]
ASF GitHub Bot commented on DRILL-6126:
---------------------------------------
Github user ppadma commented on the issue:
https://github.com/apache/drill/pull/1125
@paul-rogers Updated the PR with latest changes. I have decided not to use
vector initializer for allocation as it is subject to alias issues like you
mentioned. Instead, I added allocate vector method to columnSize in batch
sizer, which will use internal sizing information it has to allocate memory
(including all it's children) for a particular record count.
Refactored the batch sizer code, added unit tests for verifying sizing and
allocation for different vector types.
Please take a look when you get a chance and let me know what you think.
> Allocate memory for value vectors upfront in flatten operator
> -------------------------------------------------------------
>
> Key: DRILL-6126
> URL: https://issues.apache.org/jira/browse/DRILL-6126
> Project: Apache Drill
> Issue Type: Improvement
> Reporter: Padma Penumarthy
> Assignee: Padma Penumarthy
> Priority: Critical
> Fix For: 1.12.0
>
>
> With recent changes to control batch size for flatten operator, we figure out
> row count in the output batch based on memory. Since we know how many rows we
> are going to include in the batch, we can also allocate the memory needed
> upfront instead of starting with initial value (4096) and doubling, copying
> every time we need more.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)