Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improvements to Vectors using improved iteration and toArray patterns (…
…deephaven#3570) * Delete io.deephaven.base.Function, trim down io.deephaven.base.Procedure, and trim down io.deephaven.util.FunctionalInterfaces. Clean up usages of removed interfaces by using standard java.lang or java.util.function alternatives, or by introducing a new, more local interface where appropriate. * Delete FunctionalInterfaces and promote its members to top-level interfaces in io.deephaven.util.function, with slightly-improved documentation * Rename and update the remaining functional interfaces in Prodecure to better match the equivalents in java.util.function, promote them to top-level, and move the whole heap to a new engine-primitive module * Address out-of-date replication in LongSparseArraySource, and moved a block of code (shouldTrackPrevious) in CharacterSparseArraySource to a more appropriate location so it would not be duplicated by region duplication * Start replicating primitive Consumers * Don't let Spotless modify replicated code in TestAggregatingDoubleRingBufferTest, and commit the code as-replicated * Introduce CloseableIterator, and CloseablePrimitiveIteratorOf{Byte, Char, Float, Short, Int, Long, Double}, and adapter functions {Byte, Char, Short}ToIntFunction and FloatToDoubleFunction, which enable adaptation for {Byte, Char, Float, Short} to the built-int PrimitiveIterator specializations, and consequently to IntStream and DoubleStream as appropriate. Extend this stream support to the new iterator interfaces, and use the new iterator interfaces for the ColumnIterators as appropriate. * Delete deprecated BooleanVector. Remove BooleanVector use in function libraries, and address a few warnings and missed coverage issues in same. * Get rid of outdated references to "DbArray" and replace with "Vector" * Code cleanup exercise in Vector and implementations. Standardized code formatting and naming conventions, etc. * Column iterators now support first row key + length slicing * Empty, array, repeated, and concatenated iterator support in closeable/primitive iterators * Support iteration for all vector types and implementations. Use iteration for all vector methods, rather than serial-get. Eliminate Prev*VectorColumnWrappers. * Update spotless excludes * Fixed TypedChunk.downcast implementations to take the non-writable versions. Fixed a bunch of inspections and warnings in chunk code. Addressed unnecessarily-restrictive chunk attributes in sort kernels, and did some code cleanup there. Fixed a few bad downcasts. * Fix VectorColumnWrappers to use chunk filling directly, not iteration, for toArray * Fix a warning in the chunk pools * Add boolean flags to control pooled chunk use for writable (enabled) and resettable (disabled) chunks * Widen the return types for column iterators. Correct a few oversights for methods that are in TableDefaults but should instead be in QueryTable and TableAdapter * Eliminate an unnecessary constructor for column iterators, and be more assertive about types * UnionRedirection to not use ThreadLocal priorXSlot caches below a size threshold, defaulted to 128 * Split existing column iterators into interfaces and chunked implementations. Add serial implementations, and switch between the options in vectors based on a size threshold. * Address replication mismatch for cross join state managers * Minor cleanups to type code * Better unit tests for vectors and iterators. Replication for ObjectVectorTest. * Fix test table sizing and row set builder issue. Address fallout with unit tests that were oversized, missing epsilons, or just "lucky" to dodge internal logical errors.
- Loading branch information