You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-05 16:15:50 +03:00
MCOL-521 Put regr functions in their own library
This commit is contained in:
@@ -155,7 +155,7 @@ SET (ENGINE_TOOLSDIR "${INSTALL_ENGINE}/tools")
|
|||||||
SET (ENGINE_COMMON_LIBS messageqcpp loggingcpp configcpp idbboot ${Boost_LIBRARIES} xml2 pthread rt libmysql_client)
|
SET (ENGINE_COMMON_LIBS messageqcpp loggingcpp configcpp idbboot ${Boost_LIBRARIES} xml2 pthread rt libmysql_client)
|
||||||
SET (ENGINE_OAM_LIBS oamcpp alarmmanager)
|
SET (ENGINE_OAM_LIBS oamcpp alarmmanager)
|
||||||
SET (ENGINE_BRM_LIBS brm idbdatafile cacheutils rwlock ${ENGINE_OAM_LIBS} ${ENGINE_COMMON_LIBS})
|
SET (ENGINE_BRM_LIBS brm idbdatafile cacheutils rwlock ${ENGINE_OAM_LIBS} ${ENGINE_COMMON_LIBS})
|
||||||
SET (ENGINE_EXEC_LIBS joblist execplan windowfunction joiner rowgroup funcexp udfsdk dataconvert common compress querystats querytele thrift threadpool ${ENGINE_BRM_LIBS})
|
SET (ENGINE_EXEC_LIBS joblist execplan windowfunction joiner rowgroup funcexp udfsdk regr dataconvert common compress querystats querytele thrift threadpool ${ENGINE_BRM_LIBS})
|
||||||
SET (ENGINE_WRITE_LIBS ddlpackageproc ddlpackage dmlpackageproc dmlpackage writeengine writeengineclient idbdatafile cacheutils ${ENGINE_EXEC_LIBS})
|
SET (ENGINE_WRITE_LIBS ddlpackageproc ddlpackage dmlpackageproc dmlpackage writeengine writeengineclient idbdatafile cacheutils ${ENGINE_EXEC_LIBS})
|
||||||
|
|
||||||
SET (ENGINE_COMMON_LDFLAGS "")
|
SET (ENGINE_COMMON_LDFLAGS "")
|
||||||
|
@@ -3876,6 +3876,7 @@ void TupleAggregateStep::prep2PhasesDistinctAggregate(
|
|||||||
|
|
||||||
// column index for PM aggregate rowgroup
|
// column index for PM aggregate rowgroup
|
||||||
uint64_t colAggPm = 0;
|
uint64_t colAggPm = 0;
|
||||||
|
uint64_t multiParm = 0;
|
||||||
|
|
||||||
// for groupby column
|
// for groupby column
|
||||||
for (uint64_t i = 0; i < jobInfo.groupByColVec.size(); i++)
|
for (uint64_t i = 0; i < jobInfo.groupByColVec.size(); i++)
|
||||||
@@ -4027,7 +4028,7 @@ void TupleAggregateStep::prep2PhasesDistinctAggregate(
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
functionVecPm.push_back(funct);
|
functionVecPm.push_back(funct);
|
||||||
aggFuncMap.insert(make_pair(boost::make_tuple(aggKey, aggOp, pUDAFFunc), colAggPm));
|
aggFuncMap.insert(make_pair(boost::make_tuple(aggKey, aggOp, pUDAFFunc), colAggPm-multiParm));
|
||||||
|
|
||||||
switch (aggOp)
|
switch (aggOp)
|
||||||
{
|
{
|
||||||
@@ -4247,7 +4248,8 @@ void TupleAggregateStep::prep2PhasesDistinctAggregate(
|
|||||||
typeAggPm.push_back(typeProj[colProj]);
|
typeAggPm.push_back(typeProj[colProj]);
|
||||||
widthAggPm.push_back(width[colProj]);
|
widthAggPm.push_back(width[colProj]);
|
||||||
multiParmIndexes.push_back(colAggPm);
|
multiParmIndexes.push_back(colAggPm);
|
||||||
colAggPm++;
|
++colAggPm;
|
||||||
|
++multiParm;
|
||||||
// If the param is const
|
// If the param is const
|
||||||
if (udafc)
|
if (udafc)
|
||||||
{
|
{
|
||||||
@@ -4414,7 +4416,7 @@ void TupleAggregateStep::prep2PhasesDistinctAggregate(
|
|||||||
|
|
||||||
if (it != aggFuncMap.end())
|
if (it != aggFuncMap.end())
|
||||||
{
|
{
|
||||||
colUm = it->second - multiParms;
|
colUm = it->second;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -4517,14 +4519,13 @@ void TupleAggregateStep::prep2PhasesDistinctAggregate(
|
|||||||
|
|
||||||
if (it != aggFuncMap.end())
|
if (it != aggFuncMap.end())
|
||||||
{
|
{
|
||||||
colUm = it->second - multiParms;
|
colUm = it->second;
|
||||||
oidsAggDist.push_back(oidsAggUm[colUm]);
|
oidsAggDist.push_back(oidsAggUm[colUm]);
|
||||||
keysAggDist.push_back(keysAggUm[colUm]);
|
keysAggDist.push_back(keysAggUm[colUm]);
|
||||||
scaleAggDist.push_back(scaleAggUm[colUm]);
|
scaleAggDist.push_back(scaleAggUm[colUm]);
|
||||||
precisionAggDist.push_back(precisionAggUm[colUm]);
|
precisionAggDist.push_back(precisionAggUm[colUm]);
|
||||||
typeAggDist.push_back(typeAggUm[colUm]);
|
typeAggDist.push_back(typeAggUm[colUm]);
|
||||||
widthAggDist.push_back(widthAggUm[colUm]);
|
widthAggDist.push_back(widthAggUm[colUm]);
|
||||||
colUm -= multiParms;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// not a direct hit -- a returned column is not already in the RG from PMs
|
// not a direct hit -- a returned column is not already in the RG from PMs
|
||||||
@@ -4542,7 +4543,7 @@ void TupleAggregateStep::prep2PhasesDistinctAggregate(
|
|||||||
// false alarm
|
// false alarm
|
||||||
returnColMissing = false;
|
returnColMissing = false;
|
||||||
|
|
||||||
colUm = it->second - multiParms;
|
colUm = it->second;
|
||||||
|
|
||||||
if (aggOp == ROWAGG_SUM)
|
if (aggOp == ROWAGG_SUM)
|
||||||
{
|
{
|
||||||
|
@@ -72,9 +72,11 @@ fi
|
|||||||
if [ -f $installdir/lib/libcalmysql.so.1.0.0 ]; then
|
if [ -f $installdir/lib/libcalmysql.so.1.0.0 ]; then
|
||||||
libcalmysql=$installdir/lib/libcalmysql.so.1.0.0
|
libcalmysql=$installdir/lib/libcalmysql.so.1.0.0
|
||||||
libudfsdk=$installdir/lib/libudf_mysql.so.1.0.0
|
libudfsdk=$installdir/lib/libudf_mysql.so.1.0.0
|
||||||
|
libregrsdk=$installdir/lib/libregr_mysql.so.1.0.0
|
||||||
elif [ -f $installdir/lib/libcalmysql.so.1 ]; then
|
elif [ -f $installdir/lib/libcalmysql.so.1 ]; then
|
||||||
libcalmysql=$installdir/lib/libcalmysql.so.1
|
libcalmysql=$installdir/lib/libcalmysql.so.1
|
||||||
libudfsdk=$installdir/lib/libudf_mysql.so.1
|
libudfsdk=$installdir/lib/libudf_mysql.so.1
|
||||||
|
libregrsdk=$installdir/lib/libregr_mysql.so.1
|
||||||
else
|
else
|
||||||
libcalmysql=
|
libcalmysql=
|
||||||
fi
|
fi
|
||||||
@@ -84,6 +86,7 @@ if [ -d $installdir/mysql/lib64/mysql/plugin -a -n "$libcalmysql" ]; then
|
|||||||
ln -sf $libcalmysql libcalmysql.so
|
ln -sf $libcalmysql libcalmysql.so
|
||||||
ln -sf $libcalmysql libcalmysqlent.so
|
ln -sf $libcalmysql libcalmysqlent.so
|
||||||
ln -sf $libudfsdk libudf_mysql.so
|
ln -sf $libudfsdk libudf_mysql.so
|
||||||
|
ln -sf $libregrsdk libregr_mysql.so
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ $installdir != "/usr/local/mariadb/columnstore" ]; then
|
if [ $installdir != "/usr/local/mariadb/columnstore" ]; then
|
||||||
|
@@ -83,6 +83,7 @@ chown -R $user.$user $installdir/mysql
|
|||||||
if [ -f $installdir/lib/libcalmysql.so.1.0.0 ]; then
|
if [ -f $installdir/lib/libcalmysql.so.1.0.0 ]; then
|
||||||
libcalmysql=$installdir/lib/libcalmysql.so.1.0.0
|
libcalmysql=$installdir/lib/libcalmysql.so.1.0.0
|
||||||
libudfsdk=$installdir/lib/libudf_mysql.so.1.0.0
|
libudfsdk=$installdir/lib/libudf_mysql.so.1.0.0
|
||||||
|
libregrsdk=$installdir/lib/libregr_mysql.so.1.0.0
|
||||||
is_columnstore_tables=$installdir/lib/is_columnstore_tables.so.1.0.0
|
is_columnstore_tables=$installdir/lib/is_columnstore_tables.so.1.0.0
|
||||||
is_columnstore_columns=$installdir/lib/is_columnstore_columns.so.1.0.0
|
is_columnstore_columns=$installdir/lib/is_columnstore_columns.so.1.0.0
|
||||||
is_columnstore_extents=$installdir/lib/is_columnstore_extents.so.1.0.0
|
is_columnstore_extents=$installdir/lib/is_columnstore_extents.so.1.0.0
|
||||||
@@ -90,6 +91,7 @@ if [ -f $installdir/lib/libcalmysql.so.1.0.0 ]; then
|
|||||||
elif [ -f $installdir/lib/libcalmysql.so.1 ]; then
|
elif [ -f $installdir/lib/libcalmysql.so.1 ]; then
|
||||||
libcalmysql=$installdir/lib/libcalmysql.so.1
|
libcalmysql=$installdir/lib/libcalmysql.so.1
|
||||||
libudfsdk=$installdir/lib/libudf_mysql.so.1
|
libudfsdk=$installdir/lib/libudf_mysql.so.1
|
||||||
|
libregrsdk=$installdir/lib/libregr_mysql.so.1
|
||||||
is_columnstore_tables=$installdir/lib/is_columnstore_tables.so.1
|
is_columnstore_tables=$installdir/lib/is_columnstore_tables.so.1
|
||||||
is_columnstore_columns=$installdir/lib/is_columnstore_columns.so.1
|
is_columnstore_columns=$installdir/lib/is_columnstore_columns.so.1
|
||||||
is_columnstore_extents=$installdir/lib/is_columnstore_extents.so.1
|
is_columnstore_extents=$installdir/lib/is_columnstore_extents.so.1
|
||||||
@@ -104,6 +106,7 @@ if [ -n "$libcalmysql" ]; then
|
|||||||
ln -sf $libcalmysql libcalmysql.so
|
ln -sf $libcalmysql libcalmysql.so
|
||||||
ln -sf $libcalmysql libcalmysqlent.so
|
ln -sf $libcalmysql libcalmysqlent.so
|
||||||
ln -sf $libudfsdk libudf_mysql.so
|
ln -sf $libudfsdk libudf_mysql.so
|
||||||
|
ln -sf $libregrsdk libregr_mysql.so
|
||||||
ln -sf $is_columnstore_tables is_columnstore_tables.so
|
ln -sf $is_columnstore_tables is_columnstore_tables.so
|
||||||
ln -sf $is_columnstore_columns is_columnstore_columns.so
|
ln -sf $is_columnstore_columns is_columnstore_columns.so
|
||||||
ln -sf $is_columnstore_extents is_columnstore_extents.so
|
ln -sf $is_columnstore_extents is_columnstore_extents.so
|
||||||
|
Reference in New Issue
Block a user