The -march=native option to gcc generates different code depending on the architecture of the host. ccache does not store the machine architecture in its hash which means that if you change the architecture of the machine, for example to switch to a high performance VPS node, the cached object files may be incompatible.
How can I make sure I get the correct object files while still taking advantage of caching?