Re: Mingw task for Cirrus CI - Mailing list pgsql-hackers
From | Andres Freund |
---|---|
Subject | Re: Mingw task for Cirrus CI |
Date | |
Msg-id | 20221011184612.edxifnqsq7tadxze@awork3.anarazel.de Whole thread Raw |
In response to | Re: Mingw task for Cirrus CI (Andres Freund <andres@anarazel.de>) |
Responses |
Re: Mingw task for Cirrus CI
|
List | pgsql-hackers |
Hi, On 2022-10-11 11:23:36 -0700, Andres Freund wrote: > > + build_script: > > + - C:\msys64\usr\bin\dash.exe -lc "cd %CIRRUS_WORKING_DIR% && ninja -C %BUILD_DIR%" > > + upload_caches: ccache Only remembered that just after sending my email: When using b_pch=true (which saves a lot of time on mingw) ccache won't cache much (IIRC just the pch files themselves) unless you do something like export CCACHE_SLOPPINESS=pch_defines,time_macros $ ccache -z -C Clearing... 100.0% [==============================================================================] $ ninja clean && ccache -z && CCACHE_SLOPPINESS= time ninja src/bin/pg_test_fsync/pg_test_fsync.exe && ccache -s [2/2] Cleaning Cleaning... 200 files. Statistics zeroed [124/124] Linking target src/bin/pg_test_fsync/pg_test_fsync.exe 0.00user 0.01system 0:07.60elapsed 0%CPU (0avgtext+0avgdata 4936maxresident)k 0inputs+0outputs (1314major+0minor)pagefaults 0swaps Summary: Hits: 0 / 1 (0.00 %) Direct: 0 / 1 (0.00 %) Preprocessed: 0 / 1 (0.00 %) Misses: 1 Direct: 1 Preprocessed: 1 Uncacheable: 110 As you can see, most of the files are determined to be unachable. The build took 7.6s. $ ninja clean && ccache -z && CCACHE_SLOPPINESS=pch_defines,time_macros time ninja src/bin/pg_test_fsync/pg_test_fsync.exe&& ccache -s [2/2] Cleaning Cleaning... 200 files. Statistics zeroed [124/124] Linking target src/bin/pg_test_fsync/pg_test_fsync.exe 0.00user 0.01system 0:09.91elapsed 0%CPU (0avgtext+0avgdata 4936maxresident)k 0inputs+0outputs (1313major+0minor)pagefaults 0swaps Summary: Hits: 0 / 111 (0.00 %) Direct: 0 / 111 (0.00 %) Preprocessed: 0 / 111 (0.00 %) Misses: 111 Direct: 111 Preprocessed: 111 Primary storage: Hits: 0 / 216 (0.00 %) Misses: 216 Cache size (GB): 0.05 / 5.00 (0.98 %) Files are cachable, but are cache misses (because we cleaned the cache above). The build took 9.91s. $ ninja clean && ccache -z && CCACHE_SLOPPINESS=pch_defines,time_macros time ninja src/bin/pg_test_fsync/pg_test_fsync.exe&& ccache -s [2/2] Cleaning Cleaning... 200 files. Statistics zeroed [124/124] Linking target src/bin/pg_test_fsync/pg_test_fsync.exe 0.00user 0.01system 0:02.40elapsed 0%CPU (0avgtext+0avgdata 4936maxresident)k 0inputs+0outputs (1314major+0minor)pagefaults 0swaps Summary: Hits: 111 / 111 (100.0 %) Direct: 111 / 111 (100.0 %) Preprocessed: 0 / 0 Misses: 0 Direct: 0 Preprocessed: 0 Primary storage: Hits: 222 / 222 (100.0 %) Misses: 0 Cache size (GB): 0.05 / 5.00 (0.98 %) Files are cachable, and hit the cache. The build takes 2.4s. Using ccache's depend mode reduce the cache-miss case to 7.51s and the cache hit case to 1.75s. So we should likely export CCACHE_DEPEND=1 as well. Greetings, Andres Freund
pgsql-hackers by date: