From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-x42e.google.com (mail-wr1-x42e.google.com [IPv6:2a00:1450:4864:20::42e]) by sourceware.org (Postfix) with ESMTPS id 51C633858CDB for ; Fri, 26 May 2023 13:19:42 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 51C633858CDB Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=embecosm.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=embecosm.com Received: by mail-wr1-x42e.google.com with SMTP id ffacd0b85a97d-3090d3e9c92so680719f8f.2 for ; Fri, 26 May 2023 06:19:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=embecosm.com; s=google; t=1685107180; x=1687699180; h=mime-version:user-agent:references:message-id:in-reply-to:subject :cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=dauOXsJjUvivr86sPD7fC9iZhn9pfmFgtQHI/XQ0bBA=; b=WIyANK1JtlC4reElndDSiOsEar4Znaor25Y/lLrYoOhUCujd6tLc2EGvNKIMSsMrJf V+m7A8i+omlTvwqiWcrmLgDE9G/MVrrvrbyL3eGtS/5E9r2EDLRrtsRjUe7e0+sTSLEb VCD1itXExL8ZyII4ByZa6Thg2vIdUJpPg0wNx4hA5ArSNUia1zjDq1taLY5O45oxYwYZ CUPX+m7lcwm6wDj5ko+RQDPmi+1+dj5yr6lBUDLSICigaTfS0ZtsnUSG1IqArw3KAHU0 8jg4aBvlG+HcaK0HZ9aHXSGC9wWYUNNz5viJkWP0KWKrMjf0kv12HOm0V0TLzpvwnoB1 TyLQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685107180; x=1687699180; h=mime-version:user-agent:references:message-id:in-reply-to:subject :cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=dauOXsJjUvivr86sPD7fC9iZhn9pfmFgtQHI/XQ0bBA=; b=QMeAiS+Ywoo9p0LW/Dt8UbT1oLNKN02Wg3zk71Uzb0PQsLZyFNrLA7YEIRbg2jGaB7 uYwjCHCZjU+fNIZ++BdBLrPoqHyish5OMdVXf/JHGZo+RoNEmmjGpNw/NK5Fsm6zBYHW +x2n6BmXgP3pd+4ZUrJVwFis1OVIfZWocfJgMizFwkHqE14hemcWap9a74qQz1U/fK4K 2qnn1f8d1uIRbBFN5IHjR3WC/I4wJ5Y+5wYD+4824f9/qDlC6GkyYBRQZ3kO2rwnayN1 e4ohA1jaE96hEVQm/2iE5lu6M4A5zIl+Sfj7eWEMwJf9maiBNbByFWyVlxBQKI5qw2yA xsrQ== X-Gm-Message-State: AC+VfDwY+PLceLPSqK9cA4T+5lOkjvJ2YSCLWttp8iel2E/DFKWLI33M RH7IAXNcPHuteCNimihwVcOSjw== X-Google-Smtp-Source: ACHHUZ55P+36yWnabuuqtoHMkBglPg+NfPA+vLwdmvFVesc5IG21OWCR3tAU1Izksg13AXENFyP42A== X-Received: by 2002:adf:f3c9:0:b0:30a:c35d:25d3 with SMTP id g9-20020adff3c9000000b0030ac35d25d3mr1670595wrp.52.1685107180572; Fri, 26 May 2023 06:19:40 -0700 (PDT) Received: from tpp.orcam.me.uk (tpp.orcam.me.uk. [2001:8b0:154:0:ea6a:64ff:fe24:f2fc]) by smtp.gmail.com with ESMTPSA id q10-20020adfdfca000000b003078681a1e8sm5114798wrn.54.2023.05.26.06.19.39 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 26 May 2023 06:19:39 -0700 (PDT) Date: Fri, 26 May 2023 14:19:38 +0100 (BST) From: "Maciej W. Rozycki" To: Jin Ma cc: gcc-patches@gcc.gnu.org, jeffreyalaw@gmail.com, kito.cheng@gmail.com, christoph.muellner@vrull.eu, jinma.contrib@gmail.com Subject: Re: [PATCH] RISC-V: Add the option "-mdisable-multilib-check" to avoid multilib checks breaking the compilation. In-Reply-To: <20230523044202.1201-1-jinma@linux.alibaba.com> Message-ID: References: <20230523044202.1201-1-jinma@linux.alibaba.com> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,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 server2.sourceware.org List-Id: On Tue, 23 May 2023, Jin Ma via Gcc-patches wrote: > When testing a extension, it is often necessary for a certain program not to > need some kind of extension, such as the bitmanip extension, to evaluate the > performance or codesize of the extension. However, the current multilib rules > will report an error when it is not a superset of the MULTILIB_REQUIRED list, > which will cause the program to be unable to link normally, thus failing to > achieve the expected purpose. Hmm, I have troubles understanding what is going on here. What do you refer to by saying: "it is not a superset of the MULTILIB_REQUIRED list"? There should be no problem with linking compiled modules together that make use of different extensions, with the static linker figuring out the combined set of extensions actually required at run time for the program loader to consider, as long as the modules do not have contradicting requirements, e.g. big vs little endianness or RV32 vs RV64. Can you give me a specific example (compilation options and multilibs available) of a failure you refer to? Is this something that could be solved without resorting to a possibly dangerous hack, by making use of MULTILIB_REUSE? Maciej