Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B6123C433E1 for ; Tue, 25 Aug 2020 08:09:00 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8474F2075B for ; Tue, 25 Aug 2020 08:09:00 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8474F2075B Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1kAU0Y-0007fy-84; Tue, 25 Aug 2020 08:08:42 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1kAU0X-0007ft-Kf for xen-devel@lists.xenproject.org; Tue, 25 Aug 2020 08:08:41 +0000 X-Inumbo-ID: 761a0939-de7e-40cf-9db2-3ea7ad24052f Received: from mx2.suse.de (unknown [195.135.220.15]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id 761a0939-de7e-40cf-9db2-3ea7ad24052f; Tue, 25 Aug 2020 08:08:40 +0000 (UTC) X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 56CA6B1E9; Tue, 25 Aug 2020 08:09:10 +0000 (UTC) Subject: Re: Kconfig vs tool chain capabilities To: Jan Beulich Cc: "xen-devel@lists.xenproject.org" , Andrew Cooper , Anthony Perard References: <6d5a2014-5184-04f0-62f9-60ddd7537886@suse.com> <4449ee1b-6d2c-70f2-d8e9-80397aeffa41@suse.com> From: =?UTF-8?B?SsO8cmdlbiBHcm/Dnw==?= Message-ID: <61d2adc1-c28f-7ed6-237e-45444249173c@suse.com> Date: Tue, 25 Aug 2020 10:08:39 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" On 25.08.20 09:48, Jan Beulich wrote: > On 25.08.2020 09:43, Jürgen Groß wrote: >> On 25.08.20 09:34, Jan Beulich wrote: >>> On 25.08.2020 09:12, Jürgen Groß wrote: >>>> I think both problems can be solved at the same time via the following >>>> approach: >>>> >>>> - collect the data which is reflected in today's CONFIG_ variables in a >>>> single script and store it in a file, e.g in a format like: >>>> >>>> CC_IS_GCC y >>>> GCC_VERSION 70500 >>>> CLANG_VERSION 0 >>>> CC_HAS_VISIBILITY_ATTRIBUTE y >>>> >>>> - check the tool data at each build to match the contents of that file >>>> and either fail the build or update the file and rerun kconfig if they >>>> don't match (I think failing the build and requiring to run a >>>> "make config" would be the better approach) >>>> >>>> - fill the CONFIG_ variable contents from that file in kconfig instead >>>> of issuing the single shell commands >>> >>> While I agree this is a possible model to use (but still not the >>> one we've inherited from Linux), I fail to see how this addresses >>> my "developers should be aware of what they do (not) build and >>> test" concern: There'd still be dependencies of Kconfig options >>> on the tool chain capabilities, and their prompts therefore would >>> still be invisible without the tool chain having the needed >>> capabilities. IOW I only see this to address 2), but not 1). >> >> Sorry, I fail to see a problem here. >> >> What sense does it make to be able to configure an option which the >> tools don't support? > > Take CET as an example (chosen because that's the one which > already uses the Kconfig approach, despite my disagreement): It's > quite relevant to know whether you're testing Xen with it enabled, > or with it disabled (and hence you potentially missing changes you > need to make to relevant code portions). Correct me if I'm wrong, but assuming my suggested changes being made, wouldn't a .config file setup once with CET enabled (and I assume you'd try to enable CET on purpose when trying to test CET and you'd realize not being able to do so in case your tools don't support CET) ensure you'd never been hit by surprise when some tool updates would remove CET support? > >> Why aren't you concerned that you can't configure >> ARM-specific options in an x86 build then? > > I can't see how this is related. You are asking for a way to select options not supported by the tools. This is very similar to asking for the possibility to select options not supported by the architecture. Juergen