Describe the enhancement requested
Lookup functionality in concrete array classes can be invoked repeatedly in some operations, e.g. the sort kernels which access multiple array chunks in random order:
|
const value_type* raw_values() const { |
|
return reinterpret_cast<const value_type*>(raw_values_) + data_->offset; |
|
} |
|
|
|
value_type Value(int64_t i) const { return raw_values()[i]; } |
The compiler might always not be able to hoist the data_->offset lookup out of loops, therefore it would be useful to avoid it altogether.
Component(s)
C++
Describe the enhancement requested
Lookup functionality in concrete array classes can be invoked repeatedly in some operations, e.g. the sort kernels which access multiple array chunks in random order:
arrow/cpp/src/arrow/array/array_primitive.h
Lines 105 to 109 in 0f7b5e5
The compiler might always not be able to hoist the
data_->offsetlookup out of loops, therefore it would be useful to avoid it altogether.Component(s)
C++