Re: global / super barriers (for checksums)

2020-01-03 Thread Robert Haas
On Mon, Dec 9, 2019 at 10:42 AM Robert Haas wrote: > > Hm. In my mental model it would be useful for barrier "processors" to > > not acknowledge the state change at certain points. Imagine e.g. needing > > to efficiently wait till all backends have processed a config file > > reload - since we don

Re: global / super barriers (for checksums)

2019-12-19 Thread Magnus Hagander
On Thu, Dec 19, 2019 at 8:57 PM Robert Haas wrote: > On Tue, Dec 17, 2019 at 1:38 PM Robert Haas wrote: > > On Thu, Dec 12, 2019 at 2:54 PM Andres Freund > wrote: > > > I'd either add a test (if we have some) or placeholder kind > > > initially. But I'd also be ok with going for either of the o

Re: global / super barriers (for checksums)

2019-12-19 Thread Robert Haas
On Tue, Dec 17, 2019 at 1:38 PM Robert Haas wrote: > On Thu, Dec 12, 2019 at 2:54 PM Andres Freund wrote: > > I'd either add a test (if we have some) or placeholder kind > > initially. But I'd also be ok with going for either of the other > > versions directly - but it seems harder to tackle the

Re: global / super barriers (for checksums)

2019-12-17 Thread Sergei Kornilov
Hi > Andrew Gierth complained about this too over on -committers, and I saw > his message first and pushed a fix. It includes the first and third > hunks from your proposed patch, but not the second one. Yep, I received his email just after sending mine. Thanks, my build is clean now. regards,

Re: global / super barriers (for checksums)

2019-12-17 Thread Robert Haas
On Tue, Dec 17, 2019 at 1:44 PM Sergei Kornilov wrote: > > Stellar. If nobody objects in the meantime, I plan to commit 0001-0003 > > next week. > > My compiler (gcc 8.3.0) is not happy with recent > 5910d6c7e311f0b14e3d3cb9ce3597c01d3a3cde commit: > > autovacuum.c:831:1: error: ‘AutoVacLauncherS

Re: global / super barriers (for checksums)

