Intel® Advisor User Guide

ID 766448
Date 3/31/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

cache-sources

Enable source code visibility in a read-only snapshot you can view any time (with --snapshot action). Enable keeping source code cache within a project (with --collect action).

GUI Equivalent

To add source to a snapshot: File > Create Data Snapshot > Cache Sources

To keep cached source during data collection: Project Properties > Analysis Target > Survey Hotspots Analysis > Source caching

Syntax

--cache-sources

--no-cache-sources

Default

Off (no-cache-sources)

Actions Modified

snapshot

collect

Usage

When used with collect action, report is supplied with source code folded like a snapshot. Once set, this option triggers a flag in project configuration that prevents deleting cache with each analysis run unless you manually disable it.

Example

Create a read-only snapshot. Include performance data, sources, and binaries. Save the snapshot to the tmp directory. Name the snapshot myAdvisorProjSnapshot.advixeexpz.

advisor --snapshot --project-dir=./advi_results --pack --cache-sources --cache-binaries -- ./bin/myApplication

Run a Survey analysis and keep source cache.

advisor --collect=survey --cache-sources --project-dir=./advi_results -- ./bin/myApplication

See Also