Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tree filter for bisections #302

Merged
merged 1 commit into from
Oct 4, 2023

Conversation

gctucker
Copy link
Contributor

@gctucker gctucker commented Oct 2, 2023

Add a Celery parameter with a list of Git kernel trees to bisect.  If
the list is not provided then no filtering is applied.  If the list is
provided then only regressions found on trees in the list will be
bisected.

This is to avoid scheduling lots of bisections that are then later on
aborted in Jenkins with the filter parameter as doing so still fills
up the queue unnecessarily.

Signed-off-by: Guillaume Tucker <guillaume.tucker@collabora.com>

Fixes kernelci/kernelci-project#260

@gctucker gctucker force-pushed the bisection-tree-filter branch 3 times, most recently from 743abd9 to 1a73bc6 Compare October 3, 2023 10:00
Add a Celery parameter with a list of Git kernel trees to bisect.  If
the list is not provided then no filtering is applied.  If the list is
provided then only regressions found on trees in the list will be
bisected.

This is to avoid scheduling lots of bisections that are then later on
aborted in Jenkins with the filter parameter as doing so still fills
up the queue unnecessarily.

Signed-off-by: Guillaume Tucker <guillaume.tucker@collabora.com>
@gctucker gctucker changed the title WIP filter bisection by git tree Add tree filter for bisections Oct 3, 2023
@gctucker gctucker marked this pull request as ready for review October 3, 2023 10:32
@gctucker
Copy link
Contributor Author

gctucker commented Oct 3, 2023

Tested OK on staging with these regressions:
https://staging.kernelci.org/test/job/gtucker/branch/kernelci-staging/kernel/kernelci-bisect-snapshot-029-14-ga61eeaf161ae/plan/baseline/

and this Celery config:

    "jenkins_options": {
        "url": "https://bot.staging.kernelci.org/",
        "user": "bisection",
        "bisect": "lava-bisection",
        "token": "<TOKEN>",
        "bisection-git-trees": ["gtucker"]
    },

Bisection job: https://bot.staging.kernelci.org/job/lava-bisection/15/

I'm now waiting for the bisection to complete and will post an update then.

@gctucker
Copy link
Contributor Author

gctucker commented Oct 3, 2023

Tested OK:

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* This automated bisection report was sent to you on the basis  *
* that you may be involved with the breaking commit it has      *
* found.  No manual investigation has been done to verify it,   *
* and the root cause of the problem may be somewhere else.      *
*                                                               *
* If you do send a fix, please include this trailer:            *
*   Reported-by: "kernelci.org bot" <bot@kernelci.org>          *
*                                                               *
* Hope this helps!                                              *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

gtucker/kernelci-staging bisection: baseline.dmesg.emerg on qemu_x86_64 #15-staging

Summary:
  Start:      a61eeaf161ae NOISE Readability counts
  Plain log:  https://storage.staging.kernelci.org/gtucker/kernelci-staging/kernelci-bisect-snapshot-029-14-ga61eeaf161ae/x86_64/x86_64_defconfig/gcc-10/lab-collabora-staging/baseline-qemu_x86_64.txt
  HTML log:   https://storage.staging.kernelci.org/gtucker/kernelci-staging/kernelci-bisect-snapshot-029-14-ga61eeaf161ae/x86_64/x86_64_defconfig/gcc-10/lab-collabora-staging/baseline-qemu_x86_64.html
  Result:     3c6634c9143e NOISE Simple is better than complex

See this regression on the Kernel CI dashboard:
baseline.dmesg.emerg: https://staging.kernelci.org/test/case/id/651bea18d6f11dc6920a4d80

Checks:
  revert:     PASS
  verify:     PASS

Parameters:
  Tree:       gtucker
  URL:        https://gitlab.collabora.com/gtucker/linux.git
  Branch:     kernelci-staging
  Target:     qemu_x86_64
  CPU arch:   x86_64
  Lab:        lab-collabora-staging
  Compiler:   gcc-10
  Config:     x86_64_defconfig
  Test case:  baseline.dmesg.emerg