2019-12-17 Thread Sergei Kornilov
Hello > Stellar. If nobody objects in the meantime, I plan to commit 0001-0003 > next week. My compiler (gcc 8.3.0) is not happy with recent 5910d6c7e311f0b14e3d3cb9ce3597c01d3a3cde commit: autovacuum.c:831:1: error: ‘AutoVacLauncherShutdown’ was used with no prototype before its definition [-

Re: global / super barriers (for checksums)

2019-12-17 Thread Robert Haas
On Thu, Dec 12, 2019 at 2:54 PM Andres Freund wrote: > I'd either add a test (if we have some) or placeholder kind > initially. But I'd also be ok with going for either of the other > versions directly - but it seems harder to tackle the patches together. OK. I have committed 0001-0003 as I had m

Re: global / super barriers (for checksums)

2019-12-12 Thread Andres Freund
Hi, On 2019-12-11 13:35:26 -0500, Robert Haas wrote: > While I have passionate philosophical feelings about this topic, for > purposes of the present thread the really important question (IMV, > anyway) is whether there's any way of getting a patch for global > barriers committed in advance of the

Re: global / super barriers (for checksums)

2019-12-11 Thread Robert Haas
On Wed, Dec 11, 2019 at 12:38 PM Andres Freund wrote: > I just don't buy this argument. There's a difference in between an > unpatched version of postgres suddenly potentially running hooks > everywhere CFI() etc is called, and some user patching postgres to > behave differently. In the former cas

Re: global / super barriers (for checksums)

2019-12-11 Thread Andres Freund
Hi, On 2019-12-11 09:12:49 -0500, Robert Haas wrote: > On Mon, Dec 9, 2019 at 7:37 PM Daniel Gustafsson wrote: > > I sort of like the callback idea conceptually, but Andres is making a good > > point about the extensibility actually making it harder to reason about. > > That objection doesn't ho

Re: global / super barriers (for checksums)

2019-12-11 Thread Robert Haas
On Mon, Dec 9, 2019 at 7:37 PM Daniel Gustafsson wrote: > I've read through the patchset and played around with it to try and break it > and understand it (not in that order). Being a bit out of my comfort zone, I > can't offer the deep insights that Andres has done; but in reading the code it >

Re: global / super barriers (for checksums)

2019-12-09 Thread Daniel Gustafsson
> On 9 Dec 2019, at 16:42, Robert Haas wrote: > On Fri, Dec 6, 2019 at 12:17 PM Andres Freund wrote: I've read through the patchset and played around with it to try and break it and understand it (not in that order). Being a bit out of my comfort zone, I can't offer the deep insights that Andre

Re: global / super barriers (for checksums)

2019-12-09 Thread Robert Haas
On Fri, Dec 6, 2019 at 12:17 PM Andres Freund wrote: > > 0001 is just a code movement patch. It puts the interrupt handling for > > each type of background process into a subroutine, instead of having > > it all inline in the main loop. I feel this makes things more clear. > > Hopefully it's uncon

Re: global / super barriers (for checksums)

2019-12-06 Thread Andres Freund
Hi, Thanks for the updated version! On 2019-12-02 13:06:24 -0500, Robert Haas wrote: > On Sun, Nov 17, 2019 at 8:38 AM Magnus Hagander wrote: > > I'm definitely happy to work with it, but I did not and do not feel I have > > the skills for doing the "proper review" needed for it. So I am also v

Re: global / super barriers (for checksums)

2019-12-02 Thread Robert Haas
On Sun, Nov 17, 2019 at 8:38 AM Magnus Hagander wrote: > I'm definitely happy to work with it, but I did not and do not feel I have > the skills for doing the "proper review" needed for it. So I am also very > happy for you to pick it up and run with it. OK, here's what I came up with. 0001 is

Re: global / super barriers (for checksums)

2019-11-25 Thread Robert Haas
On Wed, Nov 13, 2019 at 12:26 PM Robert Haas wrote: > On the other hand, 0002 seems like it's pretty clearly a good idea. It > makes a whole bunch of auxiliary processes use > procsignal_sigusr1_handler() and those things all get called from > AuxiliaryProcessMain(), which does ProcSignalInit(), a

Re: global / super barriers (for checksums)

2019-11-17 Thread Magnus Hagander
On Wed, Nov 13, 2019 at 8:45 PM Andres Freund wrote: > Hi, > > On 2019-11-13 12:26:34 -0500, Robert Haas wrote: > > TL;DR: I'm not sure that we need 0001; I propose to commit 0002; and I > > have some concerns about 0003 and am interested in working further on > > it. > > Thanks for looking at th

Re: global / super barriers (for checksums)

2019-11-14 Thread Robert Haas
On Wed, Nov 13, 2019 at 2:45 PM Andres Freund wrote: > I might be missing something. Aren't all of the places where those > checks are places where we currently can't do a CHECK_FOR_INTERRUPTS()? > I've swapped this thoroughly out of my mind, but going through them: > > 1) AutoVacLauncherMain() -

Re: global / super barriers (for checksums)

2019-11-13 Thread Andres Freund
Hi, On 2019-11-13 12:26:34 -0500, Robert Haas wrote: > TL;DR: I'm not sure that we need 0001; I propose to commit 0002; and I > have some concerns about 0003 and am interested in working further on > it. Thanks for looking at the patch! > 0001 changes the StartBackgroundWorker so that the SIGIN

Re: global / super barriers (for checksums)

2019-11-13 Thread Robert Haas
On Tue, Oct 30, 2018 at 1:17 AM Andres Freund wrote: > The patch definitely is in a prototype stage. At the very least it needs > a high-level comment somewhere, and some of the lower-level code needs > to be cleaned up. > > One thing I wasn't happy about is how checksum internals have to absorb >

Re: global / super barriers (for checksums)

2019-07-19 Thread Andres Freund
Hi, On 2019-07-10 15:31:11 +0200, Magnus Hagander wrote: > In re-reading this, I notice there are a lot of references to Intterrupt > (with two t). I'm guessing this is just a spelling error, and not something > that actually conveys some meaning? Just a spelling error. I think I wrote the patch

Re: global / super barriers (for checksums)

2019-07-10 Thread Magnus Hagander
On Tue, Oct 30, 2018 at 6:16 AM Andres Freund wrote: > Hi, > > Magnus cornered me at pgconf.eu and asked me whether I could prototype > the "barriers" I'd been talking about in the online checksumming thread. > > The problem there was to make sure that all processes, backends and > auxiliary proc

Re: global / super barriers (for checksums)

2018-12-27 Thread Magnus Hagander
On Thu, Dec 27, 2018 at 2:22 PM Andres Freund wrote: > Hi, > > On 2018-12-27 13:54:34 +0100, Magnus Hagander wrote: > > Finally getting around to playing with this one and it unfortunately > > doesn't apply anymore (0003). > > > > I think it's just a matter of adding those two rows though, right?

Re: global / super barriers (for checksums)

2018-12-27 Thread Andres Freund
Hi, On 2018-12-27 13:54:34 +0100, Magnus Hagander wrote: > Finally getting around to playing with this one and it unfortunately > doesn't apply anymore (0003). > > I think it's just a matter of adding those two rows though, right? That is, > it's not an actual conflict it's just something else ad

Re: global / super barriers (for checksums)

2018-12-27 Thread Magnus Hagander
On Tue, Oct 30, 2018 at 6:16 AM Andres Freund wrote: > Hi, > > Magnus cornered me at pgconf.eu and asked me whether I could prototype > the "barriers" I'd been talking about in the online checksumming thread. > > The problem there was to make sure that all processes, backends and > auxiliary proc