I noticed full debug with cargo can be large, in our case, they are almost 1GB. OTOH, using debug = "line-tables-only" is much smaller, but also shows a slightly different name resolution.
I was wondering if samply has guidance on what options to use that allow profiling and ideally storing profiling binaries for reproducibility, without creating excessively large files?
The builds, with line-tables-only, with full debug and in release mode:
$ du -h target/*/uv
360M target/profiling2/uv
986M target/profiling/uv
54M target/release/uv
The two slightly different profiles:
full https://share.firefox.dev/4dAwjBY
line-tables-only https://share.firefox.dev/4bFmgcu
From the cargo docs on the different debuginfo options (https://doc.rust-lang.org/rustc/codegen-options/index.html#debuginfo):
This flag controls the generation of debug information. It takes one of the
following values:
0 or none: no debug info at all (the default).
line-directives-only: line info directives only. For the nvptx* targets this enables profiling. For other use cases, line-tables-only is the better, more compatible choice.
line-tables-only: line tables only. Generates the minimal amount of debug info for backtraces with filename/line number info, but not anything else, i.e. no variable or function parameter info.
1 or limited: debug info without type or variable-level information.
2 or full: full debug info.
Note: The [-g flag][option-g-debug] is an alias for -C debuginfo=2.
I noticed full debug with cargo can be large, in our case, they are almost 1GB. OTOH, using
debug = "line-tables-only"is much smaller, but also shows a slightly different name resolution.I was wondering if samply has guidance on what options to use that allow profiling and ideally storing profiling binaries for reproducibility, without creating excessively large files?
The builds, with line-tables-only, with full debug and in release mode:
The two slightly different profiles:
full https://share.firefox.dev/4dAwjBY
line-tables-only https://share.firefox.dev/4bFmgcu
From the cargo docs on the different debuginfo options (https://doc.rust-lang.org/rustc/codegen-options/index.html#debuginfo):