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

Method initializeRows

bolt/exec/GroupingSet.cpp:1945–1963  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1943 numOutputRows += sources.size();
1944 }
1945 result->resize(numOutputRows);
1946 return numOutputRows > 0;
1947}
1948
1949void GroupingSet::ensureGroupIndices(vector_size_t size) {
1950 vector_size_t originSize = groupIndicesOfRows_.size();
1951 if (originSize < size) {
1952 groupIndicesOfRows_.resize(size);
1953 std::iota(
1954 groupIndicesOfRows_.begin() + originSize,
1955 groupIndicesOfRows_.end(),
1956 originSize);
1957 }
1958}
1959
1960void GroupingSet::initializeRows(std::vector<char*> rows) {
1961 ensureGroupIndices(rows.size());
1962 for (auto& aggregate : aggregates_) {
1963 if (!aggregate.sortingKeys.empty()) {
1964 continue;
1965 }
1966 aggregate.function->initializeNewGroups(

Callers

nothing calls this directly

Calls 4

sizeMethod · 0.45
emptyMethod · 0.45
initializeNewGroupsMethod · 0.45
dataMethod · 0.45

Tested by

no test coverage detected