From: "Alex Bennée" <alex.bennee@linaro.org>
To: "Emilio G. Cota" <cota@braap.org>
Cc: peter.maydell@linaro.org, qemu-devel@nongnu.org,
Aurelien Jarno <aurelien@aurel32.net>
Subject: Re: [Qemu-devel] [PULL v3 08/15] tests/fp: add fp-bench
Date: Tue, 18 Dec 2018 10:53:00 +0000 [thread overview]
Message-ID: <87tvjb9kdv.fsf@linaro.org> (raw)
In-Reply-To: <20181218014707.GA10098@flamenco>
Emilio G. Cota <cota@braap.org> writes:
> On Mon, Dec 17, 2018 at 10:56:43 +0000, Alex Bennée wrote:
>> From: "Emilio G. Cota" <cota@braap.org>
>> +static void update_random_ops(int n_ops, enum precision prec)
>> +{
>> + int i;
>> +
>> + for (i = 0; i < n_ops; i++) {
>> + uint64_t r = random_ops[i];
>> +
>> + if (prec == PREC_SINGLE || PREC_FLOAT32) {
>> + do {
>> + r = xorshift64star(r);
>> + } while (!float32_is_normal(r));
>> + } else if (prec == PREC_DOUBLE || PREC_FLOAT64) {
>
> I just noticed that there's a bug here (I was seeing non-normals
> where I didn't expect any):
>
> for (i = 0; i < n_ops; i++) {
> uint64_t r = random_ops[i];
>
> - if (prec == PREC_SINGLE || PREC_FLOAT32) {
> + if (prec == PREC_SINGLE || prec == PREC_FLOAT32) {
> do {
> r = xorshift64star(r);
> } while (!float32_is_normal(r));
> - } else if (prec == PREC_DOUBLE || PREC_FLOAT64) {
> + } else if (prec == PREC_DOUBLE || prec == PREC_FLOAT64) {
> do {
> r = xorshift64star(r);
> } while (!float64_is_normal(r));
>
> Let me know if you want me to send a proper patch (this is non-critical
> so it's OK to fix after merging) or you'd rather fix it up directly.
<snip>
I'll fix it up an resubmit - I suspect it won't get merged until the new
year now anyway.
--
Alex Bennée
next prev parent reply other threads:[~2018-12-18 11:09 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-17 10:56 [Qemu-devel] [PULL v3 00/15] Hardfloat + softfloat maintainers update and gitdm Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 01/15] contrib: add a basic gitdm config Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 02/15] MAINTAINERS: update status of FPU emulation Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 03/15] fp-test: pick TARGET_ARM to get its specialization Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 04/15] softfloat: add float{32, 64}_is_{de, }normal Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 05/15] target/tricore: use float32_is_denormal Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 06/15] softfloat: rename canonicalize to sf_canonicalize Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 07/15] softfloat: add float{32, 64}_is_zero_or_normal Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 08/15] tests/fp: add fp-bench Alex Bennée
2018-12-18 1:47 ` Emilio G. Cota
2018-12-18 10:53 ` Alex Bennée [this message]
2018-12-18 14:38 ` Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 09/15] fpu: introduce hardfloat Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 10/15] hardfloat: implement float32/64 addition and subtraction Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 11/15] hardfloat: implement float32/64 multiplication Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 12/15] hardfloat: implement float32/64 division Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 13/15] hardfloat: implement float32/64 fused multiply-add Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 14/15] hardfloat: implement float32/64 square root Alex Bennée
2018-12-17 10:56 ` [Qemu-devel] [PULL v3 15/15] hardfloat: implement float32/64 comparison Alex Bennée
2018-12-18 14:08 ` [Qemu-devel] [PULL v3 00/15] Hardfloat + softfloat maintainers update and gitdm Peter Maydell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87tvjb9kdv.fsf@linaro.org \
--to=alex.bennee@linaro.org \
--cc=aurelien@aurel32.net \
--cc=cota@braap.org \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).