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...