forked from apache/arrow
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ARROW-14718: [Java] loadValidityBuffer should avoid allocating memory…
… when input is not null and there are only null or non-null values Currently in `BitVectorHelper.loadValidityBuffer`, we always allocate memory when the source vector contains only null or non-null values. However, as the [format also allows](https://arrow.apache.org/docs/format/Columnar.html#validity-bitmaps) allocating validity buffer even if all values are null or not-null, the method should also consider whether the input validity buffer is null or not, and avoiding allocating new buffer when it is latter. Closes apache#11709 from sunchao/ARROW-14718 Authored-by: Chao Sun <[email protected]> Signed-off-by: Chao Sun <[email protected]>
- Loading branch information
Showing
2 changed files
with
65 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters