From: | Andres Freund <andres(at)anarazel(dot)de> |
---|---|
To: | Peter Eisentraut <peter(at)eisentraut(dot)org> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: pgaio_io_get_id() type (was Re: Datum as struct) |
Date: | 2025-08-08 20:07:11 |
Message-ID: | vmyq5naq3abyhja5swi2hegguq5d23wfa7xrbog3cy7lgwyau4@uhevvc25r5ef |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
On 2025-08-05 19:20:20 +0200, Peter Eisentraut wrote:
> On 31.07.25 19:17, Tom Lane wrote:
> > Also I see a "// XXX" in pg_get_aios, which I guess is a note
> > to confirm the data type to use for ioh_id?
>
> Yes, the stuff returned from pgaio_io_get_id() should be int, but some code
> uses uint32, and also UINT32_MAX as a special marker. Here is a patch that
> tries to straighten that out by using int consistently and -1 as a special
> marker.
> From e1bb97e13af226cd15c9a59929aef48bc92c4ac2 Mon Sep 17 00:00:00 2001
> From: Peter Eisentraut <peter(at)eisentraut(dot)org>
> Date: Tue, 5 Aug 2025 19:16:38 +0200
> Subject: [PATCH] Use consistent type for pgaio_io_get_id() result
>
> The result of pgaio_io_get_id() was being assigned to a mix of int and
> uint32 variables. This fixes it to use int consistently, which seems
> the most correct. Also change the queue empty special value in
> method_worker.c to -1 from UINT32_MAX.
WFM. I guess I could see some value going with an unsigned value instead of a
signed one, but it really doesn't matter...
Greetings,
Andres
From | Date | Subject | |
---|---|---|---|
Next Message | Dagfinn Ilmari Mannsåker | 2025-08-08 20:07:42 | Re: [PATCH] OAuth: fix performance bug with stuck multiplexer events |
Previous Message | Tom Lane | 2025-08-08 19:32:16 | Re: Support for 8-byte TOAST values (aka the TOAST infinite loop problem) |