All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nathan Chancellor <nathan@kernel.org>
To: Guillaume Tucker <gtucker@gtucker.io>
Cc: Denys Fedoryshchenko <denys.f@collabora.com>,
	kernelci@lists.linux.dev,
	Nick Desaulniers <ndesaulniers@google.com>,
	clang-built-linux <llvm@lists.linux.dev>,
	Miguel Ojeda <ojeda@kernel.org>
Subject: Re: Migration to Debian Bookworm and compiler updates for KernelCI
Date: Wed, 13 Mar 2024 10:56:22 -0700	[thread overview]
Message-ID: <20240313175622.GA3091999@dev-arch.thelio-3990X> (raw)
In-Reply-To: <64395770-84d4-4b6d-a7ff-d5623564daf3@gtucker.io>

On Mon, Mar 11, 2024 at 08:10:31PM +0100, Guillaume Tucker wrote:
> Hello,
> 
> On 07/03/2024 6:05 pm, Nathan Chancellor wrote:
> > Hi Denys,
> > 
> > On Thu, Mar 07, 2024 at 01:02:26PM +0200, Denys Fedoryshchenko wrote:
> > > Hello,
> > > 
> > > I'm reaching out on behalf of the KernelCI project team to discuss our
> > > current compiler setup and planned migration to Debian Bookworm.
> > > 
> > > As you may know, our compiler images are currently based on Debian
> > > Bullseye, which is approaching its end of life in July 2024. We have
> > > been testing using gcc-10, which has presented us with some recent
> > > challenges, notably a significant bug that results in false positive
> > > compilation errors (specifically, the -Werror memcpy issue in
> > > security.c). This situation has prompted us to consider an urgent
> > > migration to Debian Bookworm. Additionally, the migration is
> > > necessitated by our requirement to upgrade to a newer Python version to
> > > support KernelCI v2 development efforts.
> > > 
> > > However, before we proceed, we have a couple of pending questions that
> > > we hope to get clarity on:
> > > 
> > > 1) We've noticed that the minimal available version of clang on
> > > https://apt.llvm.org/bookworm/dists/ is 15, whereas our current minimal
> > > requirement for the Linux kernel compilation is clang-13.0.1
> > > (https://www.kernel.org/doc/html/next/process/changes.html). How
> > > critical is it to continue providing compile tests for clang-13 (and
> > > potentially clang-14)? This information would be vital for us in
> > > planning our compiler support strategy moving forward.
> > 
> > Coverage of the minimum version of a particular toolchain for building
> > the kernel is important but I would not describe it as critical.
> > 
> > While apt.llvm.org's Bookworm distribution does not have clang-13 and
> > clang-14, the Bullseye distribution of clang-13 and clang-14 does work
> > on Bookworm, I personally do that for my Debian development containers:
> > 
> > https://github.com/nathanchance/env/blob/12927502f12ec63f50a460f842c9d0a70a82c629/podman/dev/debian/setup-env.sh#L54-L64
> > 
> > Have you explored using the kernel.org GCC and LLVM toolchains instead
> > of the ones in Debian?
> > 
> > https://mirrors.edge.kernel.org/pub/tools/crosstool/
> > https://mirrors.edge.kernel.org/pub/tools/llvm/
> > 
> > That would potentially give you more flexibility with distribution
> > upgrades and stable/deterministic compiler versions around that. I
> > maintain the LLVM ones, which are optimized at build time to be quicker
> > than the Debian one's, so that would save you build minutes over time.
> 
> Ah nice, Arnd suggested a while ago that we used his GCC
> cross-compiler toolchains in KernelCI but it got stuck at a
> slightly lower priority than everything else for core developers.
> It has always been considered a nice thing to do one day, and I

Heh, story of my life :)

> guess there may be additional reasons to pick it up now with the
> need for a wider GCC version coverage and LLVM/Clang too.
> 
> Out of interest, is there going to be some Rust toolchains there
> as well?  Having all the reference toolchains to build the kernel
> in a single location would be great I think.  Of course Rust
> support is still a moving target, so maybe it's still a bit too
> early right now - just wondering.

As Miguel mentioned, we are talking about providing a combo LLVM + Rust
tarball to help make it more accessible to more people.

> Then in addition to the tarballs, one thing that was discussed
> with Linaro in the very early days of tuxmake was to have a
> reference set of Docker image with the toolchains already
> installed - to save everyone creating their own like in Nathan's
> GitHub link.  Has anyone done that already?
> 
> I started looking into it while I was writing my tutorial to
> build a kernel last month but didn't find anything, so it's kind
> of going up on my TODO list now.  It would greatly help unify
> kernel builds across CI systems in particular and improve
> reproducibility.  The TuxBuild / tuxmake Docker images were
> forked from the KernelCI ones so that's already something that
> could be reunited at some point.

I am not aware of that. As far as I can tell, the TuxMake images are
only lightly customized for TuxMake itself, so it is possible they are
already usable by other entities (I maintain my own containers for other
reasons). They recently added images for my kernel.org LLVM builds as
well:

https://gitlab.com/Linaro/tuxmake/-/commit/dca69b3e2f007cc31ab08200ad59593b7eaa5f40

Cheers,
Nathan

  parent reply	other threads:[~2024-03-13 17:56 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-07 11:02 Migration to Debian Bookworm and compiler updates for KernelCI Denys Fedoryshchenko
2024-03-07 11:19 ` Lukas Bulwahn
2024-03-07 14:02   ` Gustavo Padovan
2024-03-07 17:05 ` Nathan Chancellor
2024-03-11 19:10   ` Guillaume Tucker
2024-03-12 13:11     ` Mark Brown
2024-03-12 14:36     ` Miguel Ojeda
2024-03-13 17:56     ` Nathan Chancellor [this message]
2024-03-14 13:00       ` Mark Brown
2024-03-12 16:13 ` Chris Paterson
2024-03-12 16:44   ` Jan Kiszka

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240313175622.GA3091999@dev-arch.thelio-3990X \
    --to=nathan@kernel.org \
    --cc=denys.f@collabora.com \
    --cc=gtucker@gtucker.io \
    --cc=kernelci@lists.linux.dev \
    --cc=llvm@lists.linux.dev \
    --cc=ndesaulniers@google.com \
    --cc=ojeda@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.