Обсуждение: ipc_test

Поиск
Список
Период
Сортировка

ipc_test

От
Robert Haas
Дата:
Does anybody care about being able to compile ipc_test as a standalone
binary any more?

I ask because, while working on some of the outstanding cleanup issues
around dynamic shared memory, I made sure to test whether it required
further adjustments based on the changes that I'd done, only to
discover that it was already broken by the huge pages patch:

[rhaas pgsql]$ make -C src/backend/port ipc_test
gcc -O2 -Wall -Wmissing-prototypes -Wpointer-arith
-Wdeclaration-after-statement -Wendif-labels
-Wmissing-format-attribute -Wformat-security -fno-strict-aliasing
-fwrapv -g -Wall -Werror -L../../../src/port -L../../../src/common
-L/opt/local/lib -Wl,-dead_strip_dylibs  -Wall -Werror   ipc_test.o
pg_sema.o pg_shmem.o -lpgcommon -lpgport -lintl -lxml2 -lssl -lcrypto
-lz -lreadline -lm  -o ipc_test
Undefined symbols for architecture x86_64: "_huge_pages", referenced from:     _PGSharedMemoryCreate in pg_shmem.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
make: *** [ipc_test] Error 1

My judgement is that ipc_test has insufficient utility to justify
keeping it around and updating it every time sysv_shmem.c references a
new symbol or experiences a relevant calling signature change.  So I'd
favor just ripping it out.  I doubt we're likely to have any
completely new semaphore or shared memory implementations that require
this kind of testing any time soon, and even if we do I think whoever
is doing it can quite easily put together a bespoke testing framework
that will likely serve their needs at least as well as ipc_test does.
It was probably quite reasonable to add this 12 years ago but I just
don't think we need it any more.

All that having been said, if somebody feels strongly that this is
still useful, I'd rather just fix it than argue about it.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



Re: ipc_test

От
Andres Freund
Дата:
Hi,

On 2014-04-04 09:31:01 -0400, Robert Haas wrote:
> Does anybody care about being able to compile ipc_test as a standalone
> binary any more?

I don't.

But if we want to keep it, it should be built during a normal build to
make sure it doesn't get broken.

Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



Re: ipc_test

От
Tom Lane
Дата:
Andres Freund <andres@2ndquadrant.com> writes:
> On 2014-04-04 09:31:01 -0400, Robert Haas wrote:
>> Does anybody care about being able to compile ipc_test as a standalone
>> binary any more?

> I don't.

I can't remember the last time I had use for it either.  +1 for removal.

> But if we want to keep it, it should be built during a normal build to
> make sure it doesn't get broken.

Yup.
        regards, tom lane



Re: ipc_test

От
Robert Haas
Дата:
On Fri, Apr 4, 2014 at 10:11 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Andres Freund <andres@2ndquadrant.com> writes:
>> On 2014-04-04 09:31:01 -0400, Robert Haas wrote:
>>> Does anybody care about being able to compile ipc_test as a standalone
>>> binary any more?
>
>> I don't.
>
> I can't remember the last time I had use for it either.  +1 for removal.

OK, done.  One less thing to worry about when committing!

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



Re: ipc_test

От
Greg Stark
Дата:
On Mon, Apr 7, 2014 at 10:43 AM, Robert Haas <robertmhaas@gmail.com> wrote:
> OK, done.  One less thing to worry about when committing!

Also one less thing to cause headaches with etags and similar tools.
It always drove me nuts that I was constantly being sent to ipc_test
files for various typedefs. Thanks!

-- 
greg



Re: ipc_test

От
Alvaro Herrera
Дата:
Greg Stark wrote:
> On Mon, Apr 7, 2014 at 10:43 AM, Robert Haas <robertmhaas@gmail.com> wrote:
> > OK, done.  One less thing to worry about when committing!
> 
> Also one less thing to cause headaches with etags and similar tools.
> It always drove me nuts that I was constantly being sent to ipc_test
> files for various typedefs. Thanks!

Yeah, my thoughts exactly.  Thanks.

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services



Re: ipc_test

От
Bruce Momjian
Дата:
On Tue, Apr  8, 2014 at 02:08:25PM -0400, Greg Stark wrote:
> On Mon, Apr 7, 2014 at 10:43 AM, Robert Haas <robertmhaas@gmail.com> wrote:
> > OK, done.  One less thing to worry about when committing!
> 
> Also one less thing to cause headaches with etags and similar tools.
> It always drove me nuts that I was constantly being sent to ipc_test
> files for various typedefs. Thanks!

Oh, yeah, that was a _big_ pain.  Thanks!

--  Bruce Momjian  <bruce@momjian.us>        http://momjian.us EnterpriseDB
http://enterprisedb.com
 + Everyone has their own god. +