Breaking commit found:

-------------------------------------------------------------------------------
commit 3c6634c9143ea6c8f551439c013431b1d0b60169
Author: Guillaume Tucker <guillaume.tucker@collabora.com>
Date:   Wed Jun 14 16:43:46 2017 +0100

    NOISE Simple is better than complex

diff --git a/init/initramfs.c b/init/initramfs.c
index 59e6c2767f39..8b2448099f06 100644
--- a/init/initramfs.c
+++ b/init/initramfs.c
@@ -705,6 +705,11 @@ static void __init do_populate_rootfs(void *unused, async_cookie_t cookie)
 	if (!initrd_start || IS_ENABLED(CONFIG_INITRAMFS_FORCE))
 		goto done;
 
+#if 1 /* Noise to test the kernelci automatic bisection */
+	printk(KERN_EMERG "*** Random lines from the Zen of Python ***\n");
+	printk(KERN_EMERG "Simple is better than complex.\n");
+#endif
+
 	if (IS_ENABLED(CONFIG_BLK_DEV_RAM))
 		printk(KERN_INFO "Trying to unpack rootfs image as initramfs...\n");
 	else
-------------------------------------------------------------------------------


Git bisection log:

-------------------------------------------------------------------------------
git bisect start
# good: [7df17aca08d196601b8f70c95b6118d1412cbcce] NOISE random comment
git bisect good 7df17aca08d196601b8f70c95b6118d1412cbcce
# bad: [a61eeaf161aeda9776a885b49b420d971364a2fd] NOISE Readability counts
git bisect bad a61eeaf161aeda9776a885b49b420d971364a2fd
# bad: [ed98ab4acf8037e79c9f478fd54d5bba4d416b9f] NOISE Sparse is better than dense
git bisect bad ed98ab4acf8037e79c9f478fd54d5bba4d416b9f
# bad: [babceab4d2dcc9e6e72e3b7d4540dd20f103ea55] NOISE Flat is better than nested
git bisect bad babceab4d2dcc9e6e72e3b7d4540dd20f103ea55
# bad: [b75deda075af1a346ab9ab8914420450cdf340d3] NOISE Complex is better than complicated
git bisect bad b75deda075af1a346ab9ab8914420450cdf340d3
# bad: [3c6634c9143ea6c8f551439c013431b1d0b60169] NOISE Simple is better than complex
git bisect bad 3c6634c9143ea6c8f551439c013431b1d0b60169
# first bad commit: [3c6634c9143ea6c8f551439c013431b1d0b60169] NOISE Simple is better than complex
-------------------------------------------------------------------------------

@gctucker
Copy link
Contributor Author

gctucker commented Oct 4, 2023

Also confirmed that trees not in the list aren't being bisected, for example this was on the kernelci tree and no bisection was scheduled:

Oct 04 10:17:59 kernelci-staging kernelci-celery[7853]: [    INFO/MainThread] Triggering bisections for 'kernelci-staging-next-staging-next-20231004.0-sleep'
Oct 04 10:17:59 kernelci-staging kernelci-celery[56074]: [    INFO/MainThread] Task trigger-test-bisections[1e0780d5-9363-4f91-b0ca-665ebfdb622b] succeeded in 0.00529820751399s: None

@gctucker
Copy link
Contributor Author

gctucker commented Oct 4, 2023

Ignoring the GitHub checks as I believe they're broken due to some Python 2.7 environment issue (deprecated language anyway...).

@gctucker
Copy link
Contributor Author

gctucker commented Oct 4, 2023

See also: actions/setup-python#672

@gctucker gctucker merged commit bbd6638 into kernelci:main Oct 4, 2023
1 of 2 checks passed
@gctucker gctucker deleted the bisection-tree-filter branch October 4, 2023 16:17
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.

Automated bisection base coverage
1 participant