hawq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vraghava...@apache.org
Subject [1/2] incubator-hawq git commit: Remove traceflag that allows ORCA to run in multiple threads [#118416535]
Date Wed, 22 Jun 2016 17:27:14 GMT
Repository: incubator-hawq
Updated Branches:
  refs/heads/master 64dce1a8a -> 817249a46


Remove traceflag that allows ORCA to run in multiple threads [#118416535]


Project: http://git-wip-us.apache.org/repos/asf/incubator-hawq/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-hawq/commit/43efc87e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-hawq/tree/43efc87e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-hawq/diff/43efc87e

Branch: refs/heads/master
Commit: 43efc87e0ae0234bf5eb645294c2c951ce349319
Parents: 80e25b4
Author: Venkatesh (Venky) Raghavan <vraghavan@pivotal.io>
Authored: Tue May 10 16:59:31 2016 -0700
Committer: Venkatesh (Venky) Raghavan <vraghavan@pivotal.io>
Committed: Tue Jun 21 18:30:49 2016 -0700

----------------------------------------------------------------------
 .../gpopt/config/CConfigParamMapping.cpp        |  7 ------
 src/backend/gpopt/utils/COptTasks.cpp           | 25 ++------------------
 src/backend/utils/misc/guc.c                    | 10 --------
 src/include/utils/guc.h                         |  1 -
 4 files changed, 2 insertions(+), 41 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/43efc87e/src/backend/gpopt/config/CConfigParamMapping.cpp
----------------------------------------------------------------------
diff --git a/src/backend/gpopt/config/CConfigParamMapping.cpp b/src/backend/gpopt/config/CConfigParamMapping.cpp
index beb355e..b7b0475 100644
--- a/src/backend/gpopt/config/CConfigParamMapping.cpp
+++ b/src/backend/gpopt/config/CConfigParamMapping.cpp
@@ -127,13 +127,6 @@ CConfigParamMapping::SConfigMappingElem CConfigParamMapping::m_elem[]
=
 		},
 
 		{
-		EopttraceParallel,
-		&optimizer_parallel,
-		false, // m_fNegate
-		GPOS_WSZ_LIT("Enable using threads in optimization engine.")
-		},
-
-		{
 		EopttraceMinidump,
 		&optimizer_minidump,
 		false, // m_fNegate

http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/43efc87e/src/backend/gpopt/utils/COptTasks.cpp
----------------------------------------------------------------------
diff --git a/src/backend/gpopt/utils/COptTasks.cpp b/src/backend/gpopt/utils/COptTasks.cpp
index 4de4cdb..6ff6556 100644
--- a/src/backend/gpopt/utils/COptTasks.cpp
+++ b/src/backend/gpopt/utils/COptTasks.cpp
@@ -129,7 +129,7 @@ using namespace gpdbcost;
 #define GPOPT_ERROR_BUFFER_SIZE 10 * 1024 * 1024
 
 // definition of default AutoMemoryPool
-#define AUTO_MEM_POOL(amp) CAutoMemoryPool amp(CAutoMemoryPool::ElcExc, CMemoryPoolManager::EatTracker,
optimizer_parallel)
+#define AUTO_MEM_POOL(amp) CAutoMemoryPool amp(CAutoMemoryPool::ElcExc, CMemoryPoolManager::EatTracker,
false /* fThreadSafe */)
 
 // default id for the source system
 const CSystemId sysidDefault(IMDId::EmdidGPDB, GPOS_WSZ_STR_LENGTH("GPDB"));
