Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-alugrid
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ag-ohlberger
dune-community
dune-alugrid
Commits
d739477e
Commit
d739477e
authored
12 years ago
by
Martin Nolte
Browse files
Options
Downloads
Patches
Plain Diff
migrate mpi dependence to aluparmetis.hh
parent
41fc66cb
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dune/alugrid/src/parallel/aluparmetis.hh
+16
-14
16 additions, 14 deletions
dune/alugrid/src/parallel/aluparmetis.hh
dune/alugrid/src/parallel/gitter_pll_ldb.cc
+2
-5
2 additions, 5 deletions
dune/alugrid/src/parallel/gitter_pll_ldb.cc
with
18 additions
and
19 deletions
dune/alugrid/src/parallel/aluparmetis.hh
+
16
−
14
View file @
d739477e
...
...
@@ -32,37 +32,39 @@ inline void CALL_ParMETIS_V3_PartKway(
idxtype
*
vtxdist
,
idxtype
*
xadj
,
idxtype
*
adjncy
,
idxtype
*
vwgt
,
idxtype
*
adjwgt
,
idxtype
*
wgtflag
,
idxtype
*
numflag
,
idxtype
*
ncon
,
idxtype
*
nparts
,
realtype
*
tpwgts
,
realtype
*
ubvec
,
idxtype
*
options
,
idxtype
*
edgecut
,
idxtype
*
part
,
M
PI_Comm
*
comm
)
M
pAccessGlobal
&
mpa
)
{
#if HAVE_PARMETIS
// get communincator (see mpAccess_MPI.cc)
MPI_Comm
comm
=
getMPICommunicator
(
mpa
.
communicator
()
);
::
ParMETIS_V3_PartKway
(
vtxdist
,
xadj
,
adjncy
,
vwgt
,
adjwgt
,
wgtflag
,
numflag
,
ncon
,
nparts
,
tpwgts
,
ubvec
,
options
,
edgecut
,
part
,
comm
)
;
#else
ubvec
,
options
,
edgecut
,
part
,
&
comm
)
;
#else
// #if HAVE_PARMETIS
std
::
cerr
<<
"**ERROR The use of ParMETIS is not supported, when the ParMETIS library is missing! in: "
<<
__FILE__
<<
" line: "
<<
__LINE__
<<
"
\n
"
;
std
::
cerr
<<
parmetmess
<<
std
::
endl
;
exit
(
1
);
#endif
return
;
exit
(
1
);
#endif // #else // #if HAVE_PARMETIS
}
inline
void
CALL_ParMETIS_V3_AdaptiveRepart
(
idxtype
*
vtxdist
,
idxtype
*
xadj
,
idxtype
*
adjncy
,
idxtype
*
vwgt
,
idxtype
*
vsize
,
idxtype
*
adjwgt
,
idxtype
*
wgtflag
,
idxtype
*
numflag
,
idxtype
*
ncon
,
idxtype
*
nparts
,
realtype
*
tpwgts
,
realtype
*
ubvec
,
realtype
*
ipc2redist
,
idxtype
*
options
,
idxtype
*
edgecut
,
idxtype
*
part
,
MPI_Comm
*
comm
)
idxtype
*
options
,
idxtype
*
edgecut
,
idxtype
*
part
,
MpAccessGlobal
&
mpa
)
{
#if HAVE_PARMETIS
// get communincator (see mpAccess_MPI.cc)
MPI_Comm
comm
=
getMPICommunicator
(
mpa
.
communicator
()
);
::
ParMETIS_V3_AdaptiveRepart
(
vtxdist
,
xadj
,
adjncy
,
vwgt
,
vsize
,
adjwgt
,
wgtflag
,
numflag
,
ncon
,
nparts
,
tpwgts
,
ubvec
,
ipc2redist
,
options
,
edgecut
,
part
,
comm
)
;
#else
ubvec
,
ipc2redist
,
options
,
edgecut
,
part
,
&
comm
)
;
#else
// #if HAVE_PARMETIS
std
::
cerr
<<
"**ERROR The use of ParMETIS is not supported, when the ParMETIS library is missing! in: "
<<
__FILE__
<<
" line: "
<<
__LINE__
<<
"
\n
"
;
std
::
cerr
<<
parmetmess
<<
std
::
endl
;
exit
(
1
);
#endif
return
;
exit
(
1
);
#endif // #else // #if HAVE_PARMETIS
}
}
#endif
#endif // #ifndef PARMETIS_H_INCLUDED
This diff is collapsed.
Click to expand it.
dune/alugrid/src/parallel/gitter_pll_ldb.cc
+
2
−
5
View file @
d739477e
...
...
@@ -805,15 +805,12 @@ bool LoadBalancer :: DataBase :: repartition (MpAccessGlobal & mpa,
idx_t
options
[
4
]
=
{
0
,
1
,
15
,
1
};
// these are the default values
idx_t
nparts
=
np
;
// get communincator (see mpAccess_MPI.cc)
MPI_Comm
comm
=
getMPICommunicator
(
mpa
.
communicator
()
);
// for starting partitions use PartKway
if
(
usePartKway
)
{
ALUGridParMETIS
::
CALL_ParMETIS_V3_PartKway
(
vtxdist
,
edge_p
,
edge
,
vertex_wInt
,
edge_w
,
&
wgtflag
,
&
numflag
,
&
ncon
,
&
nparts
,
tpwgts
,
ubvec
,
options
,
&
edgecut
,
neu
,
&
comm
)
;
ubvec
,
options
,
&
edgecut
,
neu
,
mpa
);
}
else
// otherwise do an adaptive repartition
{
...
...
@@ -832,7 +829,7 @@ bool LoadBalancer :: DataBase :: repartition (MpAccessGlobal & mpa,
//cout << "Call AdaptiveRepart \n";
ALUGridParMETIS
::
CALL_ParMETIS_V3_AdaptiveRepart
(
vtxdist
,
edge_p
,
edge
,
vertex_wInt
,
vsize
,
edge_w
,
&
wgtflag
,
&
numflag
,
&
ncon
,
&
nparts
,
tpwgts
,
ubvec
,
&
itr
,
options
,
&
edgecut
,
neu
,
&
comm
)
;
ubvec
,
&
itr
,
options
,
&
edgecut
,
neu
,
mpa
);
}
// delete vtxdist and set zero (see below)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment