Do not hard-code the default 'runs' value as 200 in code that fills out optimizer settings

This commit is contained in:
Kamil Śliwak
2021-06-28 14:12:28 +02:00
parent 6d8ef71277
commit 6ad6fa2382
9 changed files with 30 additions and 22 deletions
+3 -1
View File
@@ -1037,7 +1037,9 @@ General Information)").c_str(),
)
(
g_argOptimizeRuns.c_str(),
po::value<unsigned>()->value_name("n")->default_value(200),
// TODO: The type in OptimiserSettings is size_t but we only accept values up to 2**32-1
// on the CLI and in Standard JSON. We should just switch to uint32_t everywhere.
po::value<unsigned>()->value_name("n")->default_value(static_cast<unsigned>(OptimiserSettings{}.expectedExecutionsPerDeployment)),
"Set for how many contract runs to optimize. "
"Lower values will optimize more for initial deployment cost, higher values will optimize more for high-frequency usage."
)