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

Method getOutputFromSpillMerger

bolt/exec/tests/MergerTest.cpp:256–278  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

254 }
255
256 static std::vector<RowVectorPtr> getOutputFromSpillMerger(
257 SpillMerger* spillMerger) {
258 std::vector<ContinueFuture> sourceBlockingFutures;
259 std::vector<RowVectorPtr> results;
260 for (;;) {
261 bool atEnd = false;
262 auto output = spillMerger->getOutput(sourceBlockingFutures, atEnd);
263 if (output != nullptr) {
264 results.emplace_back(std::move(output));
265 }
266
267 if (atEnd) {
268 break;
269 }
270
271 while (!sourceBlockingFutures.empty()) {
272 auto future = std::move(sourceBlockingFutures.back());
273 sourceBlockingFutures.pop_back();
274 future.wait();
275 }
276 }
277 return results;
278 }
279
280 static void checkResults(
281 std::vector<RowVectorPtr> expectedResults,

Callers

nothing calls this directly

Calls 5

backMethod · 0.80
pop_backMethod · 0.80
waitMethod · 0.80
getOutputMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected