Skip to content

Caching

The Turbo Build Accelerator can cache build output (c++ object) files for future re-use by either the same machine or a remote machine.

This powerful feature can significantly improve build times, since re-compilation can be avoided.

Each Agent holds a cache for fast local lookups. Additionally, to maximise performance, the Scheduler is aware of the Cache on each Agent, and can schedule build jobs to the agent with a cache 'hit'.

Ideally locate the Cache directory (e.g. C:\ProgramData\Turbo\cache) on a large capacity SSD for best results.

The Cache data is stored in-memory for fast lookups, and persisted in a SQLite database on each Agent and Scheduler machines.

The Cache database and file store is automatically managed to maintain a maximum disk space usage, on an LRU basis.

Build Integrity

When distributing a build there is a risk of corruption of the build by a mismatched build environment on a remote machine.

Turbo Build Accelerator prevents this by only using cache results with a matching build environment. The matching criteria includes:

  • The VisualStudio Version
  • The Target Architecture
  • The VC Tools Version
  • The Windows SDK version

To maximize the cache efficiency throughout the cluster it is best to have matching build environments on all machines.

Generally speaking it is good practise anyway to have identical (or at least very similar) build environments on all Developer workstations and Build Servers to reduce complexity in the development process.

Cache Operations

The following Cache Operations are available to a Developer or Administrator :

  • Purge Cache on this Agent to Max Disk Space
  • Purge all Cache on this Agent
  • Purge all Cache on all Agents [restricted to Scheduler machine only]

These operations assist in managing the Cache (of compiled c++ object files) for these reasons :

  • to rapidly reclaim disk space (with no waiting for periodic Cache purging by the Agent)
  • to assist in any troubleshooting where the Cache is feared to be causing a Build Integrity issue

Note that the Purge all Cache on all Agents menu item is quite powerful and is therefore restricted to the Scheduler machine only. Windows user login to this machine provides the security measure to ensure only the Administrator(s) of the Turbo Build Cluster can access this operation.

See Turbo Monitor for more how to invoke these Operations.

Configuration

Cache configuration can be found in the XML files :

  • bin\turbo-common.xml
  • bin\turbo-agent.xml
  • bin\turbo-scheduler.xml

For more details on the configuration files see Configuration for more details.

Also see Turbo Monitor Settings for possible configuration via the GUI.