Refactor shared memory parallelization #49
@@ -390,6 +390,9 @@ bool checkForConflict(const map<DIST::Array*, ArrayInfo*> &currAccesses,
|
||||
|
||||
for (auto &itArray : currAccesses)
|
||||
{
|
||||
if(!itArray.first)
|
||||
continue; // skip fictitious array access in free loop
|
||||
|
||||
const ArrayInfo &currInfo = *(itArray.second);
|
||||
const string &arrayName = itArray.first->GetShortName();
|
||||
|
||||
|
||||
@@ -498,7 +498,7 @@ static vector<int> matchArrayToLoopSymbols(const vector<SgForStmt*> &parentLoops
|
||||
if (itLoop == sortedLoopGraph.end())
|
||||
printInternalError(convertFileName(__FILE__).c_str(), __LINE__);
|
||||
ifUnknownArrayAssignFound = true;
|
||||
if (side == LEFT && (currRegime == DATA_DISTR || currRegime == COMP_DISTR))
|
||||
if (side == LEFT && (currRegime == DATA_DISTR || currRegime == COMP_DISTR || currRegime == SHARED_MEMORY_PAR))
|
||||
itLoop->second->hasUnknownArrayAssigns = true;
|
||||
|
||||
itLoop->second->hasUnknownDistributedMap = true;
|
||||
|
||||
@@ -560,6 +560,8 @@ static bool runAnalysis(SgProject &project, const int curr_regime, const bool ne
|
||||
else if (curr_regime == LOOP_ANALYZER_NODIST)
|
||||
{
|
||||
auto& loopsInFile = getObjectForFileFromMap(file_name, loopGraph);
|
||||
parallizeFreeLoops = 1;
|
||||
sharedMemoryParallelization = 1;
|
||||
loopAnalyzer(file, parallelRegions, createdArrays, getObjectForFileFromMap(file_name, SPF_messages), SHARED_MEMORY_PAR,
|
||||
allFuncInfo, declaredArrays, declaratedArraysSt, arrayLinksByFuncCalls, createDefUseMapByPlace(),
|
||||
false, &(loopsInFile));
|
||||
|
||||
Reference in New Issue
Block a user