Re: standby promotion can create unreadable WAL

2022-08-27 Thread Dilip Kumar
On Fri, Aug 26, 2022 at 7:53 PM Robert Haas wrote: > > On Fri, Aug 26, 2022 at 10:06 AM Alvaro Herrera > wrote: > > There's a small typo in the comment: "When find that". I suppose that > > was meant to be "When we find that". You end that para with "and thus > > we should not do this", but

Re: use ARM intrinsics in pg_lfind32() where available

2022-08-27 Thread Nathan Bossart
Here is a new patch set in which I've attempted to address all feedback. -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From a5f381097819db05b6e47418597cd56bab411fad Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Thu, 25 Aug 2022 22:18:30 -0700 Subject: [PATCH v5 1/2]

Re: [RFC] building postgres with meson - v12

2022-08-27 Thread Thomas Munro
On Sun, Aug 28, 2022 at 1:39 PM Andres Freund wrote: > On 2022-08-27 18:02:40 -0700, Andres Freund wrote: > > FWIW, I did notice that netbsd does have working unnamed semaphores. I don't > > know how long ago they were added, but they apparently didn't work quite > > right > > in 2018 [1]. No

Re: [RFC] building postgres with meson - v12

2022-08-27 Thread Andres Freund
Hi, On 2022-08-27 18:02:40 -0700, Andres Freund wrote: > FWIW, I did notice that netbsd does have working unnamed semaphores. I don't > know how long ago they were added, but they apparently didn't work quite right > in 2018 [1]. No meaningful performance chance in the main regression tests, >

Re: [RFC] building postgres with meson - v12

2022-08-27 Thread Andres Freund
Hi, On 2022-08-27 11:04:47 -0700, Andres Freund wrote: > - choice of semaphore API needs to be cleaned up, that should be easy now, but > I thought that I needed to get a new version out first Everytime I look at the existing selection code I get confused, which is part of why I haven't

Re: Backends stunk in wait event IPC/MessageQueueInternal

2022-08-27 Thread Thomas Munro
On Sun, Jun 26, 2022 at 11:18 AM Thomas Munro wrote: > On Tue, May 17, 2022 at 3:31 PM Thomas Munro wrote: > > On Mon, May 16, 2022 at 3:45 PM Japin Li wrote: > > > Maybe use the __illumos__ macro more accurity. > > > > > > +#elif defined(WAIT_USE_EPOLL) && defined(HAVE_SYS_SIGNALFD_H) && \ > >

Re: use ARM intrinsics in pg_lfind32() where available

2022-08-27 Thread Nathan Bossart
On Sun, Aug 28, 2022 at 10:39:09AM +1200, Thomas Munro wrote: > On Sun, Aug 28, 2022 at 10:12 AM Nathan Bossart > wrote: >> Yup. The problem is that AFAICT there's no equivalent to >> _mm_movemask_epi8() on aarch64, so you end up with something like >> >> vmaxvq_u8(vandq_u8(v,

Re: use ARM intrinsics in pg_lfind32() where available

2022-08-27 Thread Thomas Munro
On Sun, Aug 28, 2022 at 10:12 AM Nathan Bossart wrote: > Yup. The problem is that AFAICT there's no equivalent to > _mm_movemask_epi8() on aarch64, so you end up with something like > > vmaxvq_u8(vandq_u8(v, vector8_broadcast(0x80))) != 0 > > But for pg_lfind32(), we really just want to

Re: use ARM intrinsics in pg_lfind32() where available

2022-08-27 Thread Nathan Bossart
On Sat, Aug 27, 2022 at 05:18:34PM -0400, Tom Lane wrote: > In short, I think the critical part of 0002 needs to look more like > this: > > +#elif defined(__aarch64__) && defined(__ARM_NEON) > +/* > + * We use the Neon instructions if the compiler provides access to them > + * (as indicated by

Re: use ARM intrinsics in pg_lfind32() where available

2022-08-27 Thread Nathan Bossart
Thanks for taking a look. On Sat, Aug 27, 2022 at 01:59:06PM +0700, John Naylor wrote: > I don't forsee any use of emulating vector registers with uint64 if > they only hold two ints. I wonder if it'd be better if all vector32 > functions were guarded with #ifndef NO_USE_SIMD. (I wonder if >

Re: use ARM intrinsics in pg_lfind32() where available

2022-08-27 Thread Tom Lane
I spent a bit more time researching the portability implications of this patch. I think that we should check __ARM_NEON before #including ; there is authoritative documentation out there telling you to, eg [1], and I can see no upside at all to not checking. We cannot check *only* __ARM_NEON,

[Commitfest 2022-09] Begins This Thursday

2022-08-27 Thread Ibrar Ahmed
Hi all, Just a reminder that September 2022 commitfest will begin this coming Thursday, September 1. As of now, there have been “267” patches in total. Out of these 267 patches, “22” patches required committer attention. Unfortunately, only three patches have a committer. I think the author

Re: [PATCH] Add native windows on arm64 support

2022-08-27 Thread Andres Freund
Hi, On 2022-08-27 11:33:51 +0900, Michael Paquier wrote: > FWIW, I would not mind re-enabling that on HEAD, as of something like the > attached. I have done a dozen of runs without seeing a test failure, and > knowing that we don't support anything older than Win10 makes me feel safer > about

Re: SQL/JSON features for v15

2022-08-27 Thread Jonathan S. Katz
On 8/26/22 4:36 PM, Andrew Dunstan wrote: On 2022-08-26 Fr 16:11, Nikita Glukhov wrote: Hi, On 26.08.2022 22:25, Andrew Dunstan wrote: On 2022-08-24 We 20:05, Nikita Glukhov wrote: v8 - is a highly WIP patch, which I failed to finish today. Even some test cases fail now, and they simply

