Received: by 2002:a05:6602:18e:0:0:0:0 with SMTP id m14csp3479125ioo; Wed, 25 May 2022 01:16:38 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx7qykA+3mztz0czFf5ruce9c0pVxqWfiprwKMEqsn3JJ0d5IILc8rftvsiRTq9zdGevND6 X-Received: by 2002:a05:6402:d64:b0:42a:9bce:1eb6 with SMTP id ec36-20020a0564020d6400b0042a9bce1eb6mr33201314edb.125.1653466598169; Wed, 25 May 2022 01:16:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1653466598; cv=none; d=google.com; s=arc-20160816; b=O8tZaa69inTZsP3oJ3nb+9wmHVuxpRU/TUuJgI1FwcEpVdvGmXXokZ+Y2vFHuswfO8 kKuHIgFW0f1BTnO/J7R2Y2L/rxiK9o+8eYCMoveEnNbOVZCIYMJZMRqXxGCRfx3+5kCP hPcYLWRCURfWQ9P5QgX2Hxstsrxgs0W0kiFZfVwGu5jLMsu79DgBM5iO6kq/dKh2TSlE SH5r1zmvmJlyF/0Q4Lem8BfTDn8QeVQWP0QLDk1Hm6WdowR+6Lf+iwrAp0vAFW3xqqiT 1B6x9F/wOZNFj3f2rmPm8jrKl3+cy41xde21+CjIlMj20/lL6Ava26Pj/kpLpylV01m6 Lasw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=Gu6XrP09brfzVASce66siSDhg75Ij5bF3a/2sse9FTI=; b=OEFJP4hHpcJ5mZLEC32+hAtN2S5l3D/9tztCGnQQoxJCq6MKCpuh7LmvEJtSn20b8u HnM5cDW3jNV7wi/qf6jJ+IpsLuTbas+asG8s73s93QGSaQO9IgAMYiMLnnO6kqA+j3Ib zACM0mr1NKJ9YvFSUk32unYbOyIs9g+BaaqLSI/RGdV1QyQDaU31UaOCurXUZPbsajhG m2YgO0Fy0J+wbMBPrECyO1JA+kbmZhA4FPWJcS0Qm6C+/zkZNDlTKBuLjj8PR8N3mhby OA0t60S1AxA3v+26vnvhbaYrH/i4mivAZCKN0kq9Pqq7fzyMF3u+C6ENiXdCrk/iPndJ YrOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Gx5DLI2+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gl1-20020a1709073c8100b006fe9a0289d5si18491955ejc.885.2022.05.25.01.16.12; Wed, 25 May 2022 01:16:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=Gx5DLI2+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S231371AbiEXPMV (ORCPT + 99 others); Tue, 24 May 2022 11:12:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49588 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238713AbiEXPMR (ORCPT ); Tue, 24 May 2022 11:12:17 -0400 Received: from mail-il1-x136.google.com (mail-il1-x136.google.com [IPv6:2607:f8b0:4864:20::136]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D502A63BC2; Tue, 24 May 2022 08:12:12 -0700 (PDT) Received: by mail-il1-x136.google.com with SMTP id t13so5151443ilm.9; Tue, 24 May 2022 08:12:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Gu6XrP09brfzVASce66siSDhg75Ij5bF3a/2sse9FTI=; b=Gx5DLI2+S6FgASvjmxzOMLEBTLLzoAeOJHUNf3qse7ftzHJRZNKIGlYfA7vzGBgRTO qTgrr/QrMpssZBVPExxUekM5wFpDSCMG20g+mdIisIrrqbSj8j8ach4aeT+H+1CPDjcY ofuIYAFZ0a1ST0nZaCgMaH9g0s8MDKoG8WUVuGjlCh3vgQMUp8zwHIFKbe8dhL1HhQTe sZWf5vyTao7FwxYkNnBY5UxCjXGw7WvpGDwAKwR0hZcAz9ljJn2ttXMG4oHl2DC/BtQd krQkv/WkL/ceZkaPabiR+mwCrn4tbOibG9mbSGHQ9sK9s67DEn4CdB96hUXVE/XXsJbF NRiQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Gu6XrP09brfzVASce66siSDhg75Ij5bF3a/2sse9FTI=; b=437c6i0vOdcyGq0Uidsdb1DAZmgoVljbw7JpnkngKVCpx16FoqkIVmhVun+Hgudw0G T0hkN4P0iBWDOSEUEWRmEseyEYosihqvyTiJvHNJmbrP4WRuDpyAkR20xtTcaBXUF/L7 jdqaFmv+iCpofuroh0gKTXoEDH+/veq0p3L5qKsjb91EKfDaMTPigjCZumSCMKPp4chS E8HcqhTnZChw6GZP4yd963dNqBUdHeowEQocttVICM67T/uSTMPWeSVliZzE4izO/wiW jmQGU27nKAyZMTjKTCAB9zvxP6jYV8HLLf+G+KUVpi4fm96wS4MWcD3a2I/iYF9+CgZZ b4vw== X-Gm-Message-State: AOAM530Aq8eg1igwpWpM1xNfdAUmNjiDhbP++NXEQsBpsev3SFxnmT3b 2MVKlPKozSIAe9OLjdbXyh94uOvHhk6kRvzk7o+TVmHh1qPEnQ== X-Received: by 2002:a05:6e02:170b:b0:2cf:970f:6050 with SMTP id u11-20020a056e02170b00b002cf970f6050mr14549964ill.5.1653405130972; Tue, 24 May 2022 08:12:10 -0700 (PDT) MIME-Version: 1.0 References: <20220523020209.11810-1-ojeda@kernel.org> <20220523020209.11810-22-ojeda@kernel.org> In-Reply-To: From: Miguel Ojeda Date: Tue, 24 May 2022 17:12:00 +0200 Message-ID: Subject: Re: [PATCH v7 21/25] Kbuild: add Rust support To: Nick Desaulniers Cc: Miguel Ojeda , Linus Torvalds , Greg Kroah-Hartman , rust-for-linux , linux-kernel , Jarkko Sakkinen , Alex Gaynor , Finn Behrens , Adam Bratschi-Kaye , Wedson Almeida Filho , Michael Ellerman , Sven Van Asbroeck , Gary Guo , Boris-Chengbiao Zhou , Boqun Feng , Douglas Su , Dariusz Sosnowski , Antonio Terceiro , Daniel Xu , Miguel Cano , David Gow , Masahiro Yamada , Michal Marek , Russell King , Catalin Marinas , Will Deacon , Benjamin Herrenschmidt , Paul Mackerras , Paul Walmsley , Palmer Dabbelt , Albert Ou , Richard Weinberger , Anton Ivanov , Johannes Berg , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "maintainer:X86 ARCHITECTURE (32-BIT AND 64-BIT)" , "H. Peter Anvin" , Linux Kbuild mailing list , Linux ARM , linuxppc-dev , linux-riscv , linux-um@lists.infradead.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 23, 2022 at 8:45 PM Nick Desaulniers wrote: > > I'm super not into having the rust optimization level differ from the > C optimization level. This is just someone having too much fun > wrapping every compiler flag in a kbuild option. Either folks wan't I mean, `Makefile`s are not my favorite pastime... :) > smaller size or more optimizations. Allowing for RUST_OPT_LEVEL_S and > CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE or RUST_OPT_LEVEL_3 and > CONFIG_CC_OPTIMIZE_FOR_SIZE is just wacky nonsense that's going to > make randconfig bug reports more confusing to tease out. I think what is important is to decide whether extra levels, for C and Rust, should be kept compile-able/maintained or not (I also replied in the `-O1` for C thread [1]). Note that the Rust side can be compiled as `-O0` or `-O1` at the moment, which is something we do not have for the C side; thus having only the C == Rust option means we will not have a configuration with those anymore. For me it is less complex to not have them, and I have not heard more opinions on this, either for or against (apart from that thread suggesting `-O1` for the C side), so if nobody else chimes in, I will remove them. [1] https://lore.kernel.org/lkml/CANiq72kySVvOQ7eqwe0Jzz3V0JTtrcqODHR9Ty4-sfDMdzP6XQ@mail.gmail.com/ Cheers, Miguel