Re: ccache, MSVC, and meson - Mailing list pgsql-hackers

From Justin Pryzby
Subject Re: ccache, MSVC, and meson
Date
Msg-id 20220524221747.GM19626@telsasoft.com
Whole thread Raw
In response to Re: ccache, MSVC, and meson  (Andres Freund <andres@anarazel.de>)
Responses Re: ccache, MSVC, and meson
List pgsql-hackers
On Tue, May 24, 2022 at 01:30:39PM -0700, Andres Freund wrote:
> > As I recall, CC='ccache cl.exe' didn't work because it didn't attempt to do any
> > argument splitting.
> 
> I tried it, and it works for me when building with ninja (compiling with
> cl.exe). I assume you are using msbuild?

Apparently it works to write "ccache.exe" but not just "ccache", which is what
I used before.

It seems to work by fooling meson, which intends to strip off the leading
"ccache" but fails due to the "exe", but then happens to do what's desired.

If I'm not wrong, pgccache.exe + CCACHE_COMPILER=cl runs 30sec faster on
cirrus.  I suppose it's because windows is running cmd.exe on the
CC="ccache.exe cl".

Also, /O2 cuts ~3 minutes off the test time on cirrus, which seems worth it,
except that it omits frame pointers, which probably breaks debuggability.  And
when I pass /Oy- to "avoid omitting" frame pointers, several tests crash...



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: postgres_fdw has insufficient support for large object
Next
From: Bruce Momjian
Date:
Subject: Re: Limiting memory allocation