This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Math errors
- From: Jonathan Nieder <jrnieder at gmail dot com>
- To: Alistair Francis <alistair23 at gmail dot com>
- Cc: Jim Wilson <jimw at sifive dot com>, Joseph Myers <joseph at codesourcery dot com>, GNU C Library <libc-alpha at sourceware dot org>
- Date: Tue, 14 Jan 2020 02:28:56 +0000
- Subject: Re: Math errors
- References: <CAKmqyKNQXGVriszbWvfyAys-8aoe-ShWDqXr9H7fMs9M8Htm5A@mail.gmail.com> <alpine.DEB.2.21.1912302227040.17472@digraph.polyomino.org.uk> <alpine.DEB.2.21.1912302229041.17472@digraph.polyomino.org.uk> <CAKmqyKO6tkQjTkP85z3PoX13Y+Xgd1S6zZZo0HjZQsSMW=E=9A@mail.gmail.com> <CAFyWVaYqcvNuLM9oE2GYGN82CBGGHbYJz=cZQYGJNySzJzUbpA@mail.gmail.com> <CAKmqyKOfm8pcJYPkZyp89WL+t7WMnmRJL3rXALYokj1A3pdu8g@mail.gmail.com> <CAFyWVaYFRAVd7bWTGpw-iqYn3iwEVwT7B=PQpjaD_gOC+=Pcbg@mail.gmail.com> <CAKmqyKOSqsUeADkB3KDCxj67AHix7jrexDetRcG-xLbQVr3E7g@mail.gmail.com>
Hi,
Alistair Francis wrote:
> On Wed, Jan 8, 2020 at 4:29 AM Jim Wilson <jimw@sifive.com> wrote:
>> On Mon, Jan 6, 2020 at 5:33 PM Alistair Francis <alistair23@gmail.com> wrote:
>>> I have the latest 5.4.x kernel, I'm not sure if that has it or not.
>>
>> I don't know. I don't follow linux kernel development that closely.
>> But the failures I sometimes see are test-fenv and test-fpucw which I
>> don't see in your list.
>>
>> I only run glibc testsuite on hardware though, and I've only been
>> testing rv64gc support. I haven't tried qemu. In the RISC-V software
>> meeting this morning, Palmer mentioned that there are some known
>> RISC-V qemu FP bugs, for instance fcmp doesn't set the FP reg dirty
>> bit when an exception flag is set, which could cause a testcase
>> failure if a context switch happens at the wrong time. This could
>
> I have noticed that running the tests not in parallel gives much better results
Interesting. Can you provide full "uname -r" output? What Linux
distribution do you use?
I suspect the issue Jim mentioned is fixed by v5.3-rc5~12^2~1 ("riscv:
Correct the initialized flow of FP register", 2019-08-14), which you
would already have. That said, the 5.5-rc series has some more fp reg
handling fixes.
[...]
>> Someone will have to look at the rv32gc math failures, and keep an
>> open mind that they could be glibc, qemu, gcc, linux kernel, etc
>
> Yeah, that's what I was thinking. There are only a few math tests left
> failing, so it's not too bad. Thanks for the information Jim.
That it appears more often with threading does suggest some kind of FP
register leakage.
Thanks and happy hunting,
Jonathan