Re: CCACHE_READONLY=1 setting now working

Joel Rosdahl <[email protected]> Wed, 25 Feb 2015 22:05:25 +0100
Newsgroups gmane.comp.compilers.ccache
Message-ID <CAK8D=pixUZ0DHvgBJhQbjap26Qx8ShAkk1H3aOx7y+WdmHiMxg@mail.gmail.com>
> However, the time taken for the build when CCACHE_READONLY=1 flag is set
is much
> more compared to the time taken when this flag is not set. The ccache hit
rate is almost
> the same in both cases. I am using CCACHE_TEMPDIR option ( same filesystem
> location ) with CCACHE_READONLY flag. Could you let me know what could
have
> gone wrong in this setup ?

The hit rate is expected to be the same with and without read-only mode
(unless you rebuild again, of course) but if you let ccache write back
results it should noticeably slower, so it's really strange if it's the
other way around.

To debug what is happening I think you should time a single compilation
with and without cache hit, with and without read-only mode, etc. Set
CCACHE_LOGFILE to catch information on what is going on.

-- Joel