1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-07-07 09:01:10 +03:00

feat(joblist,runtime): this is the first part of the execution model that produces a workload that can be predicted for a given query.

* feat(joblist,runtime): this is the first part of the execution model that produces a workload that can be predicted for a given query.
  - forces to UM join converter to use a value from a configuration
  - replaces a constant used to control a number of outstanding requests with a value depends on column width
  - modifies related Columnstore.xml values
This commit is contained in:
drrtuy
2024-12-03 22:17:49 +00:00
committed by GitHub
parent bba2133cd0
commit 6445f4dff3
9 changed files with 76 additions and 74 deletions

View File

@ -1387,6 +1387,7 @@ void BatchPrimitiveProcessor::execute()
#ifdef PRIMPROC_STOPWATCH
stopwatch->start("BatchPrimitiveProcessor::execute first part");
#endif
utils::setThreadName("BPPFilt&Pr");
// if only one scan step which has no predicate, async load all columns
if (filterCount == 1 && hasScan)
@ -1550,6 +1551,8 @@ void BatchPrimitiveProcessor::execute()
#endif
outputRG.resetRowGroup(baseRid);
utils::setThreadName("BPPFE1_1");
if (fe1)
{
uint32_t newRidCount = 0;
@ -1616,6 +1619,8 @@ void BatchPrimitiveProcessor::execute()
}
if (fe2)
{
utils::setThreadName("BPPFE2_1");
/* functionize this -> processFE2() */
fe2Output.resetRowGroup(baseRid);
fe2Output.getRow(0, &fe2Out);
@ -1646,6 +1651,8 @@ void BatchPrimitiveProcessor::execute()
if (fAggregator)
{
utils::setThreadName("BPPAgg_1");
*serialized << (uint8_t)1; // the "count this msg" var
// see TupleBPS::setFcnExpGroup2() and where it gets called.
@ -1662,17 +1669,17 @@ void BatchPrimitiveProcessor::execute()
if ((currentBlockOffset + 1) == count) // @bug4507, 8k
{
fAggregator->loadResult(*serialized); // @bug4507, 8k
} // @bug4507, 8k
fAggregator->loadResult(*serialized); // @bug4507, 8k
} // @bug4507, 8k
else if (utils::MonitorProcMem::isMemAvailable()) // @bug4507, 8k
{
fAggregator->loadEmptySet(*serialized); // @bug4507, 8k
} // @bug4507, 8k
else // @bug4507, 8k
} // @bug4507, 8k
else // @bug4507, 8k
{
fAggregator->loadResult(*serialized); // @bug4507, 8k
fAggregator->aggReset(); // @bug4507, 8k
} // @bug4507, 8k
} // @bug4507, 8k
}
if (!fAggregator && !fe2)
@ -1726,6 +1733,8 @@ void BatchPrimitiveProcessor::execute()
do // while (startRid > 0)
{
utils::setThreadName("BPPJoin_1");
#ifdef PRIMPROC_STOPWATCH
stopwatch->start("-- executeTupleJoin()");
startRid = executeTupleJoin(startRid, largeSideRowGroup);
@ -1777,6 +1786,8 @@ void BatchPrimitiveProcessor::execute()
*serialized << sendCount;
if (fe2)
{
utils::setThreadName("BPPFE2_2");
/* functionize this -> processFE2()*/
fe2Output.resetRowGroup(baseRid);
fe2Output.setDBRoot(dbRoot);
@ -1800,21 +1811,23 @@ void BatchPrimitiveProcessor::execute()
if (fAggregator)
{
utils::setThreadName("BPPAgg_2");
fAggregator->addRowGroup(&nextRG);
if ((currentBlockOffset + 1) == count && moreRGs == false && startRid == 0) // @bug4507, 8k
{
fAggregator->loadResult(*serialized); // @bug4507, 8k
} // @bug4507, 8k
fAggregator->loadResult(*serialized); // @bug4507, 8k
} // @bug4507, 8k
else if (utils::MonitorProcMem::isMemAvailable()) // @bug4507, 8k
{
fAggregator->loadEmptySet(*serialized); // @bug4507, 8k
} // @bug4507, 8k
else // @bug4507, 8k
} // @bug4507, 8k
else // @bug4507, 8k
{
fAggregator->loadResult(*serialized); // @bug4507, 8k
fAggregator->aggReset(); // @bug4507, 8k
} // @bug4507, 8k
} // @bug4507, 8k
}
else
{
@ -1901,6 +1914,7 @@ void BatchPrimitiveProcessor::execute()
// cout << "sent physIO=" << physIO << " cachedIO=" << cachedIO <<
// " touchedBlocks=" << touchedBlocks << endl;
}
utils::setThreadName("BPPExecuteEnd");
#ifdef PRIMPROC_STOPWATCH
stopwatch->stop("BatchPrimitiveProcessor::execute fourth part");
@ -2751,7 +2765,6 @@ void BatchPrimitiveProcessor::buildVSSCache(uint32_t loopCount)
if (rc == 0)
for (i = 0; i < vssData.size(); i++)
vssCache.insert(make_pair(lbidList[i], vssData[i]));
}
} // namespace primitiveprocessor