Received: from list by lists.gnu.org with archive (Exim 4.90_1) id 1n1Ijr-0006tQ-2l for mharc-qemu-riscv@gnu.org; Sat, 25 Dec 2021 20:54:19 -0500 Received: from eggs.gnu.org ([209.51.188.92]:41278) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n1Ijp-0006t6-2D; Sat, 25 Dec 2021 20:54:17 -0500 Received: from smtp21.cstnet.cn ([159.226.251.21]:51972 helo=cstnet.cn) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n1Ijm-0004IF-UD; Sat, 25 Dec 2021 20:54:16 -0500 Received: from [192.168.0.103] (unknown [180.156.147.178]) by APP-01 (Coremail) with SMTP id qwCowAAHD1c8y8dhmEc3BQ--.59172S2; Sun, 26 Dec 2021 09:54:05 +0800 (CST) Subject: Re: [PATCH 2/6] target/riscv: add support for unique fpr read/write with support for zfinx From: liweiwei To: Richard Henderson , palmer@dabbelt.com, alistair.francis@wdc.com, bin.meng@windriver.com, qemu-riscv@nongnu.org, qemu-devel@nongnu.org Cc: wangjunqiang@iscas.ac.cn, lazyparser@gmail.com, ardxwe@gmail.com References: <20211224034915.17204-1-liweiwei@iscas.ac.cn> <20211224034915.17204-3-liweiwei@iscas.ac.cn> <2acd9ead-d9e8-46be-b306-2aa26ced06b5@iscas.ac.cn> <9ea3554f-367a-bd4e-fc4f-a98367b96260@iscas.ac.cn> Message-ID: <25f6e9a9-ebee-e3d3-9b06-dd4a0d11cd79@iscas.ac.cn> Date: Sun, 26 Dec 2021 09:54:04 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 MIME-Version: 1.0 In-Reply-To: <9ea3554f-367a-bd4e-fc4f-a98367b96260@iscas.ac.cn> Content-Type: multipart/alternative; boundary="------------69C1F999210678B4B68B7B25" Content-Language: en-US X-CM-TRANSID: qwCowAAHD1c8y8dhmEc3BQ--.59172S2 X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cSsGvfC2KfnxnUUI43ZEXa7VUbfcTPUUUUU== X-Originating-IP: [180.156.147.178] X-CM-SenderInfo: 5olzvxxzhlqxpvfd2hldfou0/ Received-SPF: pass client-ip=159.226.251.21; envelope-from=liweiwei@iscas.ac.cn; helo=cstnet.cn X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, HTML_MESSAGE=0.001, NICE_REPLY_A=-0.196, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-riscv@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 26 Dec 2021 01:54:17 -0000 This is a multi-part message in MIME format. --------------69C1F999210678B4B68B7B25 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit OK. It have been changed to sign-extended in the "processing of Narrower Values" section of the new spec(version 1.0.0.rc) . I'll fix this and update other nan-boxing processing in current implementation. 在 2021/12/26 上午9:42, liweiwei 写道: > > Sorry. In the old spec(version 0.41), nanboxing is not totally > disabled, but "NaN-boxing is limited to |XLEN| bits, not |FLEN| bits". > Taking misa.mxl into acount, if misa.mxl is RV32, and maximum is RV64, > this should be sign-extended. Is there any other new update for > nanboxing  to the spec? > > 在 2021/12/26 上午6:00, Richard Henderson 写道: >> On 12/24/21 7:13 PM, liweiwei wrote: >>> In RV64 case, this should be nan-boxing value( upper bits are all >>> ones).  However, zfinx will not check nan-boxing of source, the >>> upper 32 bits have no effect on the final result. So I think both >>> zero-extended or sign-extended are OK. >> >> There is no nanboxing in zfinx at all -- values are sign-extended. >> >> >> r~ --------------69C1F999210678B4B68B7B25 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 8bit

OK. It have been changed to sign-extended in the "processing of Narrower Values" section of the new spec(version 1.0.0.rc) . I'll fix this and update other nan-boxing processing in current implementation.

在 2021/12/26 上午9:42, liweiwei 写道:

Sorry. In the old spec(version 0.41), nanboxing is not totally disabled, but "NaN-boxing is limited to XLEN bits, not FLEN bits". Taking misa.mxl into acount, if misa.mxl is RV32, and maximum is RV64, this should be sign-extended. Is there any other new update for nanboxing  to the spec?

在 2021/12/26 上午6:00, Richard Henderson 写道:
On 12/24/21 7:13 PM, liweiwei wrote:
In RV64 case, this should be nan-boxing value( upper bits are all ones).  However, zfinx will not check nan-boxing of source, the upper 32 bits have no effect on the final result. So I think both zero-extended or sign-extended are OK.

There is no nanboxing in zfinx at all -- values are sign-extended.


r~
--------------69C1F999210678B4B68B7B25--