| From: | Greg Burd <greg(at)burd(dot)me> |
|---|---|
| To: | Peter Eisentraut <peter(at)eisentraut(dot)org>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Nathan Bossart <nathandbossart(at)gmail(dot)com>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi> |
| Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Subject: | Re: Trying out <stdatomic.h> |
| Date: | 2026-09-30 15:55:24 |
| Message-ID: | 7M97JuEC8HrnNLB7Eszo1dkpfdhEwkaj0F06SUhdQMutWvKmXShbXnanOxX_1purmzQKhGVybgNohEqGhTmLeQOCK23wefCfMbbyiF3OXO4=@burd.me |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Monday, September 14th, 2026 at 3:02 PM, Greg Burd <greg(at)burd(dot)me> wrote:
>
> On Mon, Sep 14, 2026, at 2:48 PM, Peter Eisentraut wrote:
> > On 10.09.26 16:10, Greg Burd wrote:
> >> 1. Is an opt-in, default-off second implementation worth carrying at
> >> all? Tom's concern was that this not become The Only Way, hence the
> >> default. If the answer is no, that's fine and I'll stop pushing.
> >
> > Depends on what the plan in the long term is. Just having another
> > variant available at compile time doesn't accomplish much by itself.
> > Except that we'd now have even more code to maintain. What are we
> > asking people to do with it? Are we asking for testing? (What kind?)
> > What do we do when the testing is complete?
> >
> > Personally, I think a possible valuable outcome would be that we don't
> > have to maintain our own atomics library at all anymore, and just rely
> > on the compiler. This would require, most likely, some intermediate
> > steps and some testing and so on, but it would be good to clarify what
> > those steps are and whether this is indeed the goal.
>
> Hey Peter, thanks for the reply.
>
> I agree, high level end game goal is to move entirely to stdatomic and remove the atomics we've been maintaining.
>
> I'd imagined we could do that "testing and so on" while we leave them both in tree and then cut over mid-cycle if all looks good. I'm open to other ideas. I'm happy to try to split this up or ease it into the tree, suggestions welcome.
>
> best.
>
> -greg
Rebased on dca6a9e320e attached is v7, nothing significant changed. I've
left the 0003 patch which removes the non-stdatomic path in the set for
cfbot to chew on this round.
-greg
| Attachment | Content-Type | Size |
|---|---|---|
| v7-0002-NOT-FOR-MERGE-Add-atomics-benchmark-harness.patch | text/x-patch | 88.6 KB |
| v7-0001-Add-an-opt-in-C11-stdatomic.h-implementation-of-t.patch | text/x-patch | 63.5 KB |
| v7-0003-NOT-FOR-MERGE.-yet.-Remove-traditional-atomics-us.patch | text/x-patch | 105.6 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Kacper Kuras | 2026-09-30 16:14:40 | Re: injection_points: canceled or terminated waiters leak their wait slots |
| Previous Message | Johannes Edmeier | 2026-09-30 15:47:45 | Detoast a column once per row instead of once per reference |