@@ -541,23 +541,12 @@ COptTasks::Execute
 {
 	Assert(pfunc);
 
-	if (optimizer_parallel)
-	{
-		// be-aware that parallel optimizer mode may conflict with GPDB signal handlers,
-		// this mode should be avoided unless optimizer is spawned in a different process
-		if (gpos_set_threads(4, 4))
-		{
-			elog(ERROR, "unable to set number of threads in gpos");
-			return;
-		}
-	}
-
 	// initialize DXL support
 	InitDXL();
 
 	bool abort_flag = false;
 
-	CAutoMemoryPool amp(CAutoMemoryPool::ElcNone, CMemoryPoolManager::EatTracker, optimizer_parallel);
+	CAutoMemoryPool amp(CAutoMemoryPool::ElcNone, CMemoryPoolManager::EatTracker, false /* fThreadSafe
*/);
 	IMemoryPool *pmp = amp.Pmp();
 	CHAR *err_buf = SzAllocate(pmp, GPOPT_ERROR_BUFFER_SIZE);
 
@@ -1018,16 +1007,6 @@ COptTasks::PvOptimizeTask
 			IConstExprEvaluator *pceeval =
 					GPOS_NEW(pmp) CConstExprEvaluatorDXL(pmp, &mda, &ceevalproxy);
 
-			// preload metadata if optimizer uses multiple threads
-			if (optimizer_parallel)
-			{
-				// install opt context in TLS
-				pocconf->AddRef();
-				pceeval->AddRef();
-				CAutoOptCtxt aoc(pmp, &mda, pceeval, pocconf);
-				CTranslatorUtils::PreloadMD(pmp, &mda, sysidDefault, (Query*) poctx->m_pquery);
-			}
-
 			CDXLNode *pdxlnQuery = ptrquerytodxl->PdxlnFromQuery();
 			DrgPdxln *pdrgpdxlnQueryOutput = ptrquerytodxl->PdrgpdxlnQueryOutput();
 			DrgPdxln *pdrgpdxlnCTE = ptrquerytodxl->PdrgpdxlnCTE();

http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/43efc87e/src/backend/utils/misc/guc.c
----------------------------------------------------------------------
diff --git a/src/backend/utils/misc/guc.c b/src/backend/utils/misc/guc.c
index eb01c35..48e09f2 100644
--- a/src/backend/utils/misc/guc.c
+++ b/src/backend/utils/misc/guc.c
@@ -689,7 +689,6 @@ bool		optimizer_print_expression_properties;
 bool		optimizer_print_group_properties;
 bool		optimizer_print_optimization_context;
 bool		optimizer_print_optimization_stats;
-bool		optimizer_parallel;
 bool		optimizer_local;
 int 		optimizer_retries;
 bool  		optimizer_xforms[OPTIMIZER_XFORMS_COUNT] = {[0 ... OPTIMIZER_XFORMS_COUNT - 1] =
false}; /* array of xforms disable flags */
@@ -3539,15 +3538,6 @@ static struct config_bool ConfigureNamesBool[] =
 		false, NULL, NULL
 	},
 
-	{
-		{"optimizer_parallel", PGC_USERSET, LOGGING_WHAT,
-			gettext_noop("Enable using threads in optimization engine."),
-			NULL,
-			GUC_NO_SHOW_ALL | GUC_NOT_IN_SAMPLE
-		},
-		&optimizer_parallel,
-		false, NULL, NULL
-	},
  	{
 		{"optimizer_extract_dxl_stats", PGC_USERSET, LOGGING_WHAT,
 			gettext_noop("Extract plan stats in dxl."),

http://git-wip-us.apache.org/repos/asf/incubator-hawq/blob/43efc87e/src/include/utils/guc.h
----------------------------------------------------------------------
diff --git a/src/include/utils/guc.h b/src/include/utils/guc.h
index 2e4e6eb..337d265 100644
--- a/src/include/utils/guc.h
+++ b/src/include/utils/guc.h
@@ -372,7 +372,6 @@ extern bool	optimizer_print_expression_properties;
 extern bool	optimizer_print_group_properties;
 extern bool	optimizer_print_optimization_context;
 extern bool optimizer_print_optimization_stats;
-extern bool	optimizer_parallel;
 extern bool	optimizer_local;
 extern int  optimizer_retries;
 extern bool  optimizer_xforms[OPTIMIZER_XFORMS_COUNT];


Mime
View raw message