[Buildroot] [git commit branch/2021.02.x] utils/genrandconfig: reduce the maximum "size" of random configurations

Peter Korsgaard peter at korsgaard.com
Wed Nov 17 22:12:59 UTC 2021


commit: https://git.buildroot.net/buildroot/commit/?id=90ccff9ad8ff438328ee88ae4305ab5a42f20268
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/2021.02.x

genrandconfig is used by the Buildroot autobuilders to generate
semi-random configurations that we build test. As part of this, we use
"make randpackageconfig" to randomize the selection of packages,
together with a KCONFIG_PROBABILITY value, which indicates the
probabibility for each option to be enabled. This probability is
itself randomized, between 1% and 30% for every build.

However, with our increasing number of packages (over 2900), when we
use a 30% probability for options to be enabled, it means a *lot* of
options are enabled, causing very large configurations to be
tested. These configurations are not very realistic, and they take
ages to build on our autobuilders: we have builds that take 4, 5 or
even 7 hours to build.

In order to test a larger number of configurations and therefore a
larger variety of configurations, this commit reduces the maximum
probability to 20%.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni at bootlin.com>
Signed-off-by: Peter Korsgaard <peter at korsgaard.com>
(cherry picked from commit 0e64537917a5b27565b8c479fda83508a6da7b86)
Signed-off-by: Peter Korsgaard <peter at korsgaard.com>
---
 utils/genrandconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/utils/genrandconfig b/utils/genrandconfig
index 93dc6d898b..90420596ff 100755
--- a/utils/genrandconfig
+++ b/utils/genrandconfig
@@ -422,7 +422,7 @@ def gen_config(args):
             return 1
         bounded_loop -= 1
         subprocess.check_call(["make", "O=%s" % args.outputdir, "-C", args.buildrootdir,
-                               "KCONFIG_PROBABILITY=%d" % randint(1, 30),
+                               "KCONFIG_PROBABILITY=%d" % randint(1, 20),
                                "randpackageconfig"])
 
         if fixup_config(sysinfo, configfile):


More information about the buildroot mailing list