Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp3380762ybi; Mon, 10 Jun 2019 09:15:59 -0700 (PDT) X-Google-Smtp-Source: APXvYqxUJIzKg7clGjuxgiQLlZsa7hSKoaBpxSPuXMPspzekHtvNlZ9baFbzOEQzW1bf8nxiiW1Y X-Received: by 2002:a17:902:20ec:: with SMTP id v41mr67424157plg.142.1560183359436; Mon, 10 Jun 2019 09:15:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560183359; cv=none; d=google.com; s=arc-20160816; b=A/8cBbS+UaxSFHodRkPYr2vkM67lkJDcB1q1B+M9x4p9tBuQsz/8ocXqCGOAsUb9IL /AGZ6iHdjw611EzFYAR0j8Q0ZIQ0ZVKehmAY0XcPbcyJmqg7Mek1Ewjal2tHjiG83a44 5Ieu/cm/CV3vLvfpk2kchpZK3jb8hntk/6mgKOJwwftu+/uRjSvI+6/sNuvpDLmlXIgH y32NpVtq2GMcTYyQ6hcIkJiwHva7Cd0BgS/OUYj00ehh6i/2y07XOM04/m8nbCzO61dX nCXjwTr9F6yoLA1dAYycw0k6PGE+mhkEupRnMpSaErnD6fZdCPHUsQAEfi39F0qIUmgn yxUw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=JlGKclY/bHvJDeSRZXa+M2saWzmI4Gp/wAz0wTgws2w=; b=x/tHgqtrPjvrGN5LbNvdtTb11Uw9Lh7GeTOXptlEJ1MxrRGbwdOllbiC1ePGl9alpi tz/bcbP+lKyHbQQVyBtETetQKZ06W8ddr21LGvaxF5DRWitbxPNA/k/sjcK9Ab21WoIJ U6bHENpU7CxUWLgazcqGjd7lZwpyHVlcp/4jlT03J7ZWAP2TAkELmXW6Kmzu9OZPBorY fotM9UIFGomFdFJGJDYBDEHX5v+G8xkXU+AR0F22dINRWgv+iKfzWG1qsPTOydM4WkAC XLOC6K/axwU6juonh7WSnD/OdptrNdGBlu6lGK91ChMYtn80Dfpd51MtUvlJhL1uRMnE NjTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=NhfeEdpi; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 207si834731pfu.258.2019.06.10.09.15.44; Mon, 10 Jun 2019 09:15:59 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=NhfeEdpi; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391051AbfFJPE4 (ORCPT + 99 others); Mon, 10 Jun 2019 11:04:56 -0400 Received: from mail-lf1-f65.google.com ([209.85.167.65]:44065 "EHLO mail-lf1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2389368AbfFJPE4 (ORCPT ); Mon, 10 Jun 2019 11:04:56 -0400 Received: by mail-lf1-f65.google.com with SMTP id r15so6875257lfm.11; Mon, 10 Jun 2019 08:04:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=JlGKclY/bHvJDeSRZXa+M2saWzmI4Gp/wAz0wTgws2w=; b=NhfeEdpiincXSqU7FtldKqketoZf30UquGvzS6kxSQdA4NdSNMuQMjFZCI7zprrq9n tdrH//tHgqASjIuQmcjL4Zs7JRTkKGLgyftJOoju/Q2NIqDNntuBwzQFRQq/P2GK1OXW D4kMHiO0wXGoF1WNI4XLlCGLoI1tlblW1G6tlzFqgpIxrDnLCX5Pohf1t/GYjcc+SkRj 2RW02M15MxLf2Nbt1LScwn3atbTWbzq27/pCMeQ1GEpsZqbXJ8v1tFl5yW5R2EDtRNSH Y3+aYI5n03uFtrmykJzVYtKjGbn4dNRuWbp9HHCzpApFX+TpmLVl2QcG3Q/S5ru24a15 04Mg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=JlGKclY/bHvJDeSRZXa+M2saWzmI4Gp/wAz0wTgws2w=; b=G3yi9SyFnKUQ1Bp9ktcmQQGlGCtWMR9OOeQnjiG8Nnn8jdBQLtOxq+BW1tskEwlqj4 lrG2W7+jmj5gPcrSEbUFjpzmyy0zpn7B6ABLjwYCSt6mCmaM9J4x1dAJPsLeJ2LmaYTG H+w0Kcc17aWJLNXljg3UIGXlwou3DY+3aWjw3oRQTqGvUbrELKWVzT1nqPHQzBife93V EVzVVsuMCqekbFJsKBhLY2HR4+8tIsODuThWucsAmzITWFS2wgjJBEv67azXyBM6F32J Y/Nt/U5DoyntomzCdNGCXWpgUXQ8H0xdf1pDhlNDLfBCmOWn/+q89CVKxtDLldKgffAM XqIw== X-Gm-Message-State: APjAAAXVX3fsnW68WkbO4qOdF0WFSnDgFcfVabPktTDHHXCLdzdGlwQ7 TKHOdYKjriIbIFzeNyAAOUch5CFwefz/O3EdoBo= X-Received: by 2002:a19:491d:: with SMTP id w29mr18544344lfa.149.1560179094278; Mon, 10 Jun 2019 08:04:54 -0700 (PDT) MIME-Version: 1.0 References: <20190517085126.GA3249@kroah.com> <20190517152200.GI8945@kernel.org> <4FE2D490-F379-4CAE-9784-9BF81B7FE258@kernel.org> <20190610074510.GA24746@kroah.com> <20190610142145.GC5937@kroah.com> <20190610144858.GA1481@kroah.com> In-Reply-To: <20190610144858.GA1481@kroah.com> From: Miguel Ojeda Date: Mon, 10 Jun 2019 17:04:43 +0200 Message-ID: Subject: Re: Linux 4.19 and GCC 9 To: Greg KH Cc: Ignat Korchagin , Ivan Babrou , Arnaldo Carvalho de Melo , Peter Zijlstra , Josh Poimboeuf , Ingo Molnar , Alexander Shishkin , Jiri Olsa , Namhyung Kim , linux-kernel , Linux Kbuild mailing list , kernel-team Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 10, 2019 at 4:49 PM Greg KH wrote: > > On Mon, Jun 10, 2019 at 04:42:27PM +0200, Miguel Ojeda wrote: > > I think Josh Poimboeuf added support for a few related things in GCC 8 > > (e.g. 13810435b9a7 ("objtool: Support GCC 8's cold subfunctions")). > > That commit is already in all stable releases, so does there need to be > a gcc 9 specific one? Ah, you are right. Hm... I recall discussing this at some point when cleaning up for GCC 9, let me take a look... > > I typically compile a bare-bones GCC for those things, it is quite quick. > > Pointers to how to do that is appreciated. It's been years since I had > to build gcc "from scratch". We crossed emails -- I copy it here on-list in case someone else wants it :-) mkdir ${BUILD_PATH} \ && cd ${BUILD_PATH} \ && ${REPO_PATH}/configure \ --enable-languages=c,c++ \ --disable-multilib \ --disable-bootstrap \ --disable-nls \ --prefix=${INSTALL_PATH} \ && time make \ && time make install The key thing is disabling bootstrap to have a single-pass compilation -- that speeds up things a lot (although, of course, you get less testing). I would guess you can also disable c++ for the kernel for even a faster build. You can also use -j, but even without it it does not really take long (1 hour? -- way less than LLVM anyway). The installed size nowadays is about 1 GiB. To get the actual code, I use the git mirror in github for speed (although it is not that big anyway): git clone https://github.com/gcc-mirror/gcc The tags you want to use look like: gcc-9_1_0-release Also, the first time you run this, you may need some extra dependencies: libgmp-dev (maybe named gmp-devel) libmpfr-dev (mpfr-devel) libmpc-dev (libmpc-devel) Unless your distro is quite old, I think they should simply work (a few years ago I had to compile those manually, but nowadays I don't seem to need them anymore). Cheers, Miguel