pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter_e@gmx.net>
To: Michael Paquier <michael.paquier@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Cc: Fabien COELHO <coelho@cri.ensmp.fr>
Subject: Re: improving speed of make check-world
Date: Sun, 08 Mar 2015 09:22:53 -0400
Message-ID: <54FC4D2D.8060901@gmx.net> (raw)
In-Reply-To: <CAB7nPqTgR+-NB3UhOebpicY9oJpDrECMWXiuTBPNM2wecq+Osg@mail.gmail.com>
References: <53ED9E6C.1080700@gmx.net>
	<alpine.DEB.2.10.1408311125080.14824@sto>
	<54DFFE0C.4060100@gmx.net>
	<CAB7nPqTgR+-NB3UhOebpicY9oJpDrECMWXiuTBPNM2wecq+Osg@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

On 2/24/15 3:06 AM, Michael Paquier wrote:
> On Sun, Feb 15, 2015 at 11:01 AM, Peter Eisentraut wrote:
>> Here is an updated patch.
> 
> Nice patch. This is going to save a lot of resources.
> 
> An update of vcregress.pl is necessary. This visibly just consists in
> updating the options that have been renamed in pg_regress (don't mind
> testing any code sent out).

Well, that turns out to be more complicated than initially thought.
Apparently, the msvc has a bit of a different idea of what check and
installcheck do with respect to temporary installs.  For instance,
vcregress installcheck does not use psql from the installation but from
the build tree.  vcregress check uses psql from the build tree but other
binaries (initdb, pg_ctl) from the temporary installation.  It is hard
for me to straighten this out by just looking at the code.  Attached is
a patch that shows the idea, but I can't easily take it further than that.

> -               {"top-builddir", required_argument, NULL, 11},
> +               {"datadir", required_argument, NULL, 12},
> In pg_regress.c datadir is a new option but it is used nowhere, so it
> could be as well removed.

Yeah, that's an oversight that is easily corrected.

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Attachments:

regress-temp-instance-msvc.patch (application/x-patch, 2.9K) download diff --git a/src/tools/msvc/vcregress.pl b/src/tools/msvc/vcregress.pl index bd3dd2c..1e09c74 100644 --- a/src/tools/msvc/vcregress.pl +++ b/src/tools/msvc/vcregress.pl @@ -94,7 +94,7 @@ sub installcheck my @args = ( "../../../$Config/pg_regress/pg_regress", "--dlpath=.", - "--psqldir=../../../$Config/psql", + "--bindir=../../../$Config/psql", "--schedule=${schedule}_schedule", "--encoding=SQL_ASCII", "--no-locale"); @@ -106,39 +106,56 @@ sub installcheck sub check { + my $cwd = getcwd(); + + system($0, 'install.pl', "$cwd/tmp_install"); + my $status = $? >> 8; + exit $status if $status; + + $ENV{PATH} = "$cwd/tmp_install/bin;$cwd/tmp_install/lib;$ENV{PATH}"; + my @args = ( "../../../$Config/pg_regress/pg_regress", "--dlpath=.", - "--psqldir=../../../$Config/psql", + "--bindir=", "--schedule=${schedule}_schedule", "--encoding=SQL_ASCII", "--no-locale", - "--temp-install=./tmp_check", - "--top-builddir=\"$topdir\""); + "--temp-instance=./tmp_check"); push(@args, $maxconn) if $maxconn; push(@args, $temp_config) if $temp_config; system(@args); - my $status = $? >> 8; + $status = $? >> 8; exit $status if $status; } sub ecpgcheck { chdir $startdir; + system("msbuild ecpg_regression.proj /p:config=$Config"); my $status = $? >> 8; exit $status if $status; + + my $cwd = getcwd(); + + system($0, 'install.pl', "$cwd/tmp_install"); + $status = $? >> 8; + exit $status if $status; + + $ENV{PATH} = "$cwd/tmp_install/bin;$cwd/tmp_install/lib;$ENV{PATH}"; + chdir "$topdir/src/interfaces/ecpg/test"; $schedule = "ecpg"; my @args = ( "../../../../$Config/pg_regress_ecpg/pg_regress_ecpg", - "--psqldir=../../../$Config/psql", + "--bindir=", "--dbname=regress1,connectdb", "--create-role=connectuser,connectdb", "--schedule=${schedule}_schedule", "--encoding=SQL_ASCII", "--no-locale", - "--temp-install=./tmp_chk", + "--temp-instance=./tmp_chk", "--top-builddir=\"$topdir\""); push(@args, $maxconn) if $maxconn; system(@args); @@ -153,7 +170,7 @@ sub isolationcheck "../../../$Config/pg_isolation_regress"); my @args = ( "../../../$Config/pg_isolation_regress/pg_isolation_regress", - "--psqldir=../../../$Config/psql", + "--bindir=../../../$Config/psql", "--inputdir=.", "--schedule=./isolation_schedule"); push(@args, $maxconn) if $maxconn; @@ -202,7 +219,7 @@ sub plcheck print "Checking $lang\n"; my @args = ( "../../../$Config/pg_regress/pg_regress", - "--psqldir=../../../$Config/psql", + "--bindir=../../../$Config/psql", "--dbname=pl_regression", @lang_args, @tests); system(@args); my $status = $? >> 8; @@ -237,7 +254,7 @@ sub contribcheck my @opts = fetchRegressOpts(); my @args = ( "../../$Config/pg_regress/pg_regress", - "--psqldir=../../$Config/psql", + "--bindir=../../$Config/psql", "--dbname=contrib_regression", @opts, @tests); system(@args); my $status = $? >> 8;

view thread (22+ messages)  latest in thread

Message-ID: <54FC4D2D.8060901@gmx.net>
Permalink:  ../54FC4D2D.8060901@gmx.net/
Also on:    postgresql.org/message-id/54FC4D2D.8060901@gmx.net

 ·  · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: peter_e@gmx.net, michael.paquier@gmail.com, coelho@cri.ensmp.fr
  Subject: Re: improving speed of make check-world
  In-Reply-To: <54FC4D2D.8060901@gmx.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox