forked from spack/spack
-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge release/1.4.1 into jcsda_emc_spack_stack (#296)
* add noarch variant to scotch to disable SPACK_TARGET_ARGS * Update bufr package.py for v12.0.0 * remove debug line * Add [email protected] * Add MPI (MPI_Fint/mpi_comm_f2c) patch to scotch/parmetis * add comment for parmetis mpi patch * Fix style errors in eckit and scotch * Trigger CI --------- Co-authored-by: Alex Richert <[email protected]> Co-authored-by: Alex Richert <[email protected]>
- Loading branch information
1 parent
204f826
commit 01d6aa5
Showing
3 changed files
with
148 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
127 changes: 127 additions & 0 deletions
127
var/spack/repos/builtin/packages/scotch/parmetis-mpi.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,127 @@ | ||
diff --git a/src/libscotchmetis/parmetis_dgraph_order_f.c b/src/libscotchmetis/parmetis_dgraph_order_f.c | ||
index 44c2ede..549a834 100644 | ||
--- a/src/libscotchmetis/parmetis_dgraph_order_f.c | ||
+++ b/src/libscotchmetis/parmetis_dgraph_order_f.c | ||
@@ -46,7 +46,7 @@ | ||
/** # Version 6.0 : from : 13 sep 2012 **/ | ||
/** to : 18 may 2019 **/ | ||
/** # Version 7.0 : from : 21 jan 2023 **/ | ||
-/** to : 21 jan 2023 **/ | ||
+/** to : 30 jun 2023 **/ | ||
/** **/ | ||
/************************************************************/ | ||
|
||
@@ -76,11 +76,14 @@ const SCOTCH_Num * const numflag, \ | ||
const SCOTCH_Num * const options, \ | ||
SCOTCH_Num * const order, \ | ||
SCOTCH_Num * const sizes, \ | ||
-MPI_Comm * const commptr, \ | ||
+const MPI_Fint * const commptr, \ | ||
int * const revaptr), \ | ||
(vtxdist, xadj, adjncy, numflag, options, order, sizes, commptr, revaptr)) | ||
{ | ||
- *revaptr = SCOTCH_ParMETIS_V3_NodeND (vtxdist, xadj, adjncy, numflag, options, order, sizes, commptr); | ||
+ MPI_Comm commdat; | ||
+ | ||
+ commdat = MPI_Comm_f2c (*commptr); | ||
+ *revaptr = SCOTCH_ParMETIS_V3_NodeND (vtxdist, xadj, adjncy, numflag, options, order, sizes, &commdat); | ||
} | ||
|
||
/*******************/ | ||
@@ -101,10 +104,13 @@ const SCOTCH_Num * const numflag, \ | ||
const SCOTCH_Num * const options, \ | ||
SCOTCH_Num * const order, \ | ||
SCOTCH_Num * const sizes, \ | ||
-MPI_Comm * const commptr), \ | ||
+const MPI_Fint * const commptr), \ | ||
(vtxdist, xadj, adjncy, numflag, options, order, sizes, commptr)) | ||
{ | ||
- METISNAMEU (ParMETIS_V3_NodeND) (vtxdist, xadj, adjncy, numflag, options, order, sizes, commptr); | ||
+ MPI_Comm commdat; | ||
+ | ||
+ commdat = MPI_Comm_f2c (*commptr); | ||
+ METISNAMEU (ParMETIS_V3_NodeND) (vtxdist, xadj, adjncy, numflag, options, order, sizes, &commdat); | ||
} | ||
|
||
#endif /* SCOTCH_METIS_PREFIX */ | ||
diff --git a/src/libscotchmetis/parmetis_dgraph_part_f.c b/src/libscotchmetis/parmetis_dgraph_part_f.c | ||
index 2b76818..3bf66af 100644 | ||
--- a/src/libscotchmetis/parmetis_dgraph_part_f.c | ||
+++ b/src/libscotchmetis/parmetis_dgraph_part_f.c | ||
@@ -44,7 +44,7 @@ | ||
/** # Version 6.0 : from : 13 sep 2012 **/ | ||
/** to : 18 may 2019 **/ | ||
/** # Version 7.0 : from : 21 jan 2023 **/ | ||
-/** to : 21 jan 2023 **/ | ||
+/** to : 30 jun 2023 **/ | ||
/** **/ | ||
/************************************************************/ | ||
|
||
@@ -81,12 +81,15 @@ const float * const ubvec, \ | ||
const SCOTCH_Num * const options, \ | ||
SCOTCH_Num * const edgecut, \ | ||
SCOTCH_Num * const part, \ | ||
-MPI_Comm * const commptr, \ | ||
+const MPI_Fint * const commptr, \ | ||
int * const revaptr), \ | ||
(vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr, revaptr)) | ||
{ | ||
+ MPI_Comm commdat; | ||
+ | ||
+ commdat = MPI_Comm_f2c (*commptr); | ||
*revaptr = SCOTCH_ParMETIS_V3_PartKway (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, | ||
- ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr); | ||
+ ncon, nparts, tpwgts, ubvec, options, edgecut, part, &commdat); | ||
} | ||
|
||
/* | ||
@@ -111,12 +114,15 @@ const float * const ubvec, \ | ||
const SCOTCH_Num * const options, \ | ||
SCOTCH_Num * const edgecut, \ | ||
SCOTCH_Num * const part, \ | ||
-MPI_Comm * const commptr, \ | ||
+const MPI_Fint * const commptr, \ | ||
int * const revaptr), \ | ||
(vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr, revaptr)) | ||
{ | ||
+ MPI_Comm commdat; | ||
+ | ||
+ commdat = MPI_Comm_f2c (*commptr); | ||
*revaptr = SCOTCH_ParMETIS_V3_PartGeomKway (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, | ||
- ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr); | ||
+ ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, &commdat); | ||
} | ||
|
||
/*******************/ | ||
@@ -144,10 +150,13 @@ const float * const ubvec, \ | ||
const SCOTCH_Num * const options, \ | ||
SCOTCH_Num * const edgecut, \ | ||
SCOTCH_Num * const part, \ | ||
-MPI_Comm * const commptr), \ | ||
+const MPI_Fint * const commptr), \ | ||
(vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr)) | ||
{ | ||
- METISNAMEU (ParMETIS_V3_PartKway) (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr); | ||
+ MPI_Comm commdat; | ||
+ | ||
+ commdat = MPI_Comm_f2c (*commptr); | ||
+ METISNAMEU (ParMETIS_V3_PartKway) (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ncon, nparts, tpwgts, ubvec, options, edgecut, part, &commdat); | ||
} | ||
|
||
/* | ||
@@ -172,10 +181,13 @@ const float * const ubvec, | ||
const SCOTCH_Num * const options, \ | ||
SCOTCH_Num * const edgecut, \ | ||
SCOTCH_Num * const part, \ | ||
-MPI_Comm * const commptr), \ | ||
+const MPI_Fint * const commptr), \ | ||
(vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr)) | ||
{ | ||
- METISNAMEU (ParMETIS_V3_PartGeomKway) (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, commptr); | ||
+ MPI_Comm commdat; | ||
+ | ||
+ commdat = MPI_Comm_f2c (*commptr); | ||
+ METISNAMEU (ParMETIS_V3_PartGeomKway) (vtxdist, xadj, adjncy, vwgt, adjwgt, wgtflag, numflag, ndims, xyz, ncon, nparts, tpwgts, ubvec, options, edgecut, part, &commdat); | ||
} | ||
|
||
#endif /* SCOTCH_METIS_PREFIX */ |