MCPcopy Create free account
hub / github.com/apache/impala / DecodeBufferedLiterals

Method DecodeBufferedLiterals

be/src/util/rle-encoding.h:729–741  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

727template <typename T>
728template <typename OutType>
729inline int32_t RleBatchDecoder<T>::DecodeBufferedLiterals(int32_t max_to_output,
730 OutType* dict, int64_t dict_len, StrideWriter<OutType>* RESTRICT out) {
731 int32_t num_to_output =
732 std::min<int32_t>(max_to_output, num_buffered_literals_ - literal_buffer_pos_);
733 for (int32_t i = 0; i < num_to_output; ++i) {
734 T idx = literal_buffer_[literal_buffer_pos_ + i];
735 if (UNLIKELY(idx < 0 || idx >= dict_len)) return 0;
736 out->SetNext(dict[idx]);
737 }
738 literal_buffer_pos_ += num_to_output;
739 literal_count_ -= num_to_output;
740 return num_to_output;
741}
742
743template <typename T>
744inline int32_t RleBatchDecoder<T>::GetValues(int32_t num_values_to_consume, T* values) {

Callers

nothing calls this directly

Calls 1

SetNextMethod · 0.45

Tested by

no test coverage detected