Re: thread safety on clients - Mailing list pgsql-hackers

From Tom Lane
Subject Re: thread safety on clients
Date
Msg-id 23088.1260562858@sss.pgh.pa.us
Whole thread Raw
In response to Re: thread safety on clients  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
I wrote:
> ... What I would have expected is crashes on the very
> similar updates to pgbench_branches, which is designed to be
> high-contention.  It might be that there is some other effect going on
> here that explains why that wasn't happening.  Need to go back and look
> more closely.

... and the answer to that is that pgbench_branches isn't subject to the
bug, because its only pass-by-reference column happens to be filled with
all NULLs by the initialization step, unlike the accounts filler column
which happens to be filled with non-null strings.  Null values mean no
dangling pointers and no chance for a memory management issue.  So you
could have run this all day and never seen a crash on pgbench_branches
updates.  (If you manually set the filler column non-null before
starting a run, the unpatched code crashes instantly, even with a
non-bollixed pgbench.)

So, nothing to see here except lack of test coverage, move along.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Zdenek Kotala
Date:
Subject: Re: [PATCH] dtrace probes for memory manager
Next
From: Stephen Smalley
Date:
Subject: Re: Adding support for SE-Linux security