trivial, version updated
This commit is contained in:
@@ -36,10 +36,10 @@ static SgExpression* findExprWithVariant(SgExpression* exp, int variant)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool switchToDeclarationFile(DIST::Array* array_p,
|
static bool switchToDeclarationFile(DIST::Array* array_p,
|
||||||
pair<string, int>& decl_place,
|
pair<string, int>& decl_place,
|
||||||
const string ¤t_file_name,
|
const string ¤t_file_name,
|
||||||
FuncInfo *current_func)
|
FuncInfo *current_func)
|
||||||
{
|
{
|
||||||
if (!array_p)
|
if (!array_p)
|
||||||
return false;
|
return false;
|
||||||
@@ -122,9 +122,7 @@ static bool checkAssumedSize(const string &array_name, DIST::Array* array_p, con
|
|||||||
return true;
|
return true;
|
||||||
|
|
||||||
auto *st = SgStatement::getStatementByFileAndLine(decl_place.first, decl_place.second);
|
auto *st = SgStatement::getStatementByFileAndLine(decl_place.first, decl_place.second);
|
||||||
|
checkNull(st, convertFileName(__FILE__).c_str(), __LINE__);
|
||||||
if (!st)
|
|
||||||
printInternalError(convertFileName(__FILE__).c_str(), __LINE__);
|
|
||||||
|
|
||||||
SgExpression* list = st->expr(0);
|
SgExpression* list = st->expr(0);
|
||||||
while (list)
|
while (list)
|
||||||
@@ -255,6 +253,7 @@ static void populateDistributedIoArrays(map<SgSymbol*, set<SgStatement*>>& array
|
|||||||
spec = spec->rhs();
|
spec = spec->rhs();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
@@ -275,8 +274,7 @@ static void populateDistributedIoArrays(map<SgSymbol*, set<SgStatement*>>& array
|
|||||||
DIST::Array* array_p = getArrayFromDeclarated(declaratedInStmt(by_symb), array_name);
|
DIST::Array* array_p = getArrayFromDeclarated(declaratedInStmt(by_symb), array_name);
|
||||||
if (array_p &&
|
if (array_p &&
|
||||||
array_p->GetDistributeFlagVal() == Distribution::distFlag::IO_PRIV &&
|
array_p->GetDistributeFlagVal() == Distribution::distFlag::IO_PRIV &&
|
||||||
!checkAssumedSize(array_name, array_p, current_file_name, current_func)
|
!checkAssumedSize(array_name, array_p, current_file_name, current_func))
|
||||||
)
|
|
||||||
{
|
{
|
||||||
auto inserted = arrays[by_symb].insert(stat).second;
|
auto inserted = arrays[by_symb].insert(stat).second;
|
||||||
|
|
||||||
@@ -379,6 +377,7 @@ static void copyArrayBetweenStatements(SgSymbol* replace_symb,
|
|||||||
auto* parent = start_is_scope ? start : start->controlParent();
|
auto* parent = start_is_scope ? start : start->controlParent();
|
||||||
if (parent && parent->lastNodeOfStmt() == start)
|
if (parent && parent->lastNodeOfStmt() == start)
|
||||||
parent = parent->controlParent();
|
parent = parent->controlParent();
|
||||||
|
checkNull(parent, convertFileName(__FILE__).c_str(), __LINE__);
|
||||||
|
|
||||||
start->insertStmtAfter(*assign, *parent);
|
start->insertStmtAfter(*assign, *parent);
|
||||||
}
|
}
|
||||||
@@ -540,13 +539,10 @@ void replaceDistributedArraysInIO(vector<ParallelRegion*>& regions,
|
|||||||
|
|
||||||
auto func_info_it = allFuncInfo.find(current_file_name);
|
auto func_info_it = allFuncInfo.find(current_file_name);
|
||||||
if (func_info_it == allFuncInfo.end())
|
if (func_info_it == allFuncInfo.end())
|
||||||
{
|
|
||||||
printInternalError(convertFileName(__FILE__).c_str(), __LINE__);
|
printInternalError(convertFileName(__FILE__).c_str(), __LINE__);
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
auto *lbound_symb = new SgSymbol(PROCEDURE_NAME, "lbound");
|
auto *lbound_symb = new SgSymbol(FUNCTION_NAME, "lbound");
|
||||||
auto *ubound_symb = new SgSymbol(PROCEDURE_NAME, "ubound");
|
auto *ubound_symb = new SgSymbol(FUNCTION_NAME, "ubound");
|
||||||
|
|
||||||
for (auto& lines : lines_by_file.second)
|
for (auto& lines : lines_by_file.second)
|
||||||
{
|
{
|
||||||
@@ -594,10 +590,7 @@ void replaceDistributedArraysInIO(vector<ParallelRegion*>& regions,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!current_func_info)
|
if (!current_func_info)
|
||||||
{
|
|
||||||
printInternalError(convertFileName(__FILE__).c_str(), __LINE__);
|
printInternalError(convertFileName(__FILE__).c_str(), __LINE__);
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
curr_stmt = curr_stmt->lexNext();
|
curr_stmt = curr_stmt->lexNext();
|
||||||
while (curr_stmt && !isSgExecutableStatement(curr_stmt))
|
while (curr_stmt && !isSgExecutableStatement(curr_stmt))
|
||||||
|
|||||||
@@ -1,3 +1,3 @@
|
|||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#define VERSION_SPF "2443"
|
#define VERSION_SPF "2444"
|
||||||
|
|||||||
Reference in New Issue
Block a user