Skip to content

[JAVA] Restructure ValueVector hierarchy to minimize compile-time generated code #17483

@asfimport

Description

@asfimport

The templates used in the java package are very high mainteance and the if conditions are hard to track. As started in the discussion here: #1012, I'd like to propose that we modify the structure of the internal value vectors and code generation dynamics.

Create new abstract base vectors:

BaseFixedVector
BaseVariableVector
BaseNullableVector

For each of these, implement all the basic functionality of a vector without using templating.

Evaluate whether to use code generation to generate specific specializations of this functionality for each type where needed for performance purposes (probably constrained to mutator and accessor set/get methods). Giant and complex if conditions in the templates are actually worse from my perspective than a small amount of hand written duplicated code since templates are much harder to work with.

Reporter: Jacques Nadeau / @jacques-n
Assignee: Siddharth Teotia / @siddharthteotia

Subtasks:

Related issues:

PRs and other links:

Note: This issue was originally created as ARROW-1463. Please see the migration documentation for further details.

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions