[mpich2-commits] r5554 - in mpich2/trunk: . src/mpid/ch3/channels/nemesis/nemesis/include
balaji at mcs.anl.gov
balaji at mcs.anl.gov
Mon Oct 26 10:01:50 CDT 2009
Author: balaji
Date: 2009-10-26 10:01:49 -0500 (Mon, 26 Oct 2009)
New Revision: 5554
Modified:
mpich2/trunk/configure.in
mpich2/trunk/src/mpid/ch3/channels/nemesis/nemesis/include/mpid_nem_datatypes.h
Log:
The padding in the nemesis cell structures was assuming that the
OPA_ptr_t would be the same size as a pointer. This is not true for
platforms where OPA_ptr_t is larger in order to keep alignments, for
example. This should fix ticket #906.
Reviewed by goodell.
Modified: mpich2/trunk/configure.in
===================================================================
--- mpich2/trunk/configure.in 2009-10-26 04:20:28 UTC (rev 5553)
+++ mpich2/trunk/configure.in 2009-10-26 15:01:49 UTC (rev 5554)
@@ -6056,8 +6056,12 @@
# Make subsystems available to makefiles.
subsystems="$devsubsystems $subsystems $bindingsubsystems"
AC_SUBST(subsystems)
-#
+# Find the size of OPA_ptr_t. This step needs to come after the OPA
+# configure above in order to get the size OPA_ptr_t evaluated for
+# this platform.
+AC_CHECK_SIZEOF(OPA_ptr_t,-1,[#include "${master_top_srcdir}/src/openpa/src/opa_primitives.h"])
+
if test "$enable_f77" != "yes" ; then
# These are Fortran datatypes ONLY. Set to null if no Fortran compiler.
for name in CHARACTER INTEGER REAL LOGICAL COMPLEX DOUBLE_PRECISION \
Modified: mpich2/trunk/src/mpid/ch3/channels/nemesis/nemesis/include/mpid_nem_datatypes.h
===================================================================
--- mpich2/trunk/src/mpid/ch3/channels/nemesis/nemesis/include/mpid_nem_datatypes.h 2009-10-26 04:20:28 UTC (rev 5553)
+++ mpich2/trunk/src/mpid/ch3/channels/nemesis/nemesis/include/mpid_nem_datatypes.h 2009-10-26 15:01:49 UTC (rev 5554)
@@ -185,7 +185,7 @@
typedef struct MPID_nem_cell
{
MPID_nem_cell_rel_ptr_t next;
-#if MPID_NEM_CELL_HEAD_LEN != SIZEOF_VOID_P
+#if MPID_NEM_CELL_HEAD_LEN != SIZEOF_OPA_PTR_T
char padding[MPID_NEM_CELL_HEAD_LEN - sizeof(MPID_nem_cell_rel_ptr_t)];
#endif
volatile MPID_nem_pkt_t pkt;
@@ -222,11 +222,11 @@
{
MPID_nem_cell_rel_ptr_t head;
MPID_nem_cell_rel_ptr_t tail;
-#if MPID_NEM_CACHE_LINE_LEN != (2 * SIZEOF_VOID_P)
+#if MPID_NEM_CACHE_LINE_LEN != (2 * SIZEOF_OPA_PTR_T)
char padding1[MPID_NEM_CACHE_LINE_LEN - 2 * sizeof(MPID_nem_cell_rel_ptr_t)];
#endif
MPID_nem_cell_rel_ptr_t my_head;
-#if MPID_NEM_CACHE_LINE_LEN != SIZEOF_VOID_P
+#if MPID_NEM_CACHE_LINE_LEN != SIZEOF_OPA_PTR_T
char padding2[MPID_NEM_CACHE_LINE_LEN - sizeof(MPID_nem_cell_rel_ptr_t)];
#endif
#if !defined(MPID_NEM_USE_LOCK_FREE_QUEUES)
More information about the mpich2-commits
mailing list