diff --git a/utils/e2e-tests/bash/fixtures/help.benchmark.block.stdout.txt b/utils/e2e-tests/bash/fixtures/help.benchmark.block.stdout.txt new file mode 100644 index 000000000..163f84ce2 --- /dev/null +++ b/utils/e2e-tests/bash/fixtures/help.benchmark.block.stdout.txt @@ -0,0 +1,242 @@ +Benchmark the execution time of historic blocks. + +This can be used to verify that blocks do not use more weight than they consumed in their `WeightInfo`. Example: + +Let's say you are on a Substrate chain and want to verify that the first 3 blocks did not use more weight than declared which would otherwise be an issue. To test this with a dev node, first create one with a temp directory: + +$ substrate --dev -d /tmp/my-dev --execution wasm --wasm-execution compiled + +And wait some time to let it produce 3 blocks. Then benchmark them with: + +$ substrate benchmark-block --from 1 --to 3 --dev -d /tmp/my-dev --execution wasm --wasm-execution compiled --pruning archive + +The output will be similar to this: + +Block 1 with 1 tx used 77.34% of its weight ( 5,308,964 of 6,864,645 ns) Block 2 with 1 tx used 77.99% of its weight ( 5,353,992 of 6,864,645 ns) Block 3 with 1 tx used 75.91% of its weight ( 5,305,938 of 6,989,645 ns) + +The percent number is important and indicates how much weight was used as compared to the consumed weight. This number should be below 100% for reference hardware. + +Usage: humanode-peer benchmark block [OPTIONS] --from --to + +Options: + --chain + Specify the chain specification. + + It can be one of the predefined ones (dev, local, or staging) or it can be a path to a file with the chainspec (such as one exported by the `build-spec` subcommand). + + --dev + Specify the development chain. + + This flag sets `--chain=dev`, `--force-authoring`, `--rpc-cors=all`, `--alice`, and `--tmp` flags, unless explicitly overridden. + + -d, --base-path + Specify custom base path + + -l, --log ... + Sets a custom logging filter. Syntax is `=`, e.g. -lsync=debug. + + Log levels (least to most verbose) are error, warn, info, debug, and trace. By default, all targets log `info`. The global log level can be set with `-l`. + + --detailed-log-output + Enable detailed log output. + + This includes displaying the log target, log level and thread name. + + This is automatically enabled when something is logged with any higher level than `info`. + + --disable-log-color + Disable log color output + + --enable-log-reloading + Enable feature to dynamically update and reload the log filter. + + Be aware that enabling this feature can lead to a performance decrease up to factor six or more. Depending on the global logging level the performance decrease changes. + + The `system_addLogFilter` and `system_resetLogFilter` RPCs will have no effect with this option not being set. + + --tracing-targets + Sets a custom profiling filter. Syntax is the same as for logging: `=` + + --tracing-receiver + Receiver to process tracing messages + + [default: log] + + Possible values: + - log: Output the tracing records using the log + + --state-pruning + Specify the state pruning mode. + + This mode specifies when the block's state (ie, storage) should be pruned (ie, removed) from the database. + + This setting can only be set on the first creation of the database. Every subsequent run will load the pruning mode from the database and will error if the stored mode doesn't match this CLI value. It is fine to drop this CLI flag for subsequent runs. + + Possible values: + + - archive: + + Keep the state of all blocks. + + - 'archive-canonical' + + Keep only the state of finalized blocks. + + - number + + Keep the state of the last number of finalized blocks. + + [default: 256] + + --blocks-pruning + Specify the blocks pruning mode. + + This mode specifies when the block's body (including justifications) should be pruned (ie, removed) from the database. + + Possible values: - 'archive' + + Keep all blocks. + + - 'archive-canonical' + + Keep only finalized blocks. + + - number + + Keep the last `number` of finalized blocks. + + [default: archive-canonical] + + --database + Select database backend to use + + Possible values: + - rocksdb: Facebooks RocksDB + - paritydb: ParityDb. + - auto: Detect whether there is an existing database. Use it, if there is, if not, create new instance of ParityDb + - paritydb-experimental: ParityDb. + + --db-cache + Limit the memory the database cache can use + + --wasm-execution + Method for executing Wasm runtime code + + [default: compiled] + + Possible values: + - interpreted-i-know-what-i-do: Uses an interpreter + - compiled: Uses a compiled runtime + + --wasmtime-instantiation-strategy + The WASM instantiation method to use. + + Only has an effect when `wasm-execution` is set to `compiled`. + + The copy-on-write strategies are only supported on Linux. If the copy-on-write variant of a strategy is unsupported the executor will fall back to the non-CoW equivalent. + + The fastest (and the default) strategy available is `pooling-copy-on-write`. + + The `legacy-instance-reuse` strategy is deprecated and will be removed in the future. It should only be used in case of issues with the default instantiation strategy. + + [default: pooling-copy-on-write] + + Possible values: + - pooling-copy-on-write: Pool the instances to avoid initializing everything from scratch on each instantiation. Use copy-on-write memory when possible + - recreate-instance-copy-on-write: Recreate the instance from scratch on every instantiation. Use copy-on-write memory when possible + - pooling: Pool the instances to avoid initializing everything from scratch on each instantiation + - recreate-instance: Recreate the instance from scratch on every instantiation. Very slow + - legacy-instance-reuse: Legacy instance reuse mechanism. DEPRECATED. Will be removed in the future + + --wasm-runtime-overrides + Specify the path where local WASM runtimes are stored. + + These runtimes will override on-chain runtimes when the version matches. + + --execution-syncing + The means of execution used when calling into the runtime for importing blocks as part of an initial sync + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-import-block + The means of execution used when calling into the runtime for general block import (including locally authored blocks) + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-block-construction + The means of execution used when calling into the runtime while constructing blocks + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-offchain-worker + The means of execution used when calling into the runtime while using an off-chain worker + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-other + The means of execution used when calling into the runtime while not syncing, importing or constructing blocks + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution + The execution strategy that should be used by all execution contexts + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --trie-cache-size + Specify the state cache size. + + Providing `0` will disable the cache. + + [default: 67108864] + + --state-cache-size + DEPRECATED + + Switch to `--trie-cache-size`. + + --from + Number of the first block to consider + + --to + Last block number to consider + + --repeat + Number of times that the benchmark should be repeated for each block + + [default: 10] + + --enable-trie-cache + Enable the Trie cache. + + This should only be used for performance analysis and not for final results. + + -h, --help + Print help (see a summary with '-h') + + -V, --version + Print version diff --git a/utils/e2e-tests/bash/fixtures/help.benchmark.extrinsic.stdout.txt b/utils/e2e-tests/bash/fixtures/help.benchmark.extrinsic.stdout.txt new file mode 100644 index 000000000..252879f30 --- /dev/null +++ b/utils/e2e-tests/bash/fixtures/help.benchmark.extrinsic.stdout.txt @@ -0,0 +1,245 @@ +Benchmark the execution time of different extrinsics. + +This is calculated by filling a block with a specific extrinsic and executing the block. The result time is then divided by the number of extrinsics in that block. + +NOTE: The BlockExecutionWeight is ignored in this case since it + +Usage: humanode-peer benchmark extrinsic [OPTIONS] + +Options: + --chain + Specify the chain specification. + + It can be one of the predefined ones (dev, local, or staging) or it can be a path to a file with the chainspec (such as one exported by the `build-spec` subcommand). + + --dev + Specify the development chain. + + This flag sets `--chain=dev`, `--force-authoring`, `--rpc-cors=all`, `--alice`, and `--tmp` flags, unless explicitly overridden. + + -d, --base-path + Specify custom base path + + -l, --log ... + Sets a custom logging filter. Syntax is `=`, e.g. -lsync=debug. + + Log levels (least to most verbose) are error, warn, info, debug, and trace. By default, all targets log `info`. The global log level can be set with `-l`. + + --detailed-log-output + Enable detailed log output. + + This includes displaying the log target, log level and thread name. + + This is automatically enabled when something is logged with any higher level than `info`. + + --disable-log-color + Disable log color output + + --enable-log-reloading + Enable feature to dynamically update and reload the log filter. + + Be aware that enabling this feature can lead to a performance decrease up to factor six or more. Depending on the global logging level the performance decrease changes. + + The `system_addLogFilter` and `system_resetLogFilter` RPCs will have no effect with this option not being set. + + --tracing-targets + Sets a custom profiling filter. Syntax is the same as for logging: `=` + + --tracing-receiver + Receiver to process tracing messages + + [default: log] + + Possible values: + - log: Output the tracing records using the log + + --state-pruning + Specify the state pruning mode. + + This mode specifies when the block's state (ie, storage) should be pruned (ie, removed) from the database. + + This setting can only be set on the first creation of the database. Every subsequent run will load the pruning mode from the database and will error if the stored mode doesn't match this CLI value. It is fine to drop this CLI flag for subsequent runs. + + Possible values: + + - archive: + + Keep the state of all blocks. + + - 'archive-canonical' + + Keep only the state of finalized blocks. + + - number + + Keep the state of the last number of finalized blocks. + + [default: 256] + + --blocks-pruning + Specify the blocks pruning mode. + + This mode specifies when the block's body (including justifications) should be pruned (ie, removed) from the database. + + Possible values: - 'archive' + + Keep all blocks. + + - 'archive-canonical' + + Keep only finalized blocks. + + - number + + Keep the last `number` of finalized blocks. + + [default: archive-canonical] + + --database + Select database backend to use + + Possible values: + - rocksdb: Facebooks RocksDB + - paritydb: ParityDb. + - auto: Detect whether there is an existing database. Use it, if there is, if not, create new instance of ParityDb + - paritydb-experimental: ParityDb. + + --db-cache + Limit the memory the database cache can use + + --wasm-execution + Method for executing Wasm runtime code + + [default: compiled] + + Possible values: + - interpreted-i-know-what-i-do: Uses an interpreter + - compiled: Uses a compiled runtime + + --wasmtime-instantiation-strategy + The WASM instantiation method to use. + + Only has an effect when `wasm-execution` is set to `compiled`. + + The copy-on-write strategies are only supported on Linux. If the copy-on-write variant of a strategy is unsupported the executor will fall back to the non-CoW equivalent. + + The fastest (and the default) strategy available is `pooling-copy-on-write`. + + The `legacy-instance-reuse` strategy is deprecated and will be removed in the future. It should only be used in case of issues with the default instantiation strategy. + + [default: pooling-copy-on-write] + + Possible values: + - pooling-copy-on-write: Pool the instances to avoid initializing everything from scratch on each instantiation. Use copy-on-write memory when possible + - recreate-instance-copy-on-write: Recreate the instance from scratch on every instantiation. Use copy-on-write memory when possible + - pooling: Pool the instances to avoid initializing everything from scratch on each instantiation + - recreate-instance: Recreate the instance from scratch on every instantiation. Very slow + - legacy-instance-reuse: Legacy instance reuse mechanism. DEPRECATED. Will be removed in the future + + --wasm-runtime-overrides + Specify the path where local WASM runtimes are stored. + + These runtimes will override on-chain runtimes when the version matches. + + --execution-syncing + The means of execution used when calling into the runtime for importing blocks as part of an initial sync + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-import-block + The means of execution used when calling into the runtime for general block import (including locally authored blocks) + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-block-construction + The means of execution used when calling into the runtime while constructing blocks + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-offchain-worker + The means of execution used when calling into the runtime while using an off-chain worker + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-other + The means of execution used when calling into the runtime while not syncing, importing or constructing blocks + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution + The execution strategy that should be used by all execution contexts + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --trie-cache-size + Specify the state cache size. + + Providing `0` will disable the cache. + + [default: 67108864] + + --state-cache-size + DEPRECATED + + Switch to `--trie-cache-size`. + + --warmup + Rounds of warmups before measuring + + [default: 10] + + --repeat + How many times the benchmark should be repeated + + [default: 100] + + --max-ext-per-block + Maximal number of extrinsics that should be put into a block. + + Only useful for debugging. + + --list + List all available pallets and extrinsics. + + The format is CSV with header `pallet, extrinsic`. + + --pallet + Pallet name of the extrinsic to benchmark + + --extrinsic + Extrinsic to benchmark + + --enable-trie-cache + Enable the Trie cache. + + This should only be used for performance analysis and not for final results. + + -h, --help + Print help (see a summary with '-h') + + -V, --version + Print version diff --git a/utils/e2e-tests/bash/fixtures/help.benchmark.machine.stdout.txt b/utils/e2e-tests/bash/fixtures/help.benchmark.machine.stdout.txt new file mode 100644 index 000000000..82b07b34d --- /dev/null +++ b/utils/e2e-tests/bash/fixtures/help.benchmark.machine.stdout.txt @@ -0,0 +1,92 @@ +Command to benchmark the hardware. + +Runs multiple benchmarks and prints their output to console. Can be used to gauge if the hardware is fast enough to keep up with a chain's requirements. This command must be integrated by the client since the client can set compiler flags which influence the results. + +You can use the `--base-path` flag to set a location for the disk benchmarks. + +Usage: humanode-peer benchmark machine [OPTIONS] + +Options: + --chain + Specify the chain specification. + + It can be one of the predefined ones (dev, local, or staging) or it can be a path to a file with the chainspec (such as one exported by the `build-spec` subcommand). + + --dev + Specify the development chain. + + This flag sets `--chain=dev`, `--force-authoring`, `--rpc-cors=all`, `--alice`, and `--tmp` flags, unless explicitly overridden. + + -d, --base-path + Specify custom base path + + -l, --log ... + Sets a custom logging filter. Syntax is `=`, e.g. -lsync=debug. + + Log levels (least to most verbose) are error, warn, info, debug, and trace. By default, all targets log `info`. The global log level can be set with `-l`. + + --detailed-log-output + Enable detailed log output. + + This includes displaying the log target, log level and thread name. + + This is automatically enabled when something is logged with any higher level than `info`. + + --disable-log-color + Disable log color output + + --enable-log-reloading + Enable feature to dynamically update and reload the log filter. + + Be aware that enabling this feature can lead to a performance decrease up to factor six or more. Depending on the global logging level the performance decrease changes. + + The `system_addLogFilter` and `system_resetLogFilter` RPCs will have no effect with this option not being set. + + --tracing-targets + Sets a custom profiling filter. Syntax is the same as for logging: `=` + + --tracing-receiver + Receiver to process tracing messages + + [default: log] + + Possible values: + - log: Output the tracing records using the log + + --allow-fail + Do not return an error if any check fails. + + Should only be used for debugging. + + --tolerance + Set a fault tolerance for passing a requirement. + + 10% means that the test would pass even when only 90% score was archived. Can be used to mitigate outliers of the benchmarks. + + [default: 10] + + --verify-duration + Time limit for the verification benchmark + + [default: 5] + + --hash-duration + Time limit for the hash function benchmark + + [default: 5] + + --memory-duration + Time limit for the memory benchmark + + [default: 5] + + --disk-duration + Time limit for each disk benchmark + + [default: 5] + + -h, --help + Print help (see a summary with '-h') + + -V, --version + Print version diff --git a/utils/e2e-tests/bash/fixtures/help.benchmark.overhead.stdout.txt b/utils/e2e-tests/bash/fixtures/help.benchmark.overhead.stdout.txt new file mode 100644 index 000000000..464bbe9c3 --- /dev/null +++ b/utils/e2e-tests/bash/fixtures/help.benchmark.overhead.stdout.txt @@ -0,0 +1,276 @@ +Benchmark the execution overhead per-block and per-extrinsic + +Usage: humanode-peer benchmark overhead [OPTIONS] + +Options: + --chain + Specify the chain specification. + + It can be one of the predefined ones (dev, local, or staging) or it can be a path to a file with the chainspec (such as one exported by the `build-spec` subcommand). + + --dev + Specify the development chain. + + This flag sets `--chain=dev`, `--force-authoring`, `--rpc-cors=all`, `--alice`, and `--tmp` flags, unless explicitly overridden. + + -d, --base-path + Specify custom base path + + -l, --log ... + Sets a custom logging filter. Syntax is `=`, e.g. -lsync=debug. + + Log levels (least to most verbose) are error, warn, info, debug, and trace. By default, all targets log `info`. The global log level can be set with `-l`. + + --detailed-log-output + Enable detailed log output. + + This includes displaying the log target, log level and thread name. + + This is automatically enabled when something is logged with any higher level than `info`. + + --disable-log-color + Disable log color output + + --enable-log-reloading + Enable feature to dynamically update and reload the log filter. + + Be aware that enabling this feature can lead to a performance decrease up to factor six or more. Depending on the global logging level the performance decrease changes. + + The `system_addLogFilter` and `system_resetLogFilter` RPCs will have no effect with this option not being set. + + --tracing-targets + Sets a custom profiling filter. Syntax is the same as for logging: `=` + + --tracing-receiver + Receiver to process tracing messages + + [default: log] + + Possible values: + - log: Output the tracing records using the log + + --state-pruning + Specify the state pruning mode. + + This mode specifies when the block's state (ie, storage) should be pruned (ie, removed) from the database. + + This setting can only be set on the first creation of the database. Every subsequent run will load the pruning mode from the database and will error if the stored mode doesn't match this CLI value. It is fine to drop this CLI flag for subsequent runs. + + Possible values: + + - archive: + + Keep the state of all blocks. + + - 'archive-canonical' + + Keep only the state of finalized blocks. + + - number + + Keep the state of the last number of finalized blocks. + + [default: 256] + + --blocks-pruning + Specify the blocks pruning mode. + + This mode specifies when the block's body (including justifications) should be pruned (ie, removed) from the database. + + Possible values: - 'archive' + + Keep all blocks. + + - 'archive-canonical' + + Keep only finalized blocks. + + - number + + Keep the last `number` of finalized blocks. + + [default: archive-canonical] + + --database + Select database backend to use + + Possible values: + - rocksdb: Facebooks RocksDB + - paritydb: ParityDb. + - auto: Detect whether there is an existing database. Use it, if there is, if not, create new instance of ParityDb + - paritydb-experimental: ParityDb. + + --db-cache + Limit the memory the database cache can use + + --wasm-execution + Method for executing Wasm runtime code + + [default: compiled] + + Possible values: + - interpreted-i-know-what-i-do: Uses an interpreter + - compiled: Uses a compiled runtime + + --wasmtime-instantiation-strategy + The WASM instantiation method to use. + + Only has an effect when `wasm-execution` is set to `compiled`. + + The copy-on-write strategies are only supported on Linux. If the copy-on-write variant of a strategy is unsupported the executor will fall back to the non-CoW equivalent. + + The fastest (and the default) strategy available is `pooling-copy-on-write`. + + The `legacy-instance-reuse` strategy is deprecated and will be removed in the future. It should only be used in case of issues with the default instantiation strategy. + + [default: pooling-copy-on-write] + + Possible values: + - pooling-copy-on-write: Pool the instances to avoid initializing everything from scratch on each instantiation. Use copy-on-write memory when possible + - recreate-instance-copy-on-write: Recreate the instance from scratch on every instantiation. Use copy-on-write memory when possible + - pooling: Pool the instances to avoid initializing everything from scratch on each instantiation + - recreate-instance: Recreate the instance from scratch on every instantiation. Very slow + - legacy-instance-reuse: Legacy instance reuse mechanism. DEPRECATED. Will be removed in the future + + --wasm-runtime-overrides + Specify the path where local WASM runtimes are stored. + + These runtimes will override on-chain runtimes when the version matches. + + --execution-syncing + The means of execution used when calling into the runtime for importing blocks as part of an initial sync + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-import-block + The means of execution used when calling into the runtime for general block import (including locally authored blocks) + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-block-construction + The means of execution used when calling into the runtime while constructing blocks + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-offchain-worker + The means of execution used when calling into the runtime while using an off-chain worker + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution-other + The means of execution used when calling into the runtime while not syncing, importing or constructing blocks + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --execution + The execution strategy that should be used by all execution contexts + + Possible values: + - native: Execute with native build (if available, WebAssembly otherwise) + - wasm: Only execute with the WebAssembly build + - both: Execute with both native (where available) and WebAssembly builds + - native-else-wasm: Execute with the native build if possible; if it fails, then execute with WebAssembly + + --trie-cache-size + Specify the state cache size. + + Providing `0` will disable the cache. + + [default: 67108864] + + --state-cache-size + DEPRECATED + + Switch to `--trie-cache-size`. + + --weight-path + File or directory to write the *weight* files to. + + For Substrate this should be `frame/support/src/weights`. + + --metric + Select a specific metric to calculate the final weight output + + [default: average] + + --mul + Multiply the resulting weight with the given factor. Must be positive. + + Is applied before `weight_add`. + + [default: 1] + + --add + Add the given offset to the resulting weight. + + Is applied after `weight_mul`. + + [default: 0] + + --warmup + Rounds of warmups before measuring + + [default: 10] + + --repeat + How many times the benchmark should be repeated + + [default: 100] + + --max-ext-per-block + Maximal number of extrinsics that should be put into a block. + + Only useful for debugging. + + --hostname-override + Manually override the hostname to use + + --hostname-fallback + Specify a fallback hostname if no-one could be detected automatically. + + Note: This only exists to make the `hostname` function infallible. + + [default: ] + + --cpuname-fallback + Specify a fallback CPU name if no-one could be detected automatically. + + Note: This only exists to make the `cpuname` function infallible. + + [default: ] + + --header + Add a header to the generated weight output file. + + Good for adding LICENSE headers. + + --enable-trie-cache + Enable the Trie cache. + + This should only be used for performance analysis and not for final results. + + -h, --help + Print help (see a summary with '-h') + + -V, --version + Print version diff --git a/utils/e2e-tests/bash/fixtures/help.benchmark.pallet.stdout.txt b/utils/e2e-tests/bash/fixtures/help.benchmark.pallet.stdout.txt new file mode 100644 index 000000000..1ce080489 --- /dev/null +++ b/utils/e2e-tests/bash/fixtures/help.benchmark.pallet.stdout.txt @@ -0,0 +1,214 @@ +Benchmark the extrinsic weight of FRAME Pallets + +Usage: humanode-peer benchmark pallet [OPTIONS] + +Options: + -p, --pallet + Select a FRAME Pallet to benchmark, or `*` for all (in which case `extrinsic` must be `*`) + + -e, --extrinsic + Select an extrinsic inside the pallet to benchmark, or `*` for all + + -s, --steps + Select how many samples we should take across the variable components + + [default: 2] + + --low + Indicates lowest values for each of the component ranges + + --high + Indicates highest values for each of the component ranges + + -r, --repeat + Select how many repetitions of this benchmark should run from within the wasm + + [default: 1] + + --external-repeat + Select how many repetitions of this benchmark should run from the client. + + NOTE: Using this alone may give slower results, but will afford you maximum Wasm memory. + + [default: 1] + + --json + Print the raw results in JSON format + + --json-file + Write the raw results in JSON format into the given file + + --no-median-slopes + Don't print the median-slopes linear regression analysis + + --no-min-squares + Don't print the min-squares linear regression analysis + + --output + Output the benchmarks to a Rust file at the given path + + --header
+ Add a header file to your outputted benchmarks + + --template