MCPcopy Create free account
hub / github.com/apache/arrow / EnsureDecodeBuffer

Method EnsureDecodeBuffer

cpp/src/parquet/decoder.cc:2290–2297  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2288 }
2289
2290 uint8_t* EnsureDecodeBuffer(int64_t min_values) {
2291 const int64_t size = this->type_length_ * min_values;
2292 if (!decode_buffer_ || decode_buffer_->size() < size) {
2293 const auto alloc_size = ::arrow::bit_util::NextPower2(size);
2294 PARQUET_ASSIGN_OR_THROW(decode_buffer_, ::arrow::AllocateBuffer(alloc_size));
2295 }
2296 return decode_buffer_->mutable_data();
2297 }
2298
2299 int stride_{0};
2300 std::shared_ptr<Buffer> decode_buffer_;

Callers 1

DecodeMethod · 0.80

Calls 4

NextPower2Function · 0.85
AllocateBufferFunction · 0.70
sizeMethod · 0.45
mutable_dataMethod · 0.45

Tested by

no test coverage detected