Boost logo

Boost :

From: Ion Gaztañaga (igaztanaga_at_[hidden])
Date: 2006-02-09 01:11:10


Hi Fred,

> There is some missing documentation for shmem.
> basic_named_shared_object is missing the member functions that are in
> basic_named_object_impl. I wouldn't have brought this up except that
> I've got a question about some of them. (Actually, Google's cache has
> some documentation on some of this. Is that out of date?)

I think that the problem is that doxygen-quickbook-boosbook team does
not show inherited funcitions. The functions are already commented in
the source code. What I can do for the final version is to implement all
functions in derived classes as forwarding functions to the base class
and document them so they are in the reference section.

In the documentation when I present shared_named_object, you can see all
the function and the comments for them. If you have any question about
them, please ask.

> When you create a named_shared_object, your examples do so on the
> stack in the creating (or opening) process. From looking at the code,
> it appears that a named_shared_object::segment_manager is created in
> the shared memory. These segment_managers are also undocumented, but
> it appears that they do many (all?) of the things that can be done
> through the named_shared_object.

Yes, the segment manager, as the documentation in the architecture
chapter says, is created in the shared memory. So it's the entity that
really does all the job. Named_shared_object and other front-ends create
the back-end memory and forward all functions to the segment manager. I
should document it, because it's a class that the user can need. Maybe I
should pull it out of the detail namespace.

> I'm hoping to use one of these. I'm hoping to store an offset_ptr to
> the segment_manager in a shared object that I'm creating. The object
> would then be able to use the segment_manager to allocate and
> deallocate shared memory.

Yes, that's the idea. You can have a relative pointer to the segment
manager, so that you have all allocation functions available from an
object placed in shared memory. That's the way all Shmem STL-like
allocators work.

Regards,

Ion


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk