Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
amdis
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Aland, Sebastian
amdis
Commits
b115e944
Commit
b115e944
authored
Feb 08, 2012
by
Thomas Witkowski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Small changes and code refactoring in parallel AMDiS.
parent
a71cce06
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
28 additions
and
16 deletions
+28
-16
AMDiS/src/MeshStructure.cc
AMDiS/src/MeshStructure.cc
+8
-4
AMDiS/src/MeshStructure.h
AMDiS/src/MeshStructure.h
+2
-4
AMDiS/src/io/ArhReader.cc
AMDiS/src/io/ArhReader.cc
+4
-5
AMDiS/src/parallel/DofComm.cc
AMDiS/src/parallel/DofComm.cc
+7
-1
AMDiS/src/parallel/MeshDistributor.cc
AMDiS/src/parallel/MeshDistributor.cc
+5
-1
AMDiS/src/parallel/ParallelDebug.cc
AMDiS/src/parallel/ParallelDebug.cc
+1
-1
AMDiS/src/parallel/PetscSolverGlobalMatrix.cc
AMDiS/src/parallel/PetscSolverGlobalMatrix.cc
+1
-0
No files found.
AMDiS/src/MeshStructure.cc
View file @
b115e944
...
...
@@ -137,14 +137,18 @@ namespace AMDiS {
if
(
!
reverseOrder
)
{
if
(
s1
!=
-
1
)
addAlongSide
(
el
->
getFirstChild
(),
subObj
,
s1
,
el
->
getChildType
(
elType
),
reverseOrder
);
addAlongSide
(
el
->
getFirstChild
(),
subObj
,
s1
,
el
->
getChildType
(
elType
),
reverseOrder
);
if
(
s2
!=
-
1
)
addAlongSide
(
el
->
getSecondChild
(),
subObj
,
s2
,
el
->
getChildType
(
elType
),
reverseOrder
);
addAlongSide
(
el
->
getSecondChild
(),
subObj
,
s2
,
el
->
getChildType
(
elType
),
reverseOrder
);
}
else
{
if
(
s2
!=
-
1
)
addAlongSide
(
el
->
getSecondChild
(),
subObj
,
s2
,
el
->
getChildType
(
elType
),
reverseOrder
);
addAlongSide
(
el
->
getSecondChild
(),
subObj
,
s2
,
el
->
getChildType
(
elType
),
reverseOrder
);
if
(
s1
!=
-
1
)
addAlongSide
(
el
->
getFirstChild
(),
subObj
,
s1
,
el
->
getChildType
(
elType
),
reverseOrder
);
addAlongSide
(
el
->
getFirstChild
(),
subObj
,
s1
,
el
->
getChildType
(
elType
),
reverseOrder
);
}
}
}
...
...
AMDiS/src/MeshStructure.h
View file @
b115e944
...
...
@@ -66,10 +66,8 @@ namespace AMDiS {
reset
();
}
/** \brief
* Sets all position counters, that are used to traverse the code, to the starting
* position. The code itself is not changed.
*/
/// Sets all position counters, that are used to traverse the code, to the
/// starting position. The code itself is not changed.
void
reset
();
/// Returns whether the code is empty or not.
...
...
AMDiS/src/io/ArhReader.cc
View file @
b115e944
...
...
@@ -51,7 +51,6 @@ namespace AMDiS {
{
FUNCNAME
(
"ArhReader::read()"
);
#ifdef HAVE_PARALLEL_DOMAIN_AMDIS
if
(
writeParallel
)
{
using
boost
::
lexical_cast
;
int
sPos
=
filename
.
find
(
".arh"
);
...
...
@@ -59,8 +58,12 @@ namespace AMDiS {
string
name
=
filename
.
substr
(
0
,
sPos
);
if
(
nProcs
==
-
1
)
{
#ifdef HAVE_PARALLEL_DOMAIN_AMDIS
string
procFilename
=
name
+
"-p"
+
lexical_cast
<
string
>
(
MPI
::
COMM_WORLD
.
Get_rank
())
+
"-.arh"
;
readFile
(
procFilename
,
mesh
,
vecs
);
#else
ERROR_EXIT
(
"Reading parallel ARH files in sequential computations requires to specify the number of nodes on which the ARH file was created!
\n
"
);
#endif
}
else
{
for
(
int
i
=
0
;
i
<
nProcs
;
i
++
)
{
string
procFilename
=
name
+
"-p"
+
lexical_cast
<
string
>
(
i
)
+
"-.arh"
;
...
...
@@ -70,10 +73,6 @@ namespace AMDiS {
}
else
{
readFile
(
filename
,
mesh
,
vecs
);
}
#else
readFile
(
filename
,
mesh
,
vecs
);
#endif
MSG
(
"ARH file read from: %s
\n
"
,
filename
.
c_str
());
}
...
...
AMDiS/src/parallel/DofComm.cc
View file @
b115e944
...
...
@@ -18,7 +18,8 @@ namespace AMDiS {
void
DofComm
::
removeEmpty
()
{
for
(
DataIter
dit
=
data
.
begin
();
dit
!=
data
.
end
();
++
dit
)
{
DataIter
dit
=
data
.
begin
();
while
(
dit
!=
data
.
end
())
{
FeMapIter
it
=
dit
->
second
.
begin
();
while
(
it
!=
dit
->
second
.
end
())
{
if
(
it
->
second
.
size
()
==
0
)
{
...
...
@@ -28,6 +29,11 @@ namespace AMDiS {
}
else
++
it
;
}
if
(
dit
->
second
.
size
()
==
0
)
data
.
erase
(
dit
++
);
else
++
dit
;
}
}
...
...
AMDiS/src/parallel/MeshDistributor.cc
View file @
b115e944
...
...
@@ -777,6 +777,9 @@ namespace AMDiS {
double
first
=
MPI
::
Wtime
();
int
skip
=
0
;
Parameters
::
get
(
"parallel->debug->skip check mesh change"
,
skip
);
// === If mesh has not been changed on all ranks, return. ===
int
recvAllValues
=
0
;
...
...
@@ -789,6 +792,7 @@ namespace AMDiS {
// === At least one rank mesh has been changed, so the boundaries must be ===
// === adapted to the new mesh structure. ===
if
(
skip
==
0
)
do
{
bool
meshChanged
=
false
;
...
...
AMDiS/src/parallel/ParallelDebug.cc
View file @
b115e944
...
...
@@ -785,7 +785,7 @@ namespace AMDiS {
{
FUNCNAME
(
"ParallelDebug::writeCoordsFile()"
);
const
FiniteElemSpace
*
feSpace
=
pdb
.
feSpaces
[
0
];
const
FiniteElemSpace
*
feSpace
=
pdb
.
feSpaces
[
pdb
.
feSpaces
.
size
()
-
1
];
stringstream
filename
;
filename
<<
prefix
<<
"-"
<<
pdb
.
mpiRank
<<
"."
<<
postfix
;
...
...
AMDiS/src/parallel/PetscSolverGlobalMatrix.cc
View file @
b115e944
...
...
@@ -431,6 +431,7 @@ namespace AMDiS {
(
"Should not happen!
\n
"
);
int
rowIndex
=
rowIt
->
first
;
MatSetValues
(
petscMatrix
,
1
,
&
rowIndex
,
rowIt
->
second
.
size
(),
&
(
rowIt
->
second
[
0
]),
&
(
valsMap
[
rowIt
->
first
][
0
]),
ADD_VALUES
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment