Re: Remove last traces of HPPA support

2023-10-20 Thread Andres Freund
Hi, On 2023-10-20 22:06:55 -0400, Tom Lane wrote: > Noah Misch writes: > > If the next thing is a patch removing half of the fallback atomics, that is > > a > > solid reason to remove hppa. > > Agreed, though I don't think we have a clear proposal as to what > else to remove. > > > The code

Re: Add support for AT LOCAL

2023-10-20 Thread Tom Lane
Andres Freund writes: > On 2023-10-19 10:38:14 -0400, Robert Haas wrote: >> To be honest, I'm not entirely sure that even AIX gcc support is >> delivering enough value per unit work to justify keeping it around. >> But the xlc situation is worse. > Agreed with both. If it were just a platform

Re: Add support for AT LOCAL

2023-10-20 Thread Andres Freund
Hi, On 2023-10-19 10:38:14 -0400, Robert Haas wrote: > On Wed, Oct 18, 2023 at 7:33 PM Noah Misch wrote: > > I feel the gravity and longevity of xlc bugs has been out of proportion with > > the compiler's contribution to PostgreSQL. I would find it reasonable to > > revoke xlc support in v17+,

Re: post-recovery amcheck expectations

2023-10-20 Thread Noah Misch
On Mon, Oct 09, 2023 at 04:46:26PM -0700, Peter Geoghegan wrote: > On Wed, Oct 4, 2023 at 7:52 PM Noah Misch wrote: > Might make sense to test the fix for this issue using a similar > approach: by adding custom code that randomly throws errors at a point > that stresses the implementation. I'm

Remove extraneous break condition in logical slot advance function

2023-10-20 Thread Bharath Rupireddy
Hi, There exists an extraneous break condition in pg_logical_replication_slot_advance(). When the end of WAL or moveto LSN is reached, the main while condition helps to exit the loop, so no separate break condition is needed. Attached patch removes it. Thoughts? -- Bharath Rupireddy PostgreSQL

Re: Fix output of zero privileges in psql

2023-10-20 Thread Erik Wienhold
On 2023-10-20 22:35 +0200, David G. Johnston wrote: > Ok, I found my mis-understanding and better understand where you are all > coming from now; I apparently had the usage of NULL flip-flopped. > > Taking pg_tablespace as an example. Its "spcacl" column produces NULL for > default privileges

Re: Remove last traces of HPPA support

2023-10-20 Thread Tom Lane
Noah Misch writes: > If the next thing is a patch removing half of the fallback atomics, that is a > solid reason to remove hppa. Agreed, though I don't think we have a clear proposal as to what else to remove. > The code removed in the last proposed patch was > not that and was code that never

Re: Fix output of zero privileges in psql

2023-10-20 Thread Erik Wienhold
On 2023-10-20 08:42 +0200, Laurenz Albe wrote: > If you want to proceed with your patch, you could send a new version. v2 attached. > I think it could do with an added line of documentation to the > "Privileges" chapter, and I'd say that the regression tests should be > in "psql.sql" (not that

Re: The documentation for storage type 'plain' actually allows single byte header

2023-10-20 Thread Bruce Momjian
On Fri, Sep 29, 2023 at 06:45:52PM -0400, Tom Lane wrote: > Laurenz Albe writes: > > On Fri, 2023-09-29 at 18:19 -0400, Bruce Momjian wrote: > >> Where did we end with this? Is a doc patch the solution? > > > I don't think this went anywhere, and a doc patch is not the solution. > > Tom has

Re: LLVM 16 (opaque pointers)

2023-10-20 Thread Tom Lane
Thomas Munro writes: > (It'd be nice if the > build farm logged "$LLVM_CONFIG --version" somewhere.) It's not really the buildfarm script's responsibility to do that, but feel free to make configure do so. regards, tom lane

Re: Remove last traces of HPPA support

2023-10-20 Thread Noah Misch
On Fri, Oct 20, 2023 at 12:40:00PM -0700, Andres Freund wrote: > On 2023-10-19 17:23:04 -0700, Noah Misch wrote: > > On Thu, Oct 19, 2023 at 11:16:28AM -0400, Tom Lane wrote: > > > We removed support for the HP-UX OS in v16, but left in support > > > for the PA-RISC architecture, mainly because I

Re: LLVM 16 (opaque pointers)

2023-10-20 Thread Thomas Munro
On Sat, Oct 21, 2023 at 12:02 PM Thomas Munro wrote: > On Sat, Oct 21, 2023 at 11:12 AM Andres Freund wrote: > > I'm quite sure that jiting did pass on ppc64 at some point. > > Yeah, I remember debugging it on EDB's POWER machine. First off, we > know that LLVM < 7 doesn't work for us on POWER,

Re: [PoC] pg_upgrade: allow to upgrade publisher node

2023-10-20 Thread Bharath Rupireddy
On Fri, Oct 20, 2023 at 8:51 PM Zhijie Hou (Fujitsu) wrote: > > Attach the new version patch. Thanks. Here are some comments on v55 patch: 1. A nit: + +/* + * We also skip decoding in 'fast_forward' mode. In passing set the + * 'processing_required' flag to indicate, were it not for

Re: Server crash on RHEL 9/s390x platform against PG16

2023-10-20 Thread Andres Freund
Hi, On 2023-09-12 15:27:21 +0530, Suraj Kharage wrote: > *[edb@9428da9d2137 postgres]$ cat /etc/redhat-release AlmaLinux release 9.2 > (Turquoise Kodkod)[edb@9428da9d2137 postgres]$ lscpuArchitecture: > s390x CPU op-mode(s): 32-bit, 64-bit Address sizes:39 bits Can you provide

Re: LLVM 16 (opaque pointers)

2023-10-20 Thread Andres Freund
Hi, On 2023-10-21 12:02:51 +1300, Thomas Munro wrote: > On Sat, Oct 21, 2023 at 11:12 AM Andres Freund wrote: > > > I doubt I can get anywhere near an s390x though, and we definitely had > > > pre-existing problems on that arch. > > > > IMO an LLVM bug, rather than a postgres bug, but I guess

Re: LLVM 16 (opaque pointers)

2023-10-20 Thread Thomas Munro
On Sat, Oct 21, 2023 at 11:12 AM Andres Freund wrote: > On 2023-10-21 10:48:47 +1300, Thomas Munro wrote: > > On Thu, Oct 19, 2023 at 6:20 AM Thomas Munro wrote: > > I see that Mark has also just enabled --with-llvm on some POWER Linux > > animals, and they have failed in various ways. The

Re: Optimizing nbtree ScalarArrayOp execution, allowing multi-column ordered scans, skip scan

2023-10-20 Thread Peter Geoghegan
On Sun, Oct 15, 2023 at 1:50 PM Peter Geoghegan wrote: > Attached is v4, which applies cleanly on top of HEAD. This was needed > due to Alexandar Korotkov's commit e0b1ee17, "Skip checking of scan > keys required for directional scan in B-tree". > > Unfortunately I have more or less dealt with

Re: LLVM 16 (opaque pointers)

2023-10-20 Thread Andres Freund
Hi, On 2023-10-21 10:48:47 +1300, Thomas Munro wrote: > On Thu, Oct 19, 2023 at 6:20 AM Thomas Munro wrote: > > Interestingly, a new problem just showed up on the the RHEL9 s390x > > machine "lora", where a previously reported problem [1] apparently > > re-appeared. It complains about

Re: Remove last traces of HPPA support

2023-10-20 Thread Andres Freund
Hi, On 2023-10-20 17:46:59 -0400, Tom Lane wrote: > Andres Freund writes: > > On 2023-10-20 15:59:42 -0400, Tom Lane wrote: > >> Hmm, are you saying there's more of port/atomics/ that could be > >> removed? What exactly? > > > I was thinking we could remove the whole fallback path for atomic

Re: LLVM 16 (opaque pointers)

2023-10-20 Thread Tom Lane
Thomas Munro writes: > I doubt I can get anywhere near an s390x though, and we definitely had > pre-existing problems on that arch. Yeah. Too bad there's no s390x in the gcc compile farm. (I'm wondering how straight a line to draw between that fact and llvm's evident shortcomings on s390x.)

Re: LLVM 16 (opaque pointers)

2023-10-20 Thread Mark Wong
On Sat, Oct 21, 2023 at 10:48:47AM +1300, Thomas Munro wrote: > On Thu, Oct 19, 2023 at 6:20 AM Thomas Munro wrote: > > Interestingly, a new problem just showed up on the the RHEL9 s390x > > machine "lora", where a previously reported problem [1] apparently > > re-appeared. It complains about

Re: LLVM 16 (opaque pointers)

2023-10-20 Thread Thomas Munro
On Thu, Oct 19, 2023 at 6:20 AM Thomas Munro wrote: > Interestingly, a new problem just showed up on the the RHEL9 s390x > machine "lora", where a previously reported problem [1] apparently > re-appeared. It complains about incompatible layout, previously > blamed on mismatch between clang and

Re: Remove last traces of HPPA support

2023-10-20 Thread Tom Lane
Andres Freund writes: > On 2023-10-20 15:59:42 -0400, Tom Lane wrote: >> Hmm, are you saying there's more of port/atomics/ that could be >> removed? What exactly? > I was thinking we could remove the whole fallback path for atomic operations, > but it's a bit less, because we likely don't want

Re: Remove last traces of HPPA support

2023-10-20 Thread Andres Freund
Hi, On 2023-10-20 15:59:42 -0400, Tom Lane wrote: > Andres Freund writes: > > In addition to the point Tom has made, I think it's also not correct that > > hppa > > doesn't impose a burden: hppa is the only of our architectures that doesn't > > actually support atomic operations, requiring us

Re: Fix output of zero privileges in psql

2023-10-20 Thread David G. Johnston
On Fri, Oct 20, 2023 at 12:57 PM Tom Lane wrote: > "David G. Johnston" writes: > > On Fri, Oct 20, 2023 at 12:34 PM Tom Lane wrote: > >> As near as I can tell, doing both things (the \pset null fix and > >> substituting "(none)" for empty privileges) would be an acceptable > >> answer to

Re: Remove last traces of HPPA support

2023-10-20 Thread Tom Lane
Andres Freund writes: > In addition to the point Tom has made, I think it's also not correct that hppa > doesn't impose a burden: hppa is the only of our architectures that doesn't > actually support atomic operations, requiring us to have infrastructure to > backfill atomics using spinlocks.

Re: Fix output of zero privileges in psql

2023-10-20 Thread Tom Lane
"David G. Johnston" writes: > On Fri, Oct 20, 2023 at 12:34 PM Tom Lane wrote: >> As near as I can tell, doing both things (the \pset null fix and >> substituting "(none)" for empty privileges) would be an acceptable >> answer to everyone who has commented. Let's proceed with both >> patches,

Re: Fix output of zero privileges in psql

2023-10-20 Thread David G. Johnston
On Fri, Oct 20, 2023 at 12:34 PM Tom Lane wrote: > Laurenz Albe writes: > > I am not sure how to proceed. Perhaps it would indeed be better to have > > two competing commitfest entries. Both could be "ready for committer", > > and the committers can decide what they prefer. > > As near as I

Re: Remove last traces of HPPA support

2023-10-20 Thread Andres Freund
Hi, On 2023-10-19 17:23:04 -0700, Noah Misch wrote: > On Thu, Oct 19, 2023 at 11:16:28AM -0400, Tom Lane wrote: > > We removed support for the HP-UX OS in v16, but left in support > > for the PA-RISC architecture, mainly because I thought that its > > spinlock mechanism is weird enough to be a

Re: Meson build updates

2023-10-20 Thread Andres Freund
Hi, On 2023-07-12 18:53:03 -0500, Tristan Partin wrote: > Did you need anything more from the "Make finding pkg-config(python3) > more robust" patch? That one doesn't seem to have been applied yet. Sorry, was overloaded at the time and then lost track of it. Pushed now! Greetings, Andres

Re: Fix output of zero privileges in psql

2023-10-20 Thread Tom Lane
Laurenz Albe writes: > I am not sure how to proceed. Perhaps it would indeed be better to have > two competing commitfest entries. Both could be "ready for committer", > and the committers can decide what they prefer. As near as I can tell, doing both things (the \pset null fix and substituting

Re: Remove last traces of HPPA support

2023-10-20 Thread Tom Lane
I wrote: > Noah Misch writes: >> On Thu, Oct 19, 2023 at 11:16:28AM -0400, Tom Lane wrote: >>> Hence, the attached removes the remaining support for HPPA. >> I wouldn't do this. NetBSD/hppa still claims to exist, as does the OpenBSD >> equivalent. I presume its pkgsrc compiles this code. The

Re: controlling meson's parallelism (and some whining)

2023-10-20 Thread Tristan Partin
On Fri Oct 20, 2023 at 11:22 AM CDT, Tristan Partin wrote: On Thu Oct 19, 2023 at 12:44 PM CDT, Robert Haas wrote: > The obvious fix to this is to just tell 'meson test' how many > processes I'd like it to run. I thought maybe I could just do 'meson > -j8 test' but that does not work, because

Re: Improve WALRead() to suck data directly from WAL buffers when possible

2023-10-20 Thread Bharath Rupireddy
On Thu, Oct 12, 2023 at 4:13 AM Andres Freund wrote: > > On 2023-10-03 16:05:32 -0700, Jeff Davis wrote: > > On Sat, 2023-01-14 at 12:34 -0800, Andres Freund wrote: > > > One benefit would be that it'd make it more realistic to use direct > > > IO for WAL > > > - for which I have seen significant

Re: [PATCH] Extend ALTER OPERATOR to support adding commutator, negator, hashes, and merges

2023-10-20 Thread Tom Lane
jian he writes: > errmsg("operator attribute \"negator\" cannot be changed if it has > already been set"))); > I feel like the above message is not very helpful. I think it's okay to be concise about this as long as the operator we're referring to is the target of the ALTER. I agree that when

Re: Is this a problem in GenericXLogFinish()?

2023-10-20 Thread Jeff Davis
On Thu, 2023-10-19 at 16:12 -0400, Robert Haas wrote: > For what it's worth, though, I think it would be better to > just make these cases exceptions to your Assert OK, I'll probably commit something like v4 then. I still have a question though: if a buffer is exclusive-locked, unmodified and

Re: controlling meson's parallelism (and some whining)

2023-10-20 Thread Tristan Partin
On Thu Oct 19, 2023 at 12:44 PM CDT, Robert Haas wrote: The obvious fix to this is to just tell 'meson test' how many processes I'd like it to run. I thought maybe I could just do 'meson -j8 test' but that does not work, because the option is --num-processes and has no short version. Even

Re: trying again to get incremental backup

2023-10-20 Thread David Steele
On 10/19/23 16:00, Robert Haas wrote: On Thu, Oct 19, 2023 at 3:18 PM David Steele wrote: 0001 looks pretty good to me. The only thing I find a little troublesome is the repeated construction of file names with/without segment numbers in ResetUnloggedRelationsInDbspaceDir(), .e.g.: +

RE: [PoC] pg_upgrade: allow to upgrade publisher node

2023-10-20 Thread Zhijie Hou (Fujitsu)
On Friday, October 20, 2023 11:24 AM vignesh C wrote: > > On Thu, 19 Oct 2023 at 16:16, Hayato Kuroda (Fujitsu) > wrote: > > > > Dear Vignesh, > > > > Thanks for revieing! New patch can be available in [1]. > > > > > Few comments: > > > 1) Even if we comment 3rd point "Emit a non-transactional

RE: [PoC] pg_upgrade: allow to upgrade publisher node

2023-10-20 Thread Zhijie Hou (Fujitsu)
On Friday, October 20, 2023 9:50 AM Peter Smith wrote: > > Here are some review comments for v54-0001 Thanks for the review. > > == > src/backend/replication/slot.c > > 1. > + if (*invalidated && SlotIsLogical(s) && IsBinaryUpgrade) { > + ereport(ERROR,

Re: Patch: Improve Boolean Predicate JSON Path Docs

2023-10-20 Thread David Wheeler
On Oct 19, 2023, at 23:49, Erik Wienhold wrote: > I don't even know what that represents, probably not some fancy file > compression. Oh, weird. Trying from a webmail client instead. Best, David v5-0001-Improve-boolean-predicate-JSON-Path-docs.patch Description: Binary data

Re: trying again to get incremental backup

2023-10-20 Thread Jakub Wartak
Hi Robert, On Wed, Oct 4, 2023 at 10:09 PM Robert Haas wrote: > > On Tue, Oct 3, 2023 at 2:21 PM Robert Haas wrote: > > Here's a new patch set, also addressing Jakub's observation that > > MINIMUM_VERSION_FOR_WAL_SUMMARIES needed updating. > > Here's yet another new version.[..] Okay, so

Re: SQL:2011 application time

2023-10-20 Thread jian he
Hi. based on v16. /* Look up the FOR PORTION OF name requested. */ range_attno = attnameAttNum(targetrel, range_name, false); if (range_attno == InvalidAttrNumber) ereport(ERROR, (errcode(ERRCODE_UNDEFINED_COLUMN), errmsg("column or period \"%s\" of relation \"%s\" does not exist", range_name,

Re: Add the ability to limit the amount of memory that can be allocated to backends.

2023-10-20 Thread Stephen Frost
Greetings, * Andrei Lepikhov (a.lepik...@postgrespro.ru) wrote: > The only issue I worry about is the uncertainty and clutter that can be > created by this feature. In the worst case, when we have a complex error > stack (including the extension's CATCH sections, exceptions in stored >

Re: [PoC/RFC] Multiple passwords, interval expirations

2023-10-20 Thread Stephen Frost
Greetings, * Jeff Davis (pg...@j-davis.com) wrote: > On Wed, 2023-10-18 at 14:48 -0400, Stephen Frost wrote: > > Right, we need more observability, agreed, but that's not strictly > > necessary of this patch and could certainly be added independently.  > > Is > > there really a need to make this

Re: A performance issue with Memoize

2023-10-20 Thread Pavel Stehule
pá 20. 10. 2023 v 13:01 odesílatel Richard Guo napsal: > I noticed $subject with the query below. > > set enable_memoize to off; > > explain (analyze, costs off) > select * from tenk1 t1 left join lateral > (select t1.two as t1two, * from tenk1 t2 offset 0) s > on t1.two = s.two; >

RE: Initial Schema Sync for Logical Replication

2023-10-20 Thread Kumar, Sachin
> From: vignesh C > Sent: Thursday, October 19, 2023 10:41 AM > Can you rebase the patch and post the complete set of required changes for > the concurrent DDL, I will have a look at them. Sure , I will try to send the complete rebased patch within a week. Regards Sachin

A performance issue with Memoize

2023-10-20 Thread Richard Guo
I noticed $subject with the query below. set enable_memoize to off; explain (analyze, costs off) select * from tenk1 t1 left join lateral (select t1.two as t1two, * from tenk1 t2 offset 0) s on t1.two = s.two; QUERY PLAN

Re: BRIN minmax multi - incorrect distance for infinite timestamp/date

2023-10-20 Thread Ashutosh Bapat
On Thu, Oct 19, 2023 at 6:11 PM Ashutosh Bapat wrote: > > I think we should provide generate_series(date, date, integer) which > will use date + integer -> date. Just to be clear, I don't mean that this patch should add it. -- Best Wishes, Ashutosh Bapat

Re: Use virtual tuple slot for Unique node

2023-10-20 Thread Ashutosh Bapat
On Thu, Oct 19, 2023 at 4:26 PM David Rowley wrote: > > On Thu, 19 Oct 2023 at 22:29, David Rowley wrote: > > It's hard to imagine why there would be a slowdown as this query uses > > a TTSOpsMinimalTuple slot type in the patch and the unpatched version. > > I shrunk down your table sizes to 10k

Re: [patch] pg_basebackup: mention that spread checkpoints are the default in --help

2023-10-20 Thread Aleksander Alekseev
Hi, > On Thu, Oct 19, 2023 at 10:30:04PM +0200, Michael Banck wrote: > > Hrm right, but those have multiple options and they do not enumerate > > them in the help string as do -F and -c - not sure what general project > > policy here is for mentioning defaults in --help, I will check some of > >

Re: UniqueKey v2

2023-10-20 Thread zhihuifan1213
> i did some simple tests using text data type. > > it works with the primary key, not with unique indexes. > it does not work when the column is unique, not null. > > The following is my test. Can you simplify your test case please? I can't undertand what "doesn't work" mean here and for which

Re: [PATCH] Add support function for containment operators

2023-10-20 Thread jian he
On Fri, Oct 20, 2023 at 12:01 AM Laurenz Albe wrote: > > On Fri, 2023-10-13 at 14:26 +0800, jian he wrote: > > Collation problem seems solved. > > I didn't review your patch in detail, there is still a problem > with my example: > > CREATE TYPE textrange AS RANGE ( > SUBTYPE = text, >

Re: CRC32C Parallel Computation Optimization on ARM

2023-10-20 Thread Michael Paquier
On Fri, Oct 20, 2023 at 07:08:58AM +, Xiang Gao wrote: > This patch uses a parallel computing optimization algorithm to > improve crc32c computing performance on ARM. The algorithm comes > from Intel whitepaper: > crc-iscsi-polynomial-crc32-instruction-paper. Input data is divided > into three

CRC32C Parallel Computation Optimization on ARM

2023-10-20 Thread Xiang Gao
Hi all This patch uses a parallel computing optimization algorithm to improve crc32c computing performance on ARM. The algorithm comes from Intel whitepaper: crc-iscsi-polynomial-crc32-instruction-paper. Input data is divided into three equal-sized blocks.Three parallel blocks (crc0, crc1,

Re: Fix output of zero privileges in psql

2023-10-20 Thread Laurenz Albe
On Fri, 2023-10-20 at 04:13 +0200, Erik Wienhold wrote: > On 2023-10-17 04:05 +0200, David G. Johnston wrote: > > Erik seems to favors (none) > > Yes, with a slight favor for "(none)" because it's the least disruptive > to users who change \pset null to a non-blank string.  The output of \dp >