Re: First draft of the PG 15 release notes

2022-08-27 Thread Matthias van de Meent
Hi, I noticed a stray "DETAILS?" marker while going through the release notes for 15. Is that subsection still under construction or review? > > > Record and check the collation of eachlinkend="sql-createdatabase">database (Peter Eisentraut) > [...] > to match the

Re: [BUG] Logical replication failure "ERROR: could not map filenode "base/13237/442428" to relation OID" with catalog modifying txns

2022-08-27 Thread Masahiko Sawada
On Sat, Aug 27, 2022 at 7:24 PM Amit Kapila wrote: > > On Sat, Aug 27, 2022 at 1:06 PM Masahiko Sawada wrote: > > > > On Sat, Aug 27, 2022 at 3:56 PM Amit Kapila wrote: > > > > > > On Fri, Jul 29, 2022 at 12:15 PM Amit Kapila > > > wrote: > > > > > > > > > > > > > > Yeah, your description

Re: Use array as object (src/fe_utils/parallel_slot.c)

2022-08-27 Thread Ranier Vilela
Em sáb., 27 de ago. de 2022 às 00:00, Michael Paquier escreveu: > On Fri, Aug 26, 2022 at 01:54:26PM -0300, Ranier Vilela wrote: > > Is it worth creating a commiffest? > > Don't think so, but feel free to create one and mark me as committer > if you think that's appropriate. I have marked this

Re: [BUG] Logical replication failure "ERROR: could not map filenode "base/13237/442428" to relation OID" with catalog modifying txns

2022-08-27 Thread Amit Kapila
On Sat, Aug 27, 2022 at 1:06 PM Masahiko Sawada wrote: > > On Sat, Aug 27, 2022 at 3:56 PM Amit Kapila wrote: > > > > On Fri, Jul 29, 2022 at 12:15 PM Amit Kapila > > wrote: > > > > > > > > > > > Yeah, your description makes sense to me. I've also considered how to > > > > hit this path but I

Re: Avoid erroring out when unable to remove or parse logical rewrite files to save checkpoint work

2022-08-27 Thread Bharath Rupireddy
On Thu, Aug 25, 2022 at 5:51 PM Michael Paquier wrote: > > FWIW, the changes in reorderbuffer.c for > ReorderBufferCleanupSerializedTXNs() reduce the code readability, in > my opinion, so that's one less argument in favor of this change. Agreed. I reverted the changes. > The gain in

Re: pg_stat_wal: tracking the compression effect

2022-08-27 Thread Bharath Rupireddy
On Fri, Aug 26, 2022 at 8:39 AM Kyotaro Horiguchi wrote: > > At Fri, 26 Aug 2022 11:55:27 +0900 (JST), Kyotaro Horiguchi > wrote in > > At Thu, 25 Aug 2022 16:04:50 +0900, Ken Kato > > wrote in > > > Accumulating the values, which indicates how much space is saved by > > > each compression

Re: [BUG] Logical replication failure "ERROR: could not map filenode "base/13237/442428" to relation OID" with catalog modifying txns

2022-08-27 Thread Masahiko Sawada
On Sat, Aug 27, 2022 at 3:56 PM Amit Kapila wrote: > > On Fri, Jul 29, 2022 at 12:15 PM Amit Kapila wrote: > > > > > > > > Yeah, your description makes sense to me. I've also considered how to > > > hit this path but I guess it is never hit. Thinking of it in another > > > way, first of all, at

Re: windows cfbot failing: my_perl

2022-08-27 Thread John Naylor
On Sat, Aug 27, 2022 at 2:23 PM Andres Freund wrote: > > Hi, > > On 2022-08-27 12:53:24 +0700, John Naylor wrote: > > Update: I tried taking the CI for a spin, but ran into IT issues with > > Github when I tried to push my branch to remote. > > A github, not a CI issue? Just making sure... Yeah,

Re: windows cfbot failing: my_perl

2022-08-27 Thread Andres Freund
Hi, On 2022-08-27 12:53:24 +0700, John Naylor wrote: > On Sat, Aug 27, 2022 at 11:20 AM John Naylor > wrote: > > > > Here's a patch with that idea, not tested on Windows yet. > > Update: I tried taking the CI for a spin, but ran into IT issues with > Github when I tried to push my branch to

Re: windows cfbot failing: my_perl

2022-08-27 Thread Andres Freund
On 2022-08-26 23:02:06 -0400, Tom Lane wrote: > John Naylor writes: > > On Sat, Aug 27, 2022 at 4:15 AM Andres Freund wrote: > >> I think it'd also be needed in hstore_plperl.c, jsonb_plperl.c. Putting the > >> include in plperl.h would keep that aspect transparent, because > >> plperl_utils.h

Re: use ARM intrinsics in pg_lfind32() where available

2022-08-27 Thread John Naylor
On Sat, Aug 27, 2022 at 1:24 AM Nathan Bossart wrote: > > Here is a rebased patch set that applies to HEAD. 0001: #define USE_NO_SIMD typedef uint64 Vector8; +typedef uint64 Vector32; #endif I don't forsee any use of emulating vector registers with uint64 if they only hold two ints. I

Re: [BUG] Logical replication failure "ERROR: could not map filenode "base/13237/442428" to relation OID" with catalog modifying txns

2022-08-27 Thread Amit Kapila
On Fri, Jul 29, 2022 at 12:15 PM Amit Kapila wrote: > > > > > Yeah, your description makes sense to me. I've also considered how to > > hit this path but I guess it is never hit. Thinking of it in another > > way, first of all, at least 2 catalog modifying transactions have to > > be running