Parallel build with MSVC

From: Christian Ullrich <chris(at)chrullrich(dot)net>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Parallel build with MSVC
Date: 2016-04-26 13:09:42
Message-ID: nfnpan$fuc$
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On my system, "build DEBUG" takes ~2.75 minutes. When I tell MSBuild to
build in parallel by passing it the /m flag, that goes down to 1.5 minutes.

The first patch passes the value of the MSBFLAGS environment variable to
msbuild's command line.

The output of parallel and sequential builds has identical file count
and size after installing; all tests pass.

Even without /m, MSBuild will already run enough compilers to keep all
CPUs busy whenever it can do that with only a single project's files.
With /m, it will also process _projects_ in parallel.

One additional fix required is to put's "symbols.out" file
into the directory it is working on, rather than the source tree root,
to avoid collisions that cause the parallel build to fail otherwise.


Attachment Content-Type Size
0001-Support-passing-arbitrary-arguments-to-MSBuild.patch text/plain 2.5 KB
0002-Support-parallel-build-with-MSBuild.patch text/plain 1.3 KB


Browse pgsql-hackers by date

  From Date Subject
Next Message Nikolay Shaplov 2016-04-26 13:17:16 [PATCH] amroutine->amsupport from numeric to defined constants
Previous Message Etsuro Fujita 2016-04-26 12:50:30 Re: postgres_fdw : Not able to update foreign table referring to a local table's view when use_remote_estimate = true