get_address fails on arm

Issue #29 resolved
Thomas Spura created an issue

It seems that there is an failure on arm with openmpi:

FAIL: testGetAddress (test_datatype.TestGetAddress)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "test/test_datatype.py", line 360, in testGetAddress
    self.assertEqual(addr, bufptr)
AssertionError: -2128074816 != 2166892480L
------------------------------------------------

It seems some cython type might be wrong, but actually this could also be a MPI failure and not mpi4py's...

The full log can be found here.

Comments (4)

  1. Lisandro Dalcin

    This is a signed vs unsigned integer issue. MPI_Get_address() returns addresses as MPI_Int (signed integral type), while Python is returning addresses as unsigned integer (but this is not consistent across Python versions, however I should check the status of this for Py26+). See yourself:

    >>> from struct import *
    >>> unpack('i', pack('I', 2166892480))
    (-2128074816,)
    

    In other words, the test case is broken and should be fixed.

  2. Thomas Spura reporter

    It seems MPI_Int has a different size on arm than on the other arches. Does this imply, that it is not possible to mix different arches in a multi node MPI program? (I'm just asking being curious, not if such a call would make sense ;)) I always expected to have MPI_Int of the same size accross architectures.

  3. Lisandro Dalcin

    Sorry, my previous comment is misleading. I was talking about MPI_Aint (not the A in the name).

    MPI_Aint should be equivalent to intptr_t. IOW, MPI_Aint is a signed integral type large enough to represent any address, e.g., in i386 MPI_Aint should be plain C int.

    About muti-arch MPI runs (heterogeneous environments in the parlance of the MPI standard), that is perfectly possible, though the MPI implementation has to provide support for it.

  4. Log in to comment