From: | Andres Freund <andres(at)anarazel(dot)de> |
---|---|
To: | Nico Williams <nico(at)cryptonector(dot)com> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Jimmy Yih <jyih(at)pivotal(dot)io>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [HACKERS] possible self-deadlock window after bad ProcessStartupPacket |
Date: | 2018-07-19 20:46:12 |
Message-ID: | 20180719204612.afjkuywbgxefyvgb@alap3.anarazel.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2018-07-19 15:42:46 -0500, Nico Williams wrote:
> On Thu, Jul 19, 2018 at 01:38:52PM -0700, Andres Freund wrote:
> > On 2018-07-19 15:27:06 -0500, Nico Williams wrote:
> > > No, the other thread does NOT continue to do whatever -- it
> > > blocks/sleeps forever waiting for the coming exit(3).
> > >
> > > I.e., quickdie() would look like this:
> > >
> > > [...]
> > >
> > > and the thread would basically do:
> > >
> > > [...]
> > >
> > > This use of threads does not require any changes to the rest of the
> > > codebase.
> >
> > Uhm, this'd already require a fair bit of threadsafety. Like at least
> > all of the memory allocator / context code. Nor is having threads
> > around unproblematic for subprocesses that are forked off. Nor does
> > this account for the portability work.
>
> Yes, but that's in libc. None of that is in the PG code itself.
That's simply entirely completely wrong. PG has a good chunk of memory
management layers (facilitating memory contexts) ontop of malloc. And
that's stateful.
Greetings,
Andres Freund
From | Date | Subject | |
---|---|---|---|
Next Message | Andres Freund | 2018-07-19 20:47:06 | Re: [HACKERS] possible self-deadlock window after bad ProcessStartupPacket |
Previous Message | Nico Williams | 2018-07-19 20:44:23 | Re: [HACKERS] possible self-deadlock window after bad ProcessStartupPacket |