From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from xry111.site (xry111.site [89.208.246.23]) by sourceware.org (Postfix) with ESMTPS id 2D3783858418 for ; Wed, 13 Jul 2022 03:07:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 2D3783858418 Received: from localhost.localdomain (xry111.site [IPv6:2001:470:683e::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-384)) (Client did not present a certificate) (Authenticated sender: xry111@xry111.site) by xry111.site (Postfix) with ESMTPSA id C2FE5668C9; Tue, 12 Jul 2022 23:07:22 -0400 (EDT) Message-ID: Subject: Re: [PATCH v6 11/13] LoongArch: Build Infastructure From: Xi Ruoyao To: caiyinyu , libc-alpha@sourceware.org Cc: adhemerval.zanella@linaro.or, joseph_myers@mentor.com, i@xen0n.name Date: Wed, 13 Jul 2022 11:07:21 +0800 In-Reply-To: <20220708065255.2316410-12-caiyinyu@loongson.cn> References: <20220708065255.2316410-1-caiyinyu@loongson.cn> <20220708065255.2316410-12-caiyinyu@loongson.cn> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.44.3 MIME-Version: 1.0 X-Spam-Status: No, score=-1.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FROM_SUSPICIOUS_NTLD, LIKELY_SPAM_FROM, PDS_OTHER_BAD_TLD, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Jul 2022 03:07:26 -0000 On Fri, 2022-07-08 at 14:52 +0800, caiyinyu wrote: > grlen=3D`$CC $CFLAGS $CPPFLAGS -E -dM -xc /dev/null | sed -n 's/^#define = __loongarch_grlen \(.*\)/\1/p'` I suggest to use "__loongarch_lp64" for checking ABI grlen. Consider: "gcc -march=3Dla464 -mabi=3Dilp32d ..." Once ILP32 ABIs are available, will __loongarch_grlen be 64 or 32 in this case, where the hardware has 64-bit registers but the ABI uses them as 32-bit? Our documentation is not clear about this question and currently we understand __loongarch_grlen as hardware GR length instead of the register length used in ABI [1]. [1]:https://github.com/loongson/LoongArch-Documentation/pull/28#discussion_= r917364055 OTOH if you think "we should define __loongarch_grlen as the register length for ABI, irrelevant to the hardware", you need to inform your colleagues to clarify it in the doc. --=20 Xi Ruoyao School of Aerospace Science and Technology, Xidian University