From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mengyan1223.wang (mengyan1223.wang [89.208.246.23]) by sourceware.org (Postfix) with ESMTPS id 39147385841F for ; Thu, 24 Feb 2022 19:32:15 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 39147385841F Received: from [IPv6:240e:358:1147:5a00:dc73:854d:832e:4] (unknown [IPv6:240e:358:1147:5a00:dc73:854d:832e:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-384) server-digest SHA384) (Client did not present a certificate) (Authenticated sender: xry111@mengyan1223.wang) by mengyan1223.wang (Postfix) with ESMTPSA id F20B465EEB; Thu, 24 Feb 2022 14:32:10 -0500 (EST) Message-ID: <116a44c84b7986d4b3f2808242e38c2a34a3b2a2.camel@mengyan1223.wang> Subject: Re: [PATCH v7 11/12] LoongArch Port: gcc/testsuite From: Xi Ruoyao To: xuchenghua@loongson.cn, gcc-patches@gcc.gnu.org Cc: chenglulu@loongson.cn, joseph@codesourcery.com Date: Fri, 25 Feb 2022 03:32:04 +0800 In-Reply-To: <20220212031142.1165933-12-xuchenghua@loongson.cn> References: <20220212031142.1165933-1-xuchenghua@loongson.cn> <20220212031142.1165933-12-xuchenghua@loongson.cn> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.42.4 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3030.0 required=5.0 tests=BAYES_00, BODY_8BITS, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, JMQ_SPF_NEUTRAL, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Feb 2022 19:32:16 -0000 On Sat, 2022-02-12 at 11:11 +0800, xuchenghua@loongson.cn wrote: > From: chenglulu > > 2022-02-12  Chenghua Xu  >             Lulu Cheng  > > gcc/testsuite/ spec-barrier tests fail with: ./testsuite/c-c++-common/spec-barrier-1.c:21:3: warning: this target does not define a speculation barrier; your program will still execute correctly, but incorrect speculation may not be restricted I'd seen some news saying your uarch has in-silicon defense for speculation related vulnerabilities. If this is true you can just make __builtin_speculation_safe_value a nop. Quote from gcc internal doc: > If this pattern is not defined then the default expansion of > '__builtin_speculation_safe_value' will emit a warning. You can > suppress this warning by defining this pattern with a final > condition of '0' (zero), which tells the compiler that a > speculation barrier is not needed for this target. -- Xi Ruoyao School of Aerospace Science and Technology, Xidian University