Skip to content

docs: explain --reference with --prepare and parameters - #911

Open
Solaris-star wants to merge 1 commit into
sharkdp:masterfrom
Solaris-star:docs/reference-prepare-params
Open

docs: explain --reference with --prepare and parameters#911
Solaris-star wants to merge 1 commit into
sharkdp:masterfrom
Solaris-star:docs/reference-prepare-params

Conversation

@Solaris-star

Copy link
Copy Markdown

Summary

Users combining --reference with --prepare and --parameter-list often try to select a parameterized variant as the reference (e.g. --reference 'echo a (delay = 0.4)' or --reference 'delay = 0.4'). That fails because --reference is a separate command string, and a single shared --prepare with {param} is not substituted for the reference (it has no parameters).

Changes

  • New README section: Relative comparisons with a fixed reference
  • Clarifies fixed-baseline usage of --reference / --reference-name
  • Documents prepare/parameter interaction and a working multi---prepare example (reference prepare first)

How tested

  • Cross-checked against src/benchmark/scheduler.rs (reference is a separate Command prepended before parameterized commands)
  • Cross-checked against src/benchmark/mod.rs prepare selection (values[self.number] when N prepares; single prepare reuses the same template with each command's parameters)
  • Cross-checked against src/options.rs validation message: prepare count must be 1 or N including a potential reference

Closes #847

Document that --reference is a separate baseline command (not a
parameter selector) and show how multi --prepare interacts with a
reference plus parameterized benchmarks.

Signed-off-by: Solaris-star <820622658@qq.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Unclear how to use --reference with --prepare

1 participant