MCPcopy Create free account
hub / github.com/bytedance/bolt / storeRows

Method storeRows

bolt/exec/RowsStreamingWindowBuild.cpp:183–200  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

181
182template <bool needSort>
183char* RowsStreamingWindowBuild<needSort>::storeRows() {
184 BOLT_CHECK_GT(accumulatedLength_, 0);
185 BOLT_CHECK_NOT_NULL(info_);
186 char* newRows = nullptr;
187 newRows =
188 reinterpret_cast<char*>(data_->pool()->allocate(accumulatedLength_));
189 int64_t offset = 0;
190 for (auto i = 0; i < tmpSortedRows_.size(); i++) {
191 auto dest = newRows + offset;
192 ContainerRow2RowSerde::copyRow(
193 dest, tmpSortedRows_[i], tmpSortedRowsSize_[i], *info_);
194 offset += tmpSortedRowsSize_[i];
195 sortRows_.push_back(dest);
196 }
197 tmpSortedRows_.clear();
198 tmpSortedRowsSize_.clear();
199 return newRows;
200}
201
202template <bool needSort>
203void RowsStreamingWindowBuild<needSort>::loadNextPartitionFromSpill() {

Callers

nothing calls this directly

Calls 6

copyRowFunction · 0.85
allocateMethod · 0.45
poolMethod · 0.45
sizeMethod · 0.45
push_backMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected