| From: | Jasper Smit <jbsmit(at)gmail(dot)com> |
|---|---|
| To: | Heikki Linnakangas <hlinnaka(at)iki(dot)fi> |
| Cc: | pgsql-hackers(at)lists(dot)postgresql(dot)org |
| Subject: | Re: Visibility bug in tuple lock |
| Date: | 2025-12-18 09:56:25 |
| Message-ID: | CAOG+RQ7Lv36iqSi2d5ZHe9GAdMj99Ap8b4g-qacfh+CPVRRarQ@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
The test is really nice with the injection points and the dynamically
sized data.
> Ah, but this codepath is taken when HEAP_KEYS_UPDATED is *not* set. I
> got that backwards. So I agree the ItemPointerEquals(&tuple->t_self,
> ctid) check is redundant.
Ok, I did not think about deletes. So the boolean updated here could
mean both update and delete, that makes sense to me.
> I chatted about that with Andres Freund just the other day, and he said
> that compilers are not good at optimizing passing them by value. I'll
> take his word on that.
I believe that too, but in heap_lock_updated_tuple_rec() the first
thing we do is ItemPointerCopy(tid, &tupid); , which makes it probably
just as inefficient.
Jasper
| From | Date | Subject | |
|---|---|---|---|
| Next Message | John Naylor | 2025-12-18 10:05:22 | Re: [PATCH] Documentation |
| Previous Message | Alexander Pyhalov | 2025-12-18 09:56:02 | Re: Asynchronous MergeAppend |