
Hi all,

I'm working on getting BackendFork converted to a fork/exec model, and have
hit the following wall.

All the ShmemInitHash structures are allocated using DynaHashCxt. Clearly,
this context is going to have to be shared across backends in the fork/exec
case, but I can't see a non-trivial way of doing so.

Any ideas? (or have I mis-diagnosed the problem completely)

Cheers,
Claudio

--- 
Certain disclaimers and policies apply to all email sent from Memetrics.
For the full text of these disclaimers and policies see 
<a
href="http://www.memetrics.com/emailpolicy.html">http://www.memetrics.com/em
ailpolicy.html</a>

Wed, 3 Dec 2003 12:36:59 +1100 
Claudio Natoli <claudio.natoli@memetrics.com>
fork/exec problem: DynaHashCxt
Claudio Natoli <claudio.natoli@memetrics.com> writes:
> All the ShmemInitHash structures are allocated using DynaHashCxt.

I'm not sure if you're confusing backend-local hashes with shared
hashes, or hash control headers with the actual shared data.  But
the above is a false statement.  DynaHashCxt is not shared.

Shared hashes are a bit tricky because there is a backend-local
structure that has a pointer into the shared memory --- is that
what's confusing you?

Keep in mind that this code did work in a fork/exec context not
so many moons ago.  If you think you see a showstopper, it's a
relatively recent change and can be undone.

			regards, tom lane

Tue, 02 Dec 2003 23:12:04 -0500
Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] fork/exec problem: DynaHashCxt 