Re: ilist.h is not useful as-is

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)2ndquadrant(dot)com>
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: ilist.h is not useful as-is
Date: 2013-07-24 18:29:42
Message-ID: 2601.1374690582@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andres Freund <andres(at)2ndquadrant(dot)com> writes:
> The first attached patch adds slist_delete_current(), updates the
> comments addressing your points and converts the bgworker code to pass
> the iterator around (it's more efficient which might actually matter
> with a few hundred bgworkers).
> I found the added newlines in slist_foreach_modify useful, but maybe they
> should be removed again.

> I think this should be included in 9.3 once reviewed.

Agreed; since we have not shipped ilist.h in a release yet, the benefits
of having it behave the same in all branches should outweigh any pain
from changing this post-beta.

> The second patch adds a regression test for background workers via
> worker_spi which I used to test slist_delete_current() addition. It's not 100% as
> it, but I thought it worthwile to post it anyway

Hm. I'll review and commit the ilist changes, but Alvaro or somebody
should decide if such a test is sensible. I'd be a bit worried about
it in a "make installcheck" context ...

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2013-07-24 18:41:50 Re: [GENERAL] Insert result does not match record count
Previous Message Andres Freund 2013-07-24 18:08:32 Re: [GENERAL] Insert result does not match record count