kbuild: skip building kselftest when not required by jobfilter (speed up bisection)
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 50/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 静か
- 技術スタック
- python
- 領域
- build-system, ci-cd
調査の方向性
src/lava_callback.py の get_jobfilter() から始め、次に config/jobs.yaml と config/scheduler.yaml を調べて、イベントリンクをたどりながら kselftest テストから対応するビルドジョブまでを追跡します。これを kernelci/kbuild.py の現在のフィルタリングロジックと比較します。要求された kselftest ジョブが必要なアーティファクトを保持し、無関係なバイセクションビルドでは kselftest をスキップすれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Goal
To speed up bisection, do not build kselftest when it isn't needed by the requested jobs (kselftest builds are expensive and dominate bisection turnaround).
This was originally attempted in #2729, but that approach needs more design work before it can land — see below. Converting to an issue to track the proper solution.
Current attempt (#2729)
In kernelci/kbuild.py, when a jobfilter is present, kselftest is disabled unless <build-name>-kselftest literally appears in the filter:
if node['jobfilter'] and self._kfselftest is True:
kselftest_name = node['name'] + "-kselftest"
if kselftest_name not in node['jobfilter']:
self._kfselftest = False
Why this isn't enough
-
Downstream tests are invisible to the build.
kbuild.pyruns in the build container and only receivesnode+params+ a flatjobfilterlist of strings. It has no knowledge of which tests consume kselftest artifacts. So a jobfilter containing a kselftest test (but not the kselftest build name) would silently produce a build without kselftest, and the test would fail mysteriously. The dependency knowledge lives in kernelci-pipeline:- test → needs-kselftest is identifiable from
config/jobs.yaml(test_method: kselftest,kcidb_test_suite: kselftest.*) - build → test link is the
eventfield inconfig/scheduler.yaml
- test → needs-kselftest is identifiable from
-
Possible naming bug. Dedicated kselftest build variants are already named
kbuild-...-kselftest(e.g.config/jobs.yaml,scheduler.yaml). For such a node,node['name'] + "-kselftest"becomeskbuild-...-kselftest-kselftest, which never matches the filter — so kselftest would be disabled on the very build meant to produce it (this is exactly the bisection-of-a-kselftest-test path). Needs verification against realnode['name']values.
Proposed direction
Move the decision to kernelci-pipeline, which already has self._configs loaded and builds the jobfilter in get_jobfilter() (src/lava_callback.py):
- When any requested job in the jobfilter resolves to a kselftest test (
test_method == 'kselftest'), auto-enable kselftest on the corresponding build (e.g. set akselftest: enableparam on the build node, or ensure the kselftest-enabled build name is in the filter). - Otherwise, leave kselftest off so bisection builds stay fast.
The one non-trivial piece is reverse-resolving the scheduler graph (test → triggering build-node event → build job), since the build job doesn't inherently know its downstream tests. This is an in-memory config walk, not new infrastructure.
Closes #2729 (superseded by this issue).
- 主要言語
- Python
- スター
- 120
- フォーク
- 108
- 平均マージ
- 1日 12時間
- マージ済み PR(30日)
- 21
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
kernelci/kernelci-core のほかの issue
-
good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
kernelci/kernelci-core#2591 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 25/100
kernelci/kernelci-core#3234 ·
メンテナーはふだん 1 日以内に返信
-
Make Kubernetes job network readiness checks bounded and deployment-independent再び着手できるかも @Aniket1260 が 39 日前に担当しましたが、オープン中のプルリクエストはありません。 オープンgood first issue techdebt
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
kernelci/kernelci-core#3197 · コメント 3 件 ·
メンテナーはふだん 1 日以内に返信
-
chromeos techdebt
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
kernelci/kernelci-core#3196 ·
メンテナーはふだん 1 日以内に返信
-
kubernetes runners missing logs and test naming wrong再び着手できるかも @nuclearcat が 71 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
kernelci/kernelci-core#3170 · コメント 2 件 · リアクション 1 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
kernelci/kernelci-core の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
[BUG] Multi-day events show "Ended" while still in progress対応中かも @tarunagnihotri534 が今日担当しました。 オープンbug
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
data-umbrella/du-event-board#231 · コメント 2 件 ·
-
avl_automation: the generated control surface block isn't valid XML (typo in avl_out_parse.py)対応中かも @brksol が今日担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 92/100
PX4/PX4-gazebo-models#164 ·