Boost logo

Boost :

From: Pedro Lamarão (pedro.lamarao_at_[hidden])
Date: 2006-02-02 12:03:57


Ion Gaztañaga escreveu:

>> I suggest supplying a default constructor to the shared memory Allocator
>> (and generally making it compatible with the Allocator concept) in order
>> to allow the easiest uses, like:
>>
>> std::queue<boost::shmem::allocator> global_queue;
>
> But since a shared memory segment is dynamic (and because of that, the
> address is not known at compile time) how can the allocator know the
> address of the segment from where it has to allocate memory?

In the simplest of cases, the program (or the programmer) may not need
multiple shared memory segments.

My suggestion is for some kind of very simple default behaviour.

Is it possible for the default constructed allocator in my example above
 use some default segment?

-- 
Pedro Lamarão
Desenvolvimento
Intersix Technologies S.A.
SP: (55 11 3803-9300)
RJ: (55 21 3852-3240)
www.intersix.com.br
Your Security is our Business

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