Re: parallel restore fixes - Mailing list pgsql-hackers

From Tom Lane
Subject Re: parallel restore fixes
Date
Msg-id 19101.1236647780@sss.pgh.pa.us
Whole thread Raw
In response to Re: parallel restore fixes  (Andrew Dunstan <andrew@dunslane.net>)
Responses Re: parallel restore fixes  (Andrew Dunstan <andrew@dunslane.net>)
List pgsql-hackers
Andrew Dunstan <andrew@dunslane.net> writes:
> Tom Lane wrote:
>> Actually, why bother with init_dump_utils at all?

> Well, the Windows reference I have suggests TlsAlloc() needs to be 
> called early in the initialisation process ...

How early is early?  The proposed call sites for init_dump_utils seem
already long past the point where any libc-level infrastructure would
think it is "initialization" time.

>> I'd lose the added retval
>> variable too; that's not contributing anything.

> It is, in fact. Until I put that in I was getting constant crashes. I 
> suspect it's something to do with stuff Windows does under the hood on 
> function return.

Pardon me while I retrieve my eyebrows from the ceiling.  I think you've
got something going on there you don't understand, and you need to
understand it not just put in a cargo-cult fix.  (Especially one that's
not documented and hence likely to be removed by the next person who
touches the code.)
        regards, tom lane


pgsql-hackers by date:

Previous
From: Koichi Suzuki
Date:
Subject: Pg_lesslog 1.2 released
Next
From: ITAGAKI Takahiro
Date:
Subject: Re: Sampling Profler for Postgres