Boost logo

Boost Users :

Subject: Re: [Boost-users] [Interprocess] Using shared Memory with different compilers (msvc, mingw)
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2009-10-29 11:49:18


AMDG

BaDBuTz wrote:
> I'll change the std::string to
> boost::interprocess::basic_string::string or basic_string.
>
> What does SBO stand for? I searched the web but couldn't find anything.

Small buffer optimization. In this case, it means that small strings
will be stored directly in the string object instead of being allocated
on the heap.

> Can I use interprocess with different compilers, if I store the
> elements of the SyncObject(U32 values, mutexes, strings) directly in
> the Shmem without wrapping them into the SyncObject container?
>
> example:
> pMtxReadWrite = segment.construct<interprocess_mutex>(id.c_str() +
> "_mtx");
> plocAddrSp0Range = segment.construct<U32>(id.c_str() +
> "_locAddrSp0Range");
>
> then I use the pointers now as if they are in the SyncObject before.

I don't think it matters. Unless the internal data structures used
by Interprocess and all the types involved have exactly the
same layout you can't use managed_shared_memory with different
compilers.

In Christ,
Steven Watanabe


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