Boost logo

Boost Users :

Subject: Re: [Boost-users] Using boost::interprocess shared memory for both 32-bit and 64-bit processes
From: Ion Gaztañaga (igaztanaga_at_[hidden])
Date: 2010-09-20 11:08:56


El 20/09/2010 16:32, Jonathon escribió:
> Hello,
>
> I would like to read/write from/to boost::interprocess shared memory
> segments from a 32-bit process and a 64-bit process on the same
> machine. Is this possible? I've attempted to do this, but I seem to
> be experiencing some compatibility issues. Note that I am
> reading/writing boost::inteprocess containers to shared memory.

No. Basic data types used inside interprocess have no fixed width, so
processes with different ABIs can't shared managed resources. Note that
if the compiler uses a different ABI (EBO optimization, etc..) for 64
and 32 processes you an additional problem.

> If it is not possible to do this, what are some possible solutions for this?

There is fix, unless you reimplement Interprocess using news fixed width
classes :-(

Best,

Ion